ent

package
v0.0.0-...-5435fe0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 29, 2022 License: MIT Imports: 44 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Operation types.
	OpCreate    = ent.OpCreate
	OpDelete    = ent.OpDelete
	OpDeleteOne = ent.OpDeleteOne
	OpUpdate    = ent.OpUpdate
	OpUpdateOne = ent.OpUpdateOne

	// Node types.
	TypeDiscordAccount           = "DiscordAccount"
	TypeDiscordBot               = "DiscordBot"
	TypeGithubAccount            = "GithubAccount"
	TypeGithubOrganization       = "GithubOrganization"
	TypeGithubOrganizationMember = "GithubOrganizationMember"
	TypeProject                  = "Project"
	TypeProjectAssociation       = "ProjectAssociation"
	TypeProjectContributor       = "ProjectContributor"
	TypeProjectTechnology        = "ProjectTechnology"
	TypeRepository               = "Repository"
	TypeRepositoryTechnology     = "RepositoryTechnology"
	TypeSite                     = "Site"
	TypeTechnology               = "Technology"
	TypeTechnologyAssociation    = "TechnologyAssociation"
	TypeUser                     = "User"
)

Variables

View Source
var (
	// DiscordAccountOrderFieldDiscordID orders DiscordAccount by discord_id.
	DiscordAccountOrderFieldDiscordID = &DiscordAccountOrderField{
		field: discordaccount.FieldDiscordID,
		toCursor: func(da *DiscordAccount) Cursor {
			return Cursor{
				ID:    da.ID,
				Value: da.DiscordID,
			}
		},
	}
	// DiscordAccountOrderFieldUsername orders DiscordAccount by username.
	DiscordAccountOrderFieldUsername = &DiscordAccountOrderField{
		field: discordaccount.FieldUsername,
		toCursor: func(da *DiscordAccount) Cursor {
			return Cursor{
				ID:    da.ID,
				Value: da.Username,
			}
		},
	}
	// DiscordAccountOrderFieldDiscriminator orders DiscordAccount by discriminator.
	DiscordAccountOrderFieldDiscriminator = &DiscordAccountOrderField{
		field: discordaccount.FieldDiscriminator,
		toCursor: func(da *DiscordAccount) Cursor {
			return Cursor{
				ID:    da.ID,
				Value: da.Discriminator,
			}
		},
	}
)
View Source
var (
	// GithubOrganizationOrderFieldName orders GithubOrganization by name.
	GithubOrganizationOrderFieldName = &GithubOrganizationOrderField{
		field: githuborganization.FieldName,
		toCursor: func(_go *GithubOrganization) Cursor {
			return Cursor{
				ID:    _go.ID,
				Value: _go.Name,
			}
		},
	}
	// GithubOrganizationOrderFieldDisplayName orders GithubOrganization by display_name.
	GithubOrganizationOrderFieldDisplayName = &GithubOrganizationOrderField{
		field: githuborganization.FieldDisplayName,
		toCursor: func(_go *GithubOrganization) Cursor {
			return Cursor{
				ID:    _go.ID,
				Value: _go.DisplayName,
			}
		},
	}
)
View Source
var (
	// ProjectOrderFieldName orders Project by name.
	ProjectOrderFieldName = &ProjectOrderField{
		field: project.FieldName,
		toCursor: func(pr *Project) Cursor {
			return Cursor{
				ID:    pr.ID,
				Value: pr.Name,
			}
		},
	}
	// ProjectOrderFieldDescription orders Project by description.
	ProjectOrderFieldDescription = &ProjectOrderField{
		field: project.FieldDescription,
		toCursor: func(pr *Project) Cursor {
			return Cursor{
				ID:    pr.ID,
				Value: pr.Description,
			}
		},
	}
	// ProjectOrderFieldStartDate orders Project by start_date.
	ProjectOrderFieldStartDate = &ProjectOrderField{
		field: project.FieldStartDate,
		toCursor: func(pr *Project) Cursor {
			return Cursor{
				ID:    pr.ID,
				Value: pr.StartDate,
			}
		},
	}
	// ProjectOrderFieldEndDate orders Project by end_date.
	ProjectOrderFieldEndDate = &ProjectOrderField{
		field: project.FieldEndDate,
		toCursor: func(pr *Project) Cursor {
			return Cursor{
				ID:    pr.ID,
				Value: pr.EndDate,
			}
		},
	}
)
View Source
var (
	// RepositoryOrderFieldName orders Repository by name.
	RepositoryOrderFieldName = &RepositoryOrderField{
		field: repository.FieldName,
		toCursor: func(r *Repository) Cursor {
			return Cursor{
				ID:    r.ID,
				Value: r.Name,
			}
		},
	}
	// RepositoryOrderFieldDescription orders Repository by description.
	RepositoryOrderFieldDescription = &RepositoryOrderField{
		field: repository.FieldDescription,
		toCursor: func(r *Repository) Cursor {
			return Cursor{
				ID:    r.ID,
				Value: r.Description,
			}
		},
	}
)
View Source
var (
	// TechnologyOrderFieldName orders Technology by name.
	TechnologyOrderFieldName = &TechnologyOrderField{
		field: technology.FieldName,
		toCursor: func(t *Technology) Cursor {
			return Cursor{
				ID:    t.ID,
				Value: t.Name,
			}
		},
	}
	// TechnologyOrderFieldDescription orders Technology by description.
	TechnologyOrderFieldDescription = &TechnologyOrderField{
		field: technology.FieldDescription,
		toCursor: func(t *Technology) Cursor {
			return Cursor{
				ID:    t.ID,
				Value: t.Description,
			}
		},
	}
	// TechnologyOrderFieldColour orders Technology by colour.
	TechnologyOrderFieldColour = &TechnologyOrderField{
		field: technology.FieldColour,
		toCursor: func(t *Technology) Cursor {
			return Cursor{
				ID:    t.ID,
				Value: t.Colour,
			}
		},
	}
	// TechnologyOrderFieldType orders Technology by type.
	TechnologyOrderFieldType = &TechnologyOrderField{
		field: technology.FieldType,
		toCursor: func(t *Technology) Cursor {
			return Cursor{
				ID:    t.ID,
				Value: t.Type,
			}
		},
	}
)
View Source
var DefaultDiscordAccountOrder = &DiscordAccountOrder{
	Direction: OrderDirectionAsc,
	Field: &DiscordAccountOrderField{
		field: discordaccount.FieldID,
		toCursor: func(da *DiscordAccount) Cursor {
			return Cursor{ID: da.ID}
		},
	},
}

DefaultDiscordAccountOrder is the default ordering of DiscordAccount.

View Source
var DefaultDiscordBotOrder = &DiscordBotOrder{
	Direction: OrderDirectionAsc,
	Field: &DiscordBotOrderField{
		field: discordbot.FieldID,
		toCursor: func(db *DiscordBot) Cursor {
			return Cursor{ID: db.ID}
		},
	},
}

DefaultDiscordBotOrder is the default ordering of DiscordBot.

View Source
var DefaultGithubAccountOrder = &GithubAccountOrder{
	Direction: OrderDirectionAsc,
	Field: &GithubAccountOrderField{
		field: githubaccount.FieldID,
		toCursor: func(ga *GithubAccount) Cursor {
			return Cursor{ID: ga.ID}
		},
	},
}

DefaultGithubAccountOrder is the default ordering of GithubAccount.

View Source
var DefaultGithubOrganizationMemberOrder = &GithubOrganizationMemberOrder{
	Direction: OrderDirectionAsc,
	Field: &GithubOrganizationMemberOrderField{
		field: githuborganizationmember.FieldID,
		toCursor: func(gom *GithubOrganizationMember) Cursor {
			return Cursor{ID: gom.ID}
		},
	},
}

DefaultGithubOrganizationMemberOrder is the default ordering of GithubOrganizationMember.

View Source
var DefaultGithubOrganizationOrder = &GithubOrganizationOrder{
	Direction: OrderDirectionAsc,
	Field: &GithubOrganizationOrderField{
		field: githuborganization.FieldID,
		toCursor: func(_go *GithubOrganization) Cursor {
			return Cursor{ID: _go.ID}
		},
	},
}

DefaultGithubOrganizationOrder is the default ordering of GithubOrganization.

View Source
var DefaultProjectAssociationOrder = &ProjectAssociationOrder{
	Direction: OrderDirectionAsc,
	Field: &ProjectAssociationOrderField{
		field: projectassociation.FieldID,
		toCursor: func(pa *ProjectAssociation) Cursor {
			return Cursor{ID: pa.ID}
		},
	},
}

DefaultProjectAssociationOrder is the default ordering of ProjectAssociation.

View Source
var DefaultProjectContributorOrder = &ProjectContributorOrder{
	Direction: OrderDirectionAsc,
	Field: &ProjectContributorOrderField{
		field: projectcontributor.FieldID,
		toCursor: func(pc *ProjectContributor) Cursor {
			return Cursor{ID: pc.ID}
		},
	},
}

DefaultProjectContributorOrder is the default ordering of ProjectContributor.

View Source
var DefaultProjectOrder = &ProjectOrder{
	Direction: OrderDirectionAsc,
	Field: &ProjectOrderField{
		field: project.FieldID,
		toCursor: func(pr *Project) Cursor {
			return Cursor{ID: pr.ID}
		},
	},
}

DefaultProjectOrder is the default ordering of Project.

View Source
var DefaultProjectTechnologyOrder = &ProjectTechnologyOrder{
	Direction: OrderDirectionAsc,
	Field: &ProjectTechnologyOrderField{
		field: projecttechnology.FieldID,
		toCursor: func(pt *ProjectTechnology) Cursor {
			return Cursor{ID: pt.ID}
		},
	},
}

DefaultProjectTechnologyOrder is the default ordering of ProjectTechnology.

View Source
var DefaultRepositoryOrder = &RepositoryOrder{
	Direction: OrderDirectionAsc,
	Field: &RepositoryOrderField{
		field: repository.FieldID,
		toCursor: func(r *Repository) Cursor {
			return Cursor{ID: r.ID}
		},
	},
}

DefaultRepositoryOrder is the default ordering of Repository.

View Source
var DefaultRepositoryTechnologyOrder = &RepositoryTechnologyOrder{
	Direction: OrderDirectionAsc,
	Field: &RepositoryTechnologyOrderField{
		field: repositorytechnology.FieldID,
		toCursor: func(rt *RepositoryTechnology) Cursor {
			return Cursor{ID: rt.ID}
		},
	},
}

DefaultRepositoryTechnologyOrder is the default ordering of RepositoryTechnology.

View Source
var DefaultSiteOrder = &SiteOrder{
	Direction: OrderDirectionAsc,
	Field: &SiteOrderField{
		field: site.FieldID,
		toCursor: func(s *Site) Cursor {
			return Cursor{ID: s.ID}
		},
	},
}

DefaultSiteOrder is the default ordering of Site.

View Source
var DefaultTechnologyAssociationOrder = &TechnologyAssociationOrder{
	Direction: OrderDirectionAsc,
	Field: &TechnologyAssociationOrderField{
		field: technologyassociation.FieldID,
		toCursor: func(ta *TechnologyAssociation) Cursor {
			return Cursor{ID: ta.ID}
		},
	},
}

DefaultTechnologyAssociationOrder is the default ordering of TechnologyAssociation.

View Source
var DefaultTechnologyOrder = &TechnologyOrder{
	Direction: OrderDirectionAsc,
	Field: &TechnologyOrderField{
		field: technology.FieldID,
		toCursor: func(t *Technology) Cursor {
			return Cursor{ID: t.ID}
		},
	},
}

DefaultTechnologyOrder is the default ordering of Technology.

View Source
var DefaultUserOrder = &UserOrder{
	Direction: OrderDirectionAsc,
	Field: &UserOrderField{
		field: user.FieldID,
		toCursor: func(u *User) Cursor {
			return Cursor{ID: u.ID}
		},
	},
}

DefaultUserOrder is the default ordering of User.

View Source
var ErrEmptyDiscordAccountWhereInput = errors.New("ent: empty predicate DiscordAccountWhereInput")

ErrEmptyDiscordAccountWhereInput is returned in case the DiscordAccountWhereInput is empty.

View Source
var ErrEmptyDiscordBotWhereInput = errors.New("ent: empty predicate DiscordBotWhereInput")

ErrEmptyDiscordBotWhereInput is returned in case the DiscordBotWhereInput is empty.

View Source
var ErrEmptyGithubAccountWhereInput = errors.New("ent: empty predicate GithubAccountWhereInput")

ErrEmptyGithubAccountWhereInput is returned in case the GithubAccountWhereInput is empty.

View Source
var ErrEmptyGithubOrganizationMemberWhereInput = errors.New("ent: empty predicate GithubOrganizationMemberWhereInput")

ErrEmptyGithubOrganizationMemberWhereInput is returned in case the GithubOrganizationMemberWhereInput is empty.

View Source
var ErrEmptyGithubOrganizationWhereInput = errors.New("ent: empty predicate GithubOrganizationWhereInput")

ErrEmptyGithubOrganizationWhereInput is returned in case the GithubOrganizationWhereInput is empty.

View Source
var ErrEmptyProjectAssociationWhereInput = errors.New("ent: empty predicate ProjectAssociationWhereInput")

ErrEmptyProjectAssociationWhereInput is returned in case the ProjectAssociationWhereInput is empty.

View Source
var ErrEmptyProjectContributorWhereInput = errors.New("ent: empty predicate ProjectContributorWhereInput")

ErrEmptyProjectContributorWhereInput is returned in case the ProjectContributorWhereInput is empty.

View Source
var ErrEmptyProjectTechnologyWhereInput = errors.New("ent: empty predicate ProjectTechnologyWhereInput")

ErrEmptyProjectTechnologyWhereInput is returned in case the ProjectTechnologyWhereInput is empty.

View Source
var ErrEmptyProjectWhereInput = errors.New("ent: empty predicate ProjectWhereInput")

ErrEmptyProjectWhereInput is returned in case the ProjectWhereInput is empty.

View Source
var ErrEmptyRepositoryTechnologyWhereInput = errors.New("ent: empty predicate RepositoryTechnologyWhereInput")

ErrEmptyRepositoryTechnologyWhereInput is returned in case the RepositoryTechnologyWhereInput is empty.

View Source
var ErrEmptyRepositoryWhereInput = errors.New("ent: empty predicate RepositoryWhereInput")

ErrEmptyRepositoryWhereInput is returned in case the RepositoryWhereInput is empty.

View Source
var ErrEmptySiteWhereInput = errors.New("ent: empty predicate SiteWhereInput")

ErrEmptySiteWhereInput is returned in case the SiteWhereInput is empty.

View Source
var ErrEmptyTechnologyAssociationWhereInput = errors.New("ent: empty predicate TechnologyAssociationWhereInput")

ErrEmptyTechnologyAssociationWhereInput is returned in case the TechnologyAssociationWhereInput is empty.

View Source
var ErrEmptyTechnologyWhereInput = errors.New("ent: empty predicate TechnologyWhereInput")

ErrEmptyTechnologyWhereInput is returned in case the TechnologyWhereInput is empty.

View Source
var ErrEmptyUserWhereInput = errors.New("ent: empty predicate UserWhereInput")

ErrEmptyUserWhereInput is returned in case the UserWhereInput is empty.

View Source
var (
	// GithubAccountOrderFieldUsername orders GithubAccount by username.
	GithubAccountOrderFieldUsername = &GithubAccountOrderField{
		field: githubaccount.FieldUsername,
		toCursor: func(ga *GithubAccount) Cursor {
			return Cursor{
				ID:    ga.ID,
				Value: ga.Username,
			}
		},
	}
)
View Source
var (
	// GithubOrganizationMemberOrderFieldRole orders GithubOrganizationMember by role.
	GithubOrganizationMemberOrderFieldRole = &GithubOrganizationMemberOrderField{
		field: githuborganizationmember.FieldRole,
		toCursor: func(gom *GithubOrganizationMember) Cursor {
			return Cursor{
				ID:    gom.ID,
				Value: gom.Role,
			}
		},
	}
)
View Source
var (
	// ProjectAssociationOrderFieldType orders ProjectAssociation by type.
	ProjectAssociationOrderFieldType = &ProjectAssociationOrderField{
		field: projectassociation.FieldType,
		toCursor: func(pa *ProjectAssociation) Cursor {
			return Cursor{
				ID:    pa.ID,
				Value: pa.Type,
			}
		},
	}
)
View Source
var (
	// ProjectContributorOrderFieldRole orders ProjectContributor by role.
	ProjectContributorOrderFieldRole = &ProjectContributorOrderField{
		field: projectcontributor.FieldRole,
		toCursor: func(pc *ProjectContributor) Cursor {
			return Cursor{
				ID:    pc.ID,
				Value: pc.Role,
			}
		},
	}
)
View Source
var (
	// ProjectTechnologyOrderFieldType orders ProjectTechnology by type.
	ProjectTechnologyOrderFieldType = &ProjectTechnologyOrderField{
		field: projecttechnology.FieldType,
		toCursor: func(pt *ProjectTechnology) Cursor {
			return Cursor{
				ID:    pt.ID,
				Value: pt.Type,
			}
		},
	}
)
View Source
var (
	// RepositoryTechnologyOrderFieldType orders RepositoryTechnology by type.
	RepositoryTechnologyOrderFieldType = &RepositoryTechnologyOrderField{
		field: repositorytechnology.FieldType,
		toCursor: func(rt *RepositoryTechnology) Cursor {
			return Cursor{
				ID:    rt.ID,
				Value: rt.Type,
			}
		},
	}
)
View Source
var (
	// SiteOrderFieldURL orders Site by url.
	SiteOrderFieldURL = &SiteOrderField{
		field: site.FieldURL,
		toCursor: func(s *Site) Cursor {
			return Cursor{
				ID:    s.ID,
				Value: s.URL,
			}
		},
	}
)
View Source
var (
	// TechnologyAssociationOrderFieldType orders TechnologyAssociation by type.
	TechnologyAssociationOrderFieldType = &TechnologyAssociationOrderField{
		field: technologyassociation.FieldType,
		toCursor: func(ta *TechnologyAssociation) Cursor {
			return Cursor{
				ID:    ta.ID,
				Value: ta.Type,
			}
		},
	}
)
View Source
var (
	// UserOrderFieldUsername orders User by username.
	UserOrderFieldUsername = &UserOrderField{
		field: user.FieldUsername,
		toCursor: func(u *User) Cursor {
			return Cursor{
				ID:    u.ID,
				Value: u.Username,
			}
		},
	}
)

Functions

func IsConstraintError

func IsConstraintError(err error) bool

IsConstraintError returns a boolean indicating whether the error is a constraint failure.

func IsNotFound

func IsNotFound(err error) bool

IsNotFound returns a boolean indicating whether the error is a not found error.

func IsNotLoaded

func IsNotLoaded(err error) bool

IsNotLoaded returns a boolean indicating whether the error is a not loaded error.

func IsNotSingular

func IsNotSingular(err error) bool

IsNotSingular returns a boolean indicating whether the error is a not singular error.

func IsValidationError

func IsValidationError(err error) bool

IsValidationError returns a boolean indicating whether the error is a validation error.

func MaskNotFound

func MaskNotFound(err error) error

MaskNotFound masks not found error.

func NewContext

func NewContext(parent context.Context, c *Client) context.Context

NewContext returns a new context with the given Client attached.

func NewTxContext

func NewTxContext(parent context.Context, tx *Tx) context.Context

NewTxContext returns a new context with the given Tx attached.

func OpenTxFromContext

func OpenTxFromContext(ctx context.Context) (context.Context, driver.Tx, error)

OpenTxFromContext open transactions from client stored in context.

Types

type AggregateFunc

type AggregateFunc func(*sql.Selector) string

AggregateFunc applies an aggregation step on the group-by traversal/selector.

func As

As is a pseudo aggregation function for renaming another other functions with custom names. For example:

GroupBy(field1, field2).
Aggregate(ent.As(ent.Sum(field1), "sum_field1"), (ent.As(ent.Sum(field2), "sum_field2")).
Scan(ctx, &v)

func Count

func Count() AggregateFunc

Count applies the "count" aggregation function on each group.

func Max

func Max(field string) AggregateFunc

Max applies the "max" aggregation function on the given field of each group.

func Mean

func Mean(field string) AggregateFunc

Mean applies the "mean" aggregation function on the given field of each group.

func Min

func Min(field string) AggregateFunc

Min applies the "min" aggregation function on the given field of each group.

func Sum

func Sum(field string) AggregateFunc

Sum applies the "sum" aggregation function on the given field of each group.

type Client

type Client struct {

	// Schema is the client for creating, migrating and dropping schema.
	Schema *migrate.Schema
	// DiscordAccount is the client for interacting with the DiscordAccount builders.
	DiscordAccount *DiscordAccountClient
	// DiscordBot is the client for interacting with the DiscordBot builders.
	DiscordBot *DiscordBotClient
	// GithubAccount is the client for interacting with the GithubAccount builders.
	GithubAccount *GithubAccountClient
	// GithubOrganization is the client for interacting with the GithubOrganization builders.
	GithubOrganization *GithubOrganizationClient
	// GithubOrganizationMember is the client for interacting with the GithubOrganizationMember builders.
	GithubOrganizationMember *GithubOrganizationMemberClient
	// Project is the client for interacting with the Project builders.
	Project *ProjectClient
	// ProjectAssociation is the client for interacting with the ProjectAssociation builders.
	ProjectAssociation *ProjectAssociationClient
	// ProjectContributor is the client for interacting with the ProjectContributor builders.
	ProjectContributor *ProjectContributorClient
	// ProjectTechnology is the client for interacting with the ProjectTechnology builders.
	ProjectTechnology *ProjectTechnologyClient
	// Repository is the client for interacting with the Repository builders.
	Repository *RepositoryClient
	// RepositoryTechnology is the client for interacting with the RepositoryTechnology builders.
	RepositoryTechnology *RepositoryTechnologyClient
	// Site is the client for interacting with the Site builders.
	Site *SiteClient
	// Technology is the client for interacting with the Technology builders.
	Technology *TechnologyClient
	// TechnologyAssociation is the client for interacting with the TechnologyAssociation builders.
	TechnologyAssociation *TechnologyAssociationClient
	// User is the client for interacting with the User builders.
	User *UserClient
	// contains filtered or unexported fields
}

Client is the client that holds all ent builders.

func FromContext

func FromContext(ctx context.Context) *Client

FromContext returns a Client stored inside a context, or nil if there isn't one.

func NewClient

func NewClient(opts ...Option) *Client

NewClient creates a new client configured with the given options.

func Open

func Open(driverName, dataSourceName string, options ...Option) (*Client, error)

Open opens a database/sql.DB specified by the driver name and the data source name, and returns a new client attached to it. Optional parameters can be added for configuring the client.

func (*Client) BeginTx

func (c *Client) BeginTx(ctx context.Context, opts *sql.TxOptions) (*Tx, error)

BeginTx returns a transactional client with specified options.

func (*Client) Close

func (c *Client) Close() error

Close closes the database connection and prevents new queries from starting.

func (*Client) Debug

func (c *Client) Debug() *Client

Debug returns a new debug-client. It's used to get verbose logging on specific operations.

client.Debug().
	DiscordAccount.
	Query().
	Count(ctx)

func (*Client) Node

func (c *Client) Node(ctx context.Context, id int) (*Node, error)

func (*Client) Noder

func (c *Client) Noder(ctx context.Context, id int, opts ...NodeOption) (_ Noder, err error)

Noder returns a Node by its id. If the NodeType was not provided, it will be derived from the id value according to the universal-id configuration.

c.Noder(ctx, id)
c.Noder(ctx, id, ent.WithNodeType(typeResolver))

func (*Client) Noders

func (c *Client) Noders(ctx context.Context, ids []int, opts ...NodeOption) ([]Noder, error)

func (*Client) OpenTx

func (c *Client) OpenTx(ctx context.Context) (context.Context, driver.Tx, error)

OpenTx opens a transaction and returns a transactional context along with the created transaction.

func (*Client) Tx

func (c *Client) Tx(ctx context.Context) (*Tx, error)

Tx returns a new transactional client. The provided context is used until the transaction is committed or rolled back.

func (*Client) Use

func (c *Client) Use(hooks ...Hook)

Use adds the mutation hooks to all the entity clients. In order to add hooks to a specific client, call: `client.Node.Use(...)`.

type CommitFunc

type CommitFunc func(context.Context, *Tx) error

The CommitFunc type is an adapter to allow the use of ordinary function as a Committer. If f is a function with the appropriate signature, CommitFunc(f) is a Committer that calls f.

func (CommitFunc) Commit

func (f CommitFunc) Commit(ctx context.Context, tx *Tx) error

Commit calls f(ctx, m).

type CommitHook

type CommitHook func(Committer) Committer

CommitHook defines the "commit middleware". A function that gets a Committer and returns a Committer. For example:

hook := func(next ent.Committer) ent.Committer {
	return ent.CommitFunc(func(ctx context.Context, tx *ent.Tx) error {
		// Do some stuff before.
		if err := next.Commit(ctx, tx); err != nil {
			return err
		}
		// Do some stuff after.
		return nil
	})
}

type Committer

type Committer interface {
	Commit(context.Context, *Tx) error
}

Committer is the interface that wraps the Commit method.

type ConstraintError

type ConstraintError struct {
	// contains filtered or unexported fields
}

ConstraintError returns when trying to create/update one or more entities and one or more of their constraints failed. For example, violation of edge or field uniqueness.

func (ConstraintError) Error

func (e ConstraintError) Error() string

Error implements the error interface.

func (*ConstraintError) Unwrap

func (e *ConstraintError) Unwrap() error

Unwrap implements the errors.Wrapper interface.

type CreateDiscordAccountInput

type CreateDiscordAccountInput struct {
	DiscordID     string
	Username      string
	Discriminator string
	Owner         *int
	Bot           *int
}

CreateDiscordAccountInput represents a mutation input for creating discordaccounts.

func (*CreateDiscordAccountInput) Mutate

Mutate applies the CreateDiscordAccountInput on the DiscordAccountCreate builder.

type CreateDiscordBotInput

type CreateDiscordBotInput struct {
	Account    int
	Project    int
	Repository *int
}

CreateDiscordBotInput represents a mutation input for creating discordbots.

func (*CreateDiscordBotInput) Mutate

Mutate applies the CreateDiscordBotInput on the DiscordBotCreate builder.

type CreateGithubAccountInput

type CreateGithubAccountInput struct {
	Username                string
	Owner                   int
	OrganizationMemberships []int
	Repositories            []int
}

CreateGithubAccountInput represents a mutation input for creating githubaccounts.

func (*CreateGithubAccountInput) Mutate

Mutate applies the CreateGithubAccountInput on the GithubAccountCreate builder.

type CreateGithubOrganizationInput

type CreateGithubOrganizationInput struct {
	Name         string
	DisplayName  *string
	Members      []int
	Repositories []int
}

CreateGithubOrganizationInput represents a mutation input for creating githuborganizations.

func (*CreateGithubOrganizationInput) Mutate

Mutate applies the CreateGithubOrganizationInput on the GithubOrganizationCreate builder.

type CreateGithubOrganizationMemberInput

type CreateGithubOrganizationMemberInput struct {
	Role         *githuborganizationmember.Role
	Organization int
	Account      int
}

CreateGithubOrganizationMemberInput represents a mutation input for creating githuborganizationmembers.

func (*CreateGithubOrganizationMemberInput) Mutate

Mutate applies the CreateGithubOrganizationMemberInput on the GithubOrganizationMemberCreate builder.

type CreateProjectAssociationInput

type CreateProjectAssociationInput struct {
	Type   projectassociation.Type
	Parent int
	Child  int
}

CreateProjectAssociationInput represents a mutation input for creating projectassociations.

func (*CreateProjectAssociationInput) Mutate

Mutate applies the CreateProjectAssociationInput on the ProjectAssociationCreate builder.

type CreateProjectContributorInput

type CreateProjectContributorInput struct {
	Role    projectcontributor.Role
	Project int
	User    int
}

CreateProjectContributorInput represents a mutation input for creating projectcontributors.

func (*CreateProjectContributorInput) Mutate

Mutate applies the CreateProjectContributorInput on the ProjectContributorCreate builder.

type CreateProjectInput

type CreateProjectInput struct {
	Name           string
	Description    *string
	StartDate      time.Time
	EndDate        *time.Time
	Contributors   []int
	ParentProjects []int
	ChildProjects  []int
	Repositories   []int
	DiscordBots    []int
	Sites          []int
	Technologies   []int
}

CreateProjectInput represents a mutation input for creating projects.

func (*CreateProjectInput) Mutate

func (i *CreateProjectInput) Mutate(m *ProjectCreate)

Mutate applies the CreateProjectInput on the ProjectCreate builder.

type CreateProjectTechnologyInput

type CreateProjectTechnologyInput struct {
	Type       projecttechnology.Type
	Project    int
	Technology int
}

CreateProjectTechnologyInput represents a mutation input for creating projecttechnologies.

func (*CreateProjectTechnologyInput) Mutate

Mutate applies the CreateProjectTechnologyInput on the ProjectTechnologyCreate builder.

type CreateRepositoryInput

type CreateRepositoryInput struct {
	Name               string
	Description        *string
	Project            int
	GithubAccount      *int
	GithubOrganization *int
	DiscordBots        []int
	Sites              []int
	Technologies       []int
}

CreateRepositoryInput represents a mutation input for creating repositories.

func (*CreateRepositoryInput) Mutate

Mutate applies the CreateRepositoryInput on the RepositoryCreate builder.

type CreateRepositoryTechnologyInput

type CreateRepositoryTechnologyInput struct {
	Type       repositorytechnology.Type
	Repository int
	Technology int
}

CreateRepositoryTechnologyInput represents a mutation input for creating repositorytechnologies.

func (*CreateRepositoryTechnologyInput) Mutate

Mutate applies the CreateRepositoryTechnologyInput on the RepositoryTechnologyCreate builder.

type CreateSiteInput

type CreateSiteInput struct {
	URL        string
	Project    int
	Repository *int
}

CreateSiteInput represents a mutation input for creating sites.

func (*CreateSiteInput) Mutate

func (i *CreateSiteInput) Mutate(m *SiteCreate)

Mutate applies the CreateSiteInput on the SiteCreate builder.

type CreateTechnologyAssociationInput

type CreateTechnologyAssociationInput struct {
	Type   technologyassociation.Type
	Parent int
	Child  int
}

CreateTechnologyAssociationInput represents a mutation input for creating technologyassociations.

func (*CreateTechnologyAssociationInput) Mutate

Mutate applies the CreateTechnologyAssociationInput on the TechnologyAssociationCreate builder.

type CreateTechnologyInput

type CreateTechnologyInput struct {
	Name               string
	Description        *string
	Colour             *string
	Type               technology.Type
	ParentTechnologies []int
	ChildTechnologies  []int
	Projects           []int
	Repositories       []int
}

CreateTechnologyInput represents a mutation input for creating technologies.

func (*CreateTechnologyInput) Mutate

Mutate applies the CreateTechnologyInput on the TechnologyCreate builder.

type CreateUserInput

type CreateUserInput struct {
	Username             string
	AvatarURL            *string
	DiscordAccounts      []int
	GithubAccounts       []int
	ProjectContributions []int
}

CreateUserInput represents a mutation input for creating users.

func (*CreateUserInput) Mutate

func (i *CreateUserInput) Mutate(m *UserCreate)

Mutate applies the CreateUserInput on the UserCreate builder.

type Cursor

type Cursor struct {
	ID    int   `msgpack:"i"`
	Value Value `msgpack:"v,omitempty"`
}

Cursor of an edge type.

func (Cursor) MarshalGQL

func (c Cursor) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (*Cursor) UnmarshalGQL

func (c *Cursor) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type DiscordAccount

type DiscordAccount struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// DiscordID holds the value of the "discord_id" field.
	DiscordID string `json:"discord_id,omitempty"`
	// Username holds the value of the "username" field.
	Username string `json:"username,omitempty"`
	// Discriminator holds the value of the "discriminator" field.
	Discriminator string `json:"discriminator,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the DiscordAccountQuery when eager-loading is set.
	Edges DiscordAccountEdges `json:"edges"`
	// contains filtered or unexported fields
}

DiscordAccount is the model entity for the DiscordAccount schema.

func (*DiscordAccount) Bot

func (da *DiscordAccount) Bot(ctx context.Context) (*DiscordBot, error)

func (*DiscordAccount) Node

func (da *DiscordAccount) Node(ctx context.Context) (node *Node, err error)

func (*DiscordAccount) Owner

func (da *DiscordAccount) Owner(ctx context.Context) (*User, error)

func (*DiscordAccount) QueryBot

func (da *DiscordAccount) QueryBot() *DiscordBotQuery

QueryBot queries the "bot" edge of the DiscordAccount entity.

func (*DiscordAccount) QueryOwner

func (da *DiscordAccount) QueryOwner() *UserQuery

QueryOwner queries the "owner" edge of the DiscordAccount entity.

func (*DiscordAccount) String

func (da *DiscordAccount) String() string

String implements the fmt.Stringer.

func (*DiscordAccount) ToEdge

ToEdge converts DiscordAccount into DiscordAccountEdge.

func (*DiscordAccount) Unwrap

func (da *DiscordAccount) Unwrap() *DiscordAccount

Unwrap unwraps the DiscordAccount entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*DiscordAccount) Update

Update returns a builder for updating this DiscordAccount. Note that you need to call DiscordAccount.Unwrap() before calling this method if this DiscordAccount was returned from a transaction, and the transaction was committed or rolled back.

type DiscordAccountClient

type DiscordAccountClient struct {
	// contains filtered or unexported fields
}

DiscordAccountClient is a client for the DiscordAccount schema.

func NewDiscordAccountClient

func NewDiscordAccountClient(c config) *DiscordAccountClient

NewDiscordAccountClient returns a client for the DiscordAccount from the given config.

func (*DiscordAccountClient) Create

Create returns a builder for creating a DiscordAccount entity.

func (*DiscordAccountClient) CreateBulk

CreateBulk returns a builder for creating a bulk of DiscordAccount entities.

func (*DiscordAccountClient) Delete

Delete returns a delete builder for DiscordAccount.

func (*DiscordAccountClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*DiscordAccountClient) DeleteOneID

func (c *DiscordAccountClient) DeleteOneID(id int) *DiscordAccountDeleteOne

DeleteOne returns a builder for deleting the given entity by its id.

func (*DiscordAccountClient) Get

Get returns a DiscordAccount entity by its id.

func (*DiscordAccountClient) GetX

GetX is like Get, but panics if an error occurs.

func (*DiscordAccountClient) Hooks

func (c *DiscordAccountClient) Hooks() []Hook

Hooks returns the client hooks.

func (*DiscordAccountClient) Query

Query returns a query builder for DiscordAccount.

func (*DiscordAccountClient) QueryBot

QueryBot queries the bot edge of a DiscordAccount.

func (*DiscordAccountClient) QueryOwner

func (c *DiscordAccountClient) QueryOwner(da *DiscordAccount) *UserQuery

QueryOwner queries the owner edge of a DiscordAccount.

func (*DiscordAccountClient) Update

Update returns an update builder for DiscordAccount.

func (*DiscordAccountClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*DiscordAccountClient) UpdateOneID

func (c *DiscordAccountClient) UpdateOneID(id int) *DiscordAccountUpdateOne

UpdateOneID returns an update builder for the given id.

func (*DiscordAccountClient) Use

func (c *DiscordAccountClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `discordaccount.Hooks(f(g(h())))`.

type DiscordAccountConnection

type DiscordAccountConnection struct {
	Edges      []*DiscordAccountEdge `json:"edges"`
	PageInfo   PageInfo              `json:"pageInfo"`
	TotalCount int                   `json:"totalCount"`
}

DiscordAccountConnection is the connection containing edges to DiscordAccount.

type DiscordAccountCreate

type DiscordAccountCreate struct {
	// contains filtered or unexported fields
}

DiscordAccountCreate is the builder for creating a DiscordAccount entity.

func (*DiscordAccountCreate) Exec

func (dac *DiscordAccountCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*DiscordAccountCreate) ExecX

func (dac *DiscordAccountCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*DiscordAccountCreate) Mutation

Mutation returns the DiscordAccountMutation object of the builder.

func (*DiscordAccountCreate) Save

Save creates the DiscordAccount in the database.

func (*DiscordAccountCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*DiscordAccountCreate) SetBot

SetBot sets the "bot" edge to the DiscordBot entity.

func (*DiscordAccountCreate) SetBotID

func (dac *DiscordAccountCreate) SetBotID(id int) *DiscordAccountCreate

SetBotID sets the "bot" edge to the DiscordBot entity by ID.

func (*DiscordAccountCreate) SetDiscordID

func (dac *DiscordAccountCreate) SetDiscordID(s string) *DiscordAccountCreate

SetDiscordID sets the "discord_id" field.

func (*DiscordAccountCreate) SetDiscriminator

func (dac *DiscordAccountCreate) SetDiscriminator(s string) *DiscordAccountCreate

SetDiscriminator sets the "discriminator" field.

func (*DiscordAccountCreate) SetInput

SetInput applies the change-set in the CreateDiscordAccountInput on the create builder.

func (*DiscordAccountCreate) SetNillableBotID

func (dac *DiscordAccountCreate) SetNillableBotID(id *int) *DiscordAccountCreate

SetNillableBotID sets the "bot" edge to the DiscordBot entity by ID if the given value is not nil.

func (*DiscordAccountCreate) SetNillableOwnerID

func (dac *DiscordAccountCreate) SetNillableOwnerID(id *int) *DiscordAccountCreate

SetNillableOwnerID sets the "owner" edge to the User entity by ID if the given value is not nil.

func (*DiscordAccountCreate) SetOwner

func (dac *DiscordAccountCreate) SetOwner(u *User) *DiscordAccountCreate

SetOwner sets the "owner" edge to the User entity.

func (*DiscordAccountCreate) SetOwnerID

func (dac *DiscordAccountCreate) SetOwnerID(id int) *DiscordAccountCreate

SetOwnerID sets the "owner" edge to the User entity by ID.

func (*DiscordAccountCreate) SetUsername

func (dac *DiscordAccountCreate) SetUsername(s string) *DiscordAccountCreate

SetUsername sets the "username" field.

type DiscordAccountCreateBulk

type DiscordAccountCreateBulk struct {
	// contains filtered or unexported fields
}

DiscordAccountCreateBulk is the builder for creating many DiscordAccount entities in bulk.

func (*DiscordAccountCreateBulk) Exec

Exec executes the query.

func (*DiscordAccountCreateBulk) ExecX

func (dacb *DiscordAccountCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*DiscordAccountCreateBulk) Save

Save creates the DiscordAccount entities in the database.

func (*DiscordAccountCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type DiscordAccountDelete

type DiscordAccountDelete struct {
	// contains filtered or unexported fields
}

DiscordAccountDelete is the builder for deleting a DiscordAccount entity.

func (*DiscordAccountDelete) Exec

func (dad *DiscordAccountDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*DiscordAccountDelete) ExecX

func (dad *DiscordAccountDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*DiscordAccountDelete) Where

Where appends a list predicates to the DiscordAccountDelete builder.

type DiscordAccountDeleteOne

type DiscordAccountDeleteOne struct {
	// contains filtered or unexported fields
}

DiscordAccountDeleteOne is the builder for deleting a single DiscordAccount entity.

func (*DiscordAccountDeleteOne) Exec

func (dado *DiscordAccountDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*DiscordAccountDeleteOne) ExecX

func (dado *DiscordAccountDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

type DiscordAccountEdge

type DiscordAccountEdge struct {
	Node   *DiscordAccount `json:"node"`
	Cursor Cursor          `json:"cursor"`
}

DiscordAccountEdge is the edge representation of DiscordAccount.

type DiscordAccountEdges

type DiscordAccountEdges struct {
	// Owner holds the value of the owner edge.
	Owner *User `json:"owner,omitempty"`
	// Bot holds the value of the bot edge.
	Bot *DiscordBot `json:"bot,omitempty"`
	// contains filtered or unexported fields
}

DiscordAccountEdges holds the relations/edges for other nodes in the graph.

func (DiscordAccountEdges) BotOrErr

func (e DiscordAccountEdges) BotOrErr() (*DiscordBot, error)

BotOrErr returns the Bot value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (DiscordAccountEdges) OwnerOrErr

func (e DiscordAccountEdges) OwnerOrErr() (*User, error)

OwnerOrErr returns the Owner value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type DiscordAccountGroupBy

type DiscordAccountGroupBy struct {
	// contains filtered or unexported fields
}

DiscordAccountGroupBy is the group-by builder for DiscordAccount entities.

func (*DiscordAccountGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*DiscordAccountGroupBy) Bool

func (s *DiscordAccountGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*DiscordAccountGroupBy) BoolX

func (s *DiscordAccountGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*DiscordAccountGroupBy) Bools

func (s *DiscordAccountGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*DiscordAccountGroupBy) BoolsX

func (s *DiscordAccountGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*DiscordAccountGroupBy) Float64

func (s *DiscordAccountGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*DiscordAccountGroupBy) Float64X

func (s *DiscordAccountGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*DiscordAccountGroupBy) Float64s

func (s *DiscordAccountGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*DiscordAccountGroupBy) Float64sX

func (s *DiscordAccountGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*DiscordAccountGroupBy) Int

func (s *DiscordAccountGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*DiscordAccountGroupBy) IntX

func (s *DiscordAccountGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*DiscordAccountGroupBy) Ints

func (s *DiscordAccountGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*DiscordAccountGroupBy) IntsX

func (s *DiscordAccountGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*DiscordAccountGroupBy) Scan

func (dagb *DiscordAccountGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*DiscordAccountGroupBy) ScanX

func (s *DiscordAccountGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*DiscordAccountGroupBy) String

func (s *DiscordAccountGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*DiscordAccountGroupBy) StringX

func (s *DiscordAccountGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*DiscordAccountGroupBy) Strings

func (s *DiscordAccountGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*DiscordAccountGroupBy) StringsX

func (s *DiscordAccountGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type DiscordAccountMutation

type DiscordAccountMutation struct {
	// contains filtered or unexported fields
}

DiscordAccountMutation represents an operation that mutates the DiscordAccount nodes in the graph.

func (*DiscordAccountMutation) AddField

func (m *DiscordAccountMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*DiscordAccountMutation) AddedEdges

func (m *DiscordAccountMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*DiscordAccountMutation) AddedField

func (m *DiscordAccountMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*DiscordAccountMutation) AddedFields

func (m *DiscordAccountMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*DiscordAccountMutation) AddedIDs

func (m *DiscordAccountMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*DiscordAccountMutation) BotCleared

func (m *DiscordAccountMutation) BotCleared() bool

BotCleared reports if the "bot" edge to the DiscordBot entity was cleared.

func (*DiscordAccountMutation) BotID

func (m *DiscordAccountMutation) BotID() (id int, exists bool)

BotID returns the "bot" edge ID in the mutation.

func (*DiscordAccountMutation) BotIDs

func (m *DiscordAccountMutation) BotIDs() (ids []int)

BotIDs returns the "bot" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use BotID instead. It exists only for internal usage by the builders.

func (*DiscordAccountMutation) ClearBot

func (m *DiscordAccountMutation) ClearBot()

ClearBot clears the "bot" edge to the DiscordBot entity.

func (*DiscordAccountMutation) ClearEdge

func (m *DiscordAccountMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*DiscordAccountMutation) ClearField

func (m *DiscordAccountMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*DiscordAccountMutation) ClearOwner

func (m *DiscordAccountMutation) ClearOwner()

ClearOwner clears the "owner" edge to the User entity.

func (*DiscordAccountMutation) ClearedEdges

func (m *DiscordAccountMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*DiscordAccountMutation) ClearedFields

func (m *DiscordAccountMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (DiscordAccountMutation) Client

func (m DiscordAccountMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*DiscordAccountMutation) DiscordID

func (m *DiscordAccountMutation) DiscordID() (r string, exists bool)

DiscordID returns the value of the "discord_id" field in the mutation.

func (*DiscordAccountMutation) Discriminator

func (m *DiscordAccountMutation) Discriminator() (r string, exists bool)

Discriminator returns the value of the "discriminator" field in the mutation.

func (*DiscordAccountMutation) EdgeCleared

func (m *DiscordAccountMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*DiscordAccountMutation) Field

func (m *DiscordAccountMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*DiscordAccountMutation) FieldCleared

func (m *DiscordAccountMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*DiscordAccountMutation) Fields

func (m *DiscordAccountMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*DiscordAccountMutation) ID

func (m *DiscordAccountMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*DiscordAccountMutation) IDs

func (m *DiscordAccountMutation) IDs(ctx context.Context) ([]int, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*DiscordAccountMutation) OldDiscordID

func (m *DiscordAccountMutation) OldDiscordID(ctx context.Context) (v string, err error)

OldDiscordID returns the old "discord_id" field's value of the DiscordAccount entity. If the DiscordAccount object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*DiscordAccountMutation) OldDiscriminator

func (m *DiscordAccountMutation) OldDiscriminator(ctx context.Context) (v string, err error)

OldDiscriminator returns the old "discriminator" field's value of the DiscordAccount entity. If the DiscordAccount object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*DiscordAccountMutation) OldField

func (m *DiscordAccountMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*DiscordAccountMutation) OldUsername

func (m *DiscordAccountMutation) OldUsername(ctx context.Context) (v string, err error)

OldUsername returns the old "username" field's value of the DiscordAccount entity. If the DiscordAccount object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*DiscordAccountMutation) Op

func (m *DiscordAccountMutation) Op() Op

Op returns the operation name.

func (*DiscordAccountMutation) OwnerCleared

func (m *DiscordAccountMutation) OwnerCleared() bool

OwnerCleared reports if the "owner" edge to the User entity was cleared.

func (*DiscordAccountMutation) OwnerID

func (m *DiscordAccountMutation) OwnerID() (id int, exists bool)

OwnerID returns the "owner" edge ID in the mutation.

func (*DiscordAccountMutation) OwnerIDs

func (m *DiscordAccountMutation) OwnerIDs() (ids []int)

OwnerIDs returns the "owner" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use OwnerID instead. It exists only for internal usage by the builders.

func (*DiscordAccountMutation) RemovedEdges

func (m *DiscordAccountMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*DiscordAccountMutation) RemovedIDs

func (m *DiscordAccountMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*DiscordAccountMutation) ResetBot

func (m *DiscordAccountMutation) ResetBot()

ResetBot resets all changes to the "bot" edge.

func (*DiscordAccountMutation) ResetDiscordID

func (m *DiscordAccountMutation) ResetDiscordID()

ResetDiscordID resets all changes to the "discord_id" field.

func (*DiscordAccountMutation) ResetDiscriminator

func (m *DiscordAccountMutation) ResetDiscriminator()

ResetDiscriminator resets all changes to the "discriminator" field.

func (*DiscordAccountMutation) ResetEdge

func (m *DiscordAccountMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*DiscordAccountMutation) ResetField

func (m *DiscordAccountMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*DiscordAccountMutation) ResetOwner

func (m *DiscordAccountMutation) ResetOwner()

ResetOwner resets all changes to the "owner" edge.

func (*DiscordAccountMutation) ResetUsername

func (m *DiscordAccountMutation) ResetUsername()

ResetUsername resets all changes to the "username" field.

func (*DiscordAccountMutation) SetBotID

func (m *DiscordAccountMutation) SetBotID(id int)

SetBotID sets the "bot" edge to the DiscordBot entity by id.

func (*DiscordAccountMutation) SetDiscordID

func (m *DiscordAccountMutation) SetDiscordID(s string)

SetDiscordID sets the "discord_id" field.

func (*DiscordAccountMutation) SetDiscriminator

func (m *DiscordAccountMutation) SetDiscriminator(s string)

SetDiscriminator sets the "discriminator" field.

func (*DiscordAccountMutation) SetField

func (m *DiscordAccountMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*DiscordAccountMutation) SetOwnerID

func (m *DiscordAccountMutation) SetOwnerID(id int)

SetOwnerID sets the "owner" edge to the User entity by id.

func (*DiscordAccountMutation) SetUsername

func (m *DiscordAccountMutation) SetUsername(s string)

SetUsername sets the "username" field.

func (DiscordAccountMutation) Tx

func (m DiscordAccountMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*DiscordAccountMutation) Type

func (m *DiscordAccountMutation) Type() string

Type returns the node type of this mutation (DiscordAccount).

func (*DiscordAccountMutation) Username

func (m *DiscordAccountMutation) Username() (r string, exists bool)

Username returns the value of the "username" field in the mutation.

func (*DiscordAccountMutation) Where

Where appends a list predicates to the DiscordAccountMutation builder.

type DiscordAccountOrder

type DiscordAccountOrder struct {
	Direction OrderDirection            `json:"direction"`
	Field     *DiscordAccountOrderField `json:"field"`
}

DiscordAccountOrder defines the ordering of DiscordAccount.

type DiscordAccountOrderField

type DiscordAccountOrderField struct {
	// contains filtered or unexported fields
}

DiscordAccountOrderField defines the ordering field of DiscordAccount.

func (DiscordAccountOrderField) MarshalGQL

func (f DiscordAccountOrderField) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (DiscordAccountOrderField) String

func (f DiscordAccountOrderField) String() string

String implement fmt.Stringer interface.

func (*DiscordAccountOrderField) UnmarshalGQL

func (f *DiscordAccountOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type DiscordAccountPaginateOption

type DiscordAccountPaginateOption func(*discordaccountPager) error

DiscordAccountPaginateOption enables pagination customization.

func WithDiscordAccountFilter

func WithDiscordAccountFilter(filter func(*DiscordAccountQuery) (*DiscordAccountQuery, error)) DiscordAccountPaginateOption

WithDiscordAccountFilter configures pagination filter.

func WithDiscordAccountOrder

func WithDiscordAccountOrder(order *DiscordAccountOrder) DiscordAccountPaginateOption

WithDiscordAccountOrder configures pagination ordering.

type DiscordAccountQuery

type DiscordAccountQuery struct {
	// contains filtered or unexported fields
}

DiscordAccountQuery is the builder for querying DiscordAccount entities.

func (*DiscordAccountQuery) All

All executes the query and returns a list of DiscordAccounts.

func (*DiscordAccountQuery) AllX

AllX is like All, but panics if an error occurs.

func (*DiscordAccountQuery) Clone

Clone returns a duplicate of the DiscordAccountQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*DiscordAccountQuery) CollectFields

func (da *DiscordAccountQuery) CollectFields(ctx context.Context, satisfies ...string) (*DiscordAccountQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*DiscordAccountQuery) Count

func (daq *DiscordAccountQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*DiscordAccountQuery) CountX

func (daq *DiscordAccountQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*DiscordAccountQuery) Exist

func (daq *DiscordAccountQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*DiscordAccountQuery) ExistX

func (daq *DiscordAccountQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*DiscordAccountQuery) First

First returns the first DiscordAccount entity from the query. Returns a *NotFoundError when no DiscordAccount was found.

func (*DiscordAccountQuery) FirstID

func (daq *DiscordAccountQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first DiscordAccount ID from the query. Returns a *NotFoundError when no DiscordAccount ID was found.

func (*DiscordAccountQuery) FirstIDX

func (daq *DiscordAccountQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*DiscordAccountQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*DiscordAccountQuery) GroupBy

func (daq *DiscordAccountQuery) GroupBy(field string, fields ...string) *DiscordAccountGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	DiscordID string `json:"discord_id,omitempty"`
	Count int `json:"count,omitempty"`
}

client.DiscordAccount.Query().
	GroupBy(discordaccount.FieldDiscordID).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*DiscordAccountQuery) IDs

func (daq *DiscordAccountQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of DiscordAccount IDs.

func (*DiscordAccountQuery) IDsX

func (daq *DiscordAccountQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*DiscordAccountQuery) Limit

func (daq *DiscordAccountQuery) Limit(limit int) *DiscordAccountQuery

Limit adds a limit step to the query.

func (*DiscordAccountQuery) Offset

func (daq *DiscordAccountQuery) Offset(offset int) *DiscordAccountQuery

Offset adds an offset step to the query.

func (*DiscordAccountQuery) Only

Only returns a single DiscordAccount entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one DiscordAccount entity is found. Returns a *NotFoundError when no DiscordAccount entities are found.

func (*DiscordAccountQuery) OnlyID

func (daq *DiscordAccountQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only DiscordAccount ID in the query. Returns a *NotSingularError when more than one DiscordAccount ID is found. Returns a *NotFoundError when no entities are found.

func (*DiscordAccountQuery) OnlyIDX

func (daq *DiscordAccountQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*DiscordAccountQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*DiscordAccountQuery) Order

Order adds an order step to the query.

func (*DiscordAccountQuery) Paginate

func (da *DiscordAccountQuery) Paginate(
	ctx context.Context, after *Cursor, first *int,
	before *Cursor, last *int, opts ...DiscordAccountPaginateOption,
) (*DiscordAccountConnection, error)

Paginate executes the query and returns a relay based cursor connection to DiscordAccount.

func (*DiscordAccountQuery) QueryBot

func (daq *DiscordAccountQuery) QueryBot() *DiscordBotQuery

QueryBot chains the current query on the "bot" edge.

func (*DiscordAccountQuery) QueryOwner

func (daq *DiscordAccountQuery) QueryOwner() *UserQuery

QueryOwner chains the current query on the "owner" edge.

func (*DiscordAccountQuery) Select

func (daq *DiscordAccountQuery) Select(fields ...string) *DiscordAccountSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	DiscordID string `json:"discord_id,omitempty"`
}

client.DiscordAccount.Query().
	Select(discordaccount.FieldDiscordID).
	Scan(ctx, &v)

func (*DiscordAccountQuery) Unique

func (daq *DiscordAccountQuery) Unique(unique bool) *DiscordAccountQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*DiscordAccountQuery) Where

Where adds a new predicate for the DiscordAccountQuery builder.

func (*DiscordAccountQuery) WithBot

func (daq *DiscordAccountQuery) WithBot(opts ...func(*DiscordBotQuery)) *DiscordAccountQuery

WithBot tells the query-builder to eager-load the nodes that are connected to the "bot" edge. The optional arguments are used to configure the query builder of the edge.

func (*DiscordAccountQuery) WithOwner

func (daq *DiscordAccountQuery) WithOwner(opts ...func(*UserQuery)) *DiscordAccountQuery

WithOwner tells the query-builder to eager-load the nodes that are connected to the "owner" edge. The optional arguments are used to configure the query builder of the edge.

type DiscordAccountSelect

type DiscordAccountSelect struct {
	*DiscordAccountQuery
	// contains filtered or unexported fields
}

DiscordAccountSelect is the builder for selecting fields of DiscordAccount entities.

func (*DiscordAccountSelect) Bool

func (s *DiscordAccountSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*DiscordAccountSelect) BoolX

func (s *DiscordAccountSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*DiscordAccountSelect) Bools

func (s *DiscordAccountSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*DiscordAccountSelect) BoolsX

func (s *DiscordAccountSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*DiscordAccountSelect) Float64

func (s *DiscordAccountSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*DiscordAccountSelect) Float64X

func (s *DiscordAccountSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*DiscordAccountSelect) Float64s

func (s *DiscordAccountSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*DiscordAccountSelect) Float64sX

func (s *DiscordAccountSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*DiscordAccountSelect) Int

func (s *DiscordAccountSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*DiscordAccountSelect) IntX

func (s *DiscordAccountSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*DiscordAccountSelect) Ints

func (s *DiscordAccountSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*DiscordAccountSelect) IntsX

func (s *DiscordAccountSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*DiscordAccountSelect) Scan

func (das *DiscordAccountSelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*DiscordAccountSelect) ScanX

func (s *DiscordAccountSelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*DiscordAccountSelect) String

func (s *DiscordAccountSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*DiscordAccountSelect) StringX

func (s *DiscordAccountSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*DiscordAccountSelect) Strings

func (s *DiscordAccountSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*DiscordAccountSelect) StringsX

func (s *DiscordAccountSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type DiscordAccountUpdate

type DiscordAccountUpdate struct {
	// contains filtered or unexported fields
}

DiscordAccountUpdate is the builder for updating DiscordAccount entities.

func (*DiscordAccountUpdate) ClearBot

func (dau *DiscordAccountUpdate) ClearBot() *DiscordAccountUpdate

ClearBot clears the "bot" edge to the DiscordBot entity.

func (*DiscordAccountUpdate) ClearOwner

func (dau *DiscordAccountUpdate) ClearOwner() *DiscordAccountUpdate

ClearOwner clears the "owner" edge to the User entity.

func (*DiscordAccountUpdate) Exec

func (dau *DiscordAccountUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*DiscordAccountUpdate) ExecX

func (dau *DiscordAccountUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*DiscordAccountUpdate) Mutation

Mutation returns the DiscordAccountMutation object of the builder.

func (*DiscordAccountUpdate) Save

func (dau *DiscordAccountUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*DiscordAccountUpdate) SaveX

func (dau *DiscordAccountUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*DiscordAccountUpdate) SetBot

SetBot sets the "bot" edge to the DiscordBot entity.

func (*DiscordAccountUpdate) SetBotID

func (dau *DiscordAccountUpdate) SetBotID(id int) *DiscordAccountUpdate

SetBotID sets the "bot" edge to the DiscordBot entity by ID.

func (*DiscordAccountUpdate) SetDiscriminator

func (dau *DiscordAccountUpdate) SetDiscriminator(s string) *DiscordAccountUpdate

SetDiscriminator sets the "discriminator" field.

func (*DiscordAccountUpdate) SetInput

SetInput applies the change-set in the UpdateDiscordAccountInput on the update builder.

func (*DiscordAccountUpdate) SetNillableBotID

func (dau *DiscordAccountUpdate) SetNillableBotID(id *int) *DiscordAccountUpdate

SetNillableBotID sets the "bot" edge to the DiscordBot entity by ID if the given value is not nil.

func (*DiscordAccountUpdate) SetNillableOwnerID

func (dau *DiscordAccountUpdate) SetNillableOwnerID(id *int) *DiscordAccountUpdate

SetNillableOwnerID sets the "owner" edge to the User entity by ID if the given value is not nil.

func (*DiscordAccountUpdate) SetOwner

func (dau *DiscordAccountUpdate) SetOwner(u *User) *DiscordAccountUpdate

SetOwner sets the "owner" edge to the User entity.

func (*DiscordAccountUpdate) SetOwnerID

func (dau *DiscordAccountUpdate) SetOwnerID(id int) *DiscordAccountUpdate

SetOwnerID sets the "owner" edge to the User entity by ID.

func (*DiscordAccountUpdate) SetUsername

func (dau *DiscordAccountUpdate) SetUsername(s string) *DiscordAccountUpdate

SetUsername sets the "username" field.

func (*DiscordAccountUpdate) Where

Where appends a list predicates to the DiscordAccountUpdate builder.

type DiscordAccountUpdateOne

type DiscordAccountUpdateOne struct {
	// contains filtered or unexported fields
}

DiscordAccountUpdateOne is the builder for updating a single DiscordAccount entity.

func (*DiscordAccountUpdateOne) ClearBot

ClearBot clears the "bot" edge to the DiscordBot entity.

func (*DiscordAccountUpdateOne) ClearOwner

ClearOwner clears the "owner" edge to the User entity.

func (*DiscordAccountUpdateOne) Exec

func (dauo *DiscordAccountUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*DiscordAccountUpdateOne) ExecX

func (dauo *DiscordAccountUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*DiscordAccountUpdateOne) Mutation

Mutation returns the DiscordAccountMutation object of the builder.

func (*DiscordAccountUpdateOne) Save

Save executes the query and returns the updated DiscordAccount entity.

func (*DiscordAccountUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*DiscordAccountUpdateOne) Select

func (dauo *DiscordAccountUpdateOne) Select(field string, fields ...string) *DiscordAccountUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*DiscordAccountUpdateOne) SetBot

SetBot sets the "bot" edge to the DiscordBot entity.

func (*DiscordAccountUpdateOne) SetBotID

SetBotID sets the "bot" edge to the DiscordBot entity by ID.

func (*DiscordAccountUpdateOne) SetDiscriminator

func (dauo *DiscordAccountUpdateOne) SetDiscriminator(s string) *DiscordAccountUpdateOne

SetDiscriminator sets the "discriminator" field.

func (*DiscordAccountUpdateOne) SetInput

SetInput applies the change-set in the UpdateDiscordAccountInput on the update-one builder.

func (*DiscordAccountUpdateOne) SetNillableBotID

func (dauo *DiscordAccountUpdateOne) SetNillableBotID(id *int) *DiscordAccountUpdateOne

SetNillableBotID sets the "bot" edge to the DiscordBot entity by ID if the given value is not nil.

func (*DiscordAccountUpdateOne) SetNillableOwnerID

func (dauo *DiscordAccountUpdateOne) SetNillableOwnerID(id *int) *DiscordAccountUpdateOne

SetNillableOwnerID sets the "owner" edge to the User entity by ID if the given value is not nil.

func (*DiscordAccountUpdateOne) SetOwner

SetOwner sets the "owner" edge to the User entity.

func (*DiscordAccountUpdateOne) SetOwnerID

func (dauo *DiscordAccountUpdateOne) SetOwnerID(id int) *DiscordAccountUpdateOne

SetOwnerID sets the "owner" edge to the User entity by ID.

func (*DiscordAccountUpdateOne) SetUsername

SetUsername sets the "username" field.

type DiscordAccountWhereInput

type DiscordAccountWhereInput struct {
	Predicates []predicate.DiscordAccount  `json:"-"`
	Not        *DiscordAccountWhereInput   `json:"not,omitempty"`
	Or         []*DiscordAccountWhereInput `json:"or,omitempty"`
	And        []*DiscordAccountWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "discord_id" field predicates.
	DiscordID             *string  `json:"discordID,omitempty"`
	DiscordIDNEQ          *string  `json:"discordIDNEQ,omitempty"`
	DiscordIDIn           []string `json:"discordIDIn,omitempty"`
	DiscordIDNotIn        []string `json:"discordIDNotIn,omitempty"`
	DiscordIDGT           *string  `json:"discordIDGT,omitempty"`
	DiscordIDGTE          *string  `json:"discordIDGTE,omitempty"`
	DiscordIDLT           *string  `json:"discordIDLT,omitempty"`
	DiscordIDLTE          *string  `json:"discordIDLTE,omitempty"`
	DiscordIDContains     *string  `json:"discordIDContains,omitempty"`
	DiscordIDHasPrefix    *string  `json:"discordIDHasPrefix,omitempty"`
	DiscordIDHasSuffix    *string  `json:"discordIDHasSuffix,omitempty"`
	DiscordIDEqualFold    *string  `json:"discordIDEqualFold,omitempty"`
	DiscordIDContainsFold *string  `json:"discordIDContainsFold,omitempty"`

	// "username" field predicates.
	Username             *string  `json:"username,omitempty"`
	UsernameNEQ          *string  `json:"usernameNEQ,omitempty"`
	UsernameIn           []string `json:"usernameIn,omitempty"`
	UsernameNotIn        []string `json:"usernameNotIn,omitempty"`
	UsernameGT           *string  `json:"usernameGT,omitempty"`
	UsernameGTE          *string  `json:"usernameGTE,omitempty"`
	UsernameLT           *string  `json:"usernameLT,omitempty"`
	UsernameLTE          *string  `json:"usernameLTE,omitempty"`
	UsernameContains     *string  `json:"usernameContains,omitempty"`
	UsernameHasPrefix    *string  `json:"usernameHasPrefix,omitempty"`
	UsernameHasSuffix    *string  `json:"usernameHasSuffix,omitempty"`
	UsernameEqualFold    *string  `json:"usernameEqualFold,omitempty"`
	UsernameContainsFold *string  `json:"usernameContainsFold,omitempty"`

	// "discriminator" field predicates.
	Discriminator             *string  `json:"discriminator,omitempty"`
	DiscriminatorNEQ          *string  `json:"discriminatorNEQ,omitempty"`
	DiscriminatorIn           []string `json:"discriminatorIn,omitempty"`
	DiscriminatorNotIn        []string `json:"discriminatorNotIn,omitempty"`
	DiscriminatorGT           *string  `json:"discriminatorGT,omitempty"`
	DiscriminatorGTE          *string  `json:"discriminatorGTE,omitempty"`
	DiscriminatorLT           *string  `json:"discriminatorLT,omitempty"`
	DiscriminatorLTE          *string  `json:"discriminatorLTE,omitempty"`
	DiscriminatorContains     *string  `json:"discriminatorContains,omitempty"`
	DiscriminatorHasPrefix    *string  `json:"discriminatorHasPrefix,omitempty"`
	DiscriminatorHasSuffix    *string  `json:"discriminatorHasSuffix,omitempty"`
	DiscriminatorEqualFold    *string  `json:"discriminatorEqualFold,omitempty"`
	DiscriminatorContainsFold *string  `json:"discriminatorContainsFold,omitempty"`

	// "owner" edge predicates.
	HasOwner     *bool             `json:"hasOwner,omitempty"`
	HasOwnerWith []*UserWhereInput `json:"hasOwnerWith,omitempty"`

	// "bot" edge predicates.
	HasBot     *bool                   `json:"hasBot,omitempty"`
	HasBotWith []*DiscordBotWhereInput `json:"hasBotWith,omitempty"`
}

DiscordAccountWhereInput represents a where input for filtering DiscordAccount queries.

func (*DiscordAccountWhereInput) AddPredicates

func (i *DiscordAccountWhereInput) AddPredicates(predicates ...predicate.DiscordAccount)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*DiscordAccountWhereInput) Filter

Filter applies the DiscordAccountWhereInput filter on the DiscordAccountQuery builder.

func (*DiscordAccountWhereInput) P

P returns a predicate for filtering discordaccounts. An error is returned if the input is empty or invalid.

type DiscordAccounts

type DiscordAccounts []*DiscordAccount

DiscordAccounts is a parsable slice of DiscordAccount.

type DiscordBot

type DiscordBot struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the DiscordBotQuery when eager-loading is set.
	Edges DiscordBotEdges `json:"edges"`
	// contains filtered or unexported fields
}

DiscordBot is the model entity for the DiscordBot schema.

func (*DiscordBot) Account

func (db *DiscordBot) Account(ctx context.Context) (*DiscordAccount, error)

func (*DiscordBot) Node

func (db *DiscordBot) Node(ctx context.Context) (node *Node, err error)

func (*DiscordBot) Project

func (db *DiscordBot) Project(ctx context.Context) (*Project, error)

func (*DiscordBot) QueryAccount

func (db *DiscordBot) QueryAccount() *DiscordAccountQuery

QueryAccount queries the "account" edge of the DiscordBot entity.

func (*DiscordBot) QueryProject

func (db *DiscordBot) QueryProject() *ProjectQuery

QueryProject queries the "project" edge of the DiscordBot entity.

func (*DiscordBot) QueryRepository

func (db *DiscordBot) QueryRepository() *RepositoryQuery

QueryRepository queries the "repository" edge of the DiscordBot entity.

func (*DiscordBot) Repository

func (db *DiscordBot) Repository(ctx context.Context) (*Repository, error)

func (*DiscordBot) String

func (db *DiscordBot) String() string

String implements the fmt.Stringer.

func (*DiscordBot) ToEdge

func (db *DiscordBot) ToEdge(order *DiscordBotOrder) *DiscordBotEdge

ToEdge converts DiscordBot into DiscordBotEdge.

func (*DiscordBot) Unwrap

func (db *DiscordBot) Unwrap() *DiscordBot

Unwrap unwraps the DiscordBot entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*DiscordBot) Update

func (db *DiscordBot) Update() *DiscordBotUpdateOne

Update returns a builder for updating this DiscordBot. Note that you need to call DiscordBot.Unwrap() before calling this method if this DiscordBot was returned from a transaction, and the transaction was committed or rolled back.

type DiscordBotClient

type DiscordBotClient struct {
	// contains filtered or unexported fields
}

DiscordBotClient is a client for the DiscordBot schema.

func NewDiscordBotClient

func NewDiscordBotClient(c config) *DiscordBotClient

NewDiscordBotClient returns a client for the DiscordBot from the given config.

func (*DiscordBotClient) Create

func (c *DiscordBotClient) Create() *DiscordBotCreate

Create returns a builder for creating a DiscordBot entity.

func (*DiscordBotClient) CreateBulk

func (c *DiscordBotClient) CreateBulk(builders ...*DiscordBotCreate) *DiscordBotCreateBulk

CreateBulk returns a builder for creating a bulk of DiscordBot entities.

func (*DiscordBotClient) Delete

func (c *DiscordBotClient) Delete() *DiscordBotDelete

Delete returns a delete builder for DiscordBot.

func (*DiscordBotClient) DeleteOne

func (c *DiscordBotClient) DeleteOne(db *DiscordBot) *DiscordBotDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*DiscordBotClient) DeleteOneID

func (c *DiscordBotClient) DeleteOneID(id int) *DiscordBotDeleteOne

DeleteOne returns a builder for deleting the given entity by its id.

func (*DiscordBotClient) Get

func (c *DiscordBotClient) Get(ctx context.Context, id int) (*DiscordBot, error)

Get returns a DiscordBot entity by its id.

func (*DiscordBotClient) GetX

func (c *DiscordBotClient) GetX(ctx context.Context, id int) *DiscordBot

GetX is like Get, but panics if an error occurs.

func (*DiscordBotClient) Hooks

func (c *DiscordBotClient) Hooks() []Hook

Hooks returns the client hooks.

func (*DiscordBotClient) Query

func (c *DiscordBotClient) Query() *DiscordBotQuery

Query returns a query builder for DiscordBot.

func (*DiscordBotClient) QueryAccount

func (c *DiscordBotClient) QueryAccount(db *DiscordBot) *DiscordAccountQuery

QueryAccount queries the account edge of a DiscordBot.

func (*DiscordBotClient) QueryProject

func (c *DiscordBotClient) QueryProject(db *DiscordBot) *ProjectQuery

QueryProject queries the project edge of a DiscordBot.

func (*DiscordBotClient) QueryRepository

func (c *DiscordBotClient) QueryRepository(db *DiscordBot) *RepositoryQuery

QueryRepository queries the repository edge of a DiscordBot.

func (*DiscordBotClient) Update

func (c *DiscordBotClient) Update() *DiscordBotUpdate

Update returns an update builder for DiscordBot.

func (*DiscordBotClient) UpdateOne

func (c *DiscordBotClient) UpdateOne(db *DiscordBot) *DiscordBotUpdateOne

UpdateOne returns an update builder for the given entity.

func (*DiscordBotClient) UpdateOneID

func (c *DiscordBotClient) UpdateOneID(id int) *DiscordBotUpdateOne

UpdateOneID returns an update builder for the given id.

func (*DiscordBotClient) Use

func (c *DiscordBotClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `discordbot.Hooks(f(g(h())))`.

type DiscordBotConnection

type DiscordBotConnection struct {
	Edges      []*DiscordBotEdge `json:"edges"`
	PageInfo   PageInfo          `json:"pageInfo"`
	TotalCount int               `json:"totalCount"`
}

DiscordBotConnection is the connection containing edges to DiscordBot.

type DiscordBotCreate

type DiscordBotCreate struct {
	// contains filtered or unexported fields
}

DiscordBotCreate is the builder for creating a DiscordBot entity.

func (*DiscordBotCreate) Exec

func (dbc *DiscordBotCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*DiscordBotCreate) ExecX

func (dbc *DiscordBotCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*DiscordBotCreate) Mutation

func (dbc *DiscordBotCreate) Mutation() *DiscordBotMutation

Mutation returns the DiscordBotMutation object of the builder.

func (*DiscordBotCreate) Save

func (dbc *DiscordBotCreate) Save(ctx context.Context) (*DiscordBot, error)

Save creates the DiscordBot in the database.

func (*DiscordBotCreate) SaveX

func (dbc *DiscordBotCreate) SaveX(ctx context.Context) *DiscordBot

SaveX calls Save and panics if Save returns an error.

func (*DiscordBotCreate) SetAccount

func (dbc *DiscordBotCreate) SetAccount(d *DiscordAccount) *DiscordBotCreate

SetAccount sets the "account" edge to the DiscordAccount entity.

func (*DiscordBotCreate) SetAccountID

func (dbc *DiscordBotCreate) SetAccountID(id int) *DiscordBotCreate

SetAccountID sets the "account" edge to the DiscordAccount entity by ID.

func (*DiscordBotCreate) SetInput

SetInput applies the change-set in the CreateDiscordBotInput on the create builder.

func (*DiscordBotCreate) SetNillableRepositoryID

func (dbc *DiscordBotCreate) SetNillableRepositoryID(id *int) *DiscordBotCreate

SetNillableRepositoryID sets the "repository" edge to the Repository entity by ID if the given value is not nil.

func (*DiscordBotCreate) SetProject

func (dbc *DiscordBotCreate) SetProject(p *Project) *DiscordBotCreate

SetProject sets the "project" edge to the Project entity.

func (*DiscordBotCreate) SetProjectID

func (dbc *DiscordBotCreate) SetProjectID(id int) *DiscordBotCreate

SetProjectID sets the "project" edge to the Project entity by ID.

func (*DiscordBotCreate) SetRepository

func (dbc *DiscordBotCreate) SetRepository(r *Repository) *DiscordBotCreate

SetRepository sets the "repository" edge to the Repository entity.

func (*DiscordBotCreate) SetRepositoryID

func (dbc *DiscordBotCreate) SetRepositoryID(id int) *DiscordBotCreate

SetRepositoryID sets the "repository" edge to the Repository entity by ID.

type DiscordBotCreateBulk

type DiscordBotCreateBulk struct {
	// contains filtered or unexported fields
}

DiscordBotCreateBulk is the builder for creating many DiscordBot entities in bulk.

func (*DiscordBotCreateBulk) Exec

func (dbcb *DiscordBotCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*DiscordBotCreateBulk) ExecX

func (dbcb *DiscordBotCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*DiscordBotCreateBulk) Save

func (dbcb *DiscordBotCreateBulk) Save(ctx context.Context) ([]*DiscordBot, error)

Save creates the DiscordBot entities in the database.

func (*DiscordBotCreateBulk) SaveX

func (dbcb *DiscordBotCreateBulk) SaveX(ctx context.Context) []*DiscordBot

SaveX is like Save, but panics if an error occurs.

type DiscordBotDelete

type DiscordBotDelete struct {
	// contains filtered or unexported fields
}

DiscordBotDelete is the builder for deleting a DiscordBot entity.

func (*DiscordBotDelete) Exec

func (dbd *DiscordBotDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*DiscordBotDelete) ExecX

func (dbd *DiscordBotDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*DiscordBotDelete) Where

Where appends a list predicates to the DiscordBotDelete builder.

type DiscordBotDeleteOne

type DiscordBotDeleteOne struct {
	// contains filtered or unexported fields
}

DiscordBotDeleteOne is the builder for deleting a single DiscordBot entity.

func (*DiscordBotDeleteOne) Exec

func (dbdo *DiscordBotDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*DiscordBotDeleteOne) ExecX

func (dbdo *DiscordBotDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

type DiscordBotEdge

type DiscordBotEdge struct {
	Node   *DiscordBot `json:"node"`
	Cursor Cursor      `json:"cursor"`
}

DiscordBotEdge is the edge representation of DiscordBot.

type DiscordBotEdges

type DiscordBotEdges struct {
	// Account holds the value of the account edge.
	Account *DiscordAccount `json:"account,omitempty"`
	// Project holds the value of the project edge.
	Project *Project `json:"project,omitempty"`
	// Repository holds the value of the repository edge.
	Repository *Repository `json:"repository,omitempty"`
	// contains filtered or unexported fields
}

DiscordBotEdges holds the relations/edges for other nodes in the graph.

func (DiscordBotEdges) AccountOrErr

func (e DiscordBotEdges) AccountOrErr() (*DiscordAccount, error)

AccountOrErr returns the Account value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (DiscordBotEdges) ProjectOrErr

func (e DiscordBotEdges) ProjectOrErr() (*Project, error)

ProjectOrErr returns the Project value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (DiscordBotEdges) RepositoryOrErr

func (e DiscordBotEdges) RepositoryOrErr() (*Repository, error)

RepositoryOrErr returns the Repository value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type DiscordBotGroupBy

type DiscordBotGroupBy struct {
	// contains filtered or unexported fields
}

DiscordBotGroupBy is the group-by builder for DiscordBot entities.

func (*DiscordBotGroupBy) Aggregate

func (dbgb *DiscordBotGroupBy) Aggregate(fns ...AggregateFunc) *DiscordBotGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*DiscordBotGroupBy) Bool

func (s *DiscordBotGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*DiscordBotGroupBy) BoolX

func (s *DiscordBotGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*DiscordBotGroupBy) Bools

func (s *DiscordBotGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*DiscordBotGroupBy) BoolsX

func (s *DiscordBotGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*DiscordBotGroupBy) Float64

func (s *DiscordBotGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*DiscordBotGroupBy) Float64X

func (s *DiscordBotGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*DiscordBotGroupBy) Float64s

func (s *DiscordBotGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*DiscordBotGroupBy) Float64sX

func (s *DiscordBotGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*DiscordBotGroupBy) Int

func (s *DiscordBotGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*DiscordBotGroupBy) IntX

func (s *DiscordBotGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*DiscordBotGroupBy) Ints

func (s *DiscordBotGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*DiscordBotGroupBy) IntsX

func (s *DiscordBotGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*DiscordBotGroupBy) Scan

func (dbgb *DiscordBotGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*DiscordBotGroupBy) ScanX

func (s *DiscordBotGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*DiscordBotGroupBy) String

func (s *DiscordBotGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*DiscordBotGroupBy) StringX

func (s *DiscordBotGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*DiscordBotGroupBy) Strings

func (s *DiscordBotGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*DiscordBotGroupBy) StringsX

func (s *DiscordBotGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type DiscordBotMutation

type DiscordBotMutation struct {
	// contains filtered or unexported fields
}

DiscordBotMutation represents an operation that mutates the DiscordBot nodes in the graph.

func (*DiscordBotMutation) AccountCleared

func (m *DiscordBotMutation) AccountCleared() bool

AccountCleared reports if the "account" edge to the DiscordAccount entity was cleared.

func (*DiscordBotMutation) AccountID

func (m *DiscordBotMutation) AccountID() (id int, exists bool)

AccountID returns the "account" edge ID in the mutation.

func (*DiscordBotMutation) AccountIDs

func (m *DiscordBotMutation) AccountIDs() (ids []int)

AccountIDs returns the "account" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use AccountID instead. It exists only for internal usage by the builders.

func (*DiscordBotMutation) AddField

func (m *DiscordBotMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*DiscordBotMutation) AddedEdges

func (m *DiscordBotMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*DiscordBotMutation) AddedField

func (m *DiscordBotMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*DiscordBotMutation) AddedFields

func (m *DiscordBotMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*DiscordBotMutation) AddedIDs

func (m *DiscordBotMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*DiscordBotMutation) ClearAccount

func (m *DiscordBotMutation) ClearAccount()

ClearAccount clears the "account" edge to the DiscordAccount entity.

func (*DiscordBotMutation) ClearEdge

func (m *DiscordBotMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*DiscordBotMutation) ClearField

func (m *DiscordBotMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*DiscordBotMutation) ClearProject

func (m *DiscordBotMutation) ClearProject()

ClearProject clears the "project" edge to the Project entity.

func (*DiscordBotMutation) ClearRepository

func (m *DiscordBotMutation) ClearRepository()

ClearRepository clears the "repository" edge to the Repository entity.

func (*DiscordBotMutation) ClearedEdges

func (m *DiscordBotMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*DiscordBotMutation) ClearedFields

func (m *DiscordBotMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (DiscordBotMutation) Client

func (m DiscordBotMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*DiscordBotMutation) EdgeCleared

func (m *DiscordBotMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*DiscordBotMutation) Field

func (m *DiscordBotMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*DiscordBotMutation) FieldCleared

func (m *DiscordBotMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*DiscordBotMutation) Fields

func (m *DiscordBotMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*DiscordBotMutation) ID

func (m *DiscordBotMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*DiscordBotMutation) IDs

func (m *DiscordBotMutation) IDs(ctx context.Context) ([]int, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*DiscordBotMutation) OldField

func (m *DiscordBotMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*DiscordBotMutation) Op

func (m *DiscordBotMutation) Op() Op

Op returns the operation name.

func (*DiscordBotMutation) ProjectCleared

func (m *DiscordBotMutation) ProjectCleared() bool

ProjectCleared reports if the "project" edge to the Project entity was cleared.

func (*DiscordBotMutation) ProjectID

func (m *DiscordBotMutation) ProjectID() (id int, exists bool)

ProjectID returns the "project" edge ID in the mutation.

func (*DiscordBotMutation) ProjectIDs

func (m *DiscordBotMutation) ProjectIDs() (ids []int)

ProjectIDs returns the "project" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ProjectID instead. It exists only for internal usage by the builders.

func (*DiscordBotMutation) RemovedEdges

func (m *DiscordBotMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*DiscordBotMutation) RemovedIDs

func (m *DiscordBotMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*DiscordBotMutation) RepositoryCleared

func (m *DiscordBotMutation) RepositoryCleared() bool

RepositoryCleared reports if the "repository" edge to the Repository entity was cleared.

func (*DiscordBotMutation) RepositoryID

func (m *DiscordBotMutation) RepositoryID() (id int, exists bool)

RepositoryID returns the "repository" edge ID in the mutation.

func (*DiscordBotMutation) RepositoryIDs

func (m *DiscordBotMutation) RepositoryIDs() (ids []int)

RepositoryIDs returns the "repository" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use RepositoryID instead. It exists only for internal usage by the builders.

func (*DiscordBotMutation) ResetAccount

func (m *DiscordBotMutation) ResetAccount()

ResetAccount resets all changes to the "account" edge.

func (*DiscordBotMutation) ResetEdge

func (m *DiscordBotMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*DiscordBotMutation) ResetField

func (m *DiscordBotMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*DiscordBotMutation) ResetProject

func (m *DiscordBotMutation) ResetProject()

ResetProject resets all changes to the "project" edge.

func (*DiscordBotMutation) ResetRepository

func (m *DiscordBotMutation) ResetRepository()

ResetRepository resets all changes to the "repository" edge.

func (*DiscordBotMutation) SetAccountID

func (m *DiscordBotMutation) SetAccountID(id int)

SetAccountID sets the "account" edge to the DiscordAccount entity by id.

func (*DiscordBotMutation) SetField

func (m *DiscordBotMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*DiscordBotMutation) SetProjectID

func (m *DiscordBotMutation) SetProjectID(id int)

SetProjectID sets the "project" edge to the Project entity by id.

func (*DiscordBotMutation) SetRepositoryID

func (m *DiscordBotMutation) SetRepositoryID(id int)

SetRepositoryID sets the "repository" edge to the Repository entity by id.

func (DiscordBotMutation) Tx

func (m DiscordBotMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*DiscordBotMutation) Type

func (m *DiscordBotMutation) Type() string

Type returns the node type of this mutation (DiscordBot).

func (*DiscordBotMutation) Where

func (m *DiscordBotMutation) Where(ps ...predicate.DiscordBot)

Where appends a list predicates to the DiscordBotMutation builder.

type DiscordBotOrder

type DiscordBotOrder struct {
	Direction OrderDirection        `json:"direction"`
	Field     *DiscordBotOrderField `json:"field"`
}

DiscordBotOrder defines the ordering of DiscordBot.

type DiscordBotOrderField

type DiscordBotOrderField struct {
	// contains filtered or unexported fields
}

DiscordBotOrderField defines the ordering field of DiscordBot.

type DiscordBotPaginateOption

type DiscordBotPaginateOption func(*discordbotPager) error

DiscordBotPaginateOption enables pagination customization.

func WithDiscordBotFilter

func WithDiscordBotFilter(filter func(*DiscordBotQuery) (*DiscordBotQuery, error)) DiscordBotPaginateOption

WithDiscordBotFilter configures pagination filter.

func WithDiscordBotOrder

func WithDiscordBotOrder(order *DiscordBotOrder) DiscordBotPaginateOption

WithDiscordBotOrder configures pagination ordering.

type DiscordBotQuery

type DiscordBotQuery struct {
	// contains filtered or unexported fields
}

DiscordBotQuery is the builder for querying DiscordBot entities.

func (*DiscordBotQuery) All

func (dbq *DiscordBotQuery) All(ctx context.Context) ([]*DiscordBot, error)

All executes the query and returns a list of DiscordBots.

func (*DiscordBotQuery) AllX

func (dbq *DiscordBotQuery) AllX(ctx context.Context) []*DiscordBot

AllX is like All, but panics if an error occurs.

func (*DiscordBotQuery) Clone

func (dbq *DiscordBotQuery) Clone() *DiscordBotQuery

Clone returns a duplicate of the DiscordBotQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*DiscordBotQuery) CollectFields

func (db *DiscordBotQuery) CollectFields(ctx context.Context, satisfies ...string) (*DiscordBotQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*DiscordBotQuery) Count

func (dbq *DiscordBotQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*DiscordBotQuery) CountX

func (dbq *DiscordBotQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*DiscordBotQuery) Exist

func (dbq *DiscordBotQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*DiscordBotQuery) ExistX

func (dbq *DiscordBotQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*DiscordBotQuery) First

func (dbq *DiscordBotQuery) First(ctx context.Context) (*DiscordBot, error)

First returns the first DiscordBot entity from the query. Returns a *NotFoundError when no DiscordBot was found.

func (*DiscordBotQuery) FirstID

func (dbq *DiscordBotQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first DiscordBot ID from the query. Returns a *NotFoundError when no DiscordBot ID was found.

func (*DiscordBotQuery) FirstIDX

func (dbq *DiscordBotQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*DiscordBotQuery) FirstX

func (dbq *DiscordBotQuery) FirstX(ctx context.Context) *DiscordBot

FirstX is like First, but panics if an error occurs.

func (*DiscordBotQuery) GroupBy

func (dbq *DiscordBotQuery) GroupBy(field string, fields ...string) *DiscordBotGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

func (*DiscordBotQuery) IDs

func (dbq *DiscordBotQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of DiscordBot IDs.

func (*DiscordBotQuery) IDsX

func (dbq *DiscordBotQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*DiscordBotQuery) Limit

func (dbq *DiscordBotQuery) Limit(limit int) *DiscordBotQuery

Limit adds a limit step to the query.

func (*DiscordBotQuery) Offset

func (dbq *DiscordBotQuery) Offset(offset int) *DiscordBotQuery

Offset adds an offset step to the query.

func (*DiscordBotQuery) Only

func (dbq *DiscordBotQuery) Only(ctx context.Context) (*DiscordBot, error)

Only returns a single DiscordBot entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one DiscordBot entity is found. Returns a *NotFoundError when no DiscordBot entities are found.

func (*DiscordBotQuery) OnlyID

func (dbq *DiscordBotQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only DiscordBot ID in the query. Returns a *NotSingularError when more than one DiscordBot ID is found. Returns a *NotFoundError when no entities are found.

func (*DiscordBotQuery) OnlyIDX

func (dbq *DiscordBotQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*DiscordBotQuery) OnlyX

func (dbq *DiscordBotQuery) OnlyX(ctx context.Context) *DiscordBot

OnlyX is like Only, but panics if an error occurs.

func (*DiscordBotQuery) Order

func (dbq *DiscordBotQuery) Order(o ...OrderFunc) *DiscordBotQuery

Order adds an order step to the query.

func (*DiscordBotQuery) Paginate

func (db *DiscordBotQuery) Paginate(
	ctx context.Context, after *Cursor, first *int,
	before *Cursor, last *int, opts ...DiscordBotPaginateOption,
) (*DiscordBotConnection, error)

Paginate executes the query and returns a relay based cursor connection to DiscordBot.

func (*DiscordBotQuery) QueryAccount

func (dbq *DiscordBotQuery) QueryAccount() *DiscordAccountQuery

QueryAccount chains the current query on the "account" edge.

func (*DiscordBotQuery) QueryProject

func (dbq *DiscordBotQuery) QueryProject() *ProjectQuery

QueryProject chains the current query on the "project" edge.

func (*DiscordBotQuery) QueryRepository

func (dbq *DiscordBotQuery) QueryRepository() *RepositoryQuery

QueryRepository chains the current query on the "repository" edge.

func (*DiscordBotQuery) Select

func (dbq *DiscordBotQuery) Select(fields ...string) *DiscordBotSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

func (*DiscordBotQuery) Unique

func (dbq *DiscordBotQuery) Unique(unique bool) *DiscordBotQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*DiscordBotQuery) Where

Where adds a new predicate for the DiscordBotQuery builder.

func (*DiscordBotQuery) WithAccount

func (dbq *DiscordBotQuery) WithAccount(opts ...func(*DiscordAccountQuery)) *DiscordBotQuery

WithAccount tells the query-builder to eager-load the nodes that are connected to the "account" edge. The optional arguments are used to configure the query builder of the edge.

func (*DiscordBotQuery) WithProject

func (dbq *DiscordBotQuery) WithProject(opts ...func(*ProjectQuery)) *DiscordBotQuery

WithProject tells the query-builder to eager-load the nodes that are connected to the "project" edge. The optional arguments are used to configure the query builder of the edge.

func (*DiscordBotQuery) WithRepository

func (dbq *DiscordBotQuery) WithRepository(opts ...func(*RepositoryQuery)) *DiscordBotQuery

WithRepository tells the query-builder to eager-load the nodes that are connected to the "repository" edge. The optional arguments are used to configure the query builder of the edge.

type DiscordBotSelect

type DiscordBotSelect struct {
	*DiscordBotQuery
	// contains filtered or unexported fields
}

DiscordBotSelect is the builder for selecting fields of DiscordBot entities.

func (*DiscordBotSelect) Bool

func (s *DiscordBotSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*DiscordBotSelect) BoolX

func (s *DiscordBotSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*DiscordBotSelect) Bools

func (s *DiscordBotSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*DiscordBotSelect) BoolsX

func (s *DiscordBotSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*DiscordBotSelect) Float64

func (s *DiscordBotSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*DiscordBotSelect) Float64X

func (s *DiscordBotSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*DiscordBotSelect) Float64s

func (s *DiscordBotSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*DiscordBotSelect) Float64sX

func (s *DiscordBotSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*DiscordBotSelect) Int

func (s *DiscordBotSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*DiscordBotSelect) IntX

func (s *DiscordBotSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*DiscordBotSelect) Ints

func (s *DiscordBotSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*DiscordBotSelect) IntsX

func (s *DiscordBotSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*DiscordBotSelect) Scan

func (dbs *DiscordBotSelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*DiscordBotSelect) ScanX

func (s *DiscordBotSelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*DiscordBotSelect) String

func (s *DiscordBotSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*DiscordBotSelect) StringX

func (s *DiscordBotSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*DiscordBotSelect) Strings

func (s *DiscordBotSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*DiscordBotSelect) StringsX

func (s *DiscordBotSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type DiscordBotUpdate

type DiscordBotUpdate struct {
	// contains filtered or unexported fields
}

DiscordBotUpdate is the builder for updating DiscordBot entities.

func (*DiscordBotUpdate) ClearAccount

func (dbu *DiscordBotUpdate) ClearAccount() *DiscordBotUpdate

ClearAccount clears the "account" edge to the DiscordAccount entity.

func (*DiscordBotUpdate) ClearProject

func (dbu *DiscordBotUpdate) ClearProject() *DiscordBotUpdate

ClearProject clears the "project" edge to the Project entity.

func (*DiscordBotUpdate) ClearRepository

func (dbu *DiscordBotUpdate) ClearRepository() *DiscordBotUpdate

ClearRepository clears the "repository" edge to the Repository entity.

func (*DiscordBotUpdate) Exec

func (dbu *DiscordBotUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*DiscordBotUpdate) ExecX

func (dbu *DiscordBotUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*DiscordBotUpdate) Mutation

func (dbu *DiscordBotUpdate) Mutation() *DiscordBotMutation

Mutation returns the DiscordBotMutation object of the builder.

func (*DiscordBotUpdate) Save

func (dbu *DiscordBotUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*DiscordBotUpdate) SaveX

func (dbu *DiscordBotUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*DiscordBotUpdate) SetAccount

func (dbu *DiscordBotUpdate) SetAccount(d *DiscordAccount) *DiscordBotUpdate

SetAccount sets the "account" edge to the DiscordAccount entity.

func (*DiscordBotUpdate) SetAccountID

func (dbu *DiscordBotUpdate) SetAccountID(id int) *DiscordBotUpdate

SetAccountID sets the "account" edge to the DiscordAccount entity by ID.

func (*DiscordBotUpdate) SetInput

SetInput applies the change-set in the UpdateDiscordBotInput on the update builder.

func (*DiscordBotUpdate) SetNillableRepositoryID

func (dbu *DiscordBotUpdate) SetNillableRepositoryID(id *int) *DiscordBotUpdate

SetNillableRepositoryID sets the "repository" edge to the Repository entity by ID if the given value is not nil.

func (*DiscordBotUpdate) SetProject

func (dbu *DiscordBotUpdate) SetProject(p *Project) *DiscordBotUpdate

SetProject sets the "project" edge to the Project entity.

func (*DiscordBotUpdate) SetProjectID

func (dbu *DiscordBotUpdate) SetProjectID(id int) *DiscordBotUpdate

SetProjectID sets the "project" edge to the Project entity by ID.

func (*DiscordBotUpdate) SetRepository

func (dbu *DiscordBotUpdate) SetRepository(r *Repository) *DiscordBotUpdate

SetRepository sets the "repository" edge to the Repository entity.

func (*DiscordBotUpdate) SetRepositoryID

func (dbu *DiscordBotUpdate) SetRepositoryID(id int) *DiscordBotUpdate

SetRepositoryID sets the "repository" edge to the Repository entity by ID.

func (*DiscordBotUpdate) Where

Where appends a list predicates to the DiscordBotUpdate builder.

type DiscordBotUpdateOne

type DiscordBotUpdateOne struct {
	// contains filtered or unexported fields
}

DiscordBotUpdateOne is the builder for updating a single DiscordBot entity.

func (*DiscordBotUpdateOne) ClearAccount

func (dbuo *DiscordBotUpdateOne) ClearAccount() *DiscordBotUpdateOne

ClearAccount clears the "account" edge to the DiscordAccount entity.

func (*DiscordBotUpdateOne) ClearProject

func (dbuo *DiscordBotUpdateOne) ClearProject() *DiscordBotUpdateOne

ClearProject clears the "project" edge to the Project entity.

func (*DiscordBotUpdateOne) ClearRepository

func (dbuo *DiscordBotUpdateOne) ClearRepository() *DiscordBotUpdateOne

ClearRepository clears the "repository" edge to the Repository entity.

func (*DiscordBotUpdateOne) Exec

func (dbuo *DiscordBotUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*DiscordBotUpdateOne) ExecX

func (dbuo *DiscordBotUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*DiscordBotUpdateOne) Mutation

func (dbuo *DiscordBotUpdateOne) Mutation() *DiscordBotMutation

Mutation returns the DiscordBotMutation object of the builder.

func (*DiscordBotUpdateOne) Save

func (dbuo *DiscordBotUpdateOne) Save(ctx context.Context) (*DiscordBot, error)

Save executes the query and returns the updated DiscordBot entity.

func (*DiscordBotUpdateOne) SaveX

func (dbuo *DiscordBotUpdateOne) SaveX(ctx context.Context) *DiscordBot

SaveX is like Save, but panics if an error occurs.

func (*DiscordBotUpdateOne) Select

func (dbuo *DiscordBotUpdateOne) Select(field string, fields ...string) *DiscordBotUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*DiscordBotUpdateOne) SetAccount

SetAccount sets the "account" edge to the DiscordAccount entity.

func (*DiscordBotUpdateOne) SetAccountID

func (dbuo *DiscordBotUpdateOne) SetAccountID(id int) *DiscordBotUpdateOne

SetAccountID sets the "account" edge to the DiscordAccount entity by ID.

func (*DiscordBotUpdateOne) SetInput

SetInput applies the change-set in the UpdateDiscordBotInput on the update-one builder.

func (*DiscordBotUpdateOne) SetNillableRepositoryID

func (dbuo *DiscordBotUpdateOne) SetNillableRepositoryID(id *int) *DiscordBotUpdateOne

SetNillableRepositoryID sets the "repository" edge to the Repository entity by ID if the given value is not nil.

func (*DiscordBotUpdateOne) SetProject

func (dbuo *DiscordBotUpdateOne) SetProject(p *Project) *DiscordBotUpdateOne

SetProject sets the "project" edge to the Project entity.

func (*DiscordBotUpdateOne) SetProjectID

func (dbuo *DiscordBotUpdateOne) SetProjectID(id int) *DiscordBotUpdateOne

SetProjectID sets the "project" edge to the Project entity by ID.

func (*DiscordBotUpdateOne) SetRepository

func (dbuo *DiscordBotUpdateOne) SetRepository(r *Repository) *DiscordBotUpdateOne

SetRepository sets the "repository" edge to the Repository entity.

func (*DiscordBotUpdateOne) SetRepositoryID

func (dbuo *DiscordBotUpdateOne) SetRepositoryID(id int) *DiscordBotUpdateOne

SetRepositoryID sets the "repository" edge to the Repository entity by ID.

type DiscordBotWhereInput

type DiscordBotWhereInput struct {
	Predicates []predicate.DiscordBot  `json:"-"`
	Not        *DiscordBotWhereInput   `json:"not,omitempty"`
	Or         []*DiscordBotWhereInput `json:"or,omitempty"`
	And        []*DiscordBotWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "account" edge predicates.
	HasAccount     *bool                       `json:"hasAccount,omitempty"`
	HasAccountWith []*DiscordAccountWhereInput `json:"hasAccountWith,omitempty"`

	// "project" edge predicates.
	HasProject     *bool                `json:"hasProject,omitempty"`
	HasProjectWith []*ProjectWhereInput `json:"hasProjectWith,omitempty"`

	// "repository" edge predicates.
	HasRepository     *bool                   `json:"hasRepository,omitempty"`
	HasRepositoryWith []*RepositoryWhereInput `json:"hasRepositoryWith,omitempty"`
}

DiscordBotWhereInput represents a where input for filtering DiscordBot queries.

func (*DiscordBotWhereInput) AddPredicates

func (i *DiscordBotWhereInput) AddPredicates(predicates ...predicate.DiscordBot)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*DiscordBotWhereInput) Filter

Filter applies the DiscordBotWhereInput filter on the DiscordBotQuery builder.

func (*DiscordBotWhereInput) P

P returns a predicate for filtering discordbots. An error is returned if the input is empty or invalid.

type DiscordBots

type DiscordBots []*DiscordBot

DiscordBots is a parsable slice of DiscordBot.

type Edge

type Edge struct {
	Type string `json:"type,omitempty"` // edge type.
	Name string `json:"name,omitempty"` // edge name.
	IDs  []int  `json:"ids,omitempty"`  // node ids (where this edge point to).
}

Edges between two nodes.

type Field

type Field struct {
	Type  string `json:"type,omitempty"`  // field type.
	Name  string `json:"name,omitempty"`  // field name (as in struct).
	Value string `json:"value,omitempty"` // stringified value.
}

Field of a node.

type GithubAccount

type GithubAccount struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Username holds the value of the "username" field.
	Username string `json:"username,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the GithubAccountQuery when eager-loading is set.
	Edges GithubAccountEdges `json:"edges"`
	// contains filtered or unexported fields
}

GithubAccount is the model entity for the GithubAccount schema.

func (*GithubAccount) NamedOrganizationMemberships

func (ga *GithubAccount) NamedOrganizationMemberships(name string) ([]*GithubOrganizationMember, error)

NamedOrganizationMemberships returns the OrganizationMemberships named value or an error if the edge was not loaded in eager-loading with this name.

func (*GithubAccount) NamedRepositories

func (ga *GithubAccount) NamedRepositories(name string) ([]*Repository, error)

NamedRepositories returns the Repositories named value or an error if the edge was not loaded in eager-loading with this name.

func (*GithubAccount) Node

func (ga *GithubAccount) Node(ctx context.Context) (node *Node, err error)

func (*GithubAccount) OrganizationMemberships

func (ga *GithubAccount) OrganizationMemberships(ctx context.Context) ([]*GithubOrganizationMember, error)

func (*GithubAccount) Owner

func (ga *GithubAccount) Owner(ctx context.Context) (*User, error)

func (*GithubAccount) QueryOrganizationMemberships

func (ga *GithubAccount) QueryOrganizationMemberships() *GithubOrganizationMemberQuery

QueryOrganizationMemberships queries the "organization_memberships" edge of the GithubAccount entity.

func (*GithubAccount) QueryOwner

func (ga *GithubAccount) QueryOwner() *UserQuery

QueryOwner queries the "owner" edge of the GithubAccount entity.

func (*GithubAccount) QueryRepositories

func (ga *GithubAccount) QueryRepositories() *RepositoryQuery

QueryRepositories queries the "repositories" edge of the GithubAccount entity.

func (*GithubAccount) Repositories

func (ga *GithubAccount) Repositories(ctx context.Context) ([]*Repository, error)

func (*GithubAccount) String

func (ga *GithubAccount) String() string

String implements the fmt.Stringer.

func (*GithubAccount) ToEdge

ToEdge converts GithubAccount into GithubAccountEdge.

func (*GithubAccount) Unwrap

func (ga *GithubAccount) Unwrap() *GithubAccount

Unwrap unwraps the GithubAccount entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*GithubAccount) Update

func (ga *GithubAccount) Update() *GithubAccountUpdateOne

Update returns a builder for updating this GithubAccount. Note that you need to call GithubAccount.Unwrap() before calling this method if this GithubAccount was returned from a transaction, and the transaction was committed or rolled back.

type GithubAccountClient

type GithubAccountClient struct {
	// contains filtered or unexported fields
}

GithubAccountClient is a client for the GithubAccount schema.

func NewGithubAccountClient

func NewGithubAccountClient(c config) *GithubAccountClient

NewGithubAccountClient returns a client for the GithubAccount from the given config.

func (*GithubAccountClient) Create

Create returns a builder for creating a GithubAccount entity.

func (*GithubAccountClient) CreateBulk

CreateBulk returns a builder for creating a bulk of GithubAccount entities.

func (*GithubAccountClient) Delete

Delete returns a delete builder for GithubAccount.

func (*GithubAccountClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*GithubAccountClient) DeleteOneID

func (c *GithubAccountClient) DeleteOneID(id int) *GithubAccountDeleteOne

DeleteOne returns a builder for deleting the given entity by its id.

func (*GithubAccountClient) Get

Get returns a GithubAccount entity by its id.

func (*GithubAccountClient) GetX

GetX is like Get, but panics if an error occurs.

func (*GithubAccountClient) Hooks

func (c *GithubAccountClient) Hooks() []Hook

Hooks returns the client hooks.

func (*GithubAccountClient) Query

Query returns a query builder for GithubAccount.

func (*GithubAccountClient) QueryOrganizationMemberships

func (c *GithubAccountClient) QueryOrganizationMemberships(ga *GithubAccount) *GithubOrganizationMemberQuery

QueryOrganizationMemberships queries the organization_memberships edge of a GithubAccount.

func (*GithubAccountClient) QueryOwner

func (c *GithubAccountClient) QueryOwner(ga *GithubAccount) *UserQuery

QueryOwner queries the owner edge of a GithubAccount.

func (*GithubAccountClient) QueryRepositories

func (c *GithubAccountClient) QueryRepositories(ga *GithubAccount) *RepositoryQuery

QueryRepositories queries the repositories edge of a GithubAccount.

func (*GithubAccountClient) Update

Update returns an update builder for GithubAccount.

func (*GithubAccountClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*GithubAccountClient) UpdateOneID

func (c *GithubAccountClient) UpdateOneID(id int) *GithubAccountUpdateOne

UpdateOneID returns an update builder for the given id.

func (*GithubAccountClient) Use

func (c *GithubAccountClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `githubaccount.Hooks(f(g(h())))`.

type GithubAccountConnection

type GithubAccountConnection struct {
	Edges      []*GithubAccountEdge `json:"edges"`
	PageInfo   PageInfo             `json:"pageInfo"`
	TotalCount int                  `json:"totalCount"`
}

GithubAccountConnection is the connection containing edges to GithubAccount.

type GithubAccountCreate

type GithubAccountCreate struct {
	// contains filtered or unexported fields
}

GithubAccountCreate is the builder for creating a GithubAccount entity.

func (*GithubAccountCreate) AddOrganizationMembershipIDs

func (gac *GithubAccountCreate) AddOrganizationMembershipIDs(ids ...int) *GithubAccountCreate

AddOrganizationMembershipIDs adds the "organization_memberships" edge to the GithubOrganizationMember entity by IDs.

func (*GithubAccountCreate) AddOrganizationMemberships

func (gac *GithubAccountCreate) AddOrganizationMemberships(g ...*GithubOrganizationMember) *GithubAccountCreate

AddOrganizationMemberships adds the "organization_memberships" edges to the GithubOrganizationMember entity.

func (*GithubAccountCreate) AddRepositories

func (gac *GithubAccountCreate) AddRepositories(r ...*Repository) *GithubAccountCreate

AddRepositories adds the "repositories" edges to the Repository entity.

func (*GithubAccountCreate) AddRepositoryIDs

func (gac *GithubAccountCreate) AddRepositoryIDs(ids ...int) *GithubAccountCreate

AddRepositoryIDs adds the "repositories" edge to the Repository entity by IDs.

func (*GithubAccountCreate) Exec

func (gac *GithubAccountCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*GithubAccountCreate) ExecX

func (gac *GithubAccountCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*GithubAccountCreate) Mutation

func (gac *GithubAccountCreate) Mutation() *GithubAccountMutation

Mutation returns the GithubAccountMutation object of the builder.

func (*GithubAccountCreate) Save

Save creates the GithubAccount in the database.

func (*GithubAccountCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*GithubAccountCreate) SetInput

SetInput applies the change-set in the CreateGithubAccountInput on the create builder.

func (*GithubAccountCreate) SetOwner

func (gac *GithubAccountCreate) SetOwner(u *User) *GithubAccountCreate

SetOwner sets the "owner" edge to the User entity.

func (*GithubAccountCreate) SetOwnerID

func (gac *GithubAccountCreate) SetOwnerID(id int) *GithubAccountCreate

SetOwnerID sets the "owner" edge to the User entity by ID.

func (*GithubAccountCreate) SetUsername

func (gac *GithubAccountCreate) SetUsername(s string) *GithubAccountCreate

SetUsername sets the "username" field.

type GithubAccountCreateBulk

type GithubAccountCreateBulk struct {
	// contains filtered or unexported fields
}

GithubAccountCreateBulk is the builder for creating many GithubAccount entities in bulk.

func (*GithubAccountCreateBulk) Exec

func (gacb *GithubAccountCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*GithubAccountCreateBulk) ExecX

func (gacb *GithubAccountCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*GithubAccountCreateBulk) Save

Save creates the GithubAccount entities in the database.

func (*GithubAccountCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type GithubAccountDelete

type GithubAccountDelete struct {
	// contains filtered or unexported fields
}

GithubAccountDelete is the builder for deleting a GithubAccount entity.

func (*GithubAccountDelete) Exec

func (gad *GithubAccountDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*GithubAccountDelete) ExecX

func (gad *GithubAccountDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*GithubAccountDelete) Where

Where appends a list predicates to the GithubAccountDelete builder.

type GithubAccountDeleteOne

type GithubAccountDeleteOne struct {
	// contains filtered or unexported fields
}

GithubAccountDeleteOne is the builder for deleting a single GithubAccount entity.

func (*GithubAccountDeleteOne) Exec

func (gado *GithubAccountDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*GithubAccountDeleteOne) ExecX

func (gado *GithubAccountDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

type GithubAccountEdge

type GithubAccountEdge struct {
	Node   *GithubAccount `json:"node"`
	Cursor Cursor         `json:"cursor"`
}

GithubAccountEdge is the edge representation of GithubAccount.

type GithubAccountEdges

type GithubAccountEdges struct {
	// Owner holds the value of the owner edge.
	Owner *User `json:"owner,omitempty"`
	// OrganizationMemberships holds the value of the organization_memberships edge.
	OrganizationMemberships []*GithubOrganizationMember `json:"organization_memberships,omitempty"`
	// Repositories holds the value of the repositories edge.
	Repositories []*Repository `json:"repositories,omitempty"`
	// contains filtered or unexported fields
}

GithubAccountEdges holds the relations/edges for other nodes in the graph.

func (GithubAccountEdges) OrganizationMembershipsOrErr

func (e GithubAccountEdges) OrganizationMembershipsOrErr() ([]*GithubOrganizationMember, error)

OrganizationMembershipsOrErr returns the OrganizationMemberships value or an error if the edge was not loaded in eager-loading.

func (GithubAccountEdges) OwnerOrErr

func (e GithubAccountEdges) OwnerOrErr() (*User, error)

OwnerOrErr returns the Owner value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (GithubAccountEdges) RepositoriesOrErr

func (e GithubAccountEdges) RepositoriesOrErr() ([]*Repository, error)

RepositoriesOrErr returns the Repositories value or an error if the edge was not loaded in eager-loading.

type GithubAccountGroupBy

type GithubAccountGroupBy struct {
	// contains filtered or unexported fields
}

GithubAccountGroupBy is the group-by builder for GithubAccount entities.

func (*GithubAccountGroupBy) Aggregate

func (gagb *GithubAccountGroupBy) Aggregate(fns ...AggregateFunc) *GithubAccountGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*GithubAccountGroupBy) Bool

func (s *GithubAccountGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*GithubAccountGroupBy) BoolX

func (s *GithubAccountGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*GithubAccountGroupBy) Bools

func (s *GithubAccountGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*GithubAccountGroupBy) BoolsX

func (s *GithubAccountGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*GithubAccountGroupBy) Float64

func (s *GithubAccountGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*GithubAccountGroupBy) Float64X

func (s *GithubAccountGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*GithubAccountGroupBy) Float64s

func (s *GithubAccountGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*GithubAccountGroupBy) Float64sX

func (s *GithubAccountGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*GithubAccountGroupBy) Int

func (s *GithubAccountGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*GithubAccountGroupBy) IntX

func (s *GithubAccountGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*GithubAccountGroupBy) Ints

func (s *GithubAccountGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*GithubAccountGroupBy) IntsX

func (s *GithubAccountGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*GithubAccountGroupBy) Scan

func (gagb *GithubAccountGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*GithubAccountGroupBy) ScanX

func (s *GithubAccountGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*GithubAccountGroupBy) String

func (s *GithubAccountGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*GithubAccountGroupBy) StringX

func (s *GithubAccountGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*GithubAccountGroupBy) Strings

func (s *GithubAccountGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*GithubAccountGroupBy) StringsX

func (s *GithubAccountGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type GithubAccountMutation

type GithubAccountMutation struct {
	// contains filtered or unexported fields
}

GithubAccountMutation represents an operation that mutates the GithubAccount nodes in the graph.

func (*GithubAccountMutation) AddField

func (m *GithubAccountMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*GithubAccountMutation) AddOrganizationMembershipIDs

func (m *GithubAccountMutation) AddOrganizationMembershipIDs(ids ...int)

AddOrganizationMembershipIDs adds the "organization_memberships" edge to the GithubOrganizationMember entity by ids.

func (*GithubAccountMutation) AddRepositoryIDs

func (m *GithubAccountMutation) AddRepositoryIDs(ids ...int)

AddRepositoryIDs adds the "repositories" edge to the Repository entity by ids.

func (*GithubAccountMutation) AddedEdges

func (m *GithubAccountMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*GithubAccountMutation) AddedField

func (m *GithubAccountMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*GithubAccountMutation) AddedFields

func (m *GithubAccountMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*GithubAccountMutation) AddedIDs

func (m *GithubAccountMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*GithubAccountMutation) ClearEdge

func (m *GithubAccountMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*GithubAccountMutation) ClearField

func (m *GithubAccountMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*GithubAccountMutation) ClearOrganizationMemberships

func (m *GithubAccountMutation) ClearOrganizationMemberships()

ClearOrganizationMemberships clears the "organization_memberships" edge to the GithubOrganizationMember entity.

func (*GithubAccountMutation) ClearOwner

func (m *GithubAccountMutation) ClearOwner()

ClearOwner clears the "owner" edge to the User entity.

func (*GithubAccountMutation) ClearRepositories

func (m *GithubAccountMutation) ClearRepositories()

ClearRepositories clears the "repositories" edge to the Repository entity.

func (*GithubAccountMutation) ClearedEdges

func (m *GithubAccountMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*GithubAccountMutation) ClearedFields

func (m *GithubAccountMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (GithubAccountMutation) Client

func (m GithubAccountMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*GithubAccountMutation) EdgeCleared

func (m *GithubAccountMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*GithubAccountMutation) Field

func (m *GithubAccountMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*GithubAccountMutation) FieldCleared

func (m *GithubAccountMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*GithubAccountMutation) Fields

func (m *GithubAccountMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*GithubAccountMutation) ID

func (m *GithubAccountMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*GithubAccountMutation) IDs

func (m *GithubAccountMutation) IDs(ctx context.Context) ([]int, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*GithubAccountMutation) OldField

func (m *GithubAccountMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*GithubAccountMutation) OldUsername

func (m *GithubAccountMutation) OldUsername(ctx context.Context) (v string, err error)

OldUsername returns the old "username" field's value of the GithubAccount entity. If the GithubAccount object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*GithubAccountMutation) Op

func (m *GithubAccountMutation) Op() Op

Op returns the operation name.

func (*GithubAccountMutation) OrganizationMembershipsCleared

func (m *GithubAccountMutation) OrganizationMembershipsCleared() bool

OrganizationMembershipsCleared reports if the "organization_memberships" edge to the GithubOrganizationMember entity was cleared.

func (*GithubAccountMutation) OrganizationMembershipsIDs

func (m *GithubAccountMutation) OrganizationMembershipsIDs() (ids []int)

OrganizationMembershipsIDs returns the "organization_memberships" edge IDs in the mutation.

func (*GithubAccountMutation) OwnerCleared

func (m *GithubAccountMutation) OwnerCleared() bool

OwnerCleared reports if the "owner" edge to the User entity was cleared.

func (*GithubAccountMutation) OwnerID

func (m *GithubAccountMutation) OwnerID() (id int, exists bool)

OwnerID returns the "owner" edge ID in the mutation.

func (*GithubAccountMutation) OwnerIDs

func (m *GithubAccountMutation) OwnerIDs() (ids []int)

OwnerIDs returns the "owner" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use OwnerID instead. It exists only for internal usage by the builders.

func (*GithubAccountMutation) RemoveOrganizationMembershipIDs

func (m *GithubAccountMutation) RemoveOrganizationMembershipIDs(ids ...int)

RemoveOrganizationMembershipIDs removes the "organization_memberships" edge to the GithubOrganizationMember entity by IDs.

func (*GithubAccountMutation) RemoveRepositoryIDs

func (m *GithubAccountMutation) RemoveRepositoryIDs(ids ...int)

RemoveRepositoryIDs removes the "repositories" edge to the Repository entity by IDs.

func (*GithubAccountMutation) RemovedEdges

func (m *GithubAccountMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*GithubAccountMutation) RemovedIDs

func (m *GithubAccountMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*GithubAccountMutation) RemovedOrganizationMembershipsIDs

func (m *GithubAccountMutation) RemovedOrganizationMembershipsIDs() (ids []int)

RemovedOrganizationMemberships returns the removed IDs of the "organization_memberships" edge to the GithubOrganizationMember entity.

func (*GithubAccountMutation) RemovedRepositoriesIDs

func (m *GithubAccountMutation) RemovedRepositoriesIDs() (ids []int)

RemovedRepositories returns the removed IDs of the "repositories" edge to the Repository entity.

func (*GithubAccountMutation) RepositoriesCleared

func (m *GithubAccountMutation) RepositoriesCleared() bool

RepositoriesCleared reports if the "repositories" edge to the Repository entity was cleared.

func (*GithubAccountMutation) RepositoriesIDs

func (m *GithubAccountMutation) RepositoriesIDs() (ids []int)

RepositoriesIDs returns the "repositories" edge IDs in the mutation.

func (*GithubAccountMutation) ResetEdge

func (m *GithubAccountMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*GithubAccountMutation) ResetField

func (m *GithubAccountMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*GithubAccountMutation) ResetOrganizationMemberships

func (m *GithubAccountMutation) ResetOrganizationMemberships()

ResetOrganizationMemberships resets all changes to the "organization_memberships" edge.

func (*GithubAccountMutation) ResetOwner

func (m *GithubAccountMutation) ResetOwner()

ResetOwner resets all changes to the "owner" edge.

func (*GithubAccountMutation) ResetRepositories

func (m *GithubAccountMutation) ResetRepositories()

ResetRepositories resets all changes to the "repositories" edge.

func (*GithubAccountMutation) ResetUsername

func (m *GithubAccountMutation) ResetUsername()

ResetUsername resets all changes to the "username" field.

func (*GithubAccountMutation) SetField

func (m *GithubAccountMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*GithubAccountMutation) SetOwnerID

func (m *GithubAccountMutation) SetOwnerID(id int)

SetOwnerID sets the "owner" edge to the User entity by id.

func (*GithubAccountMutation) SetUsername

func (m *GithubAccountMutation) SetUsername(s string)

SetUsername sets the "username" field.

func (GithubAccountMutation) Tx

func (m GithubAccountMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*GithubAccountMutation) Type

func (m *GithubAccountMutation) Type() string

Type returns the node type of this mutation (GithubAccount).

func (*GithubAccountMutation) Username

func (m *GithubAccountMutation) Username() (r string, exists bool)

Username returns the value of the "username" field in the mutation.

func (*GithubAccountMutation) Where

Where appends a list predicates to the GithubAccountMutation builder.

type GithubAccountOrder

type GithubAccountOrder struct {
	Direction OrderDirection           `json:"direction"`
	Field     *GithubAccountOrderField `json:"field"`
}

GithubAccountOrder defines the ordering of GithubAccount.

type GithubAccountOrderField

type GithubAccountOrderField struct {
	// contains filtered or unexported fields
}

GithubAccountOrderField defines the ordering field of GithubAccount.

func (GithubAccountOrderField) MarshalGQL

func (f GithubAccountOrderField) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (GithubAccountOrderField) String

func (f GithubAccountOrderField) String() string

String implement fmt.Stringer interface.

func (*GithubAccountOrderField) UnmarshalGQL

func (f *GithubAccountOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type GithubAccountPaginateOption

type GithubAccountPaginateOption func(*githubaccountPager) error

GithubAccountPaginateOption enables pagination customization.

func WithGithubAccountFilter

func WithGithubAccountFilter(filter func(*GithubAccountQuery) (*GithubAccountQuery, error)) GithubAccountPaginateOption

WithGithubAccountFilter configures pagination filter.

func WithGithubAccountOrder

func WithGithubAccountOrder(order *GithubAccountOrder) GithubAccountPaginateOption

WithGithubAccountOrder configures pagination ordering.

type GithubAccountQuery

type GithubAccountQuery struct {
	// contains filtered or unexported fields
}

GithubAccountQuery is the builder for querying GithubAccount entities.

func (*GithubAccountQuery) All

All executes the query and returns a list of GithubAccounts.

func (*GithubAccountQuery) AllX

func (gaq *GithubAccountQuery) AllX(ctx context.Context) []*GithubAccount

AllX is like All, but panics if an error occurs.

func (*GithubAccountQuery) Clone

func (gaq *GithubAccountQuery) Clone() *GithubAccountQuery

Clone returns a duplicate of the GithubAccountQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*GithubAccountQuery) CollectFields

func (ga *GithubAccountQuery) CollectFields(ctx context.Context, satisfies ...string) (*GithubAccountQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*GithubAccountQuery) Count

func (gaq *GithubAccountQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*GithubAccountQuery) CountX

func (gaq *GithubAccountQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*GithubAccountQuery) Exist

func (gaq *GithubAccountQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*GithubAccountQuery) ExistX

func (gaq *GithubAccountQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*GithubAccountQuery) First

First returns the first GithubAccount entity from the query. Returns a *NotFoundError when no GithubAccount was found.

func (*GithubAccountQuery) FirstID

func (gaq *GithubAccountQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first GithubAccount ID from the query. Returns a *NotFoundError when no GithubAccount ID was found.

func (*GithubAccountQuery) FirstIDX

func (gaq *GithubAccountQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*GithubAccountQuery) FirstX

func (gaq *GithubAccountQuery) FirstX(ctx context.Context) *GithubAccount

FirstX is like First, but panics if an error occurs.

func (*GithubAccountQuery) GroupBy

func (gaq *GithubAccountQuery) GroupBy(field string, fields ...string) *GithubAccountGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Username string `json:"username,omitempty"`
	Count int `json:"count,omitempty"`
}

client.GithubAccount.Query().
	GroupBy(githubaccount.FieldUsername).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*GithubAccountQuery) IDs

func (gaq *GithubAccountQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of GithubAccount IDs.

func (*GithubAccountQuery) IDsX

func (gaq *GithubAccountQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*GithubAccountQuery) Limit

func (gaq *GithubAccountQuery) Limit(limit int) *GithubAccountQuery

Limit adds a limit step to the query.

func (*GithubAccountQuery) Offset

func (gaq *GithubAccountQuery) Offset(offset int) *GithubAccountQuery

Offset adds an offset step to the query.

func (*GithubAccountQuery) Only

Only returns a single GithubAccount entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one GithubAccount entity is found. Returns a *NotFoundError when no GithubAccount entities are found.

func (*GithubAccountQuery) OnlyID

func (gaq *GithubAccountQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only GithubAccount ID in the query. Returns a *NotSingularError when more than one GithubAccount ID is found. Returns a *NotFoundError when no entities are found.

func (*GithubAccountQuery) OnlyIDX

func (gaq *GithubAccountQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*GithubAccountQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*GithubAccountQuery) Order

Order adds an order step to the query.

func (*GithubAccountQuery) Paginate

func (ga *GithubAccountQuery) Paginate(
	ctx context.Context, after *Cursor, first *int,
	before *Cursor, last *int, opts ...GithubAccountPaginateOption,
) (*GithubAccountConnection, error)

Paginate executes the query and returns a relay based cursor connection to GithubAccount.

func (*GithubAccountQuery) QueryOrganizationMemberships

func (gaq *GithubAccountQuery) QueryOrganizationMemberships() *GithubOrganizationMemberQuery

QueryOrganizationMemberships chains the current query on the "organization_memberships" edge.

func (*GithubAccountQuery) QueryOwner

func (gaq *GithubAccountQuery) QueryOwner() *UserQuery

QueryOwner chains the current query on the "owner" edge.

func (*GithubAccountQuery) QueryRepositories

func (gaq *GithubAccountQuery) QueryRepositories() *RepositoryQuery

QueryRepositories chains the current query on the "repositories" edge.

func (*GithubAccountQuery) Select

func (gaq *GithubAccountQuery) Select(fields ...string) *GithubAccountSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Username string `json:"username,omitempty"`
}

client.GithubAccount.Query().
	Select(githubaccount.FieldUsername).
	Scan(ctx, &v)

func (*GithubAccountQuery) Unique

func (gaq *GithubAccountQuery) Unique(unique bool) *GithubAccountQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*GithubAccountQuery) Where

Where adds a new predicate for the GithubAccountQuery builder.

func (*GithubAccountQuery) WithNamedOrganizationMemberships

func (gaq *GithubAccountQuery) WithNamedOrganizationMemberships(name string, opts ...func(*GithubOrganizationMemberQuery)) *GithubAccountQuery

WithNamedOrganizationMemberships tells the query-builder to eager-load the nodes that are connected to the "organization_memberships" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*GithubAccountQuery) WithNamedRepositories

func (gaq *GithubAccountQuery) WithNamedRepositories(name string, opts ...func(*RepositoryQuery)) *GithubAccountQuery

WithNamedRepositories tells the query-builder to eager-load the nodes that are connected to the "repositories" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*GithubAccountQuery) WithOrganizationMemberships

func (gaq *GithubAccountQuery) WithOrganizationMemberships(opts ...func(*GithubOrganizationMemberQuery)) *GithubAccountQuery

WithOrganizationMemberships tells the query-builder to eager-load the nodes that are connected to the "organization_memberships" edge. The optional arguments are used to configure the query builder of the edge.

func (*GithubAccountQuery) WithOwner

func (gaq *GithubAccountQuery) WithOwner(opts ...func(*UserQuery)) *GithubAccountQuery

WithOwner tells the query-builder to eager-load the nodes that are connected to the "owner" edge. The optional arguments are used to configure the query builder of the edge.

func (*GithubAccountQuery) WithRepositories

func (gaq *GithubAccountQuery) WithRepositories(opts ...func(*RepositoryQuery)) *GithubAccountQuery

WithRepositories tells the query-builder to eager-load the nodes that are connected to the "repositories" edge. The optional arguments are used to configure the query builder of the edge.

type GithubAccountSelect

type GithubAccountSelect struct {
	*GithubAccountQuery
	// contains filtered or unexported fields
}

GithubAccountSelect is the builder for selecting fields of GithubAccount entities.

func (*GithubAccountSelect) Bool

func (s *GithubAccountSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*GithubAccountSelect) BoolX

func (s *GithubAccountSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*GithubAccountSelect) Bools

func (s *GithubAccountSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*GithubAccountSelect) BoolsX

func (s *GithubAccountSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*GithubAccountSelect) Float64

func (s *GithubAccountSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*GithubAccountSelect) Float64X

func (s *GithubAccountSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*GithubAccountSelect) Float64s

func (s *GithubAccountSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*GithubAccountSelect) Float64sX

func (s *GithubAccountSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*GithubAccountSelect) Int

func (s *GithubAccountSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*GithubAccountSelect) IntX

func (s *GithubAccountSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*GithubAccountSelect) Ints

func (s *GithubAccountSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*GithubAccountSelect) IntsX

func (s *GithubAccountSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*GithubAccountSelect) Scan

func (gas *GithubAccountSelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*GithubAccountSelect) ScanX

func (s *GithubAccountSelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*GithubAccountSelect) String

func (s *GithubAccountSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*GithubAccountSelect) StringX

func (s *GithubAccountSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*GithubAccountSelect) Strings

func (s *GithubAccountSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*GithubAccountSelect) StringsX

func (s *GithubAccountSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type GithubAccountUpdate

type GithubAccountUpdate struct {
	// contains filtered or unexported fields
}

GithubAccountUpdate is the builder for updating GithubAccount entities.

func (*GithubAccountUpdate) AddOrganizationMembershipIDs

func (gau *GithubAccountUpdate) AddOrganizationMembershipIDs(ids ...int) *GithubAccountUpdate

AddOrganizationMembershipIDs adds the "organization_memberships" edge to the GithubOrganizationMember entity by IDs.

func (*GithubAccountUpdate) AddOrganizationMemberships

func (gau *GithubAccountUpdate) AddOrganizationMemberships(g ...*GithubOrganizationMember) *GithubAccountUpdate

AddOrganizationMemberships adds the "organization_memberships" edges to the GithubOrganizationMember entity.

func (*GithubAccountUpdate) AddRepositories

func (gau *GithubAccountUpdate) AddRepositories(r ...*Repository) *GithubAccountUpdate

AddRepositories adds the "repositories" edges to the Repository entity.

func (*GithubAccountUpdate) AddRepositoryIDs

func (gau *GithubAccountUpdate) AddRepositoryIDs(ids ...int) *GithubAccountUpdate

AddRepositoryIDs adds the "repositories" edge to the Repository entity by IDs.

func (*GithubAccountUpdate) ClearOrganizationMemberships

func (gau *GithubAccountUpdate) ClearOrganizationMemberships() *GithubAccountUpdate

ClearOrganizationMemberships clears all "organization_memberships" edges to the GithubOrganizationMember entity.

func (*GithubAccountUpdate) ClearOwner

func (gau *GithubAccountUpdate) ClearOwner() *GithubAccountUpdate

ClearOwner clears the "owner" edge to the User entity.

func (*GithubAccountUpdate) ClearRepositories

func (gau *GithubAccountUpdate) ClearRepositories() *GithubAccountUpdate

ClearRepositories clears all "repositories" edges to the Repository entity.

func (*GithubAccountUpdate) Exec

func (gau *GithubAccountUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*GithubAccountUpdate) ExecX

func (gau *GithubAccountUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*GithubAccountUpdate) Mutation

func (gau *GithubAccountUpdate) Mutation() *GithubAccountMutation

Mutation returns the GithubAccountMutation object of the builder.

func (*GithubAccountUpdate) RemoveOrganizationMembershipIDs

func (gau *GithubAccountUpdate) RemoveOrganizationMembershipIDs(ids ...int) *GithubAccountUpdate

RemoveOrganizationMembershipIDs removes the "organization_memberships" edge to GithubOrganizationMember entities by IDs.

func (*GithubAccountUpdate) RemoveOrganizationMemberships

func (gau *GithubAccountUpdate) RemoveOrganizationMemberships(g ...*GithubOrganizationMember) *GithubAccountUpdate

RemoveOrganizationMemberships removes "organization_memberships" edges to GithubOrganizationMember entities.

func (*GithubAccountUpdate) RemoveRepositories

func (gau *GithubAccountUpdate) RemoveRepositories(r ...*Repository) *GithubAccountUpdate

RemoveRepositories removes "repositories" edges to Repository entities.

func (*GithubAccountUpdate) RemoveRepositoryIDs

func (gau *GithubAccountUpdate) RemoveRepositoryIDs(ids ...int) *GithubAccountUpdate

RemoveRepositoryIDs removes the "repositories" edge to Repository entities by IDs.

func (*GithubAccountUpdate) Save

func (gau *GithubAccountUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*GithubAccountUpdate) SaveX

func (gau *GithubAccountUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*GithubAccountUpdate) SetInput

SetInput applies the change-set in the UpdateGithubAccountInput on the update builder.

func (*GithubAccountUpdate) SetOwner

func (gau *GithubAccountUpdate) SetOwner(u *User) *GithubAccountUpdate

SetOwner sets the "owner" edge to the User entity.

func (*GithubAccountUpdate) SetOwnerID

func (gau *GithubAccountUpdate) SetOwnerID(id int) *GithubAccountUpdate

SetOwnerID sets the "owner" edge to the User entity by ID.

func (*GithubAccountUpdate) SetUsername

func (gau *GithubAccountUpdate) SetUsername(s string) *GithubAccountUpdate

SetUsername sets the "username" field.

func (*GithubAccountUpdate) Where

Where appends a list predicates to the GithubAccountUpdate builder.

type GithubAccountUpdateOne

type GithubAccountUpdateOne struct {
	// contains filtered or unexported fields
}

GithubAccountUpdateOne is the builder for updating a single GithubAccount entity.

func (*GithubAccountUpdateOne) AddOrganizationMembershipIDs

func (gauo *GithubAccountUpdateOne) AddOrganizationMembershipIDs(ids ...int) *GithubAccountUpdateOne

AddOrganizationMembershipIDs adds the "organization_memberships" edge to the GithubOrganizationMember entity by IDs.

func (*GithubAccountUpdateOne) AddOrganizationMemberships

func (gauo *GithubAccountUpdateOne) AddOrganizationMemberships(g ...*GithubOrganizationMember) *GithubAccountUpdateOne

AddOrganizationMemberships adds the "organization_memberships" edges to the GithubOrganizationMember entity.

func (*GithubAccountUpdateOne) AddRepositories

func (gauo *GithubAccountUpdateOne) AddRepositories(r ...*Repository) *GithubAccountUpdateOne

AddRepositories adds the "repositories" edges to the Repository entity.

func (*GithubAccountUpdateOne) AddRepositoryIDs

func (gauo *GithubAccountUpdateOne) AddRepositoryIDs(ids ...int) *GithubAccountUpdateOne

AddRepositoryIDs adds the "repositories" edge to the Repository entity by IDs.

func (*GithubAccountUpdateOne) ClearOrganizationMemberships

func (gauo *GithubAccountUpdateOne) ClearOrganizationMemberships() *GithubAccountUpdateOne

ClearOrganizationMemberships clears all "organization_memberships" edges to the GithubOrganizationMember entity.

func (*GithubAccountUpdateOne) ClearOwner

func (gauo *GithubAccountUpdateOne) ClearOwner() *GithubAccountUpdateOne

ClearOwner clears the "owner" edge to the User entity.

func (*GithubAccountUpdateOne) ClearRepositories

func (gauo *GithubAccountUpdateOne) ClearRepositories() *GithubAccountUpdateOne

ClearRepositories clears all "repositories" edges to the Repository entity.

func (*GithubAccountUpdateOne) Exec

func (gauo *GithubAccountUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*GithubAccountUpdateOne) ExecX

func (gauo *GithubAccountUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*GithubAccountUpdateOne) Mutation

Mutation returns the GithubAccountMutation object of the builder.

func (*GithubAccountUpdateOne) RemoveOrganizationMembershipIDs

func (gauo *GithubAccountUpdateOne) RemoveOrganizationMembershipIDs(ids ...int) *GithubAccountUpdateOne

RemoveOrganizationMembershipIDs removes the "organization_memberships" edge to GithubOrganizationMember entities by IDs.

func (*GithubAccountUpdateOne) RemoveOrganizationMemberships

func (gauo *GithubAccountUpdateOne) RemoveOrganizationMemberships(g ...*GithubOrganizationMember) *GithubAccountUpdateOne

RemoveOrganizationMemberships removes "organization_memberships" edges to GithubOrganizationMember entities.

func (*GithubAccountUpdateOne) RemoveRepositories

func (gauo *GithubAccountUpdateOne) RemoveRepositories(r ...*Repository) *GithubAccountUpdateOne

RemoveRepositories removes "repositories" edges to Repository entities.

func (*GithubAccountUpdateOne) RemoveRepositoryIDs

func (gauo *GithubAccountUpdateOne) RemoveRepositoryIDs(ids ...int) *GithubAccountUpdateOne

RemoveRepositoryIDs removes the "repositories" edge to Repository entities by IDs.

func (*GithubAccountUpdateOne) Save

Save executes the query and returns the updated GithubAccount entity.

func (*GithubAccountUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*GithubAccountUpdateOne) Select

func (gauo *GithubAccountUpdateOne) Select(field string, fields ...string) *GithubAccountUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*GithubAccountUpdateOne) SetInput

SetInput applies the change-set in the UpdateGithubAccountInput on the update-one builder.

func (*GithubAccountUpdateOne) SetOwner

SetOwner sets the "owner" edge to the User entity.

func (*GithubAccountUpdateOne) SetOwnerID

func (gauo *GithubAccountUpdateOne) SetOwnerID(id int) *GithubAccountUpdateOne

SetOwnerID sets the "owner" edge to the User entity by ID.

func (*GithubAccountUpdateOne) SetUsername

SetUsername sets the "username" field.

type GithubAccountWhereInput

type GithubAccountWhereInput struct {
	Predicates []predicate.GithubAccount  `json:"-"`
	Not        *GithubAccountWhereInput   `json:"not,omitempty"`
	Or         []*GithubAccountWhereInput `json:"or,omitempty"`
	And        []*GithubAccountWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "username" field predicates.
	Username             *string  `json:"username,omitempty"`
	UsernameNEQ          *string  `json:"usernameNEQ,omitempty"`
	UsernameIn           []string `json:"usernameIn,omitempty"`
	UsernameNotIn        []string `json:"usernameNotIn,omitempty"`
	UsernameGT           *string  `json:"usernameGT,omitempty"`
	UsernameGTE          *string  `json:"usernameGTE,omitempty"`
	UsernameLT           *string  `json:"usernameLT,omitempty"`
	UsernameLTE          *string  `json:"usernameLTE,omitempty"`
	UsernameContains     *string  `json:"usernameContains,omitempty"`
	UsernameHasPrefix    *string  `json:"usernameHasPrefix,omitempty"`
	UsernameHasSuffix    *string  `json:"usernameHasSuffix,omitempty"`
	UsernameEqualFold    *string  `json:"usernameEqualFold,omitempty"`
	UsernameContainsFold *string  `json:"usernameContainsFold,omitempty"`

	// "owner" edge predicates.
	HasOwner     *bool             `json:"hasOwner,omitempty"`
	HasOwnerWith []*UserWhereInput `json:"hasOwnerWith,omitempty"`

	// "organization_memberships" edge predicates.
	HasOrganizationMemberships     *bool                                 `json:"hasOrganizationMemberships,omitempty"`
	HasOrganizationMembershipsWith []*GithubOrganizationMemberWhereInput `json:"hasOrganizationMembershipsWith,omitempty"`

	// "repositories" edge predicates.
	HasRepositories     *bool                   `json:"hasRepositories,omitempty"`
	HasRepositoriesWith []*RepositoryWhereInput `json:"hasRepositoriesWith,omitempty"`
}

GithubAccountWhereInput represents a where input for filtering GithubAccount queries.

func (*GithubAccountWhereInput) AddPredicates

func (i *GithubAccountWhereInput) AddPredicates(predicates ...predicate.GithubAccount)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*GithubAccountWhereInput) Filter

Filter applies the GithubAccountWhereInput filter on the GithubAccountQuery builder.

func (*GithubAccountWhereInput) P

P returns a predicate for filtering githubaccounts. An error is returned if the input is empty or invalid.

type GithubAccounts

type GithubAccounts []*GithubAccount

GithubAccounts is a parsable slice of GithubAccount.

type GithubOrganization

type GithubOrganization struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Name holds the value of the "name" field.
	Name string `json:"name,omitempty"`
	// DisplayName holds the value of the "display_name" field.
	DisplayName string `json:"display_name,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the GithubOrganizationQuery when eager-loading is set.
	Edges GithubOrganizationEdges `json:"edges"`
	// contains filtered or unexported fields
}

GithubOrganization is the model entity for the GithubOrganization schema.

func (*GithubOrganization) Members

func (*GithubOrganization) NamedMembers

func (_go *GithubOrganization) NamedMembers(name string) ([]*GithubOrganizationMember, error)

NamedMembers returns the Members named value or an error if the edge was not loaded in eager-loading with this name.

func (*GithubOrganization) NamedRepositories

func (_go *GithubOrganization) NamedRepositories(name string) ([]*Repository, error)

NamedRepositories returns the Repositories named value or an error if the edge was not loaded in eager-loading with this name.

func (*GithubOrganization) Node

func (_go *GithubOrganization) Node(ctx context.Context) (node *Node, err error)

func (*GithubOrganization) QueryMembers

QueryMembers queries the "members" edge of the GithubOrganization entity.

func (*GithubOrganization) QueryRepositories

func (_go *GithubOrganization) QueryRepositories() *RepositoryQuery

QueryRepositories queries the "repositories" edge of the GithubOrganization entity.

func (*GithubOrganization) Repositories

func (_go *GithubOrganization) Repositories(ctx context.Context) ([]*Repository, error)

func (*GithubOrganization) String

func (_go *GithubOrganization) String() string

String implements the fmt.Stringer.

func (*GithubOrganization) ToEdge

ToEdge converts GithubOrganization into GithubOrganizationEdge.

func (*GithubOrganization) Unwrap

func (_go *GithubOrganization) Unwrap() *GithubOrganization

Unwrap unwraps the GithubOrganization entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*GithubOrganization) Update

Update returns a builder for updating this GithubOrganization. Note that you need to call GithubOrganization.Unwrap() before calling this method if this GithubOrganization was returned from a transaction, and the transaction was committed or rolled back.

type GithubOrganizationClient

type GithubOrganizationClient struct {
	// contains filtered or unexported fields
}

GithubOrganizationClient is a client for the GithubOrganization schema.

func NewGithubOrganizationClient

func NewGithubOrganizationClient(c config) *GithubOrganizationClient

NewGithubOrganizationClient returns a client for the GithubOrganization from the given config.

func (*GithubOrganizationClient) Create

Create returns a builder for creating a GithubOrganization entity.

func (*GithubOrganizationClient) CreateBulk

CreateBulk returns a builder for creating a bulk of GithubOrganization entities.

func (*GithubOrganizationClient) Delete

Delete returns a delete builder for GithubOrganization.

func (*GithubOrganizationClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*GithubOrganizationClient) DeleteOneID

DeleteOne returns a builder for deleting the given entity by its id.

func (*GithubOrganizationClient) Get

Get returns a GithubOrganization entity by its id.

func (*GithubOrganizationClient) GetX

GetX is like Get, but panics if an error occurs.

func (*GithubOrganizationClient) Hooks

func (c *GithubOrganizationClient) Hooks() []Hook

Hooks returns the client hooks.

func (*GithubOrganizationClient) Query

Query returns a query builder for GithubOrganization.

func (*GithubOrganizationClient) QueryMembers

QueryMembers queries the members edge of a GithubOrganization.

func (*GithubOrganizationClient) QueryRepositories

func (c *GithubOrganizationClient) QueryRepositories(_go *GithubOrganization) *RepositoryQuery

QueryRepositories queries the repositories edge of a GithubOrganization.

func (*GithubOrganizationClient) Update

Update returns an update builder for GithubOrganization.

func (*GithubOrganizationClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*GithubOrganizationClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*GithubOrganizationClient) Use

func (c *GithubOrganizationClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `githuborganization.Hooks(f(g(h())))`.

type GithubOrganizationConnection

type GithubOrganizationConnection struct {
	Edges      []*GithubOrganizationEdge `json:"edges"`
	PageInfo   PageInfo                  `json:"pageInfo"`
	TotalCount int                       `json:"totalCount"`
}

GithubOrganizationConnection is the connection containing edges to GithubOrganization.

type GithubOrganizationCreate

type GithubOrganizationCreate struct {
	// contains filtered or unexported fields
}

GithubOrganizationCreate is the builder for creating a GithubOrganization entity.

func (*GithubOrganizationCreate) AddMemberIDs

func (goc *GithubOrganizationCreate) AddMemberIDs(ids ...int) *GithubOrganizationCreate

AddMemberIDs adds the "members" edge to the GithubOrganizationMember entity by IDs.

func (*GithubOrganizationCreate) AddMembers

AddMembers adds the "members" edges to the GithubOrganizationMember entity.

func (*GithubOrganizationCreate) AddRepositories

func (goc *GithubOrganizationCreate) AddRepositories(r ...*Repository) *GithubOrganizationCreate

AddRepositories adds the "repositories" edges to the Repository entity.

func (*GithubOrganizationCreate) AddRepositoryIDs

func (goc *GithubOrganizationCreate) AddRepositoryIDs(ids ...int) *GithubOrganizationCreate

AddRepositoryIDs adds the "repositories" edge to the Repository entity by IDs.

func (*GithubOrganizationCreate) Exec

Exec executes the query.

func (*GithubOrganizationCreate) ExecX

func (goc *GithubOrganizationCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*GithubOrganizationCreate) Mutation

Mutation returns the GithubOrganizationMutation object of the builder.

func (*GithubOrganizationCreate) Save

Save creates the GithubOrganization in the database.

func (*GithubOrganizationCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*GithubOrganizationCreate) SetDisplayName

SetDisplayName sets the "display_name" field.

func (*GithubOrganizationCreate) SetInput

SetInput applies the change-set in the CreateGithubOrganizationInput on the create builder.

func (*GithubOrganizationCreate) SetName

SetName sets the "name" field.

func (*GithubOrganizationCreate) SetNillableDisplayName

func (goc *GithubOrganizationCreate) SetNillableDisplayName(s *string) *GithubOrganizationCreate

SetNillableDisplayName sets the "display_name" field if the given value is not nil.

type GithubOrganizationCreateBulk

type GithubOrganizationCreateBulk struct {
	// contains filtered or unexported fields
}

GithubOrganizationCreateBulk is the builder for creating many GithubOrganization entities in bulk.

func (*GithubOrganizationCreateBulk) Exec

Exec executes the query.

func (*GithubOrganizationCreateBulk) ExecX

func (gocb *GithubOrganizationCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*GithubOrganizationCreateBulk) Save

Save creates the GithubOrganization entities in the database.

func (*GithubOrganizationCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type GithubOrganizationDelete

type GithubOrganizationDelete struct {
	// contains filtered or unexported fields
}

GithubOrganizationDelete is the builder for deleting a GithubOrganization entity.

func (*GithubOrganizationDelete) Exec

func (god *GithubOrganizationDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*GithubOrganizationDelete) ExecX

func (god *GithubOrganizationDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*GithubOrganizationDelete) Where

Where appends a list predicates to the GithubOrganizationDelete builder.

type GithubOrganizationDeleteOne

type GithubOrganizationDeleteOne struct {
	// contains filtered or unexported fields
}

GithubOrganizationDeleteOne is the builder for deleting a single GithubOrganization entity.

func (*GithubOrganizationDeleteOne) Exec

Exec executes the deletion query.

func (*GithubOrganizationDeleteOne) ExecX

func (godo *GithubOrganizationDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

type GithubOrganizationEdge

type GithubOrganizationEdge struct {
	Node   *GithubOrganization `json:"node"`
	Cursor Cursor              `json:"cursor"`
}

GithubOrganizationEdge is the edge representation of GithubOrganization.

type GithubOrganizationEdges

type GithubOrganizationEdges struct {
	// Members holds the value of the members edge.
	Members []*GithubOrganizationMember `json:"members,omitempty"`
	// Repositories holds the value of the repositories edge.
	Repositories []*Repository `json:"repositories,omitempty"`
	// contains filtered or unexported fields
}

GithubOrganizationEdges holds the relations/edges for other nodes in the graph.

func (GithubOrganizationEdges) MembersOrErr

MembersOrErr returns the Members value or an error if the edge was not loaded in eager-loading.

func (GithubOrganizationEdges) RepositoriesOrErr

func (e GithubOrganizationEdges) RepositoriesOrErr() ([]*Repository, error)

RepositoriesOrErr returns the Repositories value or an error if the edge was not loaded in eager-loading.

type GithubOrganizationGroupBy

type GithubOrganizationGroupBy struct {
	// contains filtered or unexported fields
}

GithubOrganizationGroupBy is the group-by builder for GithubOrganization entities.

func (*GithubOrganizationGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*GithubOrganizationGroupBy) Bool

func (s *GithubOrganizationGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationGroupBy) BoolX

func (s *GithubOrganizationGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*GithubOrganizationGroupBy) Bools

func (s *GithubOrganizationGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationGroupBy) BoolsX

func (s *GithubOrganizationGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*GithubOrganizationGroupBy) Float64

func (s *GithubOrganizationGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationGroupBy) Float64X

func (s *GithubOrganizationGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*GithubOrganizationGroupBy) Float64s

func (s *GithubOrganizationGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationGroupBy) Float64sX

func (s *GithubOrganizationGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*GithubOrganizationGroupBy) Int

func (s *GithubOrganizationGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationGroupBy) IntX

func (s *GithubOrganizationGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*GithubOrganizationGroupBy) Ints

func (s *GithubOrganizationGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationGroupBy) IntsX

func (s *GithubOrganizationGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*GithubOrganizationGroupBy) Scan

func (gogb *GithubOrganizationGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*GithubOrganizationGroupBy) ScanX

func (s *GithubOrganizationGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*GithubOrganizationGroupBy) String

func (s *GithubOrganizationGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationGroupBy) StringX

func (s *GithubOrganizationGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*GithubOrganizationGroupBy) Strings

func (s *GithubOrganizationGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationGroupBy) StringsX

func (s *GithubOrganizationGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type GithubOrganizationMember

type GithubOrganizationMember struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Role holds the value of the "role" field.
	Role githuborganizationmember.Role `json:"role,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the GithubOrganizationMemberQuery when eager-loading is set.
	Edges GithubOrganizationMemberEdges `json:"edges"`
	// contains filtered or unexported fields
}

GithubOrganizationMember is the model entity for the GithubOrganizationMember schema.

func (*GithubOrganizationMember) Account

func (*GithubOrganizationMember) Node

func (gom *GithubOrganizationMember) Node(ctx context.Context) (node *Node, err error)

func (*GithubOrganizationMember) Organization

func (*GithubOrganizationMember) QueryAccount

func (gom *GithubOrganizationMember) QueryAccount() *GithubAccountQuery

QueryAccount queries the "account" edge of the GithubOrganizationMember entity.

func (*GithubOrganizationMember) QueryOrganization

func (gom *GithubOrganizationMember) QueryOrganization() *GithubOrganizationQuery

QueryOrganization queries the "organization" edge of the GithubOrganizationMember entity.

func (*GithubOrganizationMember) String

func (gom *GithubOrganizationMember) String() string

String implements the fmt.Stringer.

func (*GithubOrganizationMember) ToEdge

ToEdge converts GithubOrganizationMember into GithubOrganizationMemberEdge.

func (*GithubOrganizationMember) Unwrap

Unwrap unwraps the GithubOrganizationMember entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*GithubOrganizationMember) Update

Update returns a builder for updating this GithubOrganizationMember. Note that you need to call GithubOrganizationMember.Unwrap() before calling this method if this GithubOrganizationMember was returned from a transaction, and the transaction was committed or rolled back.

type GithubOrganizationMemberClient

type GithubOrganizationMemberClient struct {
	// contains filtered or unexported fields
}

GithubOrganizationMemberClient is a client for the GithubOrganizationMember schema.

func NewGithubOrganizationMemberClient

func NewGithubOrganizationMemberClient(c config) *GithubOrganizationMemberClient

NewGithubOrganizationMemberClient returns a client for the GithubOrganizationMember from the given config.

func (*GithubOrganizationMemberClient) Create

Create returns a builder for creating a GithubOrganizationMember entity.

func (*GithubOrganizationMemberClient) CreateBulk

CreateBulk returns a builder for creating a bulk of GithubOrganizationMember entities.

func (*GithubOrganizationMemberClient) Delete

Delete returns a delete builder for GithubOrganizationMember.

func (*GithubOrganizationMemberClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*GithubOrganizationMemberClient) DeleteOneID

DeleteOne returns a builder for deleting the given entity by its id.

func (*GithubOrganizationMemberClient) Get

Get returns a GithubOrganizationMember entity by its id.

func (*GithubOrganizationMemberClient) GetX

GetX is like Get, but panics if an error occurs.

func (*GithubOrganizationMemberClient) Hooks

func (c *GithubOrganizationMemberClient) Hooks() []Hook

Hooks returns the client hooks.

func (*GithubOrganizationMemberClient) Query

Query returns a query builder for GithubOrganizationMember.

func (*GithubOrganizationMemberClient) QueryAccount

QueryAccount queries the account edge of a GithubOrganizationMember.

func (*GithubOrganizationMemberClient) QueryOrganization

QueryOrganization queries the organization edge of a GithubOrganizationMember.

func (*GithubOrganizationMemberClient) Update

Update returns an update builder for GithubOrganizationMember.

func (*GithubOrganizationMemberClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*GithubOrganizationMemberClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*GithubOrganizationMemberClient) Use

func (c *GithubOrganizationMemberClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `githuborganizationmember.Hooks(f(g(h())))`.

type GithubOrganizationMemberConnection

type GithubOrganizationMemberConnection struct {
	Edges      []*GithubOrganizationMemberEdge `json:"edges"`
	PageInfo   PageInfo                        `json:"pageInfo"`
	TotalCount int                             `json:"totalCount"`
}

GithubOrganizationMemberConnection is the connection containing edges to GithubOrganizationMember.

type GithubOrganizationMemberCreate

type GithubOrganizationMemberCreate struct {
	// contains filtered or unexported fields
}

GithubOrganizationMemberCreate is the builder for creating a GithubOrganizationMember entity.

func (*GithubOrganizationMemberCreate) Exec

Exec executes the query.

func (*GithubOrganizationMemberCreate) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*GithubOrganizationMemberCreate) Mutation

Mutation returns the GithubOrganizationMemberMutation object of the builder.

func (*GithubOrganizationMemberCreate) Save

Save creates the GithubOrganizationMember in the database.

func (*GithubOrganizationMemberCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*GithubOrganizationMemberCreate) SetAccount

SetAccount sets the "account" edge to the GithubAccount entity.

func (*GithubOrganizationMemberCreate) SetAccountID

SetAccountID sets the "account" edge to the GithubAccount entity by ID.

func (*GithubOrganizationMemberCreate) SetInput

SetInput applies the change-set in the CreateGithubOrganizationMemberInput on the create builder.

func (*GithubOrganizationMemberCreate) SetNillableRole

SetNillableRole sets the "role" field if the given value is not nil.

func (*GithubOrganizationMemberCreate) SetOrganization

SetOrganization sets the "organization" edge to the GithubOrganization entity.

func (*GithubOrganizationMemberCreate) SetOrganizationID

SetOrganizationID sets the "organization" edge to the GithubOrganization entity by ID.

func (*GithubOrganizationMemberCreate) SetRole

SetRole sets the "role" field.

type GithubOrganizationMemberCreateBulk

type GithubOrganizationMemberCreateBulk struct {
	// contains filtered or unexported fields
}

GithubOrganizationMemberCreateBulk is the builder for creating many GithubOrganizationMember entities in bulk.

func (*GithubOrganizationMemberCreateBulk) Exec

Exec executes the query.

func (*GithubOrganizationMemberCreateBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*GithubOrganizationMemberCreateBulk) Save

Save creates the GithubOrganizationMember entities in the database.

func (*GithubOrganizationMemberCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type GithubOrganizationMemberDelete

type GithubOrganizationMemberDelete struct {
	// contains filtered or unexported fields
}

GithubOrganizationMemberDelete is the builder for deleting a GithubOrganizationMember entity.

func (*GithubOrganizationMemberDelete) Exec

Exec executes the deletion query and returns how many vertices were deleted.

func (*GithubOrganizationMemberDelete) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*GithubOrganizationMemberDelete) Where

Where appends a list predicates to the GithubOrganizationMemberDelete builder.

type GithubOrganizationMemberDeleteOne

type GithubOrganizationMemberDeleteOne struct {
	// contains filtered or unexported fields
}

GithubOrganizationMemberDeleteOne is the builder for deleting a single GithubOrganizationMember entity.

func (*GithubOrganizationMemberDeleteOne) Exec

Exec executes the deletion query.

func (*GithubOrganizationMemberDeleteOne) ExecX

ExecX is like Exec, but panics if an error occurs.

type GithubOrganizationMemberEdge

type GithubOrganizationMemberEdge struct {
	Node   *GithubOrganizationMember `json:"node"`
	Cursor Cursor                    `json:"cursor"`
}

GithubOrganizationMemberEdge is the edge representation of GithubOrganizationMember.

type GithubOrganizationMemberEdges

type GithubOrganizationMemberEdges struct {
	// Organization holds the value of the organization edge.
	Organization *GithubOrganization `json:"organization,omitempty"`
	// Account holds the value of the account edge.
	Account *GithubAccount `json:"account,omitempty"`
	// contains filtered or unexported fields
}

GithubOrganizationMemberEdges holds the relations/edges for other nodes in the graph.

func (GithubOrganizationMemberEdges) AccountOrErr

func (e GithubOrganizationMemberEdges) AccountOrErr() (*GithubAccount, error)

AccountOrErr returns the Account value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (GithubOrganizationMemberEdges) OrganizationOrErr

func (e GithubOrganizationMemberEdges) OrganizationOrErr() (*GithubOrganization, error)

OrganizationOrErr returns the Organization value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type GithubOrganizationMemberGroupBy

type GithubOrganizationMemberGroupBy struct {
	// contains filtered or unexported fields
}

GithubOrganizationMemberGroupBy is the group-by builder for GithubOrganizationMember entities.

func (*GithubOrganizationMemberGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*GithubOrganizationMemberGroupBy) Bool

func (s *GithubOrganizationMemberGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberGroupBy) BoolX

func (s *GithubOrganizationMemberGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*GithubOrganizationMemberGroupBy) Bools

func (s *GithubOrganizationMemberGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberGroupBy) BoolsX

func (s *GithubOrganizationMemberGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*GithubOrganizationMemberGroupBy) Float64

func (s *GithubOrganizationMemberGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberGroupBy) Float64X

func (s *GithubOrganizationMemberGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*GithubOrganizationMemberGroupBy) Float64s

func (s *GithubOrganizationMemberGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberGroupBy) Float64sX

func (s *GithubOrganizationMemberGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*GithubOrganizationMemberGroupBy) Int

func (s *GithubOrganizationMemberGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberGroupBy) IntX

func (s *GithubOrganizationMemberGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*GithubOrganizationMemberGroupBy) Ints

func (s *GithubOrganizationMemberGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberGroupBy) IntsX

func (s *GithubOrganizationMemberGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*GithubOrganizationMemberGroupBy) Scan

func (gomgb *GithubOrganizationMemberGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*GithubOrganizationMemberGroupBy) ScanX

func (s *GithubOrganizationMemberGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*GithubOrganizationMemberGroupBy) String

func (s *GithubOrganizationMemberGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberGroupBy) StringX

func (s *GithubOrganizationMemberGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*GithubOrganizationMemberGroupBy) Strings

func (s *GithubOrganizationMemberGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberGroupBy) StringsX

func (s *GithubOrganizationMemberGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type GithubOrganizationMemberMutation

type GithubOrganizationMemberMutation struct {
	// contains filtered or unexported fields
}

GithubOrganizationMemberMutation represents an operation that mutates the GithubOrganizationMember nodes in the graph.

func (*GithubOrganizationMemberMutation) AccountCleared

func (m *GithubOrganizationMemberMutation) AccountCleared() bool

AccountCleared reports if the "account" edge to the GithubAccount entity was cleared.

func (*GithubOrganizationMemberMutation) AccountID

func (m *GithubOrganizationMemberMutation) AccountID() (id int, exists bool)

AccountID returns the "account" edge ID in the mutation.

func (*GithubOrganizationMemberMutation) AccountIDs

func (m *GithubOrganizationMemberMutation) AccountIDs() (ids []int)

AccountIDs returns the "account" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use AccountID instead. It exists only for internal usage by the builders.

func (*GithubOrganizationMemberMutation) AddField

func (m *GithubOrganizationMemberMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*GithubOrganizationMemberMutation) AddedEdges

func (m *GithubOrganizationMemberMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*GithubOrganizationMemberMutation) AddedField

func (m *GithubOrganizationMemberMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*GithubOrganizationMemberMutation) AddedFields

func (m *GithubOrganizationMemberMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*GithubOrganizationMemberMutation) AddedIDs

func (m *GithubOrganizationMemberMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*GithubOrganizationMemberMutation) ClearAccount

func (m *GithubOrganizationMemberMutation) ClearAccount()

ClearAccount clears the "account" edge to the GithubAccount entity.

func (*GithubOrganizationMemberMutation) ClearEdge

func (m *GithubOrganizationMemberMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*GithubOrganizationMemberMutation) ClearField

func (m *GithubOrganizationMemberMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*GithubOrganizationMemberMutation) ClearOrganization

func (m *GithubOrganizationMemberMutation) ClearOrganization()

ClearOrganization clears the "organization" edge to the GithubOrganization entity.

func (*GithubOrganizationMemberMutation) ClearedEdges

func (m *GithubOrganizationMemberMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*GithubOrganizationMemberMutation) ClearedFields

func (m *GithubOrganizationMemberMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (GithubOrganizationMemberMutation) Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*GithubOrganizationMemberMutation) EdgeCleared

func (m *GithubOrganizationMemberMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*GithubOrganizationMemberMutation) Field

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*GithubOrganizationMemberMutation) FieldCleared

func (m *GithubOrganizationMemberMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*GithubOrganizationMemberMutation) Fields

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*GithubOrganizationMemberMutation) ID

func (m *GithubOrganizationMemberMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*GithubOrganizationMemberMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*GithubOrganizationMemberMutation) OldField

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*GithubOrganizationMemberMutation) OldRole

OldRole returns the old "role" field's value of the GithubOrganizationMember entity. If the GithubOrganizationMember object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*GithubOrganizationMemberMutation) Op

Op returns the operation name.

func (*GithubOrganizationMemberMutation) OrganizationCleared

func (m *GithubOrganizationMemberMutation) OrganizationCleared() bool

OrganizationCleared reports if the "organization" edge to the GithubOrganization entity was cleared.

func (*GithubOrganizationMemberMutation) OrganizationID

func (m *GithubOrganizationMemberMutation) OrganizationID() (id int, exists bool)

OrganizationID returns the "organization" edge ID in the mutation.

func (*GithubOrganizationMemberMutation) OrganizationIDs

func (m *GithubOrganizationMemberMutation) OrganizationIDs() (ids []int)

OrganizationIDs returns the "organization" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use OrganizationID instead. It exists only for internal usage by the builders.

func (*GithubOrganizationMemberMutation) RemovedEdges

func (m *GithubOrganizationMemberMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*GithubOrganizationMemberMutation) RemovedIDs

func (m *GithubOrganizationMemberMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*GithubOrganizationMemberMutation) ResetAccount

func (m *GithubOrganizationMemberMutation) ResetAccount()

ResetAccount resets all changes to the "account" edge.

func (*GithubOrganizationMemberMutation) ResetEdge

func (m *GithubOrganizationMemberMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*GithubOrganizationMemberMutation) ResetField

func (m *GithubOrganizationMemberMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*GithubOrganizationMemberMutation) ResetOrganization

func (m *GithubOrganizationMemberMutation) ResetOrganization()

ResetOrganization resets all changes to the "organization" edge.

func (*GithubOrganizationMemberMutation) ResetRole

func (m *GithubOrganizationMemberMutation) ResetRole()

ResetRole resets all changes to the "role" field.

func (*GithubOrganizationMemberMutation) Role

Role returns the value of the "role" field in the mutation.

func (*GithubOrganizationMemberMutation) SetAccountID

func (m *GithubOrganizationMemberMutation) SetAccountID(id int)

SetAccountID sets the "account" edge to the GithubAccount entity by id.

func (*GithubOrganizationMemberMutation) SetField

func (m *GithubOrganizationMemberMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*GithubOrganizationMemberMutation) SetOrganizationID

func (m *GithubOrganizationMemberMutation) SetOrganizationID(id int)

SetOrganizationID sets the "organization" edge to the GithubOrganization entity by id.

func (*GithubOrganizationMemberMutation) SetRole

SetRole sets the "role" field.

func (GithubOrganizationMemberMutation) Tx

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*GithubOrganizationMemberMutation) Type

Type returns the node type of this mutation (GithubOrganizationMember).

func (*GithubOrganizationMemberMutation) Where

Where appends a list predicates to the GithubOrganizationMemberMutation builder.

type GithubOrganizationMemberOrder

type GithubOrganizationMemberOrder struct {
	Direction OrderDirection                      `json:"direction"`
	Field     *GithubOrganizationMemberOrderField `json:"field"`
}

GithubOrganizationMemberOrder defines the ordering of GithubOrganizationMember.

type GithubOrganizationMemberOrderField

type GithubOrganizationMemberOrderField struct {
	// contains filtered or unexported fields
}

GithubOrganizationMemberOrderField defines the ordering field of GithubOrganizationMember.

func (GithubOrganizationMemberOrderField) MarshalGQL

MarshalGQL implements graphql.Marshaler interface.

func (GithubOrganizationMemberOrderField) String

String implement fmt.Stringer interface.

func (*GithubOrganizationMemberOrderField) UnmarshalGQL

func (f *GithubOrganizationMemberOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type GithubOrganizationMemberPaginateOption

type GithubOrganizationMemberPaginateOption func(*githuborganizationmemberPager) error

GithubOrganizationMemberPaginateOption enables pagination customization.

func WithGithubOrganizationMemberFilter

WithGithubOrganizationMemberFilter configures pagination filter.

func WithGithubOrganizationMemberOrder

func WithGithubOrganizationMemberOrder(order *GithubOrganizationMemberOrder) GithubOrganizationMemberPaginateOption

WithGithubOrganizationMemberOrder configures pagination ordering.

type GithubOrganizationMemberQuery

type GithubOrganizationMemberQuery struct {
	// contains filtered or unexported fields
}

GithubOrganizationMemberQuery is the builder for querying GithubOrganizationMember entities.

func (*GithubOrganizationMemberQuery) All

All executes the query and returns a list of GithubOrganizationMembers.

func (*GithubOrganizationMemberQuery) AllX

AllX is like All, but panics if an error occurs.

func (*GithubOrganizationMemberQuery) Clone

Clone returns a duplicate of the GithubOrganizationMemberQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*GithubOrganizationMemberQuery) CollectFields

func (gom *GithubOrganizationMemberQuery) CollectFields(ctx context.Context, satisfies ...string) (*GithubOrganizationMemberQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*GithubOrganizationMemberQuery) Count

Count returns the count of the given query.

func (*GithubOrganizationMemberQuery) CountX

CountX is like Count, but panics if an error occurs.

func (*GithubOrganizationMemberQuery) Exist

Exist returns true if the query has elements in the graph.

func (*GithubOrganizationMemberQuery) ExistX

ExistX is like Exist, but panics if an error occurs.

func (*GithubOrganizationMemberQuery) First

First returns the first GithubOrganizationMember entity from the query. Returns a *NotFoundError when no GithubOrganizationMember was found.

func (*GithubOrganizationMemberQuery) FirstID

func (gomq *GithubOrganizationMemberQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first GithubOrganizationMember ID from the query. Returns a *NotFoundError when no GithubOrganizationMember ID was found.

func (*GithubOrganizationMemberQuery) FirstIDX

func (gomq *GithubOrganizationMemberQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*GithubOrganizationMemberQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*GithubOrganizationMemberQuery) GroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Role githuborganizationmember.Role `json:"role,omitempty"`
	Count int `json:"count,omitempty"`
}

client.GithubOrganizationMember.Query().
	GroupBy(githuborganizationmember.FieldRole).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*GithubOrganizationMemberQuery) IDs

IDs executes the query and returns a list of GithubOrganizationMember IDs.

func (*GithubOrganizationMemberQuery) IDsX

IDsX is like IDs, but panics if an error occurs.

func (*GithubOrganizationMemberQuery) Limit

Limit adds a limit step to the query.

func (*GithubOrganizationMemberQuery) Offset

Offset adds an offset step to the query.

func (*GithubOrganizationMemberQuery) Only

Only returns a single GithubOrganizationMember entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one GithubOrganizationMember entity is found. Returns a *NotFoundError when no GithubOrganizationMember entities are found.

func (*GithubOrganizationMemberQuery) OnlyID

func (gomq *GithubOrganizationMemberQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only GithubOrganizationMember ID in the query. Returns a *NotSingularError when more than one GithubOrganizationMember ID is found. Returns a *NotFoundError when no entities are found.

func (*GithubOrganizationMemberQuery) OnlyIDX

func (gomq *GithubOrganizationMemberQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*GithubOrganizationMemberQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*GithubOrganizationMemberQuery) Order

Order adds an order step to the query.

func (*GithubOrganizationMemberQuery) Paginate

Paginate executes the query and returns a relay based cursor connection to GithubOrganizationMember.

func (*GithubOrganizationMemberQuery) QueryAccount

func (gomq *GithubOrganizationMemberQuery) QueryAccount() *GithubAccountQuery

QueryAccount chains the current query on the "account" edge.

func (*GithubOrganizationMemberQuery) QueryOrganization

func (gomq *GithubOrganizationMemberQuery) QueryOrganization() *GithubOrganizationQuery

QueryOrganization chains the current query on the "organization" edge.

func (*GithubOrganizationMemberQuery) Select

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Role githuborganizationmember.Role `json:"role,omitempty"`
}

client.GithubOrganizationMember.Query().
	Select(githuborganizationmember.FieldRole).
	Scan(ctx, &v)

func (*GithubOrganizationMemberQuery) Unique

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*GithubOrganizationMemberQuery) Where

Where adds a new predicate for the GithubOrganizationMemberQuery builder.

func (*GithubOrganizationMemberQuery) WithAccount

WithAccount tells the query-builder to eager-load the nodes that are connected to the "account" edge. The optional arguments are used to configure the query builder of the edge.

func (*GithubOrganizationMemberQuery) WithOrganization

WithOrganization tells the query-builder to eager-load the nodes that are connected to the "organization" edge. The optional arguments are used to configure the query builder of the edge.

type GithubOrganizationMemberSelect

type GithubOrganizationMemberSelect struct {
	*GithubOrganizationMemberQuery
	// contains filtered or unexported fields
}

GithubOrganizationMemberSelect is the builder for selecting fields of GithubOrganizationMember entities.

func (*GithubOrganizationMemberSelect) Bool

func (s *GithubOrganizationMemberSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberSelect) BoolX

func (s *GithubOrganizationMemberSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*GithubOrganizationMemberSelect) Bools

func (s *GithubOrganizationMemberSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberSelect) BoolsX

func (s *GithubOrganizationMemberSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*GithubOrganizationMemberSelect) Float64

func (s *GithubOrganizationMemberSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberSelect) Float64X

func (s *GithubOrganizationMemberSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*GithubOrganizationMemberSelect) Float64s

func (s *GithubOrganizationMemberSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberSelect) Float64sX

func (s *GithubOrganizationMemberSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*GithubOrganizationMemberSelect) Int

func (s *GithubOrganizationMemberSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberSelect) IntX

func (s *GithubOrganizationMemberSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*GithubOrganizationMemberSelect) Ints

func (s *GithubOrganizationMemberSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberSelect) IntsX

func (s *GithubOrganizationMemberSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*GithubOrganizationMemberSelect) Scan

func (goms *GithubOrganizationMemberSelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*GithubOrganizationMemberSelect) ScanX

func (s *GithubOrganizationMemberSelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*GithubOrganizationMemberSelect) String

func (s *GithubOrganizationMemberSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberSelect) StringX

func (s *GithubOrganizationMemberSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*GithubOrganizationMemberSelect) Strings

func (s *GithubOrganizationMemberSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationMemberSelect) StringsX

func (s *GithubOrganizationMemberSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type GithubOrganizationMemberUpdate

type GithubOrganizationMemberUpdate struct {
	// contains filtered or unexported fields
}

GithubOrganizationMemberUpdate is the builder for updating GithubOrganizationMember entities.

func (*GithubOrganizationMemberUpdate) ClearAccount

ClearAccount clears the "account" edge to the GithubAccount entity.

func (*GithubOrganizationMemberUpdate) ClearOrganization

ClearOrganization clears the "organization" edge to the GithubOrganization entity.

func (*GithubOrganizationMemberUpdate) Exec

Exec executes the query.

func (*GithubOrganizationMemberUpdate) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*GithubOrganizationMemberUpdate) Mutation

Mutation returns the GithubOrganizationMemberMutation object of the builder.

func (*GithubOrganizationMemberUpdate) Save

Save executes the query and returns the number of nodes affected by the update operation.

func (*GithubOrganizationMemberUpdate) SaveX

SaveX is like Save, but panics if an error occurs.

func (*GithubOrganizationMemberUpdate) SetAccount

SetAccount sets the "account" edge to the GithubAccount entity.

func (*GithubOrganizationMemberUpdate) SetAccountID

SetAccountID sets the "account" edge to the GithubAccount entity by ID.

func (*GithubOrganizationMemberUpdate) SetInput

SetInput applies the change-set in the UpdateGithubOrganizationMemberInput on the update builder.

func (*GithubOrganizationMemberUpdate) SetNillableRole

SetNillableRole sets the "role" field if the given value is not nil.

func (*GithubOrganizationMemberUpdate) SetOrganization

SetOrganization sets the "organization" edge to the GithubOrganization entity.

func (*GithubOrganizationMemberUpdate) SetOrganizationID

SetOrganizationID sets the "organization" edge to the GithubOrganization entity by ID.

func (*GithubOrganizationMemberUpdate) SetRole

SetRole sets the "role" field.

func (*GithubOrganizationMemberUpdate) Where

Where appends a list predicates to the GithubOrganizationMemberUpdate builder.

type GithubOrganizationMemberUpdateOne

type GithubOrganizationMemberUpdateOne struct {
	// contains filtered or unexported fields
}

GithubOrganizationMemberUpdateOne is the builder for updating a single GithubOrganizationMember entity.

func (*GithubOrganizationMemberUpdateOne) ClearAccount

ClearAccount clears the "account" edge to the GithubAccount entity.

func (*GithubOrganizationMemberUpdateOne) ClearOrganization

ClearOrganization clears the "organization" edge to the GithubOrganization entity.

func (*GithubOrganizationMemberUpdateOne) Exec

Exec executes the query on the entity.

func (*GithubOrganizationMemberUpdateOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*GithubOrganizationMemberUpdateOne) Mutation

Mutation returns the GithubOrganizationMemberMutation object of the builder.

func (*GithubOrganizationMemberUpdateOne) Save

Save executes the query and returns the updated GithubOrganizationMember entity.

func (*GithubOrganizationMemberUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*GithubOrganizationMemberUpdateOne) Select

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*GithubOrganizationMemberUpdateOne) SetAccount

SetAccount sets the "account" edge to the GithubAccount entity.

func (*GithubOrganizationMemberUpdateOne) SetAccountID

SetAccountID sets the "account" edge to the GithubAccount entity by ID.

func (*GithubOrganizationMemberUpdateOne) SetInput

SetInput applies the change-set in the UpdateGithubOrganizationMemberInput on the update-one builder.

func (*GithubOrganizationMemberUpdateOne) SetNillableRole

SetNillableRole sets the "role" field if the given value is not nil.

func (*GithubOrganizationMemberUpdateOne) SetOrganization

SetOrganization sets the "organization" edge to the GithubOrganization entity.

func (*GithubOrganizationMemberUpdateOne) SetOrganizationID

SetOrganizationID sets the "organization" edge to the GithubOrganization entity by ID.

func (*GithubOrganizationMemberUpdateOne) SetRole

SetRole sets the "role" field.

type GithubOrganizationMemberWhereInput

type GithubOrganizationMemberWhereInput struct {
	Predicates []predicate.GithubOrganizationMember  `json:"-"`
	Not        *GithubOrganizationMemberWhereInput   `json:"not,omitempty"`
	Or         []*GithubOrganizationMemberWhereInput `json:"or,omitempty"`
	And        []*GithubOrganizationMemberWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "role" field predicates.
	Role      *githuborganizationmember.Role  `json:"role,omitempty"`
	RoleNEQ   *githuborganizationmember.Role  `json:"roleNEQ,omitempty"`
	RoleIn    []githuborganizationmember.Role `json:"roleIn,omitempty"`
	RoleNotIn []githuborganizationmember.Role `json:"roleNotIn,omitempty"`

	// "organization" edge predicates.
	HasOrganization     *bool                           `json:"hasOrganization,omitempty"`
	HasOrganizationWith []*GithubOrganizationWhereInput `json:"hasOrganizationWith,omitempty"`

	// "account" edge predicates.
	HasAccount     *bool                      `json:"hasAccount,omitempty"`
	HasAccountWith []*GithubAccountWhereInput `json:"hasAccountWith,omitempty"`
}

GithubOrganizationMemberWhereInput represents a where input for filtering GithubOrganizationMember queries.

func (*GithubOrganizationMemberWhereInput) AddPredicates

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*GithubOrganizationMemberWhereInput) Filter

Filter applies the GithubOrganizationMemberWhereInput filter on the GithubOrganizationMemberQuery builder.

func (*GithubOrganizationMemberWhereInput) P

P returns a predicate for filtering githuborganizationmembers. An error is returned if the input is empty or invalid.

type GithubOrganizationMembers

type GithubOrganizationMembers []*GithubOrganizationMember

GithubOrganizationMembers is a parsable slice of GithubOrganizationMember.

type GithubOrganizationMutation

type GithubOrganizationMutation struct {
	// contains filtered or unexported fields
}

GithubOrganizationMutation represents an operation that mutates the GithubOrganization nodes in the graph.

func (*GithubOrganizationMutation) AddField

func (m *GithubOrganizationMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*GithubOrganizationMutation) AddMemberIDs

func (m *GithubOrganizationMutation) AddMemberIDs(ids ...int)

AddMemberIDs adds the "members" edge to the GithubOrganizationMember entity by ids.

func (*GithubOrganizationMutation) AddRepositoryIDs

func (m *GithubOrganizationMutation) AddRepositoryIDs(ids ...int)

AddRepositoryIDs adds the "repositories" edge to the Repository entity by ids.

func (*GithubOrganizationMutation) AddedEdges

func (m *GithubOrganizationMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*GithubOrganizationMutation) AddedField

func (m *GithubOrganizationMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*GithubOrganizationMutation) AddedFields

func (m *GithubOrganizationMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*GithubOrganizationMutation) AddedIDs

func (m *GithubOrganizationMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*GithubOrganizationMutation) ClearDisplayName

func (m *GithubOrganizationMutation) ClearDisplayName()

ClearDisplayName clears the value of the "display_name" field.

func (*GithubOrganizationMutation) ClearEdge

func (m *GithubOrganizationMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*GithubOrganizationMutation) ClearField

func (m *GithubOrganizationMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*GithubOrganizationMutation) ClearMembers

func (m *GithubOrganizationMutation) ClearMembers()

ClearMembers clears the "members" edge to the GithubOrganizationMember entity.

func (*GithubOrganizationMutation) ClearRepositories

func (m *GithubOrganizationMutation) ClearRepositories()

ClearRepositories clears the "repositories" edge to the Repository entity.

func (*GithubOrganizationMutation) ClearedEdges

func (m *GithubOrganizationMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*GithubOrganizationMutation) ClearedFields

func (m *GithubOrganizationMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (GithubOrganizationMutation) Client

func (m GithubOrganizationMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*GithubOrganizationMutation) DisplayName

func (m *GithubOrganizationMutation) DisplayName() (r string, exists bool)

DisplayName returns the value of the "display_name" field in the mutation.

func (*GithubOrganizationMutation) DisplayNameCleared

func (m *GithubOrganizationMutation) DisplayNameCleared() bool

DisplayNameCleared returns if the "display_name" field was cleared in this mutation.

func (*GithubOrganizationMutation) EdgeCleared

func (m *GithubOrganizationMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*GithubOrganizationMutation) Field

func (m *GithubOrganizationMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*GithubOrganizationMutation) FieldCleared

func (m *GithubOrganizationMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*GithubOrganizationMutation) Fields

func (m *GithubOrganizationMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*GithubOrganizationMutation) ID

func (m *GithubOrganizationMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*GithubOrganizationMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*GithubOrganizationMutation) MembersCleared

func (m *GithubOrganizationMutation) MembersCleared() bool

MembersCleared reports if the "members" edge to the GithubOrganizationMember entity was cleared.

func (*GithubOrganizationMutation) MembersIDs

func (m *GithubOrganizationMutation) MembersIDs() (ids []int)

MembersIDs returns the "members" edge IDs in the mutation.

func (*GithubOrganizationMutation) Name

func (m *GithubOrganizationMutation) Name() (r string, exists bool)

Name returns the value of the "name" field in the mutation.

func (*GithubOrganizationMutation) OldDisplayName

func (m *GithubOrganizationMutation) OldDisplayName(ctx context.Context) (v string, err error)

OldDisplayName returns the old "display_name" field's value of the GithubOrganization entity. If the GithubOrganization object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*GithubOrganizationMutation) OldField

func (m *GithubOrganizationMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*GithubOrganizationMutation) OldName

func (m *GithubOrganizationMutation) OldName(ctx context.Context) (v string, err error)

OldName returns the old "name" field's value of the GithubOrganization entity. If the GithubOrganization object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*GithubOrganizationMutation) Op

Op returns the operation name.

func (*GithubOrganizationMutation) RemoveMemberIDs

func (m *GithubOrganizationMutation) RemoveMemberIDs(ids ...int)

RemoveMemberIDs removes the "members" edge to the GithubOrganizationMember entity by IDs.

func (*GithubOrganizationMutation) RemoveRepositoryIDs

func (m *GithubOrganizationMutation) RemoveRepositoryIDs(ids ...int)

RemoveRepositoryIDs removes the "repositories" edge to the Repository entity by IDs.

func (*GithubOrganizationMutation) RemovedEdges

func (m *GithubOrganizationMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*GithubOrganizationMutation) RemovedIDs

func (m *GithubOrganizationMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*GithubOrganizationMutation) RemovedMembersIDs

func (m *GithubOrganizationMutation) RemovedMembersIDs() (ids []int)

RemovedMembers returns the removed IDs of the "members" edge to the GithubOrganizationMember entity.

func (*GithubOrganizationMutation) RemovedRepositoriesIDs

func (m *GithubOrganizationMutation) RemovedRepositoriesIDs() (ids []int)

RemovedRepositories returns the removed IDs of the "repositories" edge to the Repository entity.

func (*GithubOrganizationMutation) RepositoriesCleared

func (m *GithubOrganizationMutation) RepositoriesCleared() bool

RepositoriesCleared reports if the "repositories" edge to the Repository entity was cleared.

func (*GithubOrganizationMutation) RepositoriesIDs

func (m *GithubOrganizationMutation) RepositoriesIDs() (ids []int)

RepositoriesIDs returns the "repositories" edge IDs in the mutation.

func (*GithubOrganizationMutation) ResetDisplayName

func (m *GithubOrganizationMutation) ResetDisplayName()

ResetDisplayName resets all changes to the "display_name" field.

func (*GithubOrganizationMutation) ResetEdge

func (m *GithubOrganizationMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*GithubOrganizationMutation) ResetField

func (m *GithubOrganizationMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*GithubOrganizationMutation) ResetMembers

func (m *GithubOrganizationMutation) ResetMembers()

ResetMembers resets all changes to the "members" edge.

func (*GithubOrganizationMutation) ResetName

func (m *GithubOrganizationMutation) ResetName()

ResetName resets all changes to the "name" field.

func (*GithubOrganizationMutation) ResetRepositories

func (m *GithubOrganizationMutation) ResetRepositories()

ResetRepositories resets all changes to the "repositories" edge.

func (*GithubOrganizationMutation) SetDisplayName

func (m *GithubOrganizationMutation) SetDisplayName(s string)

SetDisplayName sets the "display_name" field.

func (*GithubOrganizationMutation) SetField

func (m *GithubOrganizationMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*GithubOrganizationMutation) SetName

func (m *GithubOrganizationMutation) SetName(s string)

SetName sets the "name" field.

func (GithubOrganizationMutation) Tx

func (m GithubOrganizationMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*GithubOrganizationMutation) Type

Type returns the node type of this mutation (GithubOrganization).

func (*GithubOrganizationMutation) Where

Where appends a list predicates to the GithubOrganizationMutation builder.

type GithubOrganizationOrder

type GithubOrganizationOrder struct {
	Direction OrderDirection                `json:"direction"`
	Field     *GithubOrganizationOrderField `json:"field"`
}

GithubOrganizationOrder defines the ordering of GithubOrganization.

type GithubOrganizationOrderField

type GithubOrganizationOrderField struct {
	// contains filtered or unexported fields
}

GithubOrganizationOrderField defines the ordering field of GithubOrganization.

func (GithubOrganizationOrderField) MarshalGQL

func (f GithubOrganizationOrderField) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (GithubOrganizationOrderField) String

String implement fmt.Stringer interface.

func (*GithubOrganizationOrderField) UnmarshalGQL

func (f *GithubOrganizationOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type GithubOrganizationPaginateOption

type GithubOrganizationPaginateOption func(*githuborganizationPager) error

GithubOrganizationPaginateOption enables pagination customization.

func WithGithubOrganizationFilter

func WithGithubOrganizationFilter(filter func(*GithubOrganizationQuery) (*GithubOrganizationQuery, error)) GithubOrganizationPaginateOption

WithGithubOrganizationFilter configures pagination filter.

func WithGithubOrganizationOrder

func WithGithubOrganizationOrder(order *GithubOrganizationOrder) GithubOrganizationPaginateOption

WithGithubOrganizationOrder configures pagination ordering.

type GithubOrganizationQuery

type GithubOrganizationQuery struct {
	// contains filtered or unexported fields
}

GithubOrganizationQuery is the builder for querying GithubOrganization entities.

func (*GithubOrganizationQuery) All

All executes the query and returns a list of GithubOrganizations.

func (*GithubOrganizationQuery) AllX

AllX is like All, but panics if an error occurs.

func (*GithubOrganizationQuery) Clone

Clone returns a duplicate of the GithubOrganizationQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*GithubOrganizationQuery) CollectFields

func (_go *GithubOrganizationQuery) CollectFields(ctx context.Context, satisfies ...string) (*GithubOrganizationQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*GithubOrganizationQuery) Count

func (goq *GithubOrganizationQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*GithubOrganizationQuery) CountX

func (goq *GithubOrganizationQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*GithubOrganizationQuery) Exist

func (goq *GithubOrganizationQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*GithubOrganizationQuery) ExistX

func (goq *GithubOrganizationQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*GithubOrganizationQuery) First

First returns the first GithubOrganization entity from the query. Returns a *NotFoundError when no GithubOrganization was found.

func (*GithubOrganizationQuery) FirstID

func (goq *GithubOrganizationQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first GithubOrganization ID from the query. Returns a *NotFoundError when no GithubOrganization ID was found.

func (*GithubOrganizationQuery) FirstIDX

func (goq *GithubOrganizationQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*GithubOrganizationQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*GithubOrganizationQuery) GroupBy

func (goq *GithubOrganizationQuery) GroupBy(field string, fields ...string) *GithubOrganizationGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Name string `json:"name,omitempty"`
	Count int `json:"count,omitempty"`
}

client.GithubOrganization.Query().
	GroupBy(githuborganization.FieldName).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*GithubOrganizationQuery) IDs

func (goq *GithubOrganizationQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of GithubOrganization IDs.

func (*GithubOrganizationQuery) IDsX

func (goq *GithubOrganizationQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*GithubOrganizationQuery) Limit

Limit adds a limit step to the query.

func (*GithubOrganizationQuery) Offset

Offset adds an offset step to the query.

func (*GithubOrganizationQuery) Only

Only returns a single GithubOrganization entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one GithubOrganization entity is found. Returns a *NotFoundError when no GithubOrganization entities are found.

func (*GithubOrganizationQuery) OnlyID

func (goq *GithubOrganizationQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only GithubOrganization ID in the query. Returns a *NotSingularError when more than one GithubOrganization ID is found. Returns a *NotFoundError when no entities are found.

func (*GithubOrganizationQuery) OnlyIDX

func (goq *GithubOrganizationQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*GithubOrganizationQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*GithubOrganizationQuery) Order

Order adds an order step to the query.

func (*GithubOrganizationQuery) Paginate

func (_go *GithubOrganizationQuery) Paginate(
	ctx context.Context, after *Cursor, first *int,
	before *Cursor, last *int, opts ...GithubOrganizationPaginateOption,
) (*GithubOrganizationConnection, error)

Paginate executes the query and returns a relay based cursor connection to GithubOrganization.

func (*GithubOrganizationQuery) QueryMembers

QueryMembers chains the current query on the "members" edge.

func (*GithubOrganizationQuery) QueryRepositories

func (goq *GithubOrganizationQuery) QueryRepositories() *RepositoryQuery

QueryRepositories chains the current query on the "repositories" edge.

func (*GithubOrganizationQuery) Select

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Name string `json:"name,omitempty"`
}

client.GithubOrganization.Query().
	Select(githuborganization.FieldName).
	Scan(ctx, &v)

func (*GithubOrganizationQuery) Unique

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*GithubOrganizationQuery) Where

Where adds a new predicate for the GithubOrganizationQuery builder.

func (*GithubOrganizationQuery) WithMembers

WithMembers tells the query-builder to eager-load the nodes that are connected to the "members" edge. The optional arguments are used to configure the query builder of the edge.

func (*GithubOrganizationQuery) WithNamedMembers

func (goq *GithubOrganizationQuery) WithNamedMembers(name string, opts ...func(*GithubOrganizationMemberQuery)) *GithubOrganizationQuery

WithNamedMembers tells the query-builder to eager-load the nodes that are connected to the "members" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*GithubOrganizationQuery) WithNamedRepositories

func (goq *GithubOrganizationQuery) WithNamedRepositories(name string, opts ...func(*RepositoryQuery)) *GithubOrganizationQuery

WithNamedRepositories tells the query-builder to eager-load the nodes that are connected to the "repositories" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*GithubOrganizationQuery) WithRepositories

func (goq *GithubOrganizationQuery) WithRepositories(opts ...func(*RepositoryQuery)) *GithubOrganizationQuery

WithRepositories tells the query-builder to eager-load the nodes that are connected to the "repositories" edge. The optional arguments are used to configure the query builder of the edge.

type GithubOrganizationSelect

type GithubOrganizationSelect struct {
	*GithubOrganizationQuery
	// contains filtered or unexported fields
}

GithubOrganizationSelect is the builder for selecting fields of GithubOrganization entities.

func (*GithubOrganizationSelect) Bool

func (s *GithubOrganizationSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationSelect) BoolX

func (s *GithubOrganizationSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*GithubOrganizationSelect) Bools

func (s *GithubOrganizationSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationSelect) BoolsX

func (s *GithubOrganizationSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*GithubOrganizationSelect) Float64

func (s *GithubOrganizationSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationSelect) Float64X

func (s *GithubOrganizationSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*GithubOrganizationSelect) Float64s

func (s *GithubOrganizationSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationSelect) Float64sX

func (s *GithubOrganizationSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*GithubOrganizationSelect) Int

func (s *GithubOrganizationSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationSelect) IntX

func (s *GithubOrganizationSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*GithubOrganizationSelect) Ints

func (s *GithubOrganizationSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationSelect) IntsX

func (s *GithubOrganizationSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*GithubOrganizationSelect) Scan

func (gos *GithubOrganizationSelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*GithubOrganizationSelect) ScanX

func (s *GithubOrganizationSelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*GithubOrganizationSelect) String

func (s *GithubOrganizationSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationSelect) StringX

func (s *GithubOrganizationSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*GithubOrganizationSelect) Strings

func (s *GithubOrganizationSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*GithubOrganizationSelect) StringsX

func (s *GithubOrganizationSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type GithubOrganizationUpdate

type GithubOrganizationUpdate struct {
	// contains filtered or unexported fields
}

GithubOrganizationUpdate is the builder for updating GithubOrganization entities.

func (*GithubOrganizationUpdate) AddMemberIDs

func (gou *GithubOrganizationUpdate) AddMemberIDs(ids ...int) *GithubOrganizationUpdate

AddMemberIDs adds the "members" edge to the GithubOrganizationMember entity by IDs.

func (*GithubOrganizationUpdate) AddMembers

AddMembers adds the "members" edges to the GithubOrganizationMember entity.

func (*GithubOrganizationUpdate) AddRepositories

func (gou *GithubOrganizationUpdate) AddRepositories(r ...*Repository) *GithubOrganizationUpdate

AddRepositories adds the "repositories" edges to the Repository entity.

func (*GithubOrganizationUpdate) AddRepositoryIDs

func (gou *GithubOrganizationUpdate) AddRepositoryIDs(ids ...int) *GithubOrganizationUpdate

AddRepositoryIDs adds the "repositories" edge to the Repository entity by IDs.

func (*GithubOrganizationUpdate) ClearDisplayName

func (gou *GithubOrganizationUpdate) ClearDisplayName() *GithubOrganizationUpdate

ClearDisplayName clears the value of the "display_name" field.

func (*GithubOrganizationUpdate) ClearMembers

ClearMembers clears all "members" edges to the GithubOrganizationMember entity.

func (*GithubOrganizationUpdate) ClearRepositories

func (gou *GithubOrganizationUpdate) ClearRepositories() *GithubOrganizationUpdate

ClearRepositories clears all "repositories" edges to the Repository entity.

func (*GithubOrganizationUpdate) Exec

Exec executes the query.

func (*GithubOrganizationUpdate) ExecX

func (gou *GithubOrganizationUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*GithubOrganizationUpdate) Mutation

Mutation returns the GithubOrganizationMutation object of the builder.

func (*GithubOrganizationUpdate) RemoveMemberIDs

func (gou *GithubOrganizationUpdate) RemoveMemberIDs(ids ...int) *GithubOrganizationUpdate

RemoveMemberIDs removes the "members" edge to GithubOrganizationMember entities by IDs.

func (*GithubOrganizationUpdate) RemoveMembers

RemoveMembers removes "members" edges to GithubOrganizationMember entities.

func (*GithubOrganizationUpdate) RemoveRepositories

func (gou *GithubOrganizationUpdate) RemoveRepositories(r ...*Repository) *GithubOrganizationUpdate

RemoveRepositories removes "repositories" edges to Repository entities.

func (*GithubOrganizationUpdate) RemoveRepositoryIDs

func (gou *GithubOrganizationUpdate) RemoveRepositoryIDs(ids ...int) *GithubOrganizationUpdate

RemoveRepositoryIDs removes the "repositories" edge to Repository entities by IDs.

func (*GithubOrganizationUpdate) Save

func (gou *GithubOrganizationUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*GithubOrganizationUpdate) SaveX

func (gou *GithubOrganizationUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*GithubOrganizationUpdate) SetDisplayName

SetDisplayName sets the "display_name" field.

func (*GithubOrganizationUpdate) SetInput

SetInput applies the change-set in the UpdateGithubOrganizationInput on the update builder.

func (*GithubOrganizationUpdate) SetName

SetName sets the "name" field.

func (*GithubOrganizationUpdate) SetNillableDisplayName

func (gou *GithubOrganizationUpdate) SetNillableDisplayName(s *string) *GithubOrganizationUpdate

SetNillableDisplayName sets the "display_name" field if the given value is not nil.

func (*GithubOrganizationUpdate) Where

Where appends a list predicates to the GithubOrganizationUpdate builder.

type GithubOrganizationUpdateOne

type GithubOrganizationUpdateOne struct {
	// contains filtered or unexported fields
}

GithubOrganizationUpdateOne is the builder for updating a single GithubOrganization entity.

func (*GithubOrganizationUpdateOne) AddMemberIDs

func (gouo *GithubOrganizationUpdateOne) AddMemberIDs(ids ...int) *GithubOrganizationUpdateOne

AddMemberIDs adds the "members" edge to the GithubOrganizationMember entity by IDs.

func (*GithubOrganizationUpdateOne) AddMembers

AddMembers adds the "members" edges to the GithubOrganizationMember entity.

func (*GithubOrganizationUpdateOne) AddRepositories

AddRepositories adds the "repositories" edges to the Repository entity.

func (*GithubOrganizationUpdateOne) AddRepositoryIDs

func (gouo *GithubOrganizationUpdateOne) AddRepositoryIDs(ids ...int) *GithubOrganizationUpdateOne

AddRepositoryIDs adds the "repositories" edge to the Repository entity by IDs.

func (*GithubOrganizationUpdateOne) ClearDisplayName

func (gouo *GithubOrganizationUpdateOne) ClearDisplayName() *GithubOrganizationUpdateOne

ClearDisplayName clears the value of the "display_name" field.

func (*GithubOrganizationUpdateOne) ClearMembers

ClearMembers clears all "members" edges to the GithubOrganizationMember entity.

func (*GithubOrganizationUpdateOne) ClearRepositories

func (gouo *GithubOrganizationUpdateOne) ClearRepositories() *GithubOrganizationUpdateOne

ClearRepositories clears all "repositories" edges to the Repository entity.

func (*GithubOrganizationUpdateOne) Exec

Exec executes the query on the entity.

func (*GithubOrganizationUpdateOne) ExecX

func (gouo *GithubOrganizationUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*GithubOrganizationUpdateOne) Mutation

Mutation returns the GithubOrganizationMutation object of the builder.

func (*GithubOrganizationUpdateOne) RemoveMemberIDs

func (gouo *GithubOrganizationUpdateOne) RemoveMemberIDs(ids ...int) *GithubOrganizationUpdateOne

RemoveMemberIDs removes the "members" edge to GithubOrganizationMember entities by IDs.

func (*GithubOrganizationUpdateOne) RemoveMembers

RemoveMembers removes "members" edges to GithubOrganizationMember entities.

func (*GithubOrganizationUpdateOne) RemoveRepositories

func (gouo *GithubOrganizationUpdateOne) RemoveRepositories(r ...*Repository) *GithubOrganizationUpdateOne

RemoveRepositories removes "repositories" edges to Repository entities.

func (*GithubOrganizationUpdateOne) RemoveRepositoryIDs

func (gouo *GithubOrganizationUpdateOne) RemoveRepositoryIDs(ids ...int) *GithubOrganizationUpdateOne

RemoveRepositoryIDs removes the "repositories" edge to Repository entities by IDs.

func (*GithubOrganizationUpdateOne) Save

Save executes the query and returns the updated GithubOrganization entity.

func (*GithubOrganizationUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*GithubOrganizationUpdateOne) Select

func (gouo *GithubOrganizationUpdateOne) Select(field string, fields ...string) *GithubOrganizationUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*GithubOrganizationUpdateOne) SetDisplayName

SetDisplayName sets the "display_name" field.

func (*GithubOrganizationUpdateOne) SetInput

SetInput applies the change-set in the UpdateGithubOrganizationInput on the update-one builder.

func (*GithubOrganizationUpdateOne) SetName

SetName sets the "name" field.

func (*GithubOrganizationUpdateOne) SetNillableDisplayName

func (gouo *GithubOrganizationUpdateOne) SetNillableDisplayName(s *string) *GithubOrganizationUpdateOne

SetNillableDisplayName sets the "display_name" field if the given value is not nil.

type GithubOrganizationWhereInput

type GithubOrganizationWhereInput struct {
	Predicates []predicate.GithubOrganization  `json:"-"`
	Not        *GithubOrganizationWhereInput   `json:"not,omitempty"`
	Or         []*GithubOrganizationWhereInput `json:"or,omitempty"`
	And        []*GithubOrganizationWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "name" field predicates.
	Name             *string  `json:"name,omitempty"`
	NameNEQ          *string  `json:"nameNEQ,omitempty"`
	NameIn           []string `json:"nameIn,omitempty"`
	NameNotIn        []string `json:"nameNotIn,omitempty"`
	NameGT           *string  `json:"nameGT,omitempty"`
	NameGTE          *string  `json:"nameGTE,omitempty"`
	NameLT           *string  `json:"nameLT,omitempty"`
	NameLTE          *string  `json:"nameLTE,omitempty"`
	NameContains     *string  `json:"nameContains,omitempty"`
	NameHasPrefix    *string  `json:"nameHasPrefix,omitempty"`
	NameHasSuffix    *string  `json:"nameHasSuffix,omitempty"`
	NameEqualFold    *string  `json:"nameEqualFold,omitempty"`
	NameContainsFold *string  `json:"nameContainsFold,omitempty"`

	// "display_name" field predicates.
	DisplayName             *string  `json:"displayName,omitempty"`
	DisplayNameNEQ          *string  `json:"displayNameNEQ,omitempty"`
	DisplayNameIn           []string `json:"displayNameIn,omitempty"`
	DisplayNameNotIn        []string `json:"displayNameNotIn,omitempty"`
	DisplayNameGT           *string  `json:"displayNameGT,omitempty"`
	DisplayNameGTE          *string  `json:"displayNameGTE,omitempty"`
	DisplayNameLT           *string  `json:"displayNameLT,omitempty"`
	DisplayNameLTE          *string  `json:"displayNameLTE,omitempty"`
	DisplayNameContains     *string  `json:"displayNameContains,omitempty"`
	DisplayNameHasPrefix    *string  `json:"displayNameHasPrefix,omitempty"`
	DisplayNameHasSuffix    *string  `json:"displayNameHasSuffix,omitempty"`
	DisplayNameIsNil        bool     `json:"displayNameIsNil,omitempty"`
	DisplayNameNotNil       bool     `json:"displayNameNotNil,omitempty"`
	DisplayNameEqualFold    *string  `json:"displayNameEqualFold,omitempty"`
	DisplayNameContainsFold *string  `json:"displayNameContainsFold,omitempty"`

	// "members" edge predicates.
	HasMembers     *bool                                 `json:"hasMembers,omitempty"`
	HasMembersWith []*GithubOrganizationMemberWhereInput `json:"hasMembersWith,omitempty"`

	// "repositories" edge predicates.
	HasRepositories     *bool                   `json:"hasRepositories,omitempty"`
	HasRepositoriesWith []*RepositoryWhereInput `json:"hasRepositoriesWith,omitempty"`
}

GithubOrganizationWhereInput represents a where input for filtering GithubOrganization queries.

func (*GithubOrganizationWhereInput) AddPredicates

func (i *GithubOrganizationWhereInput) AddPredicates(predicates ...predicate.GithubOrganization)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*GithubOrganizationWhereInput) Filter

Filter applies the GithubOrganizationWhereInput filter on the GithubOrganizationQuery builder.

func (*GithubOrganizationWhereInput) P

P returns a predicate for filtering githuborganizations. An error is returned if the input is empty or invalid.

type GithubOrganizations

type GithubOrganizations []*GithubOrganization

GithubOrganizations is a parsable slice of GithubOrganization.

type Hook

type Hook = ent.Hook

ent aliases to avoid import conflicts in user's code.

type MutateFunc

type MutateFunc = ent.MutateFunc

ent aliases to avoid import conflicts in user's code.

type Mutation

type Mutation = ent.Mutation

ent aliases to avoid import conflicts in user's code.

type Mutator

type Mutator = ent.Mutator

ent aliases to avoid import conflicts in user's code.

type Node

type Node struct {
	ID     int      `json:"id,omitempty"`     // node id.
	Type   string   `json:"type,omitempty"`   // node type.
	Fields []*Field `json:"fields,omitempty"` // node fields.
	Edges  []*Edge  `json:"edges,omitempty"`  // node edges.
}

Node in the graph.

type NodeOption

type NodeOption func(*nodeOptions)

NodeOption allows configuring the Noder execution using functional options.

func WithFixedNodeType

func WithFixedNodeType(t string) NodeOption

WithFixedNodeType sets the Type of the node to a fixed value.

func WithNodeType

func WithNodeType(f func(context.Context, int) (string, error)) NodeOption

WithNodeType sets the node Type resolver function (i.e. the table to query). If was not provided, the table will be derived from the universal-id configuration as described in: https://entgo.io/docs/migrate/#universal-ids.

type Noder

type Noder interface {
	Node(context.Context) (*Node, error)
}

Noder wraps the basic Node method.

type NotFoundError

type NotFoundError struct {
	// contains filtered or unexported fields
}

NotFoundError returns when trying to fetch a specific entity and it was not found in the database.

func (*NotFoundError) Error

func (e *NotFoundError) Error() string

Error implements the error interface.

type NotLoadedError

type NotLoadedError struct {
	// contains filtered or unexported fields
}

NotLoadedError returns when trying to get a node that was not loaded by the query.

func (*NotLoadedError) Error

func (e *NotLoadedError) Error() string

Error implements the error interface.

type NotSingularError

type NotSingularError struct {
	// contains filtered or unexported fields
}

NotSingularError returns when trying to fetch a singular entity and more then one was found in the database.

func (*NotSingularError) Error

func (e *NotSingularError) Error() string

Error implements the error interface.

type Op

type Op = ent.Op

ent aliases to avoid import conflicts in user's code.

type Option

type Option func(*config)

Option function to configure the client.

func Debug

func Debug() Option

Debug enables debug logging on the ent.Driver.

func Driver

func Driver(driver dialect.Driver) Option

Driver configures the client driver.

func Log

func Log(fn func(...interface{})) Option

Log sets the logging function for debug mode.

type OrderDirection

type OrderDirection string

OrderDirection defines the directions in which to order a list of items.

const (
	// OrderDirectionAsc specifies an ascending order.
	OrderDirectionAsc OrderDirection = "ASC"
	// OrderDirectionDesc specifies a descending order.
	OrderDirectionDesc OrderDirection = "DESC"
)

func (OrderDirection) MarshalGQL

func (o OrderDirection) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (OrderDirection) String

func (o OrderDirection) String() string

String implements fmt.Stringer interface.

func (*OrderDirection) UnmarshalGQL

func (o *OrderDirection) UnmarshalGQL(val interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

func (OrderDirection) Validate

func (o OrderDirection) Validate() error

Validate the order direction value.

type OrderFunc

type OrderFunc func(*sql.Selector)

OrderFunc applies an ordering on the sql selector.

func Asc

func Asc(fields ...string) OrderFunc

Asc applies the given fields in ASC order.

func Desc

func Desc(fields ...string) OrderFunc

Desc applies the given fields in DESC order.

type PageInfo

type PageInfo struct {
	HasNextPage     bool    `json:"hasNextPage"`
	HasPreviousPage bool    `json:"hasPreviousPage"`
	StartCursor     *Cursor `json:"startCursor"`
	EndCursor       *Cursor `json:"endCursor"`
}

PageInfo of a connection type.

type Policy

type Policy = ent.Policy

ent aliases to avoid import conflicts in user's code.

type Project

type Project struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Name holds the value of the "name" field.
	Name string `json:"name,omitempty"`
	// Description holds the value of the "description" field.
	Description *string `json:"description,omitempty"`
	// StartDate holds the value of the "start_date" field.
	StartDate time.Time `json:"start_date,omitempty"`
	// EndDate holds the value of the "end_date" field.
	EndDate *time.Time `json:"end_date,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the ProjectQuery when eager-loading is set.
	Edges ProjectEdges `json:"edges"`
	// contains filtered or unexported fields
}

Project is the model entity for the Project schema.

func (*Project) ChildProjects

func (pr *Project) ChildProjects(ctx context.Context) ([]*ProjectAssociation, error)

func (*Project) Contributors

func (pr *Project) Contributors(ctx context.Context) ([]*ProjectContributor, error)

func (*Project) DiscordBots

func (pr *Project) DiscordBots(ctx context.Context) ([]*DiscordBot, error)

func (*Project) NamedChildProjects

func (pr *Project) NamedChildProjects(name string) ([]*ProjectAssociation, error)

NamedChildProjects returns the ChildProjects named value or an error if the edge was not loaded in eager-loading with this name.

func (*Project) NamedContributors

func (pr *Project) NamedContributors(name string) ([]*ProjectContributor, error)

NamedContributors returns the Contributors named value or an error if the edge was not loaded in eager-loading with this name.

func (*Project) NamedDiscordBots

func (pr *Project) NamedDiscordBots(name string) ([]*DiscordBot, error)

NamedDiscordBots returns the DiscordBots named value or an error if the edge was not loaded in eager-loading with this name.

func (*Project) NamedParentProjects

func (pr *Project) NamedParentProjects(name string) ([]*ProjectAssociation, error)

NamedParentProjects returns the ParentProjects named value or an error if the edge was not loaded in eager-loading with this name.

func (*Project) NamedRepositories

func (pr *Project) NamedRepositories(name string) ([]*Repository, error)

NamedRepositories returns the Repositories named value or an error if the edge was not loaded in eager-loading with this name.

func (*Project) NamedSites

func (pr *Project) NamedSites(name string) ([]*Site, error)

NamedSites returns the Sites named value or an error if the edge was not loaded in eager-loading with this name.

func (*Project) NamedTechnologies

func (pr *Project) NamedTechnologies(name string) ([]*ProjectTechnology, error)

NamedTechnologies returns the Technologies named value or an error if the edge was not loaded in eager-loading with this name.

func (*Project) Node

func (pr *Project) Node(ctx context.Context) (node *Node, err error)

func (*Project) ParentProjects

func (pr *Project) ParentProjects(ctx context.Context) ([]*ProjectAssociation, error)

func (*Project) QueryChildProjects

func (pr *Project) QueryChildProjects() *ProjectAssociationQuery

QueryChildProjects queries the "child_projects" edge of the Project entity.

func (*Project) QueryContributors

func (pr *Project) QueryContributors() *ProjectContributorQuery

QueryContributors queries the "contributors" edge of the Project entity.

func (*Project) QueryDiscordBots

func (pr *Project) QueryDiscordBots() *DiscordBotQuery

QueryDiscordBots queries the "discord_bots" edge of the Project entity.

func (*Project) QueryParentProjects

func (pr *Project) QueryParentProjects() *ProjectAssociationQuery

QueryParentProjects queries the "parent_projects" edge of the Project entity.

func (*Project) QueryRepositories

func (pr *Project) QueryRepositories() *RepositoryQuery

QueryRepositories queries the "repositories" edge of the Project entity.

func (*Project) QuerySites

func (pr *Project) QuerySites() *SiteQuery

QuerySites queries the "sites" edge of the Project entity.

func (*Project) QueryTechnologies

func (pr *Project) QueryTechnologies() *ProjectTechnologyQuery

QueryTechnologies queries the "technologies" edge of the Project entity.

func (*Project) Repositories

func (pr *Project) Repositories(ctx context.Context) ([]*Repository, error)

func (*Project) Sites

func (pr *Project) Sites(ctx context.Context) ([]*Site, error)

func (*Project) String

func (pr *Project) String() string

String implements the fmt.Stringer.

func (*Project) Technologies

func (pr *Project) Technologies(ctx context.Context) ([]*ProjectTechnology, error)

func (*Project) ToEdge

func (pr *Project) ToEdge(order *ProjectOrder) *ProjectEdge

ToEdge converts Project into ProjectEdge.

func (*Project) Unwrap

func (pr *Project) Unwrap() *Project

Unwrap unwraps the Project entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*Project) Update

func (pr *Project) Update() *ProjectUpdateOne

Update returns a builder for updating this Project. Note that you need to call Project.Unwrap() before calling this method if this Project was returned from a transaction, and the transaction was committed or rolled back.

type ProjectAssociation

type ProjectAssociation struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Type holds the value of the "type" field.
	Type projectassociation.Type `json:"type,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the ProjectAssociationQuery when eager-loading is set.
	Edges ProjectAssociationEdges `json:"edges"`
	// contains filtered or unexported fields
}

ProjectAssociation is the model entity for the ProjectAssociation schema.

func (*ProjectAssociation) Child

func (pa *ProjectAssociation) Child(ctx context.Context) (*Project, error)

func (*ProjectAssociation) Node

func (pa *ProjectAssociation) Node(ctx context.Context) (node *Node, err error)

func (*ProjectAssociation) Parent

func (pa *ProjectAssociation) Parent(ctx context.Context) (*Project, error)

func (*ProjectAssociation) QueryChild

func (pa *ProjectAssociation) QueryChild() *ProjectQuery

QueryChild queries the "child" edge of the ProjectAssociation entity.

func (*ProjectAssociation) QueryParent

func (pa *ProjectAssociation) QueryParent() *ProjectQuery

QueryParent queries the "parent" edge of the ProjectAssociation entity.

func (*ProjectAssociation) String

func (pa *ProjectAssociation) String() string

String implements the fmt.Stringer.

func (*ProjectAssociation) ToEdge

ToEdge converts ProjectAssociation into ProjectAssociationEdge.

func (*ProjectAssociation) Unwrap

func (pa *ProjectAssociation) Unwrap() *ProjectAssociation

Unwrap unwraps the ProjectAssociation entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*ProjectAssociation) Update

Update returns a builder for updating this ProjectAssociation. Note that you need to call ProjectAssociation.Unwrap() before calling this method if this ProjectAssociation was returned from a transaction, and the transaction was committed or rolled back.

type ProjectAssociationClient

type ProjectAssociationClient struct {
	// contains filtered or unexported fields
}

ProjectAssociationClient is a client for the ProjectAssociation schema.

func NewProjectAssociationClient

func NewProjectAssociationClient(c config) *ProjectAssociationClient

NewProjectAssociationClient returns a client for the ProjectAssociation from the given config.

func (*ProjectAssociationClient) Create

Create returns a builder for creating a ProjectAssociation entity.

func (*ProjectAssociationClient) CreateBulk

CreateBulk returns a builder for creating a bulk of ProjectAssociation entities.

func (*ProjectAssociationClient) Delete

Delete returns a delete builder for ProjectAssociation.

func (*ProjectAssociationClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*ProjectAssociationClient) DeleteOneID

DeleteOne returns a builder for deleting the given entity by its id.

func (*ProjectAssociationClient) Get

Get returns a ProjectAssociation entity by its id.

func (*ProjectAssociationClient) GetX

GetX is like Get, but panics if an error occurs.

func (*ProjectAssociationClient) Hooks

func (c *ProjectAssociationClient) Hooks() []Hook

Hooks returns the client hooks.

func (*ProjectAssociationClient) Query

Query returns a query builder for ProjectAssociation.

func (*ProjectAssociationClient) QueryChild

QueryChild queries the child edge of a ProjectAssociation.

func (*ProjectAssociationClient) QueryParent

QueryParent queries the parent edge of a ProjectAssociation.

func (*ProjectAssociationClient) Update

Update returns an update builder for ProjectAssociation.

func (*ProjectAssociationClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*ProjectAssociationClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*ProjectAssociationClient) Use

func (c *ProjectAssociationClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `projectassociation.Hooks(f(g(h())))`.

type ProjectAssociationConnection

type ProjectAssociationConnection struct {
	Edges      []*ProjectAssociationEdge `json:"edges"`
	PageInfo   PageInfo                  `json:"pageInfo"`
	TotalCount int                       `json:"totalCount"`
}

ProjectAssociationConnection is the connection containing edges to ProjectAssociation.

type ProjectAssociationCreate

type ProjectAssociationCreate struct {
	// contains filtered or unexported fields
}

ProjectAssociationCreate is the builder for creating a ProjectAssociation entity.

func (*ProjectAssociationCreate) Exec

Exec executes the query.

func (*ProjectAssociationCreate) ExecX

func (pac *ProjectAssociationCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectAssociationCreate) Mutation

Mutation returns the ProjectAssociationMutation object of the builder.

func (*ProjectAssociationCreate) Save

Save creates the ProjectAssociation in the database.

func (*ProjectAssociationCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*ProjectAssociationCreate) SetChild

SetChild sets the "child" edge to the Project entity.

func (*ProjectAssociationCreate) SetChildID

SetChildID sets the "child" edge to the Project entity by ID.

func (*ProjectAssociationCreate) SetInput

SetInput applies the change-set in the CreateProjectAssociationInput on the create builder.

func (*ProjectAssociationCreate) SetParent

SetParent sets the "parent" edge to the Project entity.

func (*ProjectAssociationCreate) SetParentID

SetParentID sets the "parent" edge to the Project entity by ID.

func (*ProjectAssociationCreate) SetType

SetType sets the "type" field.

type ProjectAssociationCreateBulk

type ProjectAssociationCreateBulk struct {
	// contains filtered or unexported fields
}

ProjectAssociationCreateBulk is the builder for creating many ProjectAssociation entities in bulk.

func (*ProjectAssociationCreateBulk) Exec

Exec executes the query.

func (*ProjectAssociationCreateBulk) ExecX

func (pacb *ProjectAssociationCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectAssociationCreateBulk) Save

Save creates the ProjectAssociation entities in the database.

func (*ProjectAssociationCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type ProjectAssociationDelete

type ProjectAssociationDelete struct {
	// contains filtered or unexported fields
}

ProjectAssociationDelete is the builder for deleting a ProjectAssociation entity.

func (*ProjectAssociationDelete) Exec

func (pad *ProjectAssociationDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*ProjectAssociationDelete) ExecX

func (pad *ProjectAssociationDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*ProjectAssociationDelete) Where

Where appends a list predicates to the ProjectAssociationDelete builder.

type ProjectAssociationDeleteOne

type ProjectAssociationDeleteOne struct {
	// contains filtered or unexported fields
}

ProjectAssociationDeleteOne is the builder for deleting a single ProjectAssociation entity.

func (*ProjectAssociationDeleteOne) Exec

Exec executes the deletion query.

func (*ProjectAssociationDeleteOne) ExecX

func (pado *ProjectAssociationDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

type ProjectAssociationEdge

type ProjectAssociationEdge struct {
	Node   *ProjectAssociation `json:"node"`
	Cursor Cursor              `json:"cursor"`
}

ProjectAssociationEdge is the edge representation of ProjectAssociation.

type ProjectAssociationEdges

type ProjectAssociationEdges struct {
	// Parent holds the value of the parent edge.
	Parent *Project `json:"parent,omitempty"`
	// Child holds the value of the child edge.
	Child *Project `json:"child,omitempty"`
	// contains filtered or unexported fields
}

ProjectAssociationEdges holds the relations/edges for other nodes in the graph.

func (ProjectAssociationEdges) ChildOrErr

func (e ProjectAssociationEdges) ChildOrErr() (*Project, error)

ChildOrErr returns the Child value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (ProjectAssociationEdges) ParentOrErr

func (e ProjectAssociationEdges) ParentOrErr() (*Project, error)

ParentOrErr returns the Parent value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type ProjectAssociationGroupBy

type ProjectAssociationGroupBy struct {
	// contains filtered or unexported fields
}

ProjectAssociationGroupBy is the group-by builder for ProjectAssociation entities.

func (*ProjectAssociationGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*ProjectAssociationGroupBy) Bool

func (s *ProjectAssociationGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationGroupBy) BoolX

func (s *ProjectAssociationGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ProjectAssociationGroupBy) Bools

func (s *ProjectAssociationGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationGroupBy) BoolsX

func (s *ProjectAssociationGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ProjectAssociationGroupBy) Float64

func (s *ProjectAssociationGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationGroupBy) Float64X

func (s *ProjectAssociationGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ProjectAssociationGroupBy) Float64s

func (s *ProjectAssociationGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationGroupBy) Float64sX

func (s *ProjectAssociationGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ProjectAssociationGroupBy) Int

func (s *ProjectAssociationGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationGroupBy) IntX

func (s *ProjectAssociationGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ProjectAssociationGroupBy) Ints

func (s *ProjectAssociationGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationGroupBy) IntsX

func (s *ProjectAssociationGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ProjectAssociationGroupBy) Scan

func (pagb *ProjectAssociationGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*ProjectAssociationGroupBy) ScanX

func (s *ProjectAssociationGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*ProjectAssociationGroupBy) String

func (s *ProjectAssociationGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationGroupBy) StringX

func (s *ProjectAssociationGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ProjectAssociationGroupBy) Strings

func (s *ProjectAssociationGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationGroupBy) StringsX

func (s *ProjectAssociationGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ProjectAssociationMutation

type ProjectAssociationMutation struct {
	// contains filtered or unexported fields
}

ProjectAssociationMutation represents an operation that mutates the ProjectAssociation nodes in the graph.

func (*ProjectAssociationMutation) AddField

func (m *ProjectAssociationMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ProjectAssociationMutation) AddedEdges

func (m *ProjectAssociationMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*ProjectAssociationMutation) AddedField

func (m *ProjectAssociationMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ProjectAssociationMutation) AddedFields

func (m *ProjectAssociationMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*ProjectAssociationMutation) AddedIDs

func (m *ProjectAssociationMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*ProjectAssociationMutation) ChildCleared

func (m *ProjectAssociationMutation) ChildCleared() bool

ChildCleared reports if the "child" edge to the Project entity was cleared.

func (*ProjectAssociationMutation) ChildID

func (m *ProjectAssociationMutation) ChildID() (id int, exists bool)

ChildID returns the "child" edge ID in the mutation.

func (*ProjectAssociationMutation) ChildIDs

func (m *ProjectAssociationMutation) ChildIDs() (ids []int)

ChildIDs returns the "child" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ChildID instead. It exists only for internal usage by the builders.

func (*ProjectAssociationMutation) ClearChild

func (m *ProjectAssociationMutation) ClearChild()

ClearChild clears the "child" edge to the Project entity.

func (*ProjectAssociationMutation) ClearEdge

func (m *ProjectAssociationMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*ProjectAssociationMutation) ClearField

func (m *ProjectAssociationMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*ProjectAssociationMutation) ClearParent

func (m *ProjectAssociationMutation) ClearParent()

ClearParent clears the "parent" edge to the Project entity.

func (*ProjectAssociationMutation) ClearedEdges

func (m *ProjectAssociationMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*ProjectAssociationMutation) ClearedFields

func (m *ProjectAssociationMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (ProjectAssociationMutation) Client

func (m ProjectAssociationMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*ProjectAssociationMutation) EdgeCleared

func (m *ProjectAssociationMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*ProjectAssociationMutation) Field

func (m *ProjectAssociationMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ProjectAssociationMutation) FieldCleared

func (m *ProjectAssociationMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*ProjectAssociationMutation) Fields

func (m *ProjectAssociationMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*ProjectAssociationMutation) GetType

func (m *ProjectAssociationMutation) GetType() (r projectassociation.Type, exists bool)

GetType returns the value of the "type" field in the mutation.

func (*ProjectAssociationMutation) ID

func (m *ProjectAssociationMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*ProjectAssociationMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*ProjectAssociationMutation) OldField

func (m *ProjectAssociationMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*ProjectAssociationMutation) OldType

OldType returns the old "type" field's value of the ProjectAssociation entity. If the ProjectAssociation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProjectAssociationMutation) Op

Op returns the operation name.

func (*ProjectAssociationMutation) ParentCleared

func (m *ProjectAssociationMutation) ParentCleared() bool

ParentCleared reports if the "parent" edge to the Project entity was cleared.

func (*ProjectAssociationMutation) ParentID

func (m *ProjectAssociationMutation) ParentID() (id int, exists bool)

ParentID returns the "parent" edge ID in the mutation.

func (*ProjectAssociationMutation) ParentIDs

func (m *ProjectAssociationMutation) ParentIDs() (ids []int)

ParentIDs returns the "parent" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ParentID instead. It exists only for internal usage by the builders.

func (*ProjectAssociationMutation) RemovedEdges

func (m *ProjectAssociationMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*ProjectAssociationMutation) RemovedIDs

func (m *ProjectAssociationMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*ProjectAssociationMutation) ResetChild

func (m *ProjectAssociationMutation) ResetChild()

ResetChild resets all changes to the "child" edge.

func (*ProjectAssociationMutation) ResetEdge

func (m *ProjectAssociationMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*ProjectAssociationMutation) ResetField

func (m *ProjectAssociationMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*ProjectAssociationMutation) ResetParent

func (m *ProjectAssociationMutation) ResetParent()

ResetParent resets all changes to the "parent" edge.

func (*ProjectAssociationMutation) ResetType

func (m *ProjectAssociationMutation) ResetType()

ResetType resets all changes to the "type" field.

func (*ProjectAssociationMutation) SetChildID

func (m *ProjectAssociationMutation) SetChildID(id int)

SetChildID sets the "child" edge to the Project entity by id.

func (*ProjectAssociationMutation) SetField

func (m *ProjectAssociationMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ProjectAssociationMutation) SetParentID

func (m *ProjectAssociationMutation) SetParentID(id int)

SetParentID sets the "parent" edge to the Project entity by id.

func (*ProjectAssociationMutation) SetType

SetType sets the "type" field.

func (ProjectAssociationMutation) Tx

func (m ProjectAssociationMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*ProjectAssociationMutation) Type

Type returns the node type of this mutation (ProjectAssociation).

func (*ProjectAssociationMutation) Where

Where appends a list predicates to the ProjectAssociationMutation builder.

type ProjectAssociationOrder

type ProjectAssociationOrder struct {
	Direction OrderDirection                `json:"direction"`
	Field     *ProjectAssociationOrderField `json:"field"`
}

ProjectAssociationOrder defines the ordering of ProjectAssociation.

type ProjectAssociationOrderField

type ProjectAssociationOrderField struct {
	// contains filtered or unexported fields
}

ProjectAssociationOrderField defines the ordering field of ProjectAssociation.

func (ProjectAssociationOrderField) MarshalGQL

func (f ProjectAssociationOrderField) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (ProjectAssociationOrderField) String

String implement fmt.Stringer interface.

func (*ProjectAssociationOrderField) UnmarshalGQL

func (f *ProjectAssociationOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type ProjectAssociationPaginateOption

type ProjectAssociationPaginateOption func(*projectassociationPager) error

ProjectAssociationPaginateOption enables pagination customization.

func WithProjectAssociationFilter

func WithProjectAssociationFilter(filter func(*ProjectAssociationQuery) (*ProjectAssociationQuery, error)) ProjectAssociationPaginateOption

WithProjectAssociationFilter configures pagination filter.

func WithProjectAssociationOrder

func WithProjectAssociationOrder(order *ProjectAssociationOrder) ProjectAssociationPaginateOption

WithProjectAssociationOrder configures pagination ordering.

type ProjectAssociationQuery

type ProjectAssociationQuery struct {
	// contains filtered or unexported fields
}

ProjectAssociationQuery is the builder for querying ProjectAssociation entities.

func (*ProjectAssociationQuery) All

All executes the query and returns a list of ProjectAssociations.

func (*ProjectAssociationQuery) AllX

AllX is like All, but panics if an error occurs.

func (*ProjectAssociationQuery) Clone

Clone returns a duplicate of the ProjectAssociationQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*ProjectAssociationQuery) CollectFields

func (pa *ProjectAssociationQuery) CollectFields(ctx context.Context, satisfies ...string) (*ProjectAssociationQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*ProjectAssociationQuery) Count

func (paq *ProjectAssociationQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*ProjectAssociationQuery) CountX

func (paq *ProjectAssociationQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*ProjectAssociationQuery) Exist

func (paq *ProjectAssociationQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*ProjectAssociationQuery) ExistX

func (paq *ProjectAssociationQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*ProjectAssociationQuery) First

First returns the first ProjectAssociation entity from the query. Returns a *NotFoundError when no ProjectAssociation was found.

func (*ProjectAssociationQuery) FirstID

func (paq *ProjectAssociationQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first ProjectAssociation ID from the query. Returns a *NotFoundError when no ProjectAssociation ID was found.

func (*ProjectAssociationQuery) FirstIDX

func (paq *ProjectAssociationQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*ProjectAssociationQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*ProjectAssociationQuery) GroupBy

func (paq *ProjectAssociationQuery) GroupBy(field string, fields ...string) *ProjectAssociationGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Type projectassociation.Type `json:"type,omitempty"`
	Count int `json:"count,omitempty"`
}

client.ProjectAssociation.Query().
	GroupBy(projectassociation.FieldType).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*ProjectAssociationQuery) IDs

func (paq *ProjectAssociationQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of ProjectAssociation IDs.

func (*ProjectAssociationQuery) IDsX

func (paq *ProjectAssociationQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*ProjectAssociationQuery) Limit

Limit adds a limit step to the query.

func (*ProjectAssociationQuery) Offset

Offset adds an offset step to the query.

func (*ProjectAssociationQuery) Only

Only returns a single ProjectAssociation entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one ProjectAssociation entity is found. Returns a *NotFoundError when no ProjectAssociation entities are found.

func (*ProjectAssociationQuery) OnlyID

func (paq *ProjectAssociationQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only ProjectAssociation ID in the query. Returns a *NotSingularError when more than one ProjectAssociation ID is found. Returns a *NotFoundError when no entities are found.

func (*ProjectAssociationQuery) OnlyIDX

func (paq *ProjectAssociationQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*ProjectAssociationQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*ProjectAssociationQuery) Order

Order adds an order step to the query.

func (*ProjectAssociationQuery) Paginate

func (pa *ProjectAssociationQuery) Paginate(
	ctx context.Context, after *Cursor, first *int,
	before *Cursor, last *int, opts ...ProjectAssociationPaginateOption,
) (*ProjectAssociationConnection, error)

Paginate executes the query and returns a relay based cursor connection to ProjectAssociation.

func (*ProjectAssociationQuery) QueryChild

func (paq *ProjectAssociationQuery) QueryChild() *ProjectQuery

QueryChild chains the current query on the "child" edge.

func (*ProjectAssociationQuery) QueryParent

func (paq *ProjectAssociationQuery) QueryParent() *ProjectQuery

QueryParent chains the current query on the "parent" edge.

func (*ProjectAssociationQuery) Select

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Type projectassociation.Type `json:"type,omitempty"`
}

client.ProjectAssociation.Query().
	Select(projectassociation.FieldType).
	Scan(ctx, &v)

func (*ProjectAssociationQuery) Unique

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*ProjectAssociationQuery) Where

Where adds a new predicate for the ProjectAssociationQuery builder.

func (*ProjectAssociationQuery) WithChild

func (paq *ProjectAssociationQuery) WithChild(opts ...func(*ProjectQuery)) *ProjectAssociationQuery

WithChild tells the query-builder to eager-load the nodes that are connected to the "child" edge. The optional arguments are used to configure the query builder of the edge.

func (*ProjectAssociationQuery) WithParent

func (paq *ProjectAssociationQuery) WithParent(opts ...func(*ProjectQuery)) *ProjectAssociationQuery

WithParent tells the query-builder to eager-load the nodes that are connected to the "parent" edge. The optional arguments are used to configure the query builder of the edge.

type ProjectAssociationSelect

type ProjectAssociationSelect struct {
	*ProjectAssociationQuery
	// contains filtered or unexported fields
}

ProjectAssociationSelect is the builder for selecting fields of ProjectAssociation entities.

func (*ProjectAssociationSelect) Bool

func (s *ProjectAssociationSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationSelect) BoolX

func (s *ProjectAssociationSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ProjectAssociationSelect) Bools

func (s *ProjectAssociationSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationSelect) BoolsX

func (s *ProjectAssociationSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ProjectAssociationSelect) Float64

func (s *ProjectAssociationSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationSelect) Float64X

func (s *ProjectAssociationSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ProjectAssociationSelect) Float64s

func (s *ProjectAssociationSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationSelect) Float64sX

func (s *ProjectAssociationSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ProjectAssociationSelect) Int

func (s *ProjectAssociationSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationSelect) IntX

func (s *ProjectAssociationSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ProjectAssociationSelect) Ints

func (s *ProjectAssociationSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationSelect) IntsX

func (s *ProjectAssociationSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ProjectAssociationSelect) Scan

func (pas *ProjectAssociationSelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*ProjectAssociationSelect) ScanX

func (s *ProjectAssociationSelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*ProjectAssociationSelect) String

func (s *ProjectAssociationSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationSelect) StringX

func (s *ProjectAssociationSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ProjectAssociationSelect) Strings

func (s *ProjectAssociationSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ProjectAssociationSelect) StringsX

func (s *ProjectAssociationSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ProjectAssociationUpdate

type ProjectAssociationUpdate struct {
	// contains filtered or unexported fields
}

ProjectAssociationUpdate is the builder for updating ProjectAssociation entities.

func (*ProjectAssociationUpdate) ClearChild

ClearChild clears the "child" edge to the Project entity.

func (*ProjectAssociationUpdate) ClearParent

ClearParent clears the "parent" edge to the Project entity.

func (*ProjectAssociationUpdate) Exec

Exec executes the query.

func (*ProjectAssociationUpdate) ExecX

func (pau *ProjectAssociationUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectAssociationUpdate) Mutation

Mutation returns the ProjectAssociationMutation object of the builder.

func (*ProjectAssociationUpdate) Save

func (pau *ProjectAssociationUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*ProjectAssociationUpdate) SaveX

func (pau *ProjectAssociationUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*ProjectAssociationUpdate) SetChild

SetChild sets the "child" edge to the Project entity.

func (*ProjectAssociationUpdate) SetChildID

SetChildID sets the "child" edge to the Project entity by ID.

func (*ProjectAssociationUpdate) SetInput

SetInput applies the change-set in the UpdateProjectAssociationInput on the update builder.

func (*ProjectAssociationUpdate) SetParent

SetParent sets the "parent" edge to the Project entity.

func (*ProjectAssociationUpdate) SetParentID

SetParentID sets the "parent" edge to the Project entity by ID.

func (*ProjectAssociationUpdate) SetType

SetType sets the "type" field.

func (*ProjectAssociationUpdate) Where

Where appends a list predicates to the ProjectAssociationUpdate builder.

type ProjectAssociationUpdateOne

type ProjectAssociationUpdateOne struct {
	// contains filtered or unexported fields
}

ProjectAssociationUpdateOne is the builder for updating a single ProjectAssociation entity.

func (*ProjectAssociationUpdateOne) ClearChild

ClearChild clears the "child" edge to the Project entity.

func (*ProjectAssociationUpdateOne) ClearParent

ClearParent clears the "parent" edge to the Project entity.

func (*ProjectAssociationUpdateOne) Exec

Exec executes the query on the entity.

func (*ProjectAssociationUpdateOne) ExecX

func (pauo *ProjectAssociationUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectAssociationUpdateOne) Mutation

Mutation returns the ProjectAssociationMutation object of the builder.

func (*ProjectAssociationUpdateOne) Save

Save executes the query and returns the updated ProjectAssociation entity.

func (*ProjectAssociationUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*ProjectAssociationUpdateOne) Select

func (pauo *ProjectAssociationUpdateOne) Select(field string, fields ...string) *ProjectAssociationUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*ProjectAssociationUpdateOne) SetChild

SetChild sets the "child" edge to the Project entity.

func (*ProjectAssociationUpdateOne) SetChildID

SetChildID sets the "child" edge to the Project entity by ID.

func (*ProjectAssociationUpdateOne) SetInput

SetInput applies the change-set in the UpdateProjectAssociationInput on the update-one builder.

func (*ProjectAssociationUpdateOne) SetParent

SetParent sets the "parent" edge to the Project entity.

func (*ProjectAssociationUpdateOne) SetParentID

SetParentID sets the "parent" edge to the Project entity by ID.

func (*ProjectAssociationUpdateOne) SetType

SetType sets the "type" field.

type ProjectAssociationWhereInput

type ProjectAssociationWhereInput struct {
	Predicates []predicate.ProjectAssociation  `json:"-"`
	Not        *ProjectAssociationWhereInput   `json:"not,omitempty"`
	Or         []*ProjectAssociationWhereInput `json:"or,omitempty"`
	And        []*ProjectAssociationWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "type" field predicates.
	Type      *projectassociation.Type  `json:"type,omitempty"`
	TypeNEQ   *projectassociation.Type  `json:"typeNEQ,omitempty"`
	TypeIn    []projectassociation.Type `json:"typeIn,omitempty"`
	TypeNotIn []projectassociation.Type `json:"typeNotIn,omitempty"`

	// "parent" edge predicates.
	HasParent     *bool                `json:"hasParent,omitempty"`
	HasParentWith []*ProjectWhereInput `json:"hasParentWith,omitempty"`

	// "child" edge predicates.
	HasChild     *bool                `json:"hasChild,omitempty"`
	HasChildWith []*ProjectWhereInput `json:"hasChildWith,omitempty"`
}

ProjectAssociationWhereInput represents a where input for filtering ProjectAssociation queries.

func (*ProjectAssociationWhereInput) AddPredicates

func (i *ProjectAssociationWhereInput) AddPredicates(predicates ...predicate.ProjectAssociation)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*ProjectAssociationWhereInput) Filter

Filter applies the ProjectAssociationWhereInput filter on the ProjectAssociationQuery builder.

func (*ProjectAssociationWhereInput) P

P returns a predicate for filtering projectassociations. An error is returned if the input is empty or invalid.

type ProjectAssociations

type ProjectAssociations []*ProjectAssociation

ProjectAssociations is a parsable slice of ProjectAssociation.

type ProjectClient

type ProjectClient struct {
	// contains filtered or unexported fields
}

ProjectClient is a client for the Project schema.

func NewProjectClient

func NewProjectClient(c config) *ProjectClient

NewProjectClient returns a client for the Project from the given config.

func (*ProjectClient) Create

func (c *ProjectClient) Create() *ProjectCreate

Create returns a builder for creating a Project entity.

func (*ProjectClient) CreateBulk

func (c *ProjectClient) CreateBulk(builders ...*ProjectCreate) *ProjectCreateBulk

CreateBulk returns a builder for creating a bulk of Project entities.

func (*ProjectClient) Delete

func (c *ProjectClient) Delete() *ProjectDelete

Delete returns a delete builder for Project.

func (*ProjectClient) DeleteOne

func (c *ProjectClient) DeleteOne(pr *Project) *ProjectDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*ProjectClient) DeleteOneID

func (c *ProjectClient) DeleteOneID(id int) *ProjectDeleteOne

DeleteOne returns a builder for deleting the given entity by its id.

func (*ProjectClient) Get

func (c *ProjectClient) Get(ctx context.Context, id int) (*Project, error)

Get returns a Project entity by its id.

func (*ProjectClient) GetX

func (c *ProjectClient) GetX(ctx context.Context, id int) *Project

GetX is like Get, but panics if an error occurs.

func (*ProjectClient) Hooks

func (c *ProjectClient) Hooks() []Hook

Hooks returns the client hooks.

func (*ProjectClient) Query

func (c *ProjectClient) Query() *ProjectQuery

Query returns a query builder for Project.

func (*ProjectClient) QueryChildProjects

func (c *ProjectClient) QueryChildProjects(pr *Project) *ProjectAssociationQuery

QueryChildProjects queries the child_projects edge of a Project.

func (*ProjectClient) QueryContributors

func (c *ProjectClient) QueryContributors(pr *Project) *ProjectContributorQuery

QueryContributors queries the contributors edge of a Project.

func (*ProjectClient) QueryDiscordBots

func (c *ProjectClient) QueryDiscordBots(pr *Project) *DiscordBotQuery

QueryDiscordBots queries the discord_bots edge of a Project.

func (*ProjectClient) QueryParentProjects

func (c *ProjectClient) QueryParentProjects(pr *Project) *ProjectAssociationQuery

QueryParentProjects queries the parent_projects edge of a Project.

func (*ProjectClient) QueryRepositories

func (c *ProjectClient) QueryRepositories(pr *Project) *RepositoryQuery

QueryRepositories queries the repositories edge of a Project.

func (*ProjectClient) QuerySites

func (c *ProjectClient) QuerySites(pr *Project) *SiteQuery

QuerySites queries the sites edge of a Project.

func (*ProjectClient) QueryTechnologies

func (c *ProjectClient) QueryTechnologies(pr *Project) *ProjectTechnologyQuery

QueryTechnologies queries the technologies edge of a Project.

func (*ProjectClient) Update

func (c *ProjectClient) Update() *ProjectUpdate

Update returns an update builder for Project.

func (*ProjectClient) UpdateOne

func (c *ProjectClient) UpdateOne(pr *Project) *ProjectUpdateOne

UpdateOne returns an update builder for the given entity.

func (*ProjectClient) UpdateOneID

func (c *ProjectClient) UpdateOneID(id int) *ProjectUpdateOne

UpdateOneID returns an update builder for the given id.

func (*ProjectClient) Use

func (c *ProjectClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `project.Hooks(f(g(h())))`.

type ProjectConnection

type ProjectConnection struct {
	Edges      []*ProjectEdge `json:"edges"`
	PageInfo   PageInfo       `json:"pageInfo"`
	TotalCount int            `json:"totalCount"`
}

ProjectConnection is the connection containing edges to Project.

type ProjectContributor

type ProjectContributor struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Role holds the value of the "role" field.
	Role projectcontributor.Role `json:"role,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the ProjectContributorQuery when eager-loading is set.
	Edges ProjectContributorEdges `json:"edges"`
	// contains filtered or unexported fields
}

ProjectContributor is the model entity for the ProjectContributor schema.

func (*ProjectContributor) Node

func (pc *ProjectContributor) Node(ctx context.Context) (node *Node, err error)

func (*ProjectContributor) Project

func (pc *ProjectContributor) Project(ctx context.Context) (*Project, error)

func (*ProjectContributor) QueryProject

func (pc *ProjectContributor) QueryProject() *ProjectQuery

QueryProject queries the "project" edge of the ProjectContributor entity.

func (*ProjectContributor) QueryUser

func (pc *ProjectContributor) QueryUser() *UserQuery

QueryUser queries the "user" edge of the ProjectContributor entity.

func (*ProjectContributor) String

func (pc *ProjectContributor) String() string

String implements the fmt.Stringer.

func (*ProjectContributor) ToEdge

ToEdge converts ProjectContributor into ProjectContributorEdge.

func (*ProjectContributor) Unwrap

func (pc *ProjectContributor) Unwrap() *ProjectContributor

Unwrap unwraps the ProjectContributor entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*ProjectContributor) Update

Update returns a builder for updating this ProjectContributor. Note that you need to call ProjectContributor.Unwrap() before calling this method if this ProjectContributor was returned from a transaction, and the transaction was committed or rolled back.

func (*ProjectContributor) User

func (pc *ProjectContributor) User(ctx context.Context) (*User, error)

type ProjectContributorClient

type ProjectContributorClient struct {
	// contains filtered or unexported fields
}

ProjectContributorClient is a client for the ProjectContributor schema.

func NewProjectContributorClient

func NewProjectContributorClient(c config) *ProjectContributorClient

NewProjectContributorClient returns a client for the ProjectContributor from the given config.

func (*ProjectContributorClient) Create

Create returns a builder for creating a ProjectContributor entity.

func (*ProjectContributorClient) CreateBulk

CreateBulk returns a builder for creating a bulk of ProjectContributor entities.

func (*ProjectContributorClient) Delete

Delete returns a delete builder for ProjectContributor.

func (*ProjectContributorClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*ProjectContributorClient) DeleteOneID

DeleteOne returns a builder for deleting the given entity by its id.

func (*ProjectContributorClient) Get

Get returns a ProjectContributor entity by its id.

func (*ProjectContributorClient) GetX

GetX is like Get, but panics if an error occurs.

func (*ProjectContributorClient) Hooks

func (c *ProjectContributorClient) Hooks() []Hook

Hooks returns the client hooks.

func (*ProjectContributorClient) Query

Query returns a query builder for ProjectContributor.

func (*ProjectContributorClient) QueryProject

QueryProject queries the project edge of a ProjectContributor.

func (*ProjectContributorClient) QueryUser

QueryUser queries the user edge of a ProjectContributor.

func (*ProjectContributorClient) Update

Update returns an update builder for ProjectContributor.

func (*ProjectContributorClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*ProjectContributorClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*ProjectContributorClient) Use

func (c *ProjectContributorClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `projectcontributor.Hooks(f(g(h())))`.

type ProjectContributorConnection

type ProjectContributorConnection struct {
	Edges      []*ProjectContributorEdge `json:"edges"`
	PageInfo   PageInfo                  `json:"pageInfo"`
	TotalCount int                       `json:"totalCount"`
}

ProjectContributorConnection is the connection containing edges to ProjectContributor.

type ProjectContributorCreate

type ProjectContributorCreate struct {
	// contains filtered or unexported fields
}

ProjectContributorCreate is the builder for creating a ProjectContributor entity.

func (*ProjectContributorCreate) Exec

Exec executes the query.

func (*ProjectContributorCreate) ExecX

func (pcc *ProjectContributorCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectContributorCreate) Mutation

Mutation returns the ProjectContributorMutation object of the builder.

func (*ProjectContributorCreate) Save

Save creates the ProjectContributor in the database.

func (*ProjectContributorCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*ProjectContributorCreate) SetInput

SetInput applies the change-set in the CreateProjectContributorInput on the create builder.

func (*ProjectContributorCreate) SetProject

SetProject sets the "project" edge to the Project entity.

func (*ProjectContributorCreate) SetProjectID

func (pcc *ProjectContributorCreate) SetProjectID(id int) *ProjectContributorCreate

SetProjectID sets the "project" edge to the Project entity by ID.

func (*ProjectContributorCreate) SetRole

SetRole sets the "role" field.

func (*ProjectContributorCreate) SetUser

SetUser sets the "user" edge to the User entity.

func (*ProjectContributorCreate) SetUserID

SetUserID sets the "user" edge to the User entity by ID.

type ProjectContributorCreateBulk

type ProjectContributorCreateBulk struct {
	// contains filtered or unexported fields
}

ProjectContributorCreateBulk is the builder for creating many ProjectContributor entities in bulk.

func (*ProjectContributorCreateBulk) Exec

Exec executes the query.

func (*ProjectContributorCreateBulk) ExecX

func (pccb *ProjectContributorCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectContributorCreateBulk) Save

Save creates the ProjectContributor entities in the database.

func (*ProjectContributorCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type ProjectContributorDelete

type ProjectContributorDelete struct {
	// contains filtered or unexported fields
}

ProjectContributorDelete is the builder for deleting a ProjectContributor entity.

func (*ProjectContributorDelete) Exec

func (pcd *ProjectContributorDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*ProjectContributorDelete) ExecX

func (pcd *ProjectContributorDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*ProjectContributorDelete) Where

Where appends a list predicates to the ProjectContributorDelete builder.

type ProjectContributorDeleteOne

type ProjectContributorDeleteOne struct {
	// contains filtered or unexported fields
}

ProjectContributorDeleteOne is the builder for deleting a single ProjectContributor entity.

func (*ProjectContributorDeleteOne) Exec

Exec executes the deletion query.

func (*ProjectContributorDeleteOne) ExecX

func (pcdo *ProjectContributorDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

type ProjectContributorEdge

type ProjectContributorEdge struct {
	Node   *ProjectContributor `json:"node"`
	Cursor Cursor              `json:"cursor"`
}

ProjectContributorEdge is the edge representation of ProjectContributor.

type ProjectContributorEdges

type ProjectContributorEdges struct {
	// Project holds the value of the project edge.
	Project *Project `json:"project,omitempty"`
	// User holds the value of the user edge.
	User *User `json:"user,omitempty"`
	// contains filtered or unexported fields
}

ProjectContributorEdges holds the relations/edges for other nodes in the graph.

func (ProjectContributorEdges) ProjectOrErr

func (e ProjectContributorEdges) ProjectOrErr() (*Project, error)

ProjectOrErr returns the Project value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (ProjectContributorEdges) UserOrErr

func (e ProjectContributorEdges) UserOrErr() (*User, error)

UserOrErr returns the User value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type ProjectContributorGroupBy

type ProjectContributorGroupBy struct {
	// contains filtered or unexported fields
}

ProjectContributorGroupBy is the group-by builder for ProjectContributor entities.

func (*ProjectContributorGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*ProjectContributorGroupBy) Bool

func (s *ProjectContributorGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ProjectContributorGroupBy) BoolX

func (s *ProjectContributorGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ProjectContributorGroupBy) Bools

func (s *ProjectContributorGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ProjectContributorGroupBy) BoolsX

func (s *ProjectContributorGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ProjectContributorGroupBy) Float64

func (s *ProjectContributorGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ProjectContributorGroupBy) Float64X

func (s *ProjectContributorGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ProjectContributorGroupBy) Float64s

func (s *ProjectContributorGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ProjectContributorGroupBy) Float64sX

func (s *ProjectContributorGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ProjectContributorGroupBy) Int

func (s *ProjectContributorGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ProjectContributorGroupBy) IntX

func (s *ProjectContributorGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ProjectContributorGroupBy) Ints

func (s *ProjectContributorGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ProjectContributorGroupBy) IntsX

func (s *ProjectContributorGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ProjectContributorGroupBy) Scan

func (pcgb *ProjectContributorGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*ProjectContributorGroupBy) ScanX

func (s *ProjectContributorGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*ProjectContributorGroupBy) String

func (s *ProjectContributorGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ProjectContributorGroupBy) StringX

func (s *ProjectContributorGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ProjectContributorGroupBy) Strings

func (s *ProjectContributorGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ProjectContributorGroupBy) StringsX

func (s *ProjectContributorGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ProjectContributorMutation

type ProjectContributorMutation struct {
	// contains filtered or unexported fields
}

ProjectContributorMutation represents an operation that mutates the ProjectContributor nodes in the graph.

func (*ProjectContributorMutation) AddField

func (m *ProjectContributorMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ProjectContributorMutation) AddedEdges

func (m *ProjectContributorMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*ProjectContributorMutation) AddedField

func (m *ProjectContributorMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ProjectContributorMutation) AddedFields

func (m *ProjectContributorMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*ProjectContributorMutation) AddedIDs

func (m *ProjectContributorMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*ProjectContributorMutation) ClearEdge

func (m *ProjectContributorMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*ProjectContributorMutation) ClearField

func (m *ProjectContributorMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*ProjectContributorMutation) ClearProject

func (m *ProjectContributorMutation) ClearProject()

ClearProject clears the "project" edge to the Project entity.

func (*ProjectContributorMutation) ClearUser

func (m *ProjectContributorMutation) ClearUser()

ClearUser clears the "user" edge to the User entity.

func (*ProjectContributorMutation) ClearedEdges

func (m *ProjectContributorMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*ProjectContributorMutation) ClearedFields

func (m *ProjectContributorMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (ProjectContributorMutation) Client

func (m ProjectContributorMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*ProjectContributorMutation) EdgeCleared

func (m *ProjectContributorMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*ProjectContributorMutation) Field

func (m *ProjectContributorMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ProjectContributorMutation) FieldCleared

func (m *ProjectContributorMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*ProjectContributorMutation) Fields

func (m *ProjectContributorMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*ProjectContributorMutation) ID

func (m *ProjectContributorMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*ProjectContributorMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*ProjectContributorMutation) OldField

func (m *ProjectContributorMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*ProjectContributorMutation) OldRole

OldRole returns the old "role" field's value of the ProjectContributor entity. If the ProjectContributor object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProjectContributorMutation) Op

Op returns the operation name.

func (*ProjectContributorMutation) ProjectCleared

func (m *ProjectContributorMutation) ProjectCleared() bool

ProjectCleared reports if the "project" edge to the Project entity was cleared.

func (*ProjectContributorMutation) ProjectID

func (m *ProjectContributorMutation) ProjectID() (id int, exists bool)

ProjectID returns the "project" edge ID in the mutation.

func (*ProjectContributorMutation) ProjectIDs

func (m *ProjectContributorMutation) ProjectIDs() (ids []int)

ProjectIDs returns the "project" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ProjectID instead. It exists only for internal usage by the builders.

func (*ProjectContributorMutation) RemovedEdges

func (m *ProjectContributorMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*ProjectContributorMutation) RemovedIDs

func (m *ProjectContributorMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*ProjectContributorMutation) ResetEdge

func (m *ProjectContributorMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*ProjectContributorMutation) ResetField

func (m *ProjectContributorMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*ProjectContributorMutation) ResetProject

func (m *ProjectContributorMutation) ResetProject()

ResetProject resets all changes to the "project" edge.

func (*ProjectContributorMutation) ResetRole

func (m *ProjectContributorMutation) ResetRole()

ResetRole resets all changes to the "role" field.

func (*ProjectContributorMutation) ResetUser

func (m *ProjectContributorMutation) ResetUser()

ResetUser resets all changes to the "user" edge.

func (*ProjectContributorMutation) Role

Role returns the value of the "role" field in the mutation.

func (*ProjectContributorMutation) SetField

func (m *ProjectContributorMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ProjectContributorMutation) SetProjectID

func (m *ProjectContributorMutation) SetProjectID(id int)

SetProjectID sets the "project" edge to the Project entity by id.

func (*ProjectContributorMutation) SetRole

SetRole sets the "role" field.

func (*ProjectContributorMutation) SetUserID

func (m *ProjectContributorMutation) SetUserID(id int)

SetUserID sets the "user" edge to the User entity by id.

func (ProjectContributorMutation) Tx

func (m ProjectContributorMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*ProjectContributorMutation) Type

Type returns the node type of this mutation (ProjectContributor).

func (*ProjectContributorMutation) UserCleared

func (m *ProjectContributorMutation) UserCleared() bool

UserCleared reports if the "user" edge to the User entity was cleared.

func (*ProjectContributorMutation) UserID

func (m *ProjectContributorMutation) UserID() (id int, exists bool)

UserID returns the "user" edge ID in the mutation.

func (*ProjectContributorMutation) UserIDs

func (m *ProjectContributorMutation) UserIDs() (ids []int)

UserIDs returns the "user" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use UserID instead. It exists only for internal usage by the builders.

func (*ProjectContributorMutation) Where

Where appends a list predicates to the ProjectContributorMutation builder.

type ProjectContributorOrder

type ProjectContributorOrder struct {
	Direction OrderDirection                `json:"direction"`
	Field     *ProjectContributorOrderField `json:"field"`
}

ProjectContributorOrder defines the ordering of ProjectContributor.

type ProjectContributorOrderField

type ProjectContributorOrderField struct {
	// contains filtered or unexported fields
}

ProjectContributorOrderField defines the ordering field of ProjectContributor.

func (ProjectContributorOrderField) MarshalGQL

func (f ProjectContributorOrderField) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (ProjectContributorOrderField) String

String implement fmt.Stringer interface.

func (*ProjectContributorOrderField) UnmarshalGQL

func (f *ProjectContributorOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type ProjectContributorPaginateOption

type ProjectContributorPaginateOption func(*projectcontributorPager) error

ProjectContributorPaginateOption enables pagination customization.

func WithProjectContributorFilter

func WithProjectContributorFilter(filter func(*ProjectContributorQuery) (*ProjectContributorQuery, error)) ProjectContributorPaginateOption

WithProjectContributorFilter configures pagination filter.

func WithProjectContributorOrder

func WithProjectContributorOrder(order *ProjectContributorOrder) ProjectContributorPaginateOption

WithProjectContributorOrder configures pagination ordering.

type ProjectContributorQuery

type ProjectContributorQuery struct {
	// contains filtered or unexported fields
}

ProjectContributorQuery is the builder for querying ProjectContributor entities.

func (*ProjectContributorQuery) All

All executes the query and returns a list of ProjectContributors.

func (*ProjectContributorQuery) AllX

AllX is like All, but panics if an error occurs.

func (*ProjectContributorQuery) Clone

Clone returns a duplicate of the ProjectContributorQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*ProjectContributorQuery) CollectFields

func (pc *ProjectContributorQuery) CollectFields(ctx context.Context, satisfies ...string) (*ProjectContributorQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*ProjectContributorQuery) Count

func (pcq *ProjectContributorQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*ProjectContributorQuery) CountX

func (pcq *ProjectContributorQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*ProjectContributorQuery) Exist

func (pcq *ProjectContributorQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*ProjectContributorQuery) ExistX

func (pcq *ProjectContributorQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*ProjectContributorQuery) First

First returns the first ProjectContributor entity from the query. Returns a *NotFoundError when no ProjectContributor was found.

func (*ProjectContributorQuery) FirstID

func (pcq *ProjectContributorQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first ProjectContributor ID from the query. Returns a *NotFoundError when no ProjectContributor ID was found.

func (*ProjectContributorQuery) FirstIDX

func (pcq *ProjectContributorQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*ProjectContributorQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*ProjectContributorQuery) GroupBy

func (pcq *ProjectContributorQuery) GroupBy(field string, fields ...string) *ProjectContributorGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Role projectcontributor.Role `json:"role,omitempty"`
	Count int `json:"count,omitempty"`
}

client.ProjectContributor.Query().
	GroupBy(projectcontributor.FieldRole).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*ProjectContributorQuery) IDs

func (pcq *ProjectContributorQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of ProjectContributor IDs.

func (*ProjectContributorQuery) IDsX

func (pcq *ProjectContributorQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*ProjectContributorQuery) Limit

Limit adds a limit step to the query.

func (*ProjectContributorQuery) Offset

Offset adds an offset step to the query.

func (*ProjectContributorQuery) Only

Only returns a single ProjectContributor entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one ProjectContributor entity is found. Returns a *NotFoundError when no ProjectContributor entities are found.

func (*ProjectContributorQuery) OnlyID

func (pcq *ProjectContributorQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only ProjectContributor ID in the query. Returns a *NotSingularError when more than one ProjectContributor ID is found. Returns a *NotFoundError when no entities are found.

func (*ProjectContributorQuery) OnlyIDX

func (pcq *ProjectContributorQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*ProjectContributorQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*ProjectContributorQuery) Order

Order adds an order step to the query.

func (*ProjectContributorQuery) Paginate

func (pc *ProjectContributorQuery) Paginate(
	ctx context.Context, after *Cursor, first *int,
	before *Cursor, last *int, opts ...ProjectContributorPaginateOption,
) (*ProjectContributorConnection, error)

Paginate executes the query and returns a relay based cursor connection to ProjectContributor.

func (*ProjectContributorQuery) QueryProject

func (pcq *ProjectContributorQuery) QueryProject() *ProjectQuery

QueryProject chains the current query on the "project" edge.

func (*ProjectContributorQuery) QueryUser

func (pcq *ProjectContributorQuery) QueryUser() *UserQuery

QueryUser chains the current query on the "user" edge.

func (*ProjectContributorQuery) Select

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Role projectcontributor.Role `json:"role,omitempty"`
}

client.ProjectContributor.Query().
	Select(projectcontributor.FieldRole).
	Scan(ctx, &v)

func (*ProjectContributorQuery) Unique

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*ProjectContributorQuery) Where

Where adds a new predicate for the ProjectContributorQuery builder.

func (*ProjectContributorQuery) WithProject

func (pcq *ProjectContributorQuery) WithProject(opts ...func(*ProjectQuery)) *ProjectContributorQuery

WithProject tells the query-builder to eager-load the nodes that are connected to the "project" edge. The optional arguments are used to configure the query builder of the edge.

func (*ProjectContributorQuery) WithUser

func (pcq *ProjectContributorQuery) WithUser(opts ...func(*UserQuery)) *ProjectContributorQuery

WithUser tells the query-builder to eager-load the nodes that are connected to the "user" edge. The optional arguments are used to configure the query builder of the edge.

type ProjectContributorSelect

type ProjectContributorSelect struct {
	*ProjectContributorQuery
	// contains filtered or unexported fields
}

ProjectContributorSelect is the builder for selecting fields of ProjectContributor entities.

func (*ProjectContributorSelect) Bool

func (s *ProjectContributorSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ProjectContributorSelect) BoolX

func (s *ProjectContributorSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ProjectContributorSelect) Bools

func (s *ProjectContributorSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ProjectContributorSelect) BoolsX

func (s *ProjectContributorSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ProjectContributorSelect) Float64

func (s *ProjectContributorSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ProjectContributorSelect) Float64X

func (s *ProjectContributorSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ProjectContributorSelect) Float64s

func (s *ProjectContributorSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ProjectContributorSelect) Float64sX

func (s *ProjectContributorSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ProjectContributorSelect) Int

func (s *ProjectContributorSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ProjectContributorSelect) IntX

func (s *ProjectContributorSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ProjectContributorSelect) Ints

func (s *ProjectContributorSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ProjectContributorSelect) IntsX

func (s *ProjectContributorSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ProjectContributorSelect) Scan

func (pcs *ProjectContributorSelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*ProjectContributorSelect) ScanX

func (s *ProjectContributorSelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*ProjectContributorSelect) String

func (s *ProjectContributorSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ProjectContributorSelect) StringX

func (s *ProjectContributorSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ProjectContributorSelect) Strings

func (s *ProjectContributorSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ProjectContributorSelect) StringsX

func (s *ProjectContributorSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ProjectContributorUpdate

type ProjectContributorUpdate struct {
	// contains filtered or unexported fields
}

ProjectContributorUpdate is the builder for updating ProjectContributor entities.

func (*ProjectContributorUpdate) ClearProject

ClearProject clears the "project" edge to the Project entity.

func (*ProjectContributorUpdate) ClearUser

ClearUser clears the "user" edge to the User entity.

func (*ProjectContributorUpdate) Exec

Exec executes the query.

func (*ProjectContributorUpdate) ExecX

func (pcu *ProjectContributorUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectContributorUpdate) Mutation

Mutation returns the ProjectContributorMutation object of the builder.

func (*ProjectContributorUpdate) Save

func (pcu *ProjectContributorUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*ProjectContributorUpdate) SaveX

func (pcu *ProjectContributorUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*ProjectContributorUpdate) SetInput

SetInput applies the change-set in the UpdateProjectContributorInput on the update builder.

func (*ProjectContributorUpdate) SetProject

SetProject sets the "project" edge to the Project entity.

func (*ProjectContributorUpdate) SetProjectID

func (pcu *ProjectContributorUpdate) SetProjectID(id int) *ProjectContributorUpdate

SetProjectID sets the "project" edge to the Project entity by ID.

func (*ProjectContributorUpdate) SetRole

SetRole sets the "role" field.

func (*ProjectContributorUpdate) SetUser

SetUser sets the "user" edge to the User entity.

func (*ProjectContributorUpdate) SetUserID

SetUserID sets the "user" edge to the User entity by ID.

func (*ProjectContributorUpdate) Where

Where appends a list predicates to the ProjectContributorUpdate builder.

type ProjectContributorUpdateOne

type ProjectContributorUpdateOne struct {
	// contains filtered or unexported fields
}

ProjectContributorUpdateOne is the builder for updating a single ProjectContributor entity.

func (*ProjectContributorUpdateOne) ClearProject

ClearProject clears the "project" edge to the Project entity.

func (*ProjectContributorUpdateOne) ClearUser

ClearUser clears the "user" edge to the User entity.

func (*ProjectContributorUpdateOne) Exec

Exec executes the query on the entity.

func (*ProjectContributorUpdateOne) ExecX

func (pcuo *ProjectContributorUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectContributorUpdateOne) Mutation

Mutation returns the ProjectContributorMutation object of the builder.

func (*ProjectContributorUpdateOne) Save

Save executes the query and returns the updated ProjectContributor entity.

func (*ProjectContributorUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*ProjectContributorUpdateOne) Select

func (pcuo *ProjectContributorUpdateOne) Select(field string, fields ...string) *ProjectContributorUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*ProjectContributorUpdateOne) SetInput

SetInput applies the change-set in the UpdateProjectContributorInput on the update-one builder.

func (*ProjectContributorUpdateOne) SetProject

SetProject sets the "project" edge to the Project entity.

func (*ProjectContributorUpdateOne) SetProjectID

SetProjectID sets the "project" edge to the Project entity by ID.

func (*ProjectContributorUpdateOne) SetRole

SetRole sets the "role" field.

func (*ProjectContributorUpdateOne) SetUser

SetUser sets the "user" edge to the User entity.

func (*ProjectContributorUpdateOne) SetUserID

SetUserID sets the "user" edge to the User entity by ID.

type ProjectContributorWhereInput

type ProjectContributorWhereInput struct {
	Predicates []predicate.ProjectContributor  `json:"-"`
	Not        *ProjectContributorWhereInput   `json:"not,omitempty"`
	Or         []*ProjectContributorWhereInput `json:"or,omitempty"`
	And        []*ProjectContributorWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "role" field predicates.
	Role      *projectcontributor.Role  `json:"role,omitempty"`
	RoleNEQ   *projectcontributor.Role  `json:"roleNEQ,omitempty"`
	RoleIn    []projectcontributor.Role `json:"roleIn,omitempty"`
	RoleNotIn []projectcontributor.Role `json:"roleNotIn,omitempty"`

	// "project" edge predicates.
	HasProject     *bool                `json:"hasProject,omitempty"`
	HasProjectWith []*ProjectWhereInput `json:"hasProjectWith,omitempty"`

	// "user" edge predicates.
	HasUser     *bool             `json:"hasUser,omitempty"`
	HasUserWith []*UserWhereInput `json:"hasUserWith,omitempty"`
}

ProjectContributorWhereInput represents a where input for filtering ProjectContributor queries.

func (*ProjectContributorWhereInput) AddPredicates

func (i *ProjectContributorWhereInput) AddPredicates(predicates ...predicate.ProjectContributor)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*ProjectContributorWhereInput) Filter

Filter applies the ProjectContributorWhereInput filter on the ProjectContributorQuery builder.

func (*ProjectContributorWhereInput) P

P returns a predicate for filtering projectcontributors. An error is returned if the input is empty or invalid.

type ProjectContributors

type ProjectContributors []*ProjectContributor

ProjectContributors is a parsable slice of ProjectContributor.

type ProjectCreate

type ProjectCreate struct {
	// contains filtered or unexported fields
}

ProjectCreate is the builder for creating a Project entity.

func (*ProjectCreate) AddChildProjectIDs

func (pc *ProjectCreate) AddChildProjectIDs(ids ...int) *ProjectCreate

AddChildProjectIDs adds the "child_projects" edge to the ProjectAssociation entity by IDs.

func (*ProjectCreate) AddChildProjects

func (pc *ProjectCreate) AddChildProjects(p ...*ProjectAssociation) *ProjectCreate

AddChildProjects adds the "child_projects" edges to the ProjectAssociation entity.

func (*ProjectCreate) AddContributorIDs

func (pc *ProjectCreate) AddContributorIDs(ids ...int) *ProjectCreate

AddContributorIDs adds the "contributors" edge to the ProjectContributor entity by IDs.

func (*ProjectCreate) AddContributors

func (pc *ProjectCreate) AddContributors(p ...*ProjectContributor) *ProjectCreate

AddContributors adds the "contributors" edges to the ProjectContributor entity.

func (*ProjectCreate) AddDiscordBotIDs

func (pc *ProjectCreate) AddDiscordBotIDs(ids ...int) *ProjectCreate

AddDiscordBotIDs adds the "discord_bots" edge to the DiscordBot entity by IDs.

func (*ProjectCreate) AddDiscordBots

func (pc *ProjectCreate) AddDiscordBots(d ...*DiscordBot) *ProjectCreate

AddDiscordBots adds the "discord_bots" edges to the DiscordBot entity.

func (*ProjectCreate) AddParentProjectIDs

func (pc *ProjectCreate) AddParentProjectIDs(ids ...int) *ProjectCreate

AddParentProjectIDs adds the "parent_projects" edge to the ProjectAssociation entity by IDs.

func (*ProjectCreate) AddParentProjects

func (pc *ProjectCreate) AddParentProjects(p ...*ProjectAssociation) *ProjectCreate

AddParentProjects adds the "parent_projects" edges to the ProjectAssociation entity.

func (*ProjectCreate) AddRepositories

func (pc *ProjectCreate) AddRepositories(r ...*Repository) *ProjectCreate

AddRepositories adds the "repositories" edges to the Repository entity.

func (*ProjectCreate) AddRepositoryIDs

func (pc *ProjectCreate) AddRepositoryIDs(ids ...int) *ProjectCreate

AddRepositoryIDs adds the "repositories" edge to the Repository entity by IDs.

func (*ProjectCreate) AddSiteIDs

func (pc *ProjectCreate) AddSiteIDs(ids ...int) *ProjectCreate

AddSiteIDs adds the "sites" edge to the Site entity by IDs.

func (*ProjectCreate) AddSites

func (pc *ProjectCreate) AddSites(s ...*Site) *ProjectCreate

AddSites adds the "sites" edges to the Site entity.

func (*ProjectCreate) AddTechnologies

func (pc *ProjectCreate) AddTechnologies(p ...*ProjectTechnology) *ProjectCreate

AddTechnologies adds the "technologies" edges to the ProjectTechnology entity.

func (*ProjectCreate) AddTechnologyIDs

func (pc *ProjectCreate) AddTechnologyIDs(ids ...int) *ProjectCreate

AddTechnologyIDs adds the "technologies" edge to the ProjectTechnology entity by IDs.

func (*ProjectCreate) Exec

func (pc *ProjectCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*ProjectCreate) ExecX

func (pc *ProjectCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectCreate) Mutation

func (pc *ProjectCreate) Mutation() *ProjectMutation

Mutation returns the ProjectMutation object of the builder.

func (*ProjectCreate) Save

func (pc *ProjectCreate) Save(ctx context.Context) (*Project, error)

Save creates the Project in the database.

func (*ProjectCreate) SaveX

func (pc *ProjectCreate) SaveX(ctx context.Context) *Project

SaveX calls Save and panics if Save returns an error.

func (*ProjectCreate) SetDescription

func (pc *ProjectCreate) SetDescription(s string) *ProjectCreate

SetDescription sets the "description" field.

func (*ProjectCreate) SetEndDate

func (pc *ProjectCreate) SetEndDate(t time.Time) *ProjectCreate

SetEndDate sets the "end_date" field.

func (*ProjectCreate) SetInput

SetInput applies the change-set in the CreateProjectInput on the create builder.

func (*ProjectCreate) SetName

func (pc *ProjectCreate) SetName(s string) *ProjectCreate

SetName sets the "name" field.

func (*ProjectCreate) SetNillableDescription

func (pc *ProjectCreate) SetNillableDescription(s *string) *ProjectCreate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*ProjectCreate) SetNillableEndDate

func (pc *ProjectCreate) SetNillableEndDate(t *time.Time) *ProjectCreate

SetNillableEndDate sets the "end_date" field if the given value is not nil.

func (*ProjectCreate) SetStartDate

func (pc *ProjectCreate) SetStartDate(t time.Time) *ProjectCreate

SetStartDate sets the "start_date" field.

type ProjectCreateBulk

type ProjectCreateBulk struct {
	// contains filtered or unexported fields
}

ProjectCreateBulk is the builder for creating many Project entities in bulk.

func (*ProjectCreateBulk) Exec

func (pcb *ProjectCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*ProjectCreateBulk) ExecX

func (pcb *ProjectCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectCreateBulk) Save

func (pcb *ProjectCreateBulk) Save(ctx context.Context) ([]*Project, error)

Save creates the Project entities in the database.

func (*ProjectCreateBulk) SaveX

func (pcb *ProjectCreateBulk) SaveX(ctx context.Context) []*Project

SaveX is like Save, but panics if an error occurs.

type ProjectDelete

type ProjectDelete struct {
	// contains filtered or unexported fields
}

ProjectDelete is the builder for deleting a Project entity.

func (*ProjectDelete) Exec

func (pd *ProjectDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*ProjectDelete) ExecX

func (pd *ProjectDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*ProjectDelete) Where

func (pd *ProjectDelete) Where(ps ...predicate.Project) *ProjectDelete

Where appends a list predicates to the ProjectDelete builder.

type ProjectDeleteOne

type ProjectDeleteOne struct {
	// contains filtered or unexported fields
}

ProjectDeleteOne is the builder for deleting a single Project entity.

func (*ProjectDeleteOne) Exec

func (pdo *ProjectDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*ProjectDeleteOne) ExecX

func (pdo *ProjectDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

type ProjectEdge

type ProjectEdge struct {
	Node   *Project `json:"node"`
	Cursor Cursor   `json:"cursor"`
}

ProjectEdge is the edge representation of Project.

type ProjectEdges

type ProjectEdges struct {
	// Contributors holds the value of the contributors edge.
	Contributors []*ProjectContributor `json:"contributors,omitempty"`
	// ParentProjects holds the value of the parent_projects edge.
	ParentProjects []*ProjectAssociation `json:"parent_projects,omitempty"`
	// ChildProjects holds the value of the child_projects edge.
	ChildProjects []*ProjectAssociation `json:"child_projects,omitempty"`
	// Repositories holds the value of the repositories edge.
	Repositories []*Repository `json:"repositories,omitempty"`
	// DiscordBots holds the value of the discord_bots edge.
	DiscordBots []*DiscordBot `json:"discord_bots,omitempty"`
	// Sites holds the value of the sites edge.
	Sites []*Site `json:"sites,omitempty"`
	// Technologies holds the value of the technologies edge.
	Technologies []*ProjectTechnology `json:"technologies,omitempty"`
	// contains filtered or unexported fields
}

ProjectEdges holds the relations/edges for other nodes in the graph.

func (ProjectEdges) ChildProjectsOrErr

func (e ProjectEdges) ChildProjectsOrErr() ([]*ProjectAssociation, error)

ChildProjectsOrErr returns the ChildProjects value or an error if the edge was not loaded in eager-loading.

func (ProjectEdges) ContributorsOrErr

func (e ProjectEdges) ContributorsOrErr() ([]*ProjectContributor, error)

ContributorsOrErr returns the Contributors value or an error if the edge was not loaded in eager-loading.

func (ProjectEdges) DiscordBotsOrErr

func (e ProjectEdges) DiscordBotsOrErr() ([]*DiscordBot, error)

DiscordBotsOrErr returns the DiscordBots value or an error if the edge was not loaded in eager-loading.

func (ProjectEdges) ParentProjectsOrErr

func (e ProjectEdges) ParentProjectsOrErr() ([]*ProjectAssociation, error)

ParentProjectsOrErr returns the ParentProjects value or an error if the edge was not loaded in eager-loading.

func (ProjectEdges) RepositoriesOrErr

func (e ProjectEdges) RepositoriesOrErr() ([]*Repository, error)

RepositoriesOrErr returns the Repositories value or an error if the edge was not loaded in eager-loading.

func (ProjectEdges) SitesOrErr

func (e ProjectEdges) SitesOrErr() ([]*Site, error)

SitesOrErr returns the Sites value or an error if the edge was not loaded in eager-loading.

func (ProjectEdges) TechnologiesOrErr

func (e ProjectEdges) TechnologiesOrErr() ([]*ProjectTechnology, error)

TechnologiesOrErr returns the Technologies value or an error if the edge was not loaded in eager-loading.

type ProjectGroupBy

type ProjectGroupBy struct {
	// contains filtered or unexported fields
}

ProjectGroupBy is the group-by builder for Project entities.

func (*ProjectGroupBy) Aggregate

func (pgb *ProjectGroupBy) Aggregate(fns ...AggregateFunc) *ProjectGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*ProjectGroupBy) Bool

func (s *ProjectGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ProjectGroupBy) BoolX

func (s *ProjectGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ProjectGroupBy) Bools

func (s *ProjectGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ProjectGroupBy) BoolsX

func (s *ProjectGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ProjectGroupBy) Float64

func (s *ProjectGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ProjectGroupBy) Float64X

func (s *ProjectGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ProjectGroupBy) Float64s

func (s *ProjectGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ProjectGroupBy) Float64sX

func (s *ProjectGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ProjectGroupBy) Int

func (s *ProjectGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ProjectGroupBy) IntX

func (s *ProjectGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ProjectGroupBy) Ints

func (s *ProjectGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ProjectGroupBy) IntsX

func (s *ProjectGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ProjectGroupBy) Scan

func (pgb *ProjectGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*ProjectGroupBy) ScanX

func (s *ProjectGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*ProjectGroupBy) String

func (s *ProjectGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ProjectGroupBy) StringX

func (s *ProjectGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ProjectGroupBy) Strings

func (s *ProjectGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ProjectGroupBy) StringsX

func (s *ProjectGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ProjectMutation

type ProjectMutation struct {
	// contains filtered or unexported fields
}

ProjectMutation represents an operation that mutates the Project nodes in the graph.

func (*ProjectMutation) AddChildProjectIDs

func (m *ProjectMutation) AddChildProjectIDs(ids ...int)

AddChildProjectIDs adds the "child_projects" edge to the ProjectAssociation entity by ids.

func (*ProjectMutation) AddContributorIDs

func (m *ProjectMutation) AddContributorIDs(ids ...int)

AddContributorIDs adds the "contributors" edge to the ProjectContributor entity by ids.

func (*ProjectMutation) AddDiscordBotIDs

func (m *ProjectMutation) AddDiscordBotIDs(ids ...int)

AddDiscordBotIDs adds the "discord_bots" edge to the DiscordBot entity by ids.

func (*ProjectMutation) AddField

func (m *ProjectMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ProjectMutation) AddParentProjectIDs

func (m *ProjectMutation) AddParentProjectIDs(ids ...int)

AddParentProjectIDs adds the "parent_projects" edge to the ProjectAssociation entity by ids.

func (*ProjectMutation) AddRepositoryIDs

func (m *ProjectMutation) AddRepositoryIDs(ids ...int)

AddRepositoryIDs adds the "repositories" edge to the Repository entity by ids.

func (*ProjectMutation) AddSiteIDs

func (m *ProjectMutation) AddSiteIDs(ids ...int)

AddSiteIDs adds the "sites" edge to the Site entity by ids.

func (*ProjectMutation) AddTechnologyIDs

func (m *ProjectMutation) AddTechnologyIDs(ids ...int)

AddTechnologyIDs adds the "technologies" edge to the ProjectTechnology entity by ids.

func (*ProjectMutation) AddedEdges

func (m *ProjectMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*ProjectMutation) AddedField

func (m *ProjectMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ProjectMutation) AddedFields

func (m *ProjectMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*ProjectMutation) AddedIDs

func (m *ProjectMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*ProjectMutation) ChildProjectsCleared

func (m *ProjectMutation) ChildProjectsCleared() bool

ChildProjectsCleared reports if the "child_projects" edge to the ProjectAssociation entity was cleared.

func (*ProjectMutation) ChildProjectsIDs

func (m *ProjectMutation) ChildProjectsIDs() (ids []int)

ChildProjectsIDs returns the "child_projects" edge IDs in the mutation.

func (*ProjectMutation) ClearChildProjects

func (m *ProjectMutation) ClearChildProjects()

ClearChildProjects clears the "child_projects" edge to the ProjectAssociation entity.

func (*ProjectMutation) ClearContributors

func (m *ProjectMutation) ClearContributors()

ClearContributors clears the "contributors" edge to the ProjectContributor entity.

func (*ProjectMutation) ClearDescription

func (m *ProjectMutation) ClearDescription()

ClearDescription clears the value of the "description" field.

func (*ProjectMutation) ClearDiscordBots

func (m *ProjectMutation) ClearDiscordBots()

ClearDiscordBots clears the "discord_bots" edge to the DiscordBot entity.

func (*ProjectMutation) ClearEdge

func (m *ProjectMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*ProjectMutation) ClearEndDate

func (m *ProjectMutation) ClearEndDate()

ClearEndDate clears the value of the "end_date" field.

func (*ProjectMutation) ClearField

func (m *ProjectMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*ProjectMutation) ClearParentProjects

func (m *ProjectMutation) ClearParentProjects()

ClearParentProjects clears the "parent_projects" edge to the ProjectAssociation entity.

func (*ProjectMutation) ClearRepositories

func (m *ProjectMutation) ClearRepositories()

ClearRepositories clears the "repositories" edge to the Repository entity.

func (*ProjectMutation) ClearSites

func (m *ProjectMutation) ClearSites()

ClearSites clears the "sites" edge to the Site entity.

func (*ProjectMutation) ClearTechnologies

func (m *ProjectMutation) ClearTechnologies()

ClearTechnologies clears the "technologies" edge to the ProjectTechnology entity.

func (*ProjectMutation) ClearedEdges

func (m *ProjectMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*ProjectMutation) ClearedFields

func (m *ProjectMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (ProjectMutation) Client

func (m ProjectMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*ProjectMutation) ContributorsCleared

func (m *ProjectMutation) ContributorsCleared() bool

ContributorsCleared reports if the "contributors" edge to the ProjectContributor entity was cleared.

func (*ProjectMutation) ContributorsIDs

func (m *ProjectMutation) ContributorsIDs() (ids []int)

ContributorsIDs returns the "contributors" edge IDs in the mutation.

func (*ProjectMutation) Description

func (m *ProjectMutation) Description() (r string, exists bool)

Description returns the value of the "description" field in the mutation.

func (*ProjectMutation) DescriptionCleared

func (m *ProjectMutation) DescriptionCleared() bool

DescriptionCleared returns if the "description" field was cleared in this mutation.

func (*ProjectMutation) DiscordBotsCleared

func (m *ProjectMutation) DiscordBotsCleared() bool

DiscordBotsCleared reports if the "discord_bots" edge to the DiscordBot entity was cleared.

func (*ProjectMutation) DiscordBotsIDs

func (m *ProjectMutation) DiscordBotsIDs() (ids []int)

DiscordBotsIDs returns the "discord_bots" edge IDs in the mutation.

func (*ProjectMutation) EdgeCleared

func (m *ProjectMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*ProjectMutation) EndDate

func (m *ProjectMutation) EndDate() (r time.Time, exists bool)

EndDate returns the value of the "end_date" field in the mutation.

func (*ProjectMutation) EndDateCleared

func (m *ProjectMutation) EndDateCleared() bool

EndDateCleared returns if the "end_date" field was cleared in this mutation.

func (*ProjectMutation) Field

func (m *ProjectMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ProjectMutation) FieldCleared

func (m *ProjectMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*ProjectMutation) Fields

func (m *ProjectMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*ProjectMutation) ID

func (m *ProjectMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*ProjectMutation) IDs

func (m *ProjectMutation) IDs(ctx context.Context) ([]int, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*ProjectMutation) Name

func (m *ProjectMutation) Name() (r string, exists bool)

Name returns the value of the "name" field in the mutation.

func (*ProjectMutation) OldDescription

func (m *ProjectMutation) OldDescription(ctx context.Context) (v *string, err error)

OldDescription returns the old "description" field's value of the Project entity. If the Project object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProjectMutation) OldEndDate

func (m *ProjectMutation) OldEndDate(ctx context.Context) (v *time.Time, err error)

OldEndDate returns the old "end_date" field's value of the Project entity. If the Project object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProjectMutation) OldField

func (m *ProjectMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*ProjectMutation) OldName

func (m *ProjectMutation) OldName(ctx context.Context) (v string, err error)

OldName returns the old "name" field's value of the Project entity. If the Project object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProjectMutation) OldStartDate

func (m *ProjectMutation) OldStartDate(ctx context.Context) (v time.Time, err error)

OldStartDate returns the old "start_date" field's value of the Project entity. If the Project object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProjectMutation) Op

func (m *ProjectMutation) Op() Op

Op returns the operation name.

func (*ProjectMutation) ParentProjectsCleared

func (m *ProjectMutation) ParentProjectsCleared() bool

ParentProjectsCleared reports if the "parent_projects" edge to the ProjectAssociation entity was cleared.

func (*ProjectMutation) ParentProjectsIDs

func (m *ProjectMutation) ParentProjectsIDs() (ids []int)

ParentProjectsIDs returns the "parent_projects" edge IDs in the mutation.

func (*ProjectMutation) RemoveChildProjectIDs

func (m *ProjectMutation) RemoveChildProjectIDs(ids ...int)

RemoveChildProjectIDs removes the "child_projects" edge to the ProjectAssociation entity by IDs.

func (*ProjectMutation) RemoveContributorIDs

func (m *ProjectMutation) RemoveContributorIDs(ids ...int)

RemoveContributorIDs removes the "contributors" edge to the ProjectContributor entity by IDs.

func (*ProjectMutation) RemoveDiscordBotIDs

func (m *ProjectMutation) RemoveDiscordBotIDs(ids ...int)

RemoveDiscordBotIDs removes the "discord_bots" edge to the DiscordBot entity by IDs.

func (*ProjectMutation) RemoveParentProjectIDs

func (m *ProjectMutation) RemoveParentProjectIDs(ids ...int)

RemoveParentProjectIDs removes the "parent_projects" edge to the ProjectAssociation entity by IDs.

func (*ProjectMutation) RemoveRepositoryIDs

func (m *ProjectMutation) RemoveRepositoryIDs(ids ...int)

RemoveRepositoryIDs removes the "repositories" edge to the Repository entity by IDs.

func (*ProjectMutation) RemoveSiteIDs

func (m *ProjectMutation) RemoveSiteIDs(ids ...int)

RemoveSiteIDs removes the "sites" edge to the Site entity by IDs.

func (*ProjectMutation) RemoveTechnologyIDs

func (m *ProjectMutation) RemoveTechnologyIDs(ids ...int)

RemoveTechnologyIDs removes the "technologies" edge to the ProjectTechnology entity by IDs.

func (*ProjectMutation) RemovedChildProjectsIDs

func (m *ProjectMutation) RemovedChildProjectsIDs() (ids []int)

RemovedChildProjects returns the removed IDs of the "child_projects" edge to the ProjectAssociation entity.

func (*ProjectMutation) RemovedContributorsIDs

func (m *ProjectMutation) RemovedContributorsIDs() (ids []int)

RemovedContributors returns the removed IDs of the "contributors" edge to the ProjectContributor entity.

func (*ProjectMutation) RemovedDiscordBotsIDs

func (m *ProjectMutation) RemovedDiscordBotsIDs() (ids []int)

RemovedDiscordBots returns the removed IDs of the "discord_bots" edge to the DiscordBot entity.

func (*ProjectMutation) RemovedEdges

func (m *ProjectMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*ProjectMutation) RemovedIDs

func (m *ProjectMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*ProjectMutation) RemovedParentProjectsIDs

func (m *ProjectMutation) RemovedParentProjectsIDs() (ids []int)

RemovedParentProjects returns the removed IDs of the "parent_projects" edge to the ProjectAssociation entity.

func (*ProjectMutation) RemovedRepositoriesIDs

func (m *ProjectMutation) RemovedRepositoriesIDs() (ids []int)

RemovedRepositories returns the removed IDs of the "repositories" edge to the Repository entity.

func (*ProjectMutation) RemovedSitesIDs

func (m *ProjectMutation) RemovedSitesIDs() (ids []int)

RemovedSites returns the removed IDs of the "sites" edge to the Site entity.

func (*ProjectMutation) RemovedTechnologiesIDs

func (m *ProjectMutation) RemovedTechnologiesIDs() (ids []int)

RemovedTechnologies returns the removed IDs of the "technologies" edge to the ProjectTechnology entity.

func (*ProjectMutation) RepositoriesCleared

func (m *ProjectMutation) RepositoriesCleared() bool

RepositoriesCleared reports if the "repositories" edge to the Repository entity was cleared.

func (*ProjectMutation) RepositoriesIDs

func (m *ProjectMutation) RepositoriesIDs() (ids []int)

RepositoriesIDs returns the "repositories" edge IDs in the mutation.

func (*ProjectMutation) ResetChildProjects

func (m *ProjectMutation) ResetChildProjects()

ResetChildProjects resets all changes to the "child_projects" edge.

func (*ProjectMutation) ResetContributors

func (m *ProjectMutation) ResetContributors()

ResetContributors resets all changes to the "contributors" edge.

func (*ProjectMutation) ResetDescription

func (m *ProjectMutation) ResetDescription()

ResetDescription resets all changes to the "description" field.

func (*ProjectMutation) ResetDiscordBots

func (m *ProjectMutation) ResetDiscordBots()

ResetDiscordBots resets all changes to the "discord_bots" edge.

func (*ProjectMutation) ResetEdge

func (m *ProjectMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*ProjectMutation) ResetEndDate

func (m *ProjectMutation) ResetEndDate()

ResetEndDate resets all changes to the "end_date" field.

func (*ProjectMutation) ResetField

func (m *ProjectMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*ProjectMutation) ResetName

func (m *ProjectMutation) ResetName()

ResetName resets all changes to the "name" field.

func (*ProjectMutation) ResetParentProjects

func (m *ProjectMutation) ResetParentProjects()

ResetParentProjects resets all changes to the "parent_projects" edge.

func (*ProjectMutation) ResetRepositories

func (m *ProjectMutation) ResetRepositories()

ResetRepositories resets all changes to the "repositories" edge.

func (*ProjectMutation) ResetSites

func (m *ProjectMutation) ResetSites()

ResetSites resets all changes to the "sites" edge.

func (*ProjectMutation) ResetStartDate

func (m *ProjectMutation) ResetStartDate()

ResetStartDate resets all changes to the "start_date" field.

func (*ProjectMutation) ResetTechnologies

func (m *ProjectMutation) ResetTechnologies()

ResetTechnologies resets all changes to the "technologies" edge.

func (*ProjectMutation) SetDescription

func (m *ProjectMutation) SetDescription(s string)

SetDescription sets the "description" field.

func (*ProjectMutation) SetEndDate

func (m *ProjectMutation) SetEndDate(t time.Time)

SetEndDate sets the "end_date" field.

func (*ProjectMutation) SetField

func (m *ProjectMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ProjectMutation) SetName

func (m *ProjectMutation) SetName(s string)

SetName sets the "name" field.

func (*ProjectMutation) SetStartDate

func (m *ProjectMutation) SetStartDate(t time.Time)

SetStartDate sets the "start_date" field.

func (*ProjectMutation) SitesCleared

func (m *ProjectMutation) SitesCleared() bool

SitesCleared reports if the "sites" edge to the Site entity was cleared.

func (*ProjectMutation) SitesIDs

func (m *ProjectMutation) SitesIDs() (ids []int)

SitesIDs returns the "sites" edge IDs in the mutation.

func (*ProjectMutation) StartDate

func (m *ProjectMutation) StartDate() (r time.Time, exists bool)

StartDate returns the value of the "start_date" field in the mutation.

func (*ProjectMutation) TechnologiesCleared

func (m *ProjectMutation) TechnologiesCleared() bool

TechnologiesCleared reports if the "technologies" edge to the ProjectTechnology entity was cleared.

func (*ProjectMutation) TechnologiesIDs

func (m *ProjectMutation) TechnologiesIDs() (ids []int)

TechnologiesIDs returns the "technologies" edge IDs in the mutation.

func (ProjectMutation) Tx

func (m ProjectMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*ProjectMutation) Type

func (m *ProjectMutation) Type() string

Type returns the node type of this mutation (Project).

func (*ProjectMutation) Where

func (m *ProjectMutation) Where(ps ...predicate.Project)

Where appends a list predicates to the ProjectMutation builder.

type ProjectOrder

type ProjectOrder struct {
	Direction OrderDirection     `json:"direction"`
	Field     *ProjectOrderField `json:"field"`
}

ProjectOrder defines the ordering of Project.

type ProjectOrderField

type ProjectOrderField struct {
	// contains filtered or unexported fields
}

ProjectOrderField defines the ordering field of Project.

func (ProjectOrderField) MarshalGQL

func (f ProjectOrderField) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (ProjectOrderField) String

func (f ProjectOrderField) String() string

String implement fmt.Stringer interface.

func (*ProjectOrderField) UnmarshalGQL

func (f *ProjectOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type ProjectPaginateOption

type ProjectPaginateOption func(*projectPager) error

ProjectPaginateOption enables pagination customization.

func WithProjectFilter

func WithProjectFilter(filter func(*ProjectQuery) (*ProjectQuery, error)) ProjectPaginateOption

WithProjectFilter configures pagination filter.

func WithProjectOrder

func WithProjectOrder(order *ProjectOrder) ProjectPaginateOption

WithProjectOrder configures pagination ordering.

type ProjectQuery

type ProjectQuery struct {
	// contains filtered or unexported fields
}

ProjectQuery is the builder for querying Project entities.

func (*ProjectQuery) All

func (pq *ProjectQuery) All(ctx context.Context) ([]*Project, error)

All executes the query and returns a list of Projects.

func (*ProjectQuery) AllX

func (pq *ProjectQuery) AllX(ctx context.Context) []*Project

AllX is like All, but panics if an error occurs.

func (*ProjectQuery) Clone

func (pq *ProjectQuery) Clone() *ProjectQuery

Clone returns a duplicate of the ProjectQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*ProjectQuery) CollectFields

func (pr *ProjectQuery) CollectFields(ctx context.Context, satisfies ...string) (*ProjectQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*ProjectQuery) Count

func (pq *ProjectQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*ProjectQuery) CountX

func (pq *ProjectQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*ProjectQuery) Exist

func (pq *ProjectQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*ProjectQuery) ExistX

func (pq *ProjectQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*ProjectQuery) First

func (pq *ProjectQuery) First(ctx context.Context) (*Project, error)

First returns the first Project entity from the query. Returns a *NotFoundError when no Project was found.

func (*ProjectQuery) FirstID

func (pq *ProjectQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first Project ID from the query. Returns a *NotFoundError when no Project ID was found.

func (*ProjectQuery) FirstIDX

func (pq *ProjectQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*ProjectQuery) FirstX

func (pq *ProjectQuery) FirstX(ctx context.Context) *Project

FirstX is like First, but panics if an error occurs.

func (*ProjectQuery) GroupBy

func (pq *ProjectQuery) GroupBy(field string, fields ...string) *ProjectGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Name string `json:"name,omitempty"`
	Count int `json:"count,omitempty"`
}

client.Project.Query().
	GroupBy(project.FieldName).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*ProjectQuery) IDs

func (pq *ProjectQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of Project IDs.

func (*ProjectQuery) IDsX

func (pq *ProjectQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*ProjectQuery) Limit

func (pq *ProjectQuery) Limit(limit int) *ProjectQuery

Limit adds a limit step to the query.

func (*ProjectQuery) Offset

func (pq *ProjectQuery) Offset(offset int) *ProjectQuery

Offset adds an offset step to the query.

func (*ProjectQuery) Only

func (pq *ProjectQuery) Only(ctx context.Context) (*Project, error)

Only returns a single Project entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Project entity is found. Returns a *NotFoundError when no Project entities are found.

func (*ProjectQuery) OnlyID

func (pq *ProjectQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only Project ID in the query. Returns a *NotSingularError when more than one Project ID is found. Returns a *NotFoundError when no entities are found.

func (*ProjectQuery) OnlyIDX

func (pq *ProjectQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*ProjectQuery) OnlyX

func (pq *ProjectQuery) OnlyX(ctx context.Context) *Project

OnlyX is like Only, but panics if an error occurs.

func (*ProjectQuery) Order

func (pq *ProjectQuery) Order(o ...OrderFunc) *ProjectQuery

Order adds an order step to the query.

func (*ProjectQuery) Paginate

func (pr *ProjectQuery) Paginate(
	ctx context.Context, after *Cursor, first *int,
	before *Cursor, last *int, opts ...ProjectPaginateOption,
) (*ProjectConnection, error)

Paginate executes the query and returns a relay based cursor connection to Project.

func (*ProjectQuery) QueryChildProjects

func (pq *ProjectQuery) QueryChildProjects() *ProjectAssociationQuery

QueryChildProjects chains the current query on the "child_projects" edge.

func (*ProjectQuery) QueryContributors

func (pq *ProjectQuery) QueryContributors() *ProjectContributorQuery

QueryContributors chains the current query on the "contributors" edge.

func (*ProjectQuery) QueryDiscordBots

func (pq *ProjectQuery) QueryDiscordBots() *DiscordBotQuery

QueryDiscordBots chains the current query on the "discord_bots" edge.

func (*ProjectQuery) QueryParentProjects

func (pq *ProjectQuery) QueryParentProjects() *ProjectAssociationQuery

QueryParentProjects chains the current query on the "parent_projects" edge.

func (*ProjectQuery) QueryRepositories

func (pq *ProjectQuery) QueryRepositories() *RepositoryQuery

QueryRepositories chains the current query on the "repositories" edge.

func (*ProjectQuery) QuerySites

func (pq *ProjectQuery) QuerySites() *SiteQuery

QuerySites chains the current query on the "sites" edge.

func (*ProjectQuery) QueryTechnologies

func (pq *ProjectQuery) QueryTechnologies() *ProjectTechnologyQuery

QueryTechnologies chains the current query on the "technologies" edge.

func (*ProjectQuery) Select

func (pq *ProjectQuery) Select(fields ...string) *ProjectSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Name string `json:"name,omitempty"`
}

client.Project.Query().
	Select(project.FieldName).
	Scan(ctx, &v)

func (*ProjectQuery) Unique

func (pq *ProjectQuery) Unique(unique bool) *ProjectQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*ProjectQuery) Where

func (pq *ProjectQuery) Where(ps ...predicate.Project) *ProjectQuery

Where adds a new predicate for the ProjectQuery builder.

func (*ProjectQuery) WithChildProjects

func (pq *ProjectQuery) WithChildProjects(opts ...func(*ProjectAssociationQuery)) *ProjectQuery

WithChildProjects tells the query-builder to eager-load the nodes that are connected to the "child_projects" edge. The optional arguments are used to configure the query builder of the edge.

func (*ProjectQuery) WithContributors

func (pq *ProjectQuery) WithContributors(opts ...func(*ProjectContributorQuery)) *ProjectQuery

WithContributors tells the query-builder to eager-load the nodes that are connected to the "contributors" edge. The optional arguments are used to configure the query builder of the edge.

func (*ProjectQuery) WithDiscordBots

func (pq *ProjectQuery) WithDiscordBots(opts ...func(*DiscordBotQuery)) *ProjectQuery

WithDiscordBots tells the query-builder to eager-load the nodes that are connected to the "discord_bots" edge. The optional arguments are used to configure the query builder of the edge.

func (*ProjectQuery) WithNamedChildProjects

func (pq *ProjectQuery) WithNamedChildProjects(name string, opts ...func(*ProjectAssociationQuery)) *ProjectQuery

WithNamedChildProjects tells the query-builder to eager-load the nodes that are connected to the "child_projects" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*ProjectQuery) WithNamedContributors

func (pq *ProjectQuery) WithNamedContributors(name string, opts ...func(*ProjectContributorQuery)) *ProjectQuery

WithNamedContributors tells the query-builder to eager-load the nodes that are connected to the "contributors" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*ProjectQuery) WithNamedDiscordBots

func (pq *ProjectQuery) WithNamedDiscordBots(name string, opts ...func(*DiscordBotQuery)) *ProjectQuery

WithNamedDiscordBots tells the query-builder to eager-load the nodes that are connected to the "discord_bots" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*ProjectQuery) WithNamedParentProjects

func (pq *ProjectQuery) WithNamedParentProjects(name string, opts ...func(*ProjectAssociationQuery)) *ProjectQuery

WithNamedParentProjects tells the query-builder to eager-load the nodes that are connected to the "parent_projects" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*ProjectQuery) WithNamedRepositories

func (pq *ProjectQuery) WithNamedRepositories(name string, opts ...func(*RepositoryQuery)) *ProjectQuery

WithNamedRepositories tells the query-builder to eager-load the nodes that are connected to the "repositories" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*ProjectQuery) WithNamedSites

func (pq *ProjectQuery) WithNamedSites(name string, opts ...func(*SiteQuery)) *ProjectQuery

WithNamedSites tells the query-builder to eager-load the nodes that are connected to the "sites" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*ProjectQuery) WithNamedTechnologies

func (pq *ProjectQuery) WithNamedTechnologies(name string, opts ...func(*ProjectTechnologyQuery)) *ProjectQuery

WithNamedTechnologies tells the query-builder to eager-load the nodes that are connected to the "technologies" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*ProjectQuery) WithParentProjects

func (pq *ProjectQuery) WithParentProjects(opts ...func(*ProjectAssociationQuery)) *ProjectQuery

WithParentProjects tells the query-builder to eager-load the nodes that are connected to the "parent_projects" edge. The optional arguments are used to configure the query builder of the edge.

func (*ProjectQuery) WithRepositories

func (pq *ProjectQuery) WithRepositories(opts ...func(*RepositoryQuery)) *ProjectQuery

WithRepositories tells the query-builder to eager-load the nodes that are connected to the "repositories" edge. The optional arguments are used to configure the query builder of the edge.

func (*ProjectQuery) WithSites

func (pq *ProjectQuery) WithSites(opts ...func(*SiteQuery)) *ProjectQuery

WithSites tells the query-builder to eager-load the nodes that are connected to the "sites" edge. The optional arguments are used to configure the query builder of the edge.

func (*ProjectQuery) WithTechnologies

func (pq *ProjectQuery) WithTechnologies(opts ...func(*ProjectTechnologyQuery)) *ProjectQuery

WithTechnologies tells the query-builder to eager-load the nodes that are connected to the "technologies" edge. The optional arguments are used to configure the query builder of the edge.

type ProjectSelect

type ProjectSelect struct {
	*ProjectQuery
	// contains filtered or unexported fields
}

ProjectSelect is the builder for selecting fields of Project entities.

func (*ProjectSelect) Bool

func (s *ProjectSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ProjectSelect) BoolX

func (s *ProjectSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ProjectSelect) Bools

func (s *ProjectSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ProjectSelect) BoolsX

func (s *ProjectSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ProjectSelect) Float64

func (s *ProjectSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ProjectSelect) Float64X

func (s *ProjectSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ProjectSelect) Float64s

func (s *ProjectSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ProjectSelect) Float64sX

func (s *ProjectSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ProjectSelect) Int

func (s *ProjectSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ProjectSelect) IntX

func (s *ProjectSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ProjectSelect) Ints

func (s *ProjectSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ProjectSelect) IntsX

func (s *ProjectSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ProjectSelect) Scan

func (ps *ProjectSelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*ProjectSelect) ScanX

func (s *ProjectSelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*ProjectSelect) String

func (s *ProjectSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ProjectSelect) StringX

func (s *ProjectSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ProjectSelect) Strings

func (s *ProjectSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ProjectSelect) StringsX

func (s *ProjectSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ProjectTechnologies

type ProjectTechnologies []*ProjectTechnology

ProjectTechnologies is a parsable slice of ProjectTechnology.

type ProjectTechnology

type ProjectTechnology struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Type holds the value of the "type" field.
	Type projecttechnology.Type `json:"type,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the ProjectTechnologyQuery when eager-loading is set.
	Edges ProjectTechnologyEdges `json:"edges"`
	// contains filtered or unexported fields
}

ProjectTechnology is the model entity for the ProjectTechnology schema.

func (*ProjectTechnology) Node

func (pt *ProjectTechnology) Node(ctx context.Context) (node *Node, err error)

func (*ProjectTechnology) Project

func (pt *ProjectTechnology) Project(ctx context.Context) (*Project, error)

func (*ProjectTechnology) QueryProject

func (pt *ProjectTechnology) QueryProject() *ProjectQuery

QueryProject queries the "project" edge of the ProjectTechnology entity.

func (*ProjectTechnology) QueryTechnology

func (pt *ProjectTechnology) QueryTechnology() *TechnologyQuery

QueryTechnology queries the "technology" edge of the ProjectTechnology entity.

func (*ProjectTechnology) String

func (pt *ProjectTechnology) String() string

String implements the fmt.Stringer.

func (*ProjectTechnology) Technology

func (pt *ProjectTechnology) Technology(ctx context.Context) (*Technology, error)

func (*ProjectTechnology) ToEdge

ToEdge converts ProjectTechnology into ProjectTechnologyEdge.

func (*ProjectTechnology) Unwrap

func (pt *ProjectTechnology) Unwrap() *ProjectTechnology

Unwrap unwraps the ProjectTechnology entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*ProjectTechnology) Update

Update returns a builder for updating this ProjectTechnology. Note that you need to call ProjectTechnology.Unwrap() before calling this method if this ProjectTechnology was returned from a transaction, and the transaction was committed or rolled back.

type ProjectTechnologyClient

type ProjectTechnologyClient struct {
	// contains filtered or unexported fields
}

ProjectTechnologyClient is a client for the ProjectTechnology schema.

func NewProjectTechnologyClient

func NewProjectTechnologyClient(c config) *ProjectTechnologyClient

NewProjectTechnologyClient returns a client for the ProjectTechnology from the given config.

func (*ProjectTechnologyClient) Create

Create returns a builder for creating a ProjectTechnology entity.

func (*ProjectTechnologyClient) CreateBulk

CreateBulk returns a builder for creating a bulk of ProjectTechnology entities.

func (*ProjectTechnologyClient) Delete

Delete returns a delete builder for ProjectTechnology.

func (*ProjectTechnologyClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*ProjectTechnologyClient) DeleteOneID

DeleteOne returns a builder for deleting the given entity by its id.

func (*ProjectTechnologyClient) Get

Get returns a ProjectTechnology entity by its id.

func (*ProjectTechnologyClient) GetX

GetX is like Get, but panics if an error occurs.

func (*ProjectTechnologyClient) Hooks

func (c *ProjectTechnologyClient) Hooks() []Hook

Hooks returns the client hooks.

func (*ProjectTechnologyClient) Query

Query returns a query builder for ProjectTechnology.

func (*ProjectTechnologyClient) QueryProject

QueryProject queries the project edge of a ProjectTechnology.

func (*ProjectTechnologyClient) QueryTechnology

QueryTechnology queries the technology edge of a ProjectTechnology.

func (*ProjectTechnologyClient) Update

Update returns an update builder for ProjectTechnology.

func (*ProjectTechnologyClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*ProjectTechnologyClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*ProjectTechnologyClient) Use

func (c *ProjectTechnologyClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `projecttechnology.Hooks(f(g(h())))`.

type ProjectTechnologyConnection

type ProjectTechnologyConnection struct {
	Edges      []*ProjectTechnologyEdge `json:"edges"`
	PageInfo   PageInfo                 `json:"pageInfo"`
	TotalCount int                      `json:"totalCount"`
}

ProjectTechnologyConnection is the connection containing edges to ProjectTechnology.

type ProjectTechnologyCreate

type ProjectTechnologyCreate struct {
	// contains filtered or unexported fields
}

ProjectTechnologyCreate is the builder for creating a ProjectTechnology entity.

func (*ProjectTechnologyCreate) Exec

Exec executes the query.

func (*ProjectTechnologyCreate) ExecX

func (ptc *ProjectTechnologyCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectTechnologyCreate) Mutation

Mutation returns the ProjectTechnologyMutation object of the builder.

func (*ProjectTechnologyCreate) Save

Save creates the ProjectTechnology in the database.

func (*ProjectTechnologyCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*ProjectTechnologyCreate) SetInput

SetInput applies the change-set in the CreateProjectTechnologyInput on the create builder.

func (*ProjectTechnologyCreate) SetProject

SetProject sets the "project" edge to the Project entity.

func (*ProjectTechnologyCreate) SetProjectID

func (ptc *ProjectTechnologyCreate) SetProjectID(id int) *ProjectTechnologyCreate

SetProjectID sets the "project" edge to the Project entity by ID.

func (*ProjectTechnologyCreate) SetTechnology

SetTechnology sets the "technology" edge to the Technology entity.

func (*ProjectTechnologyCreate) SetTechnologyID

func (ptc *ProjectTechnologyCreate) SetTechnologyID(id int) *ProjectTechnologyCreate

SetTechnologyID sets the "technology" edge to the Technology entity by ID.

func (*ProjectTechnologyCreate) SetType

SetType sets the "type" field.

type ProjectTechnologyCreateBulk

type ProjectTechnologyCreateBulk struct {
	// contains filtered or unexported fields
}

ProjectTechnologyCreateBulk is the builder for creating many ProjectTechnology entities in bulk.

func (*ProjectTechnologyCreateBulk) Exec

Exec executes the query.

func (*ProjectTechnologyCreateBulk) ExecX

func (ptcb *ProjectTechnologyCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectTechnologyCreateBulk) Save

Save creates the ProjectTechnology entities in the database.

func (*ProjectTechnologyCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type ProjectTechnologyDelete

type ProjectTechnologyDelete struct {
	// contains filtered or unexported fields
}

ProjectTechnologyDelete is the builder for deleting a ProjectTechnology entity.

func (*ProjectTechnologyDelete) Exec

func (ptd *ProjectTechnologyDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*ProjectTechnologyDelete) ExecX

func (ptd *ProjectTechnologyDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*ProjectTechnologyDelete) Where

Where appends a list predicates to the ProjectTechnologyDelete builder.

type ProjectTechnologyDeleteOne

type ProjectTechnologyDeleteOne struct {
	// contains filtered or unexported fields
}

ProjectTechnologyDeleteOne is the builder for deleting a single ProjectTechnology entity.

func (*ProjectTechnologyDeleteOne) Exec

Exec executes the deletion query.

func (*ProjectTechnologyDeleteOne) ExecX

func (ptdo *ProjectTechnologyDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

type ProjectTechnologyEdge

type ProjectTechnologyEdge struct {
	Node   *ProjectTechnology `json:"node"`
	Cursor Cursor             `json:"cursor"`
}

ProjectTechnologyEdge is the edge representation of ProjectTechnology.

type ProjectTechnologyEdges

type ProjectTechnologyEdges struct {
	// Project holds the value of the project edge.
	Project *Project `json:"project,omitempty"`
	// Technology holds the value of the technology edge.
	Technology *Technology `json:"technology,omitempty"`
	// contains filtered or unexported fields
}

ProjectTechnologyEdges holds the relations/edges for other nodes in the graph.

func (ProjectTechnologyEdges) ProjectOrErr

func (e ProjectTechnologyEdges) ProjectOrErr() (*Project, error)

ProjectOrErr returns the Project value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (ProjectTechnologyEdges) TechnologyOrErr

func (e ProjectTechnologyEdges) TechnologyOrErr() (*Technology, error)

TechnologyOrErr returns the Technology value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type ProjectTechnologyGroupBy

type ProjectTechnologyGroupBy struct {
	// contains filtered or unexported fields
}

ProjectTechnologyGroupBy is the group-by builder for ProjectTechnology entities.

func (*ProjectTechnologyGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*ProjectTechnologyGroupBy) Bool

func (s *ProjectTechnologyGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologyGroupBy) BoolX

func (s *ProjectTechnologyGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ProjectTechnologyGroupBy) Bools

func (s *ProjectTechnologyGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologyGroupBy) BoolsX

func (s *ProjectTechnologyGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ProjectTechnologyGroupBy) Float64

func (s *ProjectTechnologyGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologyGroupBy) Float64X

func (s *ProjectTechnologyGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ProjectTechnologyGroupBy) Float64s

func (s *ProjectTechnologyGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologyGroupBy) Float64sX

func (s *ProjectTechnologyGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ProjectTechnologyGroupBy) Int

func (s *ProjectTechnologyGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologyGroupBy) IntX

func (s *ProjectTechnologyGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ProjectTechnologyGroupBy) Ints

func (s *ProjectTechnologyGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologyGroupBy) IntsX

func (s *ProjectTechnologyGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ProjectTechnologyGroupBy) Scan

func (ptgb *ProjectTechnologyGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*ProjectTechnologyGroupBy) ScanX

func (s *ProjectTechnologyGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*ProjectTechnologyGroupBy) String

func (s *ProjectTechnologyGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologyGroupBy) StringX

func (s *ProjectTechnologyGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ProjectTechnologyGroupBy) Strings

func (s *ProjectTechnologyGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologyGroupBy) StringsX

func (s *ProjectTechnologyGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ProjectTechnologyMutation

type ProjectTechnologyMutation struct {
	// contains filtered or unexported fields
}

ProjectTechnologyMutation represents an operation that mutates the ProjectTechnology nodes in the graph.

func (*ProjectTechnologyMutation) AddField

func (m *ProjectTechnologyMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ProjectTechnologyMutation) AddedEdges

func (m *ProjectTechnologyMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*ProjectTechnologyMutation) AddedField

func (m *ProjectTechnologyMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ProjectTechnologyMutation) AddedFields

func (m *ProjectTechnologyMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*ProjectTechnologyMutation) AddedIDs

func (m *ProjectTechnologyMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*ProjectTechnologyMutation) ClearEdge

func (m *ProjectTechnologyMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*ProjectTechnologyMutation) ClearField

func (m *ProjectTechnologyMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*ProjectTechnologyMutation) ClearProject

func (m *ProjectTechnologyMutation) ClearProject()

ClearProject clears the "project" edge to the Project entity.

func (*ProjectTechnologyMutation) ClearTechnology

func (m *ProjectTechnologyMutation) ClearTechnology()

ClearTechnology clears the "technology" edge to the Technology entity.

func (*ProjectTechnologyMutation) ClearedEdges

func (m *ProjectTechnologyMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*ProjectTechnologyMutation) ClearedFields

func (m *ProjectTechnologyMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (ProjectTechnologyMutation) Client

func (m ProjectTechnologyMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*ProjectTechnologyMutation) EdgeCleared

func (m *ProjectTechnologyMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*ProjectTechnologyMutation) Field

func (m *ProjectTechnologyMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ProjectTechnologyMutation) FieldCleared

func (m *ProjectTechnologyMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*ProjectTechnologyMutation) Fields

func (m *ProjectTechnologyMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*ProjectTechnologyMutation) GetType

func (m *ProjectTechnologyMutation) GetType() (r projecttechnology.Type, exists bool)

GetType returns the value of the "type" field in the mutation.

func (*ProjectTechnologyMutation) ID

func (m *ProjectTechnologyMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*ProjectTechnologyMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*ProjectTechnologyMutation) OldField

func (m *ProjectTechnologyMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*ProjectTechnologyMutation) OldType

OldType returns the old "type" field's value of the ProjectTechnology entity. If the ProjectTechnology object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProjectTechnologyMutation) Op

func (m *ProjectTechnologyMutation) Op() Op

Op returns the operation name.

func (*ProjectTechnologyMutation) ProjectCleared

func (m *ProjectTechnologyMutation) ProjectCleared() bool

ProjectCleared reports if the "project" edge to the Project entity was cleared.

func (*ProjectTechnologyMutation) ProjectID

func (m *ProjectTechnologyMutation) ProjectID() (id int, exists bool)

ProjectID returns the "project" edge ID in the mutation.

func (*ProjectTechnologyMutation) ProjectIDs

func (m *ProjectTechnologyMutation) ProjectIDs() (ids []int)

ProjectIDs returns the "project" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ProjectID instead. It exists only for internal usage by the builders.

func (*ProjectTechnologyMutation) RemovedEdges

func (m *ProjectTechnologyMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*ProjectTechnologyMutation) RemovedIDs

func (m *ProjectTechnologyMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*ProjectTechnologyMutation) ResetEdge

func (m *ProjectTechnologyMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*ProjectTechnologyMutation) ResetField

func (m *ProjectTechnologyMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*ProjectTechnologyMutation) ResetProject

func (m *ProjectTechnologyMutation) ResetProject()

ResetProject resets all changes to the "project" edge.

func (*ProjectTechnologyMutation) ResetTechnology

func (m *ProjectTechnologyMutation) ResetTechnology()

ResetTechnology resets all changes to the "technology" edge.

func (*ProjectTechnologyMutation) ResetType

func (m *ProjectTechnologyMutation) ResetType()

ResetType resets all changes to the "type" field.

func (*ProjectTechnologyMutation) SetField

func (m *ProjectTechnologyMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ProjectTechnologyMutation) SetProjectID

func (m *ProjectTechnologyMutation) SetProjectID(id int)

SetProjectID sets the "project" edge to the Project entity by id.

func (*ProjectTechnologyMutation) SetTechnologyID

func (m *ProjectTechnologyMutation) SetTechnologyID(id int)

SetTechnologyID sets the "technology" edge to the Technology entity by id.

func (*ProjectTechnologyMutation) SetType

SetType sets the "type" field.

func (*ProjectTechnologyMutation) TechnologyCleared

func (m *ProjectTechnologyMutation) TechnologyCleared() bool

TechnologyCleared reports if the "technology" edge to the Technology entity was cleared.

func (*ProjectTechnologyMutation) TechnologyID

func (m *ProjectTechnologyMutation) TechnologyID() (id int, exists bool)

TechnologyID returns the "technology" edge ID in the mutation.

func (*ProjectTechnologyMutation) TechnologyIDs

func (m *ProjectTechnologyMutation) TechnologyIDs() (ids []int)

TechnologyIDs returns the "technology" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use TechnologyID instead. It exists only for internal usage by the builders.

func (ProjectTechnologyMutation) Tx

func (m ProjectTechnologyMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*ProjectTechnologyMutation) Type

Type returns the node type of this mutation (ProjectTechnology).

func (*ProjectTechnologyMutation) Where

Where appends a list predicates to the ProjectTechnologyMutation builder.

type ProjectTechnologyOrder

type ProjectTechnologyOrder struct {
	Direction OrderDirection               `json:"direction"`
	Field     *ProjectTechnologyOrderField `json:"field"`
}

ProjectTechnologyOrder defines the ordering of ProjectTechnology.

type ProjectTechnologyOrderField

type ProjectTechnologyOrderField struct {
	// contains filtered or unexported fields
}

ProjectTechnologyOrderField defines the ordering field of ProjectTechnology.

func (ProjectTechnologyOrderField) MarshalGQL

func (f ProjectTechnologyOrderField) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (ProjectTechnologyOrderField) String

String implement fmt.Stringer interface.

func (*ProjectTechnologyOrderField) UnmarshalGQL

func (f *ProjectTechnologyOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type ProjectTechnologyPaginateOption

type ProjectTechnologyPaginateOption func(*projecttechnologyPager) error

ProjectTechnologyPaginateOption enables pagination customization.

func WithProjectTechnologyFilter

func WithProjectTechnologyFilter(filter func(*ProjectTechnologyQuery) (*ProjectTechnologyQuery, error)) ProjectTechnologyPaginateOption

WithProjectTechnologyFilter configures pagination filter.

func WithProjectTechnologyOrder

func WithProjectTechnologyOrder(order *ProjectTechnologyOrder) ProjectTechnologyPaginateOption

WithProjectTechnologyOrder configures pagination ordering.

type ProjectTechnologyQuery

type ProjectTechnologyQuery struct {
	// contains filtered or unexported fields
}

ProjectTechnologyQuery is the builder for querying ProjectTechnology entities.

func (*ProjectTechnologyQuery) All

All executes the query and returns a list of ProjectTechnologies.

func (*ProjectTechnologyQuery) AllX

AllX is like All, but panics if an error occurs.

func (*ProjectTechnologyQuery) Clone

Clone returns a duplicate of the ProjectTechnologyQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*ProjectTechnologyQuery) CollectFields

func (pt *ProjectTechnologyQuery) CollectFields(ctx context.Context, satisfies ...string) (*ProjectTechnologyQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*ProjectTechnologyQuery) Count

func (ptq *ProjectTechnologyQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*ProjectTechnologyQuery) CountX

func (ptq *ProjectTechnologyQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*ProjectTechnologyQuery) Exist

func (ptq *ProjectTechnologyQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*ProjectTechnologyQuery) ExistX

func (ptq *ProjectTechnologyQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*ProjectTechnologyQuery) First

First returns the first ProjectTechnology entity from the query. Returns a *NotFoundError when no ProjectTechnology was found.

func (*ProjectTechnologyQuery) FirstID

func (ptq *ProjectTechnologyQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first ProjectTechnology ID from the query. Returns a *NotFoundError when no ProjectTechnology ID was found.

func (*ProjectTechnologyQuery) FirstIDX

func (ptq *ProjectTechnologyQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*ProjectTechnologyQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*ProjectTechnologyQuery) GroupBy

func (ptq *ProjectTechnologyQuery) GroupBy(field string, fields ...string) *ProjectTechnologyGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Type projecttechnology.Type `json:"type,omitempty"`
	Count int `json:"count,omitempty"`
}

client.ProjectTechnology.Query().
	GroupBy(projecttechnology.FieldType).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*ProjectTechnologyQuery) IDs

func (ptq *ProjectTechnologyQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of ProjectTechnology IDs.

func (*ProjectTechnologyQuery) IDsX

func (ptq *ProjectTechnologyQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*ProjectTechnologyQuery) Limit

Limit adds a limit step to the query.

func (*ProjectTechnologyQuery) Offset

func (ptq *ProjectTechnologyQuery) Offset(offset int) *ProjectTechnologyQuery

Offset adds an offset step to the query.

func (*ProjectTechnologyQuery) Only

Only returns a single ProjectTechnology entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one ProjectTechnology entity is found. Returns a *NotFoundError when no ProjectTechnology entities are found.

func (*ProjectTechnologyQuery) OnlyID

func (ptq *ProjectTechnologyQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only ProjectTechnology ID in the query. Returns a *NotSingularError when more than one ProjectTechnology ID is found. Returns a *NotFoundError when no entities are found.

func (*ProjectTechnologyQuery) OnlyIDX

func (ptq *ProjectTechnologyQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*ProjectTechnologyQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*ProjectTechnologyQuery) Order

Order adds an order step to the query.

func (*ProjectTechnologyQuery) Paginate

func (pt *ProjectTechnologyQuery) Paginate(
	ctx context.Context, after *Cursor, first *int,
	before *Cursor, last *int, opts ...ProjectTechnologyPaginateOption,
) (*ProjectTechnologyConnection, error)

Paginate executes the query and returns a relay based cursor connection to ProjectTechnology.

func (*ProjectTechnologyQuery) QueryProject

func (ptq *ProjectTechnologyQuery) QueryProject() *ProjectQuery

QueryProject chains the current query on the "project" edge.

func (*ProjectTechnologyQuery) QueryTechnology

func (ptq *ProjectTechnologyQuery) QueryTechnology() *TechnologyQuery

QueryTechnology chains the current query on the "technology" edge.

func (*ProjectTechnologyQuery) Select

func (ptq *ProjectTechnologyQuery) Select(fields ...string) *ProjectTechnologySelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Type projecttechnology.Type `json:"type,omitempty"`
}

client.ProjectTechnology.Query().
	Select(projecttechnology.FieldType).
	Scan(ctx, &v)

func (*ProjectTechnologyQuery) Unique

func (ptq *ProjectTechnologyQuery) Unique(unique bool) *ProjectTechnologyQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*ProjectTechnologyQuery) Where

Where adds a new predicate for the ProjectTechnologyQuery builder.

func (*ProjectTechnologyQuery) WithProject

func (ptq *ProjectTechnologyQuery) WithProject(opts ...func(*ProjectQuery)) *ProjectTechnologyQuery

WithProject tells the query-builder to eager-load the nodes that are connected to the "project" edge. The optional arguments are used to configure the query builder of the edge.

func (*ProjectTechnologyQuery) WithTechnology

func (ptq *ProjectTechnologyQuery) WithTechnology(opts ...func(*TechnologyQuery)) *ProjectTechnologyQuery

WithTechnology tells the query-builder to eager-load the nodes that are connected to the "technology" edge. The optional arguments are used to configure the query builder of the edge.

type ProjectTechnologySelect

type ProjectTechnologySelect struct {
	*ProjectTechnologyQuery
	// contains filtered or unexported fields
}

ProjectTechnologySelect is the builder for selecting fields of ProjectTechnology entities.

func (*ProjectTechnologySelect) Bool

func (s *ProjectTechnologySelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologySelect) BoolX

func (s *ProjectTechnologySelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ProjectTechnologySelect) Bools

func (s *ProjectTechnologySelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologySelect) BoolsX

func (s *ProjectTechnologySelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ProjectTechnologySelect) Float64

func (s *ProjectTechnologySelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologySelect) Float64X

func (s *ProjectTechnologySelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ProjectTechnologySelect) Float64s

func (s *ProjectTechnologySelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologySelect) Float64sX

func (s *ProjectTechnologySelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ProjectTechnologySelect) Int

func (s *ProjectTechnologySelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologySelect) IntX

func (s *ProjectTechnologySelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ProjectTechnologySelect) Ints

func (s *ProjectTechnologySelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologySelect) IntsX

func (s *ProjectTechnologySelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ProjectTechnologySelect) Scan

func (pts *ProjectTechnologySelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*ProjectTechnologySelect) ScanX

func (s *ProjectTechnologySelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*ProjectTechnologySelect) String

func (s *ProjectTechnologySelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologySelect) StringX

func (s *ProjectTechnologySelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ProjectTechnologySelect) Strings

func (s *ProjectTechnologySelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ProjectTechnologySelect) StringsX

func (s *ProjectTechnologySelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ProjectTechnologyUpdate

type ProjectTechnologyUpdate struct {
	// contains filtered or unexported fields
}

ProjectTechnologyUpdate is the builder for updating ProjectTechnology entities.

func (*ProjectTechnologyUpdate) ClearProject

func (ptu *ProjectTechnologyUpdate) ClearProject() *ProjectTechnologyUpdate

ClearProject clears the "project" edge to the Project entity.

func (*ProjectTechnologyUpdate) ClearTechnology

func (ptu *ProjectTechnologyUpdate) ClearTechnology() *ProjectTechnologyUpdate

ClearTechnology clears the "technology" edge to the Technology entity.

func (*ProjectTechnologyUpdate) Exec

Exec executes the query.

func (*ProjectTechnologyUpdate) ExecX

func (ptu *ProjectTechnologyUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectTechnologyUpdate) Mutation

Mutation returns the ProjectTechnologyMutation object of the builder.

func (*ProjectTechnologyUpdate) Save

func (ptu *ProjectTechnologyUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*ProjectTechnologyUpdate) SaveX

func (ptu *ProjectTechnologyUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*ProjectTechnologyUpdate) SetInput

SetInput applies the change-set in the UpdateProjectTechnologyInput on the update builder.

func (*ProjectTechnologyUpdate) SetProject

SetProject sets the "project" edge to the Project entity.

func (*ProjectTechnologyUpdate) SetProjectID

func (ptu *ProjectTechnologyUpdate) SetProjectID(id int) *ProjectTechnologyUpdate

SetProjectID sets the "project" edge to the Project entity by ID.

func (*ProjectTechnologyUpdate) SetTechnology

SetTechnology sets the "technology" edge to the Technology entity.

func (*ProjectTechnologyUpdate) SetTechnologyID

func (ptu *ProjectTechnologyUpdate) SetTechnologyID(id int) *ProjectTechnologyUpdate

SetTechnologyID sets the "technology" edge to the Technology entity by ID.

func (*ProjectTechnologyUpdate) SetType

SetType sets the "type" field.

func (*ProjectTechnologyUpdate) Where

Where appends a list predicates to the ProjectTechnologyUpdate builder.

type ProjectTechnologyUpdateOne

type ProjectTechnologyUpdateOne struct {
	// contains filtered or unexported fields
}

ProjectTechnologyUpdateOne is the builder for updating a single ProjectTechnology entity.

func (*ProjectTechnologyUpdateOne) ClearProject

ClearProject clears the "project" edge to the Project entity.

func (*ProjectTechnologyUpdateOne) ClearTechnology

func (ptuo *ProjectTechnologyUpdateOne) ClearTechnology() *ProjectTechnologyUpdateOne

ClearTechnology clears the "technology" edge to the Technology entity.

func (*ProjectTechnologyUpdateOne) Exec

Exec executes the query on the entity.

func (*ProjectTechnologyUpdateOne) ExecX

func (ptuo *ProjectTechnologyUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectTechnologyUpdateOne) Mutation

Mutation returns the ProjectTechnologyMutation object of the builder.

func (*ProjectTechnologyUpdateOne) Save

Save executes the query and returns the updated ProjectTechnology entity.

func (*ProjectTechnologyUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*ProjectTechnologyUpdateOne) Select

func (ptuo *ProjectTechnologyUpdateOne) Select(field string, fields ...string) *ProjectTechnologyUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*ProjectTechnologyUpdateOne) SetInput

SetInput applies the change-set in the UpdateProjectTechnologyInput on the update-one builder.

func (*ProjectTechnologyUpdateOne) SetProject

SetProject sets the "project" edge to the Project entity.

func (*ProjectTechnologyUpdateOne) SetProjectID

SetProjectID sets the "project" edge to the Project entity by ID.

func (*ProjectTechnologyUpdateOne) SetTechnology

SetTechnology sets the "technology" edge to the Technology entity.

func (*ProjectTechnologyUpdateOne) SetTechnologyID

func (ptuo *ProjectTechnologyUpdateOne) SetTechnologyID(id int) *ProjectTechnologyUpdateOne

SetTechnologyID sets the "technology" edge to the Technology entity by ID.

func (*ProjectTechnologyUpdateOne) SetType

SetType sets the "type" field.

type ProjectTechnologyWhereInput

type ProjectTechnologyWhereInput struct {
	Predicates []predicate.ProjectTechnology  `json:"-"`
	Not        *ProjectTechnologyWhereInput   `json:"not,omitempty"`
	Or         []*ProjectTechnologyWhereInput `json:"or,omitempty"`
	And        []*ProjectTechnologyWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "type" field predicates.
	Type      *projecttechnology.Type  `json:"type,omitempty"`
	TypeNEQ   *projecttechnology.Type  `json:"typeNEQ,omitempty"`
	TypeIn    []projecttechnology.Type `json:"typeIn,omitempty"`
	TypeNotIn []projecttechnology.Type `json:"typeNotIn,omitempty"`

	// "project" edge predicates.
	HasProject     *bool                `json:"hasProject,omitempty"`
	HasProjectWith []*ProjectWhereInput `json:"hasProjectWith,omitempty"`

	// "technology" edge predicates.
	HasTechnology     *bool                   `json:"hasTechnology,omitempty"`
	HasTechnologyWith []*TechnologyWhereInput `json:"hasTechnologyWith,omitempty"`
}

ProjectTechnologyWhereInput represents a where input for filtering ProjectTechnology queries.

func (*ProjectTechnologyWhereInput) AddPredicates

func (i *ProjectTechnologyWhereInput) AddPredicates(predicates ...predicate.ProjectTechnology)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*ProjectTechnologyWhereInput) Filter

Filter applies the ProjectTechnologyWhereInput filter on the ProjectTechnologyQuery builder.

func (*ProjectTechnologyWhereInput) P

P returns a predicate for filtering projecttechnologies. An error is returned if the input is empty or invalid.

type ProjectUpdate

type ProjectUpdate struct {
	// contains filtered or unexported fields
}

ProjectUpdate is the builder for updating Project entities.

func (*ProjectUpdate) AddChildProjectIDs

func (pu *ProjectUpdate) AddChildProjectIDs(ids ...int) *ProjectUpdate

AddChildProjectIDs adds the "child_projects" edge to the ProjectAssociation entity by IDs.

func (*ProjectUpdate) AddChildProjects

func (pu *ProjectUpdate) AddChildProjects(p ...*ProjectAssociation) *ProjectUpdate

AddChildProjects adds the "child_projects" edges to the ProjectAssociation entity.

func (*ProjectUpdate) AddContributorIDs

func (pu *ProjectUpdate) AddContributorIDs(ids ...int) *ProjectUpdate

AddContributorIDs adds the "contributors" edge to the ProjectContributor entity by IDs.

func (*ProjectUpdate) AddContributors

func (pu *ProjectUpdate) AddContributors(p ...*ProjectContributor) *ProjectUpdate

AddContributors adds the "contributors" edges to the ProjectContributor entity.

func (*ProjectUpdate) AddDiscordBotIDs

func (pu *ProjectUpdate) AddDiscordBotIDs(ids ...int) *ProjectUpdate

AddDiscordBotIDs adds the "discord_bots" edge to the DiscordBot entity by IDs.

func (*ProjectUpdate) AddDiscordBots

func (pu *ProjectUpdate) AddDiscordBots(d ...*DiscordBot) *ProjectUpdate

AddDiscordBots adds the "discord_bots" edges to the DiscordBot entity.

func (*ProjectUpdate) AddParentProjectIDs

func (pu *ProjectUpdate) AddParentProjectIDs(ids ...int) *ProjectUpdate

AddParentProjectIDs adds the "parent_projects" edge to the ProjectAssociation entity by IDs.

func (*ProjectUpdate) AddParentProjects

func (pu *ProjectUpdate) AddParentProjects(p ...*ProjectAssociation) *ProjectUpdate

AddParentProjects adds the "parent_projects" edges to the ProjectAssociation entity.

func (*ProjectUpdate) AddRepositories

func (pu *ProjectUpdate) AddRepositories(r ...*Repository) *ProjectUpdate

AddRepositories adds the "repositories" edges to the Repository entity.

func (*ProjectUpdate) AddRepositoryIDs

func (pu *ProjectUpdate) AddRepositoryIDs(ids ...int) *ProjectUpdate

AddRepositoryIDs adds the "repositories" edge to the Repository entity by IDs.

func (*ProjectUpdate) AddSiteIDs

func (pu *ProjectUpdate) AddSiteIDs(ids ...int) *ProjectUpdate

AddSiteIDs adds the "sites" edge to the Site entity by IDs.

func (*ProjectUpdate) AddSites

func (pu *ProjectUpdate) AddSites(s ...*Site) *ProjectUpdate

AddSites adds the "sites" edges to the Site entity.

func (*ProjectUpdate) AddTechnologies

func (pu *ProjectUpdate) AddTechnologies(p ...*ProjectTechnology) *ProjectUpdate

AddTechnologies adds the "technologies" edges to the ProjectTechnology entity.

func (*ProjectUpdate) AddTechnologyIDs

func (pu *ProjectUpdate) AddTechnologyIDs(ids ...int) *ProjectUpdate

AddTechnologyIDs adds the "technologies" edge to the ProjectTechnology entity by IDs.

func (*ProjectUpdate) ClearChildProjects

func (pu *ProjectUpdate) ClearChildProjects() *ProjectUpdate

ClearChildProjects clears all "child_projects" edges to the ProjectAssociation entity.

func (*ProjectUpdate) ClearContributors

func (pu *ProjectUpdate) ClearContributors() *ProjectUpdate

ClearContributors clears all "contributors" edges to the ProjectContributor entity.

func (*ProjectUpdate) ClearDescription

func (pu *ProjectUpdate) ClearDescription() *ProjectUpdate

ClearDescription clears the value of the "description" field.

func (*ProjectUpdate) ClearDiscordBots

func (pu *ProjectUpdate) ClearDiscordBots() *ProjectUpdate

ClearDiscordBots clears all "discord_bots" edges to the DiscordBot entity.

func (*ProjectUpdate) ClearEndDate

func (pu *ProjectUpdate) ClearEndDate() *ProjectUpdate

ClearEndDate clears the value of the "end_date" field.

func (*ProjectUpdate) ClearParentProjects

func (pu *ProjectUpdate) ClearParentProjects() *ProjectUpdate

ClearParentProjects clears all "parent_projects" edges to the ProjectAssociation entity.

func (*ProjectUpdate) ClearRepositories

func (pu *ProjectUpdate) ClearRepositories() *ProjectUpdate

ClearRepositories clears all "repositories" edges to the Repository entity.

func (*ProjectUpdate) ClearSites

func (pu *ProjectUpdate) ClearSites() *ProjectUpdate

ClearSites clears all "sites" edges to the Site entity.

func (*ProjectUpdate) ClearTechnologies

func (pu *ProjectUpdate) ClearTechnologies() *ProjectUpdate

ClearTechnologies clears all "technologies" edges to the ProjectTechnology entity.

func (*ProjectUpdate) Exec

func (pu *ProjectUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*ProjectUpdate) ExecX

func (pu *ProjectUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectUpdate) Mutation

func (pu *ProjectUpdate) Mutation() *ProjectMutation

Mutation returns the ProjectMutation object of the builder.

func (*ProjectUpdate) RemoveChildProjectIDs

func (pu *ProjectUpdate) RemoveChildProjectIDs(ids ...int) *ProjectUpdate

RemoveChildProjectIDs removes the "child_projects" edge to ProjectAssociation entities by IDs.

func (*ProjectUpdate) RemoveChildProjects

func (pu *ProjectUpdate) RemoveChildProjects(p ...*ProjectAssociation) *ProjectUpdate

RemoveChildProjects removes "child_projects" edges to ProjectAssociation entities.

func (*ProjectUpdate) RemoveContributorIDs

func (pu *ProjectUpdate) RemoveContributorIDs(ids ...int) *ProjectUpdate

RemoveContributorIDs removes the "contributors" edge to ProjectContributor entities by IDs.

func (*ProjectUpdate) RemoveContributors

func (pu *ProjectUpdate) RemoveContributors(p ...*ProjectContributor) *ProjectUpdate

RemoveContributors removes "contributors" edges to ProjectContributor entities.

func (*ProjectUpdate) RemoveDiscordBotIDs

func (pu *ProjectUpdate) RemoveDiscordBotIDs(ids ...int) *ProjectUpdate

RemoveDiscordBotIDs removes the "discord_bots" edge to DiscordBot entities by IDs.

func (*ProjectUpdate) RemoveDiscordBots

func (pu *ProjectUpdate) RemoveDiscordBots(d ...*DiscordBot) *ProjectUpdate

RemoveDiscordBots removes "discord_bots" edges to DiscordBot entities.

func (*ProjectUpdate) RemoveParentProjectIDs

func (pu *ProjectUpdate) RemoveParentProjectIDs(ids ...int) *ProjectUpdate

RemoveParentProjectIDs removes the "parent_projects" edge to ProjectAssociation entities by IDs.

func (*ProjectUpdate) RemoveParentProjects

func (pu *ProjectUpdate) RemoveParentProjects(p ...*ProjectAssociation) *ProjectUpdate

RemoveParentProjects removes "parent_projects" edges to ProjectAssociation entities.

func (*ProjectUpdate) RemoveRepositories

func (pu *ProjectUpdate) RemoveRepositories(r ...*Repository) *ProjectUpdate

RemoveRepositories removes "repositories" edges to Repository entities.

func (*ProjectUpdate) RemoveRepositoryIDs

func (pu *ProjectUpdate) RemoveRepositoryIDs(ids ...int) *ProjectUpdate

RemoveRepositoryIDs removes the "repositories" edge to Repository entities by IDs.

func (*ProjectUpdate) RemoveSiteIDs

func (pu *ProjectUpdate) RemoveSiteIDs(ids ...int) *ProjectUpdate

RemoveSiteIDs removes the "sites" edge to Site entities by IDs.

func (*ProjectUpdate) RemoveSites

func (pu *ProjectUpdate) RemoveSites(s ...*Site) *ProjectUpdate

RemoveSites removes "sites" edges to Site entities.

func (*ProjectUpdate) RemoveTechnologies

func (pu *ProjectUpdate) RemoveTechnologies(p ...*ProjectTechnology) *ProjectUpdate

RemoveTechnologies removes "technologies" edges to ProjectTechnology entities.

func (*ProjectUpdate) RemoveTechnologyIDs

func (pu *ProjectUpdate) RemoveTechnologyIDs(ids ...int) *ProjectUpdate

RemoveTechnologyIDs removes the "technologies" edge to ProjectTechnology entities by IDs.

func (*ProjectUpdate) Save

func (pu *ProjectUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*ProjectUpdate) SaveX

func (pu *ProjectUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*ProjectUpdate) SetDescription

func (pu *ProjectUpdate) SetDescription(s string) *ProjectUpdate

SetDescription sets the "description" field.

func (*ProjectUpdate) SetEndDate

func (pu *ProjectUpdate) SetEndDate(t time.Time) *ProjectUpdate

SetEndDate sets the "end_date" field.

func (*ProjectUpdate) SetInput

SetInput applies the change-set in the UpdateProjectInput on the update builder.

func (*ProjectUpdate) SetName

func (pu *ProjectUpdate) SetName(s string) *ProjectUpdate

SetName sets the "name" field.

func (*ProjectUpdate) SetNillableDescription

func (pu *ProjectUpdate) SetNillableDescription(s *string) *ProjectUpdate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*ProjectUpdate) SetNillableEndDate

func (pu *ProjectUpdate) SetNillableEndDate(t *time.Time) *ProjectUpdate

SetNillableEndDate sets the "end_date" field if the given value is not nil.

func (*ProjectUpdate) SetStartDate

func (pu *ProjectUpdate) SetStartDate(t time.Time) *ProjectUpdate

SetStartDate sets the "start_date" field.

func (*ProjectUpdate) Where

func (pu *ProjectUpdate) Where(ps ...predicate.Project) *ProjectUpdate

Where appends a list predicates to the ProjectUpdate builder.

type ProjectUpdateOne

type ProjectUpdateOne struct {
	// contains filtered or unexported fields
}

ProjectUpdateOne is the builder for updating a single Project entity.

func (*ProjectUpdateOne) AddChildProjectIDs

func (puo *ProjectUpdateOne) AddChildProjectIDs(ids ...int) *ProjectUpdateOne

AddChildProjectIDs adds the "child_projects" edge to the ProjectAssociation entity by IDs.

func (*ProjectUpdateOne) AddChildProjects

func (puo *ProjectUpdateOne) AddChildProjects(p ...*ProjectAssociation) *ProjectUpdateOne

AddChildProjects adds the "child_projects" edges to the ProjectAssociation entity.

func (*ProjectUpdateOne) AddContributorIDs

func (puo *ProjectUpdateOne) AddContributorIDs(ids ...int) *ProjectUpdateOne

AddContributorIDs adds the "contributors" edge to the ProjectContributor entity by IDs.

func (*ProjectUpdateOne) AddContributors

func (puo *ProjectUpdateOne) AddContributors(p ...*ProjectContributor) *ProjectUpdateOne

AddContributors adds the "contributors" edges to the ProjectContributor entity.

func (*ProjectUpdateOne) AddDiscordBotIDs

func (puo *ProjectUpdateOne) AddDiscordBotIDs(ids ...int) *ProjectUpdateOne

AddDiscordBotIDs adds the "discord_bots" edge to the DiscordBot entity by IDs.

func (*ProjectUpdateOne) AddDiscordBots

func (puo *ProjectUpdateOne) AddDiscordBots(d ...*DiscordBot) *ProjectUpdateOne

AddDiscordBots adds the "discord_bots" edges to the DiscordBot entity.

func (*ProjectUpdateOne) AddParentProjectIDs

func (puo *ProjectUpdateOne) AddParentProjectIDs(ids ...int) *ProjectUpdateOne

AddParentProjectIDs adds the "parent_projects" edge to the ProjectAssociation entity by IDs.

func (*ProjectUpdateOne) AddParentProjects

func (puo *ProjectUpdateOne) AddParentProjects(p ...*ProjectAssociation) *ProjectUpdateOne

AddParentProjects adds the "parent_projects" edges to the ProjectAssociation entity.

func (*ProjectUpdateOne) AddRepositories

func (puo *ProjectUpdateOne) AddRepositories(r ...*Repository) *ProjectUpdateOne

AddRepositories adds the "repositories" edges to the Repository entity.

func (*ProjectUpdateOne) AddRepositoryIDs

func (puo *ProjectUpdateOne) AddRepositoryIDs(ids ...int) *ProjectUpdateOne

AddRepositoryIDs adds the "repositories" edge to the Repository entity by IDs.

func (*ProjectUpdateOne) AddSiteIDs

func (puo *ProjectUpdateOne) AddSiteIDs(ids ...int) *ProjectUpdateOne

AddSiteIDs adds the "sites" edge to the Site entity by IDs.

func (*ProjectUpdateOne) AddSites

func (puo *ProjectUpdateOne) AddSites(s ...*Site) *ProjectUpdateOne

AddSites adds the "sites" edges to the Site entity.

func (*ProjectUpdateOne) AddTechnologies

func (puo *ProjectUpdateOne) AddTechnologies(p ...*ProjectTechnology) *ProjectUpdateOne

AddTechnologies adds the "technologies" edges to the ProjectTechnology entity.

func (*ProjectUpdateOne) AddTechnologyIDs

func (puo *ProjectUpdateOne) AddTechnologyIDs(ids ...int) *ProjectUpdateOne

AddTechnologyIDs adds the "technologies" edge to the ProjectTechnology entity by IDs.

func (*ProjectUpdateOne) ClearChildProjects

func (puo *ProjectUpdateOne) ClearChildProjects() *ProjectUpdateOne

ClearChildProjects clears all "child_projects" edges to the ProjectAssociation entity.

func (*ProjectUpdateOne) ClearContributors

func (puo *ProjectUpdateOne) ClearContributors() *ProjectUpdateOne

ClearContributors clears all "contributors" edges to the ProjectContributor entity.

func (*ProjectUpdateOne) ClearDescription

func (puo *ProjectUpdateOne) ClearDescription() *ProjectUpdateOne

ClearDescription clears the value of the "description" field.

func (*ProjectUpdateOne) ClearDiscordBots

func (puo *ProjectUpdateOne) ClearDiscordBots() *ProjectUpdateOne

ClearDiscordBots clears all "discord_bots" edges to the DiscordBot entity.

func (*ProjectUpdateOne) ClearEndDate

func (puo *ProjectUpdateOne) ClearEndDate() *ProjectUpdateOne

ClearEndDate clears the value of the "end_date" field.

func (*ProjectUpdateOne) ClearParentProjects

func (puo *ProjectUpdateOne) ClearParentProjects() *ProjectUpdateOne

ClearParentProjects clears all "parent_projects" edges to the ProjectAssociation entity.

func (*ProjectUpdateOne) ClearRepositories

func (puo *ProjectUpdateOne) ClearRepositories() *ProjectUpdateOne

ClearRepositories clears all "repositories" edges to the Repository entity.

func (*ProjectUpdateOne) ClearSites

func (puo *ProjectUpdateOne) ClearSites() *ProjectUpdateOne

ClearSites clears all "sites" edges to the Site entity.

func (*ProjectUpdateOne) ClearTechnologies

func (puo *ProjectUpdateOne) ClearTechnologies() *ProjectUpdateOne

ClearTechnologies clears all "technologies" edges to the ProjectTechnology entity.

func (*ProjectUpdateOne) Exec

func (puo *ProjectUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*ProjectUpdateOne) ExecX

func (puo *ProjectUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProjectUpdateOne) Mutation

func (puo *ProjectUpdateOne) Mutation() *ProjectMutation

Mutation returns the ProjectMutation object of the builder.

func (*ProjectUpdateOne) RemoveChildProjectIDs

func (puo *ProjectUpdateOne) RemoveChildProjectIDs(ids ...int) *ProjectUpdateOne

RemoveChildProjectIDs removes the "child_projects" edge to ProjectAssociation entities by IDs.

func (*ProjectUpdateOne) RemoveChildProjects

func (puo *ProjectUpdateOne) RemoveChildProjects(p ...*ProjectAssociation) *ProjectUpdateOne

RemoveChildProjects removes "child_projects" edges to ProjectAssociation entities.

func (*ProjectUpdateOne) RemoveContributorIDs

func (puo *ProjectUpdateOne) RemoveContributorIDs(ids ...int) *ProjectUpdateOne

RemoveContributorIDs removes the "contributors" edge to ProjectContributor entities by IDs.

func (*ProjectUpdateOne) RemoveContributors

func (puo *ProjectUpdateOne) RemoveContributors(p ...*ProjectContributor) *ProjectUpdateOne

RemoveContributors removes "contributors" edges to ProjectContributor entities.

func (*ProjectUpdateOne) RemoveDiscordBotIDs

func (puo *ProjectUpdateOne) RemoveDiscordBotIDs(ids ...int) *ProjectUpdateOne

RemoveDiscordBotIDs removes the "discord_bots" edge to DiscordBot entities by IDs.

func (*ProjectUpdateOne) RemoveDiscordBots

func (puo *ProjectUpdateOne) RemoveDiscordBots(d ...*DiscordBot) *ProjectUpdateOne

RemoveDiscordBots removes "discord_bots" edges to DiscordBot entities.

func (*ProjectUpdateOne) RemoveParentProjectIDs

func (puo *ProjectUpdateOne) RemoveParentProjectIDs(ids ...int) *ProjectUpdateOne

RemoveParentProjectIDs removes the "parent_projects" edge to ProjectAssociation entities by IDs.

func (*ProjectUpdateOne) RemoveParentProjects

func (puo *ProjectUpdateOne) RemoveParentProjects(p ...*ProjectAssociation) *ProjectUpdateOne

RemoveParentProjects removes "parent_projects" edges to ProjectAssociation entities.

func (*ProjectUpdateOne) RemoveRepositories

func (puo *ProjectUpdateOne) RemoveRepositories(r ...*Repository) *ProjectUpdateOne

RemoveRepositories removes "repositories" edges to Repository entities.

func (*ProjectUpdateOne) RemoveRepositoryIDs

func (puo *ProjectUpdateOne) RemoveRepositoryIDs(ids ...int) *ProjectUpdateOne

RemoveRepositoryIDs removes the "repositories" edge to Repository entities by IDs.

func (*ProjectUpdateOne) RemoveSiteIDs

func (puo *ProjectUpdateOne) RemoveSiteIDs(ids ...int) *ProjectUpdateOne

RemoveSiteIDs removes the "sites" edge to Site entities by IDs.

func (*ProjectUpdateOne) RemoveSites

func (puo *ProjectUpdateOne) RemoveSites(s ...*Site) *ProjectUpdateOne

RemoveSites removes "sites" edges to Site entities.

func (*ProjectUpdateOne) RemoveTechnologies

func (puo *ProjectUpdateOne) RemoveTechnologies(p ...*ProjectTechnology) *ProjectUpdateOne

RemoveTechnologies removes "technologies" edges to ProjectTechnology entities.

func (*ProjectUpdateOne) RemoveTechnologyIDs

func (puo *ProjectUpdateOne) RemoveTechnologyIDs(ids ...int) *ProjectUpdateOne

RemoveTechnologyIDs removes the "technologies" edge to ProjectTechnology entities by IDs.

func (*ProjectUpdateOne) Save

func (puo *ProjectUpdateOne) Save(ctx context.Context) (*Project, error)

Save executes the query and returns the updated Project entity.

func (*ProjectUpdateOne) SaveX

func (puo *ProjectUpdateOne) SaveX(ctx context.Context) *Project

SaveX is like Save, but panics if an error occurs.

func (*ProjectUpdateOne) Select

func (puo *ProjectUpdateOne) Select(field string, fields ...string) *ProjectUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*ProjectUpdateOne) SetDescription

func (puo *ProjectUpdateOne) SetDescription(s string) *ProjectUpdateOne

SetDescription sets the "description" field.

func (*ProjectUpdateOne) SetEndDate

func (puo *ProjectUpdateOne) SetEndDate(t time.Time) *ProjectUpdateOne

SetEndDate sets the "end_date" field.

func (*ProjectUpdateOne) SetInput

SetInput applies the change-set in the UpdateProjectInput on the update-one builder.

func (*ProjectUpdateOne) SetName

func (puo *ProjectUpdateOne) SetName(s string) *ProjectUpdateOne

SetName sets the "name" field.

func (*ProjectUpdateOne) SetNillableDescription

func (puo *ProjectUpdateOne) SetNillableDescription(s *string) *ProjectUpdateOne

SetNillableDescription sets the "description" field if the given value is not nil.

func (*ProjectUpdateOne) SetNillableEndDate

func (puo *ProjectUpdateOne) SetNillableEndDate(t *time.Time) *ProjectUpdateOne

SetNillableEndDate sets the "end_date" field if the given value is not nil.

func (*ProjectUpdateOne) SetStartDate

func (puo *ProjectUpdateOne) SetStartDate(t time.Time) *ProjectUpdateOne

SetStartDate sets the "start_date" field.

type ProjectWhereInput

type ProjectWhereInput struct {
	Predicates []predicate.Project  `json:"-"`
	Not        *ProjectWhereInput   `json:"not,omitempty"`
	Or         []*ProjectWhereInput `json:"or,omitempty"`
	And        []*ProjectWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "name" field predicates.
	Name             *string  `json:"name,omitempty"`
	NameNEQ          *string  `json:"nameNEQ,omitempty"`
	NameIn           []string `json:"nameIn,omitempty"`
	NameNotIn        []string `json:"nameNotIn,omitempty"`
	NameGT           *string  `json:"nameGT,omitempty"`
	NameGTE          *string  `json:"nameGTE,omitempty"`
	NameLT           *string  `json:"nameLT,omitempty"`
	NameLTE          *string  `json:"nameLTE,omitempty"`
	NameContains     *string  `json:"nameContains,omitempty"`
	NameHasPrefix    *string  `json:"nameHasPrefix,omitempty"`
	NameHasSuffix    *string  `json:"nameHasSuffix,omitempty"`
	NameEqualFold    *string  `json:"nameEqualFold,omitempty"`
	NameContainsFold *string  `json:"nameContainsFold,omitempty"`

	// "description" field predicates.
	Description             *string  `json:"description,omitempty"`
	DescriptionNEQ          *string  `json:"descriptionNEQ,omitempty"`
	DescriptionIn           []string `json:"descriptionIn,omitempty"`
	DescriptionNotIn        []string `json:"descriptionNotIn,omitempty"`
	DescriptionGT           *string  `json:"descriptionGT,omitempty"`
	DescriptionGTE          *string  `json:"descriptionGTE,omitempty"`
	DescriptionLT           *string  `json:"descriptionLT,omitempty"`
	DescriptionLTE          *string  `json:"descriptionLTE,omitempty"`
	DescriptionContains     *string  `json:"descriptionContains,omitempty"`
	DescriptionHasPrefix    *string  `json:"descriptionHasPrefix,omitempty"`
	DescriptionHasSuffix    *string  `json:"descriptionHasSuffix,omitempty"`
	DescriptionIsNil        bool     `json:"descriptionIsNil,omitempty"`
	DescriptionNotNil       bool     `json:"descriptionNotNil,omitempty"`
	DescriptionEqualFold    *string  `json:"descriptionEqualFold,omitempty"`
	DescriptionContainsFold *string  `json:"descriptionContainsFold,omitempty"`

	// "start_date" field predicates.
	StartDate      *time.Time  `json:"startDate,omitempty"`
	StartDateNEQ   *time.Time  `json:"startDateNEQ,omitempty"`
	StartDateIn    []time.Time `json:"startDateIn,omitempty"`
	StartDateNotIn []time.Time `json:"startDateNotIn,omitempty"`
	StartDateGT    *time.Time  `json:"startDateGT,omitempty"`
	StartDateGTE   *time.Time  `json:"startDateGTE,omitempty"`
	StartDateLT    *time.Time  `json:"startDateLT,omitempty"`
	StartDateLTE   *time.Time  `json:"startDateLTE,omitempty"`

	// "end_date" field predicates.
	EndDate       *time.Time  `json:"endDate,omitempty"`
	EndDateNEQ    *time.Time  `json:"endDateNEQ,omitempty"`
	EndDateIn     []time.Time `json:"endDateIn,omitempty"`
	EndDateNotIn  []time.Time `json:"endDateNotIn,omitempty"`
	EndDateGT     *time.Time  `json:"endDateGT,omitempty"`
	EndDateGTE    *time.Time  `json:"endDateGTE,omitempty"`
	EndDateLT     *time.Time  `json:"endDateLT,omitempty"`
	EndDateLTE    *time.Time  `json:"endDateLTE,omitempty"`
	EndDateIsNil  bool        `json:"endDateIsNil,omitempty"`
	EndDateNotNil bool        `json:"endDateNotNil,omitempty"`

	// "contributors" edge predicates.
	HasContributors     *bool                           `json:"hasContributors,omitempty"`
	HasContributorsWith []*ProjectContributorWhereInput `json:"hasContributorsWith,omitempty"`

	// "parent_projects" edge predicates.
	HasParentProjects     *bool                           `json:"hasParentProjects,omitempty"`
	HasParentProjectsWith []*ProjectAssociationWhereInput `json:"hasParentProjectsWith,omitempty"`

	// "child_projects" edge predicates.
	HasChildProjects     *bool                           `json:"hasChildProjects,omitempty"`
	HasChildProjectsWith []*ProjectAssociationWhereInput `json:"hasChildProjectsWith,omitempty"`

	// "repositories" edge predicates.
	HasRepositories     *bool                   `json:"hasRepositories,omitempty"`
	HasRepositoriesWith []*RepositoryWhereInput `json:"hasRepositoriesWith,omitempty"`

	// "discord_bots" edge predicates.
	HasDiscordBots     *bool                   `json:"hasDiscordBots,omitempty"`
	HasDiscordBotsWith []*DiscordBotWhereInput `json:"hasDiscordBotsWith,omitempty"`

	// "sites" edge predicates.
	HasSites     *bool             `json:"hasSites,omitempty"`
	HasSitesWith []*SiteWhereInput `json:"hasSitesWith,omitempty"`

	// "technologies" edge predicates.
	HasTechnologies     *bool                          `json:"hasTechnologies,omitempty"`
	HasTechnologiesWith []*ProjectTechnologyWhereInput `json:"hasTechnologiesWith,omitempty"`
}

ProjectWhereInput represents a where input for filtering Project queries.

func (*ProjectWhereInput) AddPredicates

func (i *ProjectWhereInput) AddPredicates(predicates ...predicate.Project)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*ProjectWhereInput) Filter

Filter applies the ProjectWhereInput filter on the ProjectQuery builder.

func (*ProjectWhereInput) P

P returns a predicate for filtering projects. An error is returned if the input is empty or invalid.

type Projects

type Projects []*Project

Projects is a parsable slice of Project.

type Query

type Query = ent.Query

ent aliases to avoid import conflicts in user's code.

type Repositories

type Repositories []*Repository

Repositories is a parsable slice of Repository.

type Repository

type Repository struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Name holds the value of the "name" field.
	Name string `json:"name,omitempty"`
	// Description holds the value of the "description" field.
	Description *string `json:"description,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the RepositoryQuery when eager-loading is set.
	Edges RepositoryEdges `json:"edges"`
	// contains filtered or unexported fields
}

Repository is the model entity for the Repository schema.

func (*Repository) DiscordBots

func (r *Repository) DiscordBots(ctx context.Context) ([]*DiscordBot, error)

func (*Repository) GithubAccount

func (r *Repository) GithubAccount(ctx context.Context) (*GithubAccount, error)

func (*Repository) GithubOrganization

func (r *Repository) GithubOrganization(ctx context.Context) (*GithubOrganization, error)

func (*Repository) NamedDiscordBots

func (r *Repository) NamedDiscordBots(name string) ([]*DiscordBot, error)

NamedDiscordBots returns the DiscordBots named value or an error if the edge was not loaded in eager-loading with this name.

func (*Repository) NamedSites

func (r *Repository) NamedSites(name string) ([]*Site, error)

NamedSites returns the Sites named value or an error if the edge was not loaded in eager-loading with this name.

func (*Repository) NamedTechnologies

func (r *Repository) NamedTechnologies(name string) ([]*RepositoryTechnology, error)

NamedTechnologies returns the Technologies named value or an error if the edge was not loaded in eager-loading with this name.

func (*Repository) Node

func (r *Repository) Node(ctx context.Context) (node *Node, err error)

func (*Repository) Project

func (r *Repository) Project(ctx context.Context) (*Project, error)

func (*Repository) QueryDiscordBots

func (r *Repository) QueryDiscordBots() *DiscordBotQuery

QueryDiscordBots queries the "discord_bots" edge of the Repository entity.

func (*Repository) QueryGithubAccount

func (r *Repository) QueryGithubAccount() *GithubAccountQuery

QueryGithubAccount queries the "github_account" edge of the Repository entity.

func (*Repository) QueryGithubOrganization

func (r *Repository) QueryGithubOrganization() *GithubOrganizationQuery

QueryGithubOrganization queries the "github_organization" edge of the Repository entity.

func (*Repository) QueryProject

func (r *Repository) QueryProject() *ProjectQuery

QueryProject queries the "project" edge of the Repository entity.

func (*Repository) QuerySites

func (r *Repository) QuerySites() *SiteQuery

QuerySites queries the "sites" edge of the Repository entity.

func (*Repository) QueryTechnologies

func (r *Repository) QueryTechnologies() *RepositoryTechnologyQuery

QueryTechnologies queries the "technologies" edge of the Repository entity.

func (*Repository) Sites

func (r *Repository) Sites(ctx context.Context) ([]*Site, error)

func (*Repository) String

func (r *Repository) String() string

String implements the fmt.Stringer.

func (*Repository) Technologies

func (r *Repository) Technologies(ctx context.Context) ([]*RepositoryTechnology, error)

func (*Repository) ToEdge

func (r *Repository) ToEdge(order *RepositoryOrder) *RepositoryEdge

ToEdge converts Repository into RepositoryEdge.

func (*Repository) Unwrap

func (r *Repository) Unwrap() *Repository

Unwrap unwraps the Repository entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*Repository) Update

func (r *Repository) Update() *RepositoryUpdateOne

Update returns a builder for updating this Repository. Note that you need to call Repository.Unwrap() before calling this method if this Repository was returned from a transaction, and the transaction was committed or rolled back.

type RepositoryClient

type RepositoryClient struct {
	// contains filtered or unexported fields
}

RepositoryClient is a client for the Repository schema.

func NewRepositoryClient

func NewRepositoryClient(c config) *RepositoryClient

NewRepositoryClient returns a client for the Repository from the given config.

func (*RepositoryClient) Create

func (c *RepositoryClient) Create() *RepositoryCreate

Create returns a builder for creating a Repository entity.

func (*RepositoryClient) CreateBulk

func (c *RepositoryClient) CreateBulk(builders ...*RepositoryCreate) *RepositoryCreateBulk

CreateBulk returns a builder for creating a bulk of Repository entities.

func (*RepositoryClient) Delete

func (c *RepositoryClient) Delete() *RepositoryDelete

Delete returns a delete builder for Repository.

func (*RepositoryClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*RepositoryClient) DeleteOneID

func (c *RepositoryClient) DeleteOneID(id int) *RepositoryDeleteOne

DeleteOne returns a builder for deleting the given entity by its id.

func (*RepositoryClient) Get

func (c *RepositoryClient) Get(ctx context.Context, id int) (*Repository, error)

Get returns a Repository entity by its id.

func (*RepositoryClient) GetX

func (c *RepositoryClient) GetX(ctx context.Context, id int) *Repository

GetX is like Get, but panics if an error occurs.

func (*RepositoryClient) Hooks

func (c *RepositoryClient) Hooks() []Hook

Hooks returns the client hooks.

func (*RepositoryClient) Query

func (c *RepositoryClient) Query() *RepositoryQuery

Query returns a query builder for Repository.

func (*RepositoryClient) QueryDiscordBots

func (c *RepositoryClient) QueryDiscordBots(r *Repository) *DiscordBotQuery

QueryDiscordBots queries the discord_bots edge of a Repository.

func (*RepositoryClient) QueryGithubAccount

func (c *RepositoryClient) QueryGithubAccount(r *Repository) *GithubAccountQuery

QueryGithubAccount queries the github_account edge of a Repository.

func (*RepositoryClient) QueryGithubOrganization

func (c *RepositoryClient) QueryGithubOrganization(r *Repository) *GithubOrganizationQuery

QueryGithubOrganization queries the github_organization edge of a Repository.

func (*RepositoryClient) QueryProject

func (c *RepositoryClient) QueryProject(r *Repository) *ProjectQuery

QueryProject queries the project edge of a Repository.

func (*RepositoryClient) QuerySites

func (c *RepositoryClient) QuerySites(r *Repository) *SiteQuery

QuerySites queries the sites edge of a Repository.

func (*RepositoryClient) QueryTechnologies

func (c *RepositoryClient) QueryTechnologies(r *Repository) *RepositoryTechnologyQuery

QueryTechnologies queries the technologies edge of a Repository.

func (*RepositoryClient) Update

func (c *RepositoryClient) Update() *RepositoryUpdate

Update returns an update builder for Repository.

func (*RepositoryClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*RepositoryClient) UpdateOneID

func (c *RepositoryClient) UpdateOneID(id int) *RepositoryUpdateOne

UpdateOneID returns an update builder for the given id.

func (*RepositoryClient) Use

func (c *RepositoryClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `repository.Hooks(f(g(h())))`.

type RepositoryConnection

type RepositoryConnection struct {
	Edges      []*RepositoryEdge `json:"edges"`
	PageInfo   PageInfo          `json:"pageInfo"`
	TotalCount int               `json:"totalCount"`
}

RepositoryConnection is the connection containing edges to Repository.

type RepositoryCreate

type RepositoryCreate struct {
	// contains filtered or unexported fields
}

RepositoryCreate is the builder for creating a Repository entity.

func (*RepositoryCreate) AddDiscordBotIDs

func (rc *RepositoryCreate) AddDiscordBotIDs(ids ...int) *RepositoryCreate

AddDiscordBotIDs adds the "discord_bots" edge to the DiscordBot entity by IDs.

func (*RepositoryCreate) AddDiscordBots

func (rc *RepositoryCreate) AddDiscordBots(d ...*DiscordBot) *RepositoryCreate

AddDiscordBots adds the "discord_bots" edges to the DiscordBot entity.

func (*RepositoryCreate) AddSiteIDs

func (rc *RepositoryCreate) AddSiteIDs(ids ...int) *RepositoryCreate

AddSiteIDs adds the "sites" edge to the Site entity by IDs.

func (*RepositoryCreate) AddSites

func (rc *RepositoryCreate) AddSites(s ...*Site) *RepositoryCreate

AddSites adds the "sites" edges to the Site entity.

func (*RepositoryCreate) AddTechnologies

func (rc *RepositoryCreate) AddTechnologies(r ...*RepositoryTechnology) *RepositoryCreate

AddTechnologies adds the "technologies" edges to the RepositoryTechnology entity.

func (*RepositoryCreate) AddTechnologyIDs

func (rc *RepositoryCreate) AddTechnologyIDs(ids ...int) *RepositoryCreate

AddTechnologyIDs adds the "technologies" edge to the RepositoryTechnology entity by IDs.

func (*RepositoryCreate) Exec

func (rc *RepositoryCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*RepositoryCreate) ExecX

func (rc *RepositoryCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryCreate) Mutation

func (rc *RepositoryCreate) Mutation() *RepositoryMutation

Mutation returns the RepositoryMutation object of the builder.

func (*RepositoryCreate) Save

func (rc *RepositoryCreate) Save(ctx context.Context) (*Repository, error)

Save creates the Repository in the database.

func (*RepositoryCreate) SaveX

func (rc *RepositoryCreate) SaveX(ctx context.Context) *Repository

SaveX calls Save and panics if Save returns an error.

func (*RepositoryCreate) SetDescription

func (rc *RepositoryCreate) SetDescription(s string) *RepositoryCreate

SetDescription sets the "description" field.

func (*RepositoryCreate) SetGithubAccount

func (rc *RepositoryCreate) SetGithubAccount(g *GithubAccount) *RepositoryCreate

SetGithubAccount sets the "github_account" edge to the GithubAccount entity.

func (*RepositoryCreate) SetGithubAccountID

func (rc *RepositoryCreate) SetGithubAccountID(id int) *RepositoryCreate

SetGithubAccountID sets the "github_account" edge to the GithubAccount entity by ID.

func (*RepositoryCreate) SetGithubOrganization

func (rc *RepositoryCreate) SetGithubOrganization(g *GithubOrganization) *RepositoryCreate

SetGithubOrganization sets the "github_organization" edge to the GithubOrganization entity.

func (*RepositoryCreate) SetGithubOrganizationID

func (rc *RepositoryCreate) SetGithubOrganizationID(id int) *RepositoryCreate

SetGithubOrganizationID sets the "github_organization" edge to the GithubOrganization entity by ID.

func (*RepositoryCreate) SetInput

SetInput applies the change-set in the CreateRepositoryInput on the create builder.

func (*RepositoryCreate) SetName

func (rc *RepositoryCreate) SetName(s string) *RepositoryCreate

SetName sets the "name" field.

func (*RepositoryCreate) SetNillableDescription

func (rc *RepositoryCreate) SetNillableDescription(s *string) *RepositoryCreate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*RepositoryCreate) SetNillableGithubAccountID

func (rc *RepositoryCreate) SetNillableGithubAccountID(id *int) *RepositoryCreate

SetNillableGithubAccountID sets the "github_account" edge to the GithubAccount entity by ID if the given value is not nil.

func (*RepositoryCreate) SetNillableGithubOrganizationID

func (rc *RepositoryCreate) SetNillableGithubOrganizationID(id *int) *RepositoryCreate

SetNillableGithubOrganizationID sets the "github_organization" edge to the GithubOrganization entity by ID if the given value is not nil.

func (*RepositoryCreate) SetProject

func (rc *RepositoryCreate) SetProject(p *Project) *RepositoryCreate

SetProject sets the "project" edge to the Project entity.

func (*RepositoryCreate) SetProjectID

func (rc *RepositoryCreate) SetProjectID(id int) *RepositoryCreate

SetProjectID sets the "project" edge to the Project entity by ID.

type RepositoryCreateBulk

type RepositoryCreateBulk struct {
	// contains filtered or unexported fields
}

RepositoryCreateBulk is the builder for creating many Repository entities in bulk.

func (*RepositoryCreateBulk) Exec

func (rcb *RepositoryCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*RepositoryCreateBulk) ExecX

func (rcb *RepositoryCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryCreateBulk) Save

func (rcb *RepositoryCreateBulk) Save(ctx context.Context) ([]*Repository, error)

Save creates the Repository entities in the database.

func (*RepositoryCreateBulk) SaveX

func (rcb *RepositoryCreateBulk) SaveX(ctx context.Context) []*Repository

SaveX is like Save, but panics if an error occurs.

type RepositoryDelete

type RepositoryDelete struct {
	// contains filtered or unexported fields
}

RepositoryDelete is the builder for deleting a Repository entity.

func (*RepositoryDelete) Exec

func (rd *RepositoryDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*RepositoryDelete) ExecX

func (rd *RepositoryDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryDelete) Where

Where appends a list predicates to the RepositoryDelete builder.

type RepositoryDeleteOne

type RepositoryDeleteOne struct {
	// contains filtered or unexported fields
}

RepositoryDeleteOne is the builder for deleting a single Repository entity.

func (*RepositoryDeleteOne) Exec

func (rdo *RepositoryDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*RepositoryDeleteOne) ExecX

func (rdo *RepositoryDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

type RepositoryEdge

type RepositoryEdge struct {
	Node   *Repository `json:"node"`
	Cursor Cursor      `json:"cursor"`
}

RepositoryEdge is the edge representation of Repository.

type RepositoryEdges

type RepositoryEdges struct {
	// Project holds the value of the project edge.
	Project *Project `json:"project,omitempty"`
	// GithubAccount holds the value of the github_account edge.
	GithubAccount *GithubAccount `json:"github_account,omitempty"`
	// GithubOrganization holds the value of the github_organization edge.
	GithubOrganization *GithubOrganization `json:"github_organization,omitempty"`
	// DiscordBots holds the value of the discord_bots edge.
	DiscordBots []*DiscordBot `json:"discord_bots,omitempty"`
	// Sites holds the value of the sites edge.
	Sites []*Site `json:"sites,omitempty"`
	// Technologies holds the value of the technologies edge.
	Technologies []*RepositoryTechnology `json:"technologies,omitempty"`
	// contains filtered or unexported fields
}

RepositoryEdges holds the relations/edges for other nodes in the graph.

func (RepositoryEdges) DiscordBotsOrErr

func (e RepositoryEdges) DiscordBotsOrErr() ([]*DiscordBot, error)

DiscordBotsOrErr returns the DiscordBots value or an error if the edge was not loaded in eager-loading.

func (RepositoryEdges) GithubAccountOrErr

func (e RepositoryEdges) GithubAccountOrErr() (*GithubAccount, error)

GithubAccountOrErr returns the GithubAccount value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (RepositoryEdges) GithubOrganizationOrErr

func (e RepositoryEdges) GithubOrganizationOrErr() (*GithubOrganization, error)

GithubOrganizationOrErr returns the GithubOrganization value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (RepositoryEdges) ProjectOrErr

func (e RepositoryEdges) ProjectOrErr() (*Project, error)

ProjectOrErr returns the Project value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (RepositoryEdges) SitesOrErr

func (e RepositoryEdges) SitesOrErr() ([]*Site, error)

SitesOrErr returns the Sites value or an error if the edge was not loaded in eager-loading.

func (RepositoryEdges) TechnologiesOrErr

func (e RepositoryEdges) TechnologiesOrErr() ([]*RepositoryTechnology, error)

TechnologiesOrErr returns the Technologies value or an error if the edge was not loaded in eager-loading.

type RepositoryGroupBy

type RepositoryGroupBy struct {
	// contains filtered or unexported fields
}

RepositoryGroupBy is the group-by builder for Repository entities.

func (*RepositoryGroupBy) Aggregate

func (rgb *RepositoryGroupBy) Aggregate(fns ...AggregateFunc) *RepositoryGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*RepositoryGroupBy) Bool

func (s *RepositoryGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*RepositoryGroupBy) BoolX

func (s *RepositoryGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*RepositoryGroupBy) Bools

func (s *RepositoryGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*RepositoryGroupBy) BoolsX

func (s *RepositoryGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*RepositoryGroupBy) Float64

func (s *RepositoryGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*RepositoryGroupBy) Float64X

func (s *RepositoryGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*RepositoryGroupBy) Float64s

func (s *RepositoryGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*RepositoryGroupBy) Float64sX

func (s *RepositoryGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*RepositoryGroupBy) Int

func (s *RepositoryGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*RepositoryGroupBy) IntX

func (s *RepositoryGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*RepositoryGroupBy) Ints

func (s *RepositoryGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*RepositoryGroupBy) IntsX

func (s *RepositoryGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*RepositoryGroupBy) Scan

func (rgb *RepositoryGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*RepositoryGroupBy) ScanX

func (s *RepositoryGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*RepositoryGroupBy) String

func (s *RepositoryGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*RepositoryGroupBy) StringX

func (s *RepositoryGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*RepositoryGroupBy) Strings

func (s *RepositoryGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*RepositoryGroupBy) StringsX

func (s *RepositoryGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type RepositoryMutation

type RepositoryMutation struct {
	// contains filtered or unexported fields
}

RepositoryMutation represents an operation that mutates the Repository nodes in the graph.

func (*RepositoryMutation) AddDiscordBotIDs

func (m *RepositoryMutation) AddDiscordBotIDs(ids ...int)

AddDiscordBotIDs adds the "discord_bots" edge to the DiscordBot entity by ids.

func (*RepositoryMutation) AddField

func (m *RepositoryMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*RepositoryMutation) AddSiteIDs

func (m *RepositoryMutation) AddSiteIDs(ids ...int)

AddSiteIDs adds the "sites" edge to the Site entity by ids.

func (*RepositoryMutation) AddTechnologyIDs

func (m *RepositoryMutation) AddTechnologyIDs(ids ...int)

AddTechnologyIDs adds the "technologies" edge to the RepositoryTechnology entity by ids.

func (*RepositoryMutation) AddedEdges

func (m *RepositoryMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*RepositoryMutation) AddedField

func (m *RepositoryMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*RepositoryMutation) AddedFields

func (m *RepositoryMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*RepositoryMutation) AddedIDs

func (m *RepositoryMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*RepositoryMutation) ClearDescription

func (m *RepositoryMutation) ClearDescription()

ClearDescription clears the value of the "description" field.

func (*RepositoryMutation) ClearDiscordBots

func (m *RepositoryMutation) ClearDiscordBots()

ClearDiscordBots clears the "discord_bots" edge to the DiscordBot entity.

func (*RepositoryMutation) ClearEdge

func (m *RepositoryMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*RepositoryMutation) ClearField

func (m *RepositoryMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*RepositoryMutation) ClearGithubAccount

func (m *RepositoryMutation) ClearGithubAccount()

ClearGithubAccount clears the "github_account" edge to the GithubAccount entity.

func (*RepositoryMutation) ClearGithubOrganization

func (m *RepositoryMutation) ClearGithubOrganization()

ClearGithubOrganization clears the "github_organization" edge to the GithubOrganization entity.

func (*RepositoryMutation) ClearProject

func (m *RepositoryMutation) ClearProject()

ClearProject clears the "project" edge to the Project entity.

func (*RepositoryMutation) ClearSites

func (m *RepositoryMutation) ClearSites()

ClearSites clears the "sites" edge to the Site entity.

func (*RepositoryMutation) ClearTechnologies

func (m *RepositoryMutation) ClearTechnologies()

ClearTechnologies clears the "technologies" edge to the RepositoryTechnology entity.

func (*RepositoryMutation) ClearedEdges

func (m *RepositoryMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*RepositoryMutation) ClearedFields

func (m *RepositoryMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (RepositoryMutation) Client

func (m RepositoryMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*RepositoryMutation) Description

func (m *RepositoryMutation) Description() (r string, exists bool)

Description returns the value of the "description" field in the mutation.

func (*RepositoryMutation) DescriptionCleared

func (m *RepositoryMutation) DescriptionCleared() bool

DescriptionCleared returns if the "description" field was cleared in this mutation.

func (*RepositoryMutation) DiscordBotsCleared

func (m *RepositoryMutation) DiscordBotsCleared() bool

DiscordBotsCleared reports if the "discord_bots" edge to the DiscordBot entity was cleared.

func (*RepositoryMutation) DiscordBotsIDs

func (m *RepositoryMutation) DiscordBotsIDs() (ids []int)

DiscordBotsIDs returns the "discord_bots" edge IDs in the mutation.

func (*RepositoryMutation) EdgeCleared

func (m *RepositoryMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*RepositoryMutation) Field

func (m *RepositoryMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*RepositoryMutation) FieldCleared

func (m *RepositoryMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*RepositoryMutation) Fields

func (m *RepositoryMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*RepositoryMutation) GithubAccountCleared

func (m *RepositoryMutation) GithubAccountCleared() bool

GithubAccountCleared reports if the "github_account" edge to the GithubAccount entity was cleared.

func (*RepositoryMutation) GithubAccountID

func (m *RepositoryMutation) GithubAccountID() (id int, exists bool)

GithubAccountID returns the "github_account" edge ID in the mutation.

func (*RepositoryMutation) GithubAccountIDs

func (m *RepositoryMutation) GithubAccountIDs() (ids []int)

GithubAccountIDs returns the "github_account" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use GithubAccountID instead. It exists only for internal usage by the builders.

func (*RepositoryMutation) GithubOrganizationCleared

func (m *RepositoryMutation) GithubOrganizationCleared() bool

GithubOrganizationCleared reports if the "github_organization" edge to the GithubOrganization entity was cleared.

func (*RepositoryMutation) GithubOrganizationID

func (m *RepositoryMutation) GithubOrganizationID() (id int, exists bool)

GithubOrganizationID returns the "github_organization" edge ID in the mutation.

func (*RepositoryMutation) GithubOrganizationIDs

func (m *RepositoryMutation) GithubOrganizationIDs() (ids []int)

GithubOrganizationIDs returns the "github_organization" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use GithubOrganizationID instead. It exists only for internal usage by the builders.

func (*RepositoryMutation) ID

func (m *RepositoryMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*RepositoryMutation) IDs

func (m *RepositoryMutation) IDs(ctx context.Context) ([]int, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*RepositoryMutation) Name

func (m *RepositoryMutation) Name() (r string, exists bool)

Name returns the value of the "name" field in the mutation.

func (*RepositoryMutation) OldDescription

func (m *RepositoryMutation) OldDescription(ctx context.Context) (v *string, err error)

OldDescription returns the old "description" field's value of the Repository entity. If the Repository object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*RepositoryMutation) OldField

func (m *RepositoryMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*RepositoryMutation) OldName

func (m *RepositoryMutation) OldName(ctx context.Context) (v string, err error)

OldName returns the old "name" field's value of the Repository entity. If the Repository object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*RepositoryMutation) Op

func (m *RepositoryMutation) Op() Op

Op returns the operation name.

func (*RepositoryMutation) ProjectCleared

func (m *RepositoryMutation) ProjectCleared() bool

ProjectCleared reports if the "project" edge to the Project entity was cleared.

func (*RepositoryMutation) ProjectID

func (m *RepositoryMutation) ProjectID() (id int, exists bool)

ProjectID returns the "project" edge ID in the mutation.

func (*RepositoryMutation) ProjectIDs

func (m *RepositoryMutation) ProjectIDs() (ids []int)

ProjectIDs returns the "project" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ProjectID instead. It exists only for internal usage by the builders.

func (*RepositoryMutation) RemoveDiscordBotIDs

func (m *RepositoryMutation) RemoveDiscordBotIDs(ids ...int)

RemoveDiscordBotIDs removes the "discord_bots" edge to the DiscordBot entity by IDs.

func (*RepositoryMutation) RemoveSiteIDs

func (m *RepositoryMutation) RemoveSiteIDs(ids ...int)

RemoveSiteIDs removes the "sites" edge to the Site entity by IDs.

func (*RepositoryMutation) RemoveTechnologyIDs

func (m *RepositoryMutation) RemoveTechnologyIDs(ids ...int)

RemoveTechnologyIDs removes the "technologies" edge to the RepositoryTechnology entity by IDs.

func (*RepositoryMutation) RemovedDiscordBotsIDs

func (m *RepositoryMutation) RemovedDiscordBotsIDs() (ids []int)

RemovedDiscordBots returns the removed IDs of the "discord_bots" edge to the DiscordBot entity.

func (*RepositoryMutation) RemovedEdges

func (m *RepositoryMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*RepositoryMutation) RemovedIDs

func (m *RepositoryMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*RepositoryMutation) RemovedSitesIDs

func (m *RepositoryMutation) RemovedSitesIDs() (ids []int)

RemovedSites returns the removed IDs of the "sites" edge to the Site entity.

func (*RepositoryMutation) RemovedTechnologiesIDs

func (m *RepositoryMutation) RemovedTechnologiesIDs() (ids []int)

RemovedTechnologies returns the removed IDs of the "technologies" edge to the RepositoryTechnology entity.

func (*RepositoryMutation) ResetDescription

func (m *RepositoryMutation) ResetDescription()

ResetDescription resets all changes to the "description" field.

func (*RepositoryMutation) ResetDiscordBots

func (m *RepositoryMutation) ResetDiscordBots()

ResetDiscordBots resets all changes to the "discord_bots" edge.

func (*RepositoryMutation) ResetEdge

func (m *RepositoryMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*RepositoryMutation) ResetField

func (m *RepositoryMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*RepositoryMutation) ResetGithubAccount

func (m *RepositoryMutation) ResetGithubAccount()

ResetGithubAccount resets all changes to the "github_account" edge.

func (*RepositoryMutation) ResetGithubOrganization

func (m *RepositoryMutation) ResetGithubOrganization()

ResetGithubOrganization resets all changes to the "github_organization" edge.

func (*RepositoryMutation) ResetName

func (m *RepositoryMutation) ResetName()

ResetName resets all changes to the "name" field.

func (*RepositoryMutation) ResetProject

func (m *RepositoryMutation) ResetProject()

ResetProject resets all changes to the "project" edge.

func (*RepositoryMutation) ResetSites

func (m *RepositoryMutation) ResetSites()

ResetSites resets all changes to the "sites" edge.

func (*RepositoryMutation) ResetTechnologies

func (m *RepositoryMutation) ResetTechnologies()

ResetTechnologies resets all changes to the "technologies" edge.

func (*RepositoryMutation) SetDescription

func (m *RepositoryMutation) SetDescription(s string)

SetDescription sets the "description" field.

func (*RepositoryMutation) SetField

func (m *RepositoryMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*RepositoryMutation) SetGithubAccountID

func (m *RepositoryMutation) SetGithubAccountID(id int)

SetGithubAccountID sets the "github_account" edge to the GithubAccount entity by id.

func (*RepositoryMutation) SetGithubOrganizationID

func (m *RepositoryMutation) SetGithubOrganizationID(id int)

SetGithubOrganizationID sets the "github_organization" edge to the GithubOrganization entity by id.

func (*RepositoryMutation) SetName

func (m *RepositoryMutation) SetName(s string)

SetName sets the "name" field.

func (*RepositoryMutation) SetProjectID

func (m *RepositoryMutation) SetProjectID(id int)

SetProjectID sets the "project" edge to the Project entity by id.

func (*RepositoryMutation) SitesCleared

func (m *RepositoryMutation) SitesCleared() bool

SitesCleared reports if the "sites" edge to the Site entity was cleared.

func (*RepositoryMutation) SitesIDs

func (m *RepositoryMutation) SitesIDs() (ids []int)

SitesIDs returns the "sites" edge IDs in the mutation.

func (*RepositoryMutation) TechnologiesCleared

func (m *RepositoryMutation) TechnologiesCleared() bool

TechnologiesCleared reports if the "technologies" edge to the RepositoryTechnology entity was cleared.

func (*RepositoryMutation) TechnologiesIDs

func (m *RepositoryMutation) TechnologiesIDs() (ids []int)

TechnologiesIDs returns the "technologies" edge IDs in the mutation.

func (RepositoryMutation) Tx

func (m RepositoryMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*RepositoryMutation) Type

func (m *RepositoryMutation) Type() string

Type returns the node type of this mutation (Repository).

func (*RepositoryMutation) Where

func (m *RepositoryMutation) Where(ps ...predicate.Repository)

Where appends a list predicates to the RepositoryMutation builder.

type RepositoryOrder

type RepositoryOrder struct {
	Direction OrderDirection        `json:"direction"`
	Field     *RepositoryOrderField `json:"field"`
}

RepositoryOrder defines the ordering of Repository.

type RepositoryOrderField

type RepositoryOrderField struct {
	// contains filtered or unexported fields
}

RepositoryOrderField defines the ordering field of Repository.

func (RepositoryOrderField) MarshalGQL

func (f RepositoryOrderField) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (RepositoryOrderField) String

func (f RepositoryOrderField) String() string

String implement fmt.Stringer interface.

func (*RepositoryOrderField) UnmarshalGQL

func (f *RepositoryOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type RepositoryPaginateOption

type RepositoryPaginateOption func(*repositoryPager) error

RepositoryPaginateOption enables pagination customization.

func WithRepositoryFilter

func WithRepositoryFilter(filter func(*RepositoryQuery) (*RepositoryQuery, error)) RepositoryPaginateOption

WithRepositoryFilter configures pagination filter.

func WithRepositoryOrder

func WithRepositoryOrder(order *RepositoryOrder) RepositoryPaginateOption

WithRepositoryOrder configures pagination ordering.

type RepositoryQuery

type RepositoryQuery struct {
	// contains filtered or unexported fields
}

RepositoryQuery is the builder for querying Repository entities.

func (*RepositoryQuery) All

func (rq *RepositoryQuery) All(ctx context.Context) ([]*Repository, error)

All executes the query and returns a list of Repositories.

func (*RepositoryQuery) AllX

func (rq *RepositoryQuery) AllX(ctx context.Context) []*Repository

AllX is like All, but panics if an error occurs.

func (*RepositoryQuery) Clone

func (rq *RepositoryQuery) Clone() *RepositoryQuery

Clone returns a duplicate of the RepositoryQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*RepositoryQuery) CollectFields

func (r *RepositoryQuery) CollectFields(ctx context.Context, satisfies ...string) (*RepositoryQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*RepositoryQuery) Count

func (rq *RepositoryQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*RepositoryQuery) CountX

func (rq *RepositoryQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*RepositoryQuery) Exist

func (rq *RepositoryQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*RepositoryQuery) ExistX

func (rq *RepositoryQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*RepositoryQuery) First

func (rq *RepositoryQuery) First(ctx context.Context) (*Repository, error)

First returns the first Repository entity from the query. Returns a *NotFoundError when no Repository was found.

func (*RepositoryQuery) FirstID

func (rq *RepositoryQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first Repository ID from the query. Returns a *NotFoundError when no Repository ID was found.

func (*RepositoryQuery) FirstIDX

func (rq *RepositoryQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*RepositoryQuery) FirstX

func (rq *RepositoryQuery) FirstX(ctx context.Context) *Repository

FirstX is like First, but panics if an error occurs.

func (*RepositoryQuery) GroupBy

func (rq *RepositoryQuery) GroupBy(field string, fields ...string) *RepositoryGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Name string `json:"name,omitempty"`
	Count int `json:"count,omitempty"`
}

client.Repository.Query().
	GroupBy(repository.FieldName).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*RepositoryQuery) IDs

func (rq *RepositoryQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of Repository IDs.

func (*RepositoryQuery) IDsX

func (rq *RepositoryQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*RepositoryQuery) Limit

func (rq *RepositoryQuery) Limit(limit int) *RepositoryQuery

Limit adds a limit step to the query.

func (*RepositoryQuery) Offset

func (rq *RepositoryQuery) Offset(offset int) *RepositoryQuery

Offset adds an offset step to the query.

func (*RepositoryQuery) Only

func (rq *RepositoryQuery) Only(ctx context.Context) (*Repository, error)

Only returns a single Repository entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Repository entity is found. Returns a *NotFoundError when no Repository entities are found.

func (*RepositoryQuery) OnlyID

func (rq *RepositoryQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only Repository ID in the query. Returns a *NotSingularError when more than one Repository ID is found. Returns a *NotFoundError when no entities are found.

func (*RepositoryQuery) OnlyIDX

func (rq *RepositoryQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*RepositoryQuery) OnlyX

func (rq *RepositoryQuery) OnlyX(ctx context.Context) *Repository

OnlyX is like Only, but panics if an error occurs.

func (*RepositoryQuery) Order

func (rq *RepositoryQuery) Order(o ...OrderFunc) *RepositoryQuery

Order adds an order step to the query.

func (*RepositoryQuery) Paginate

func (r *RepositoryQuery) Paginate(
	ctx context.Context, after *Cursor, first *int,
	before *Cursor, last *int, opts ...RepositoryPaginateOption,
) (*RepositoryConnection, error)

Paginate executes the query and returns a relay based cursor connection to Repository.

func (*RepositoryQuery) QueryDiscordBots

func (rq *RepositoryQuery) QueryDiscordBots() *DiscordBotQuery

QueryDiscordBots chains the current query on the "discord_bots" edge.

func (*RepositoryQuery) QueryGithubAccount

func (rq *RepositoryQuery) QueryGithubAccount() *GithubAccountQuery

QueryGithubAccount chains the current query on the "github_account" edge.

func (*RepositoryQuery) QueryGithubOrganization

func (rq *RepositoryQuery) QueryGithubOrganization() *GithubOrganizationQuery

QueryGithubOrganization chains the current query on the "github_organization" edge.

func (*RepositoryQuery) QueryProject

func (rq *RepositoryQuery) QueryProject() *ProjectQuery

QueryProject chains the current query on the "project" edge.

func (*RepositoryQuery) QuerySites

func (rq *RepositoryQuery) QuerySites() *SiteQuery

QuerySites chains the current query on the "sites" edge.

func (*RepositoryQuery) QueryTechnologies

func (rq *RepositoryQuery) QueryTechnologies() *RepositoryTechnologyQuery

QueryTechnologies chains the current query on the "technologies" edge.

func (*RepositoryQuery) Select

func (rq *RepositoryQuery) Select(fields ...string) *RepositorySelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Name string `json:"name,omitempty"`
}

client.Repository.Query().
	Select(repository.FieldName).
	Scan(ctx, &v)

func (*RepositoryQuery) Unique

func (rq *RepositoryQuery) Unique(unique bool) *RepositoryQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*RepositoryQuery) Where

Where adds a new predicate for the RepositoryQuery builder.

func (*RepositoryQuery) WithDiscordBots

func (rq *RepositoryQuery) WithDiscordBots(opts ...func(*DiscordBotQuery)) *RepositoryQuery

WithDiscordBots tells the query-builder to eager-load the nodes that are connected to the "discord_bots" edge. The optional arguments are used to configure the query builder of the edge.

func (*RepositoryQuery) WithGithubAccount

func (rq *RepositoryQuery) WithGithubAccount(opts ...func(*GithubAccountQuery)) *RepositoryQuery

WithGithubAccount tells the query-builder to eager-load the nodes that are connected to the "github_account" edge. The optional arguments are used to configure the query builder of the edge.

func (*RepositoryQuery) WithGithubOrganization

func (rq *RepositoryQuery) WithGithubOrganization(opts ...func(*GithubOrganizationQuery)) *RepositoryQuery

WithGithubOrganization tells the query-builder to eager-load the nodes that are connected to the "github_organization" edge. The optional arguments are used to configure the query builder of the edge.

func (*RepositoryQuery) WithNamedDiscordBots

func (rq *RepositoryQuery) WithNamedDiscordBots(name string, opts ...func(*DiscordBotQuery)) *RepositoryQuery

WithNamedDiscordBots tells the query-builder to eager-load the nodes that are connected to the "discord_bots" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*RepositoryQuery) WithNamedSites

func (rq *RepositoryQuery) WithNamedSites(name string, opts ...func(*SiteQuery)) *RepositoryQuery

WithNamedSites tells the query-builder to eager-load the nodes that are connected to the "sites" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*RepositoryQuery) WithNamedTechnologies

func (rq *RepositoryQuery) WithNamedTechnologies(name string, opts ...func(*RepositoryTechnologyQuery)) *RepositoryQuery

WithNamedTechnologies tells the query-builder to eager-load the nodes that are connected to the "technologies" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*RepositoryQuery) WithProject

func (rq *RepositoryQuery) WithProject(opts ...func(*ProjectQuery)) *RepositoryQuery

WithProject tells the query-builder to eager-load the nodes that are connected to the "project" edge. The optional arguments are used to configure the query builder of the edge.

func (*RepositoryQuery) WithSites

func (rq *RepositoryQuery) WithSites(opts ...func(*SiteQuery)) *RepositoryQuery

WithSites tells the query-builder to eager-load the nodes that are connected to the "sites" edge. The optional arguments are used to configure the query builder of the edge.

func (*RepositoryQuery) WithTechnologies

func (rq *RepositoryQuery) WithTechnologies(opts ...func(*RepositoryTechnologyQuery)) *RepositoryQuery

WithTechnologies tells the query-builder to eager-load the nodes that are connected to the "technologies" edge. The optional arguments are used to configure the query builder of the edge.

type RepositorySelect

type RepositorySelect struct {
	*RepositoryQuery
	// contains filtered or unexported fields
}

RepositorySelect is the builder for selecting fields of Repository entities.

func (*RepositorySelect) Bool

func (s *RepositorySelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*RepositorySelect) BoolX

func (s *RepositorySelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*RepositorySelect) Bools

func (s *RepositorySelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*RepositorySelect) BoolsX

func (s *RepositorySelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*RepositorySelect) Float64

func (s *RepositorySelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*RepositorySelect) Float64X

func (s *RepositorySelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*RepositorySelect) Float64s

func (s *RepositorySelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*RepositorySelect) Float64sX

func (s *RepositorySelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*RepositorySelect) Int

func (s *RepositorySelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*RepositorySelect) IntX

func (s *RepositorySelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*RepositorySelect) Ints

func (s *RepositorySelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*RepositorySelect) IntsX

func (s *RepositorySelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*RepositorySelect) Scan

func (rs *RepositorySelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*RepositorySelect) ScanX

func (s *RepositorySelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*RepositorySelect) String

func (s *RepositorySelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*RepositorySelect) StringX

func (s *RepositorySelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*RepositorySelect) Strings

func (s *RepositorySelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*RepositorySelect) StringsX

func (s *RepositorySelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type RepositoryTechnologies

type RepositoryTechnologies []*RepositoryTechnology

RepositoryTechnologies is a parsable slice of RepositoryTechnology.

type RepositoryTechnology

type RepositoryTechnology struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Type holds the value of the "type" field.
	Type repositorytechnology.Type `json:"type,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the RepositoryTechnologyQuery when eager-loading is set.
	Edges RepositoryTechnologyEdges `json:"edges"`
	// contains filtered or unexported fields
}

RepositoryTechnology is the model entity for the RepositoryTechnology schema.

func (*RepositoryTechnology) Node

func (rt *RepositoryTechnology) Node(ctx context.Context) (node *Node, err error)

func (*RepositoryTechnology) QueryRepository

func (rt *RepositoryTechnology) QueryRepository() *RepositoryQuery

QueryRepository queries the "repository" edge of the RepositoryTechnology entity.

func (*RepositoryTechnology) QueryTechnology

func (rt *RepositoryTechnology) QueryTechnology() *TechnologyQuery

QueryTechnology queries the "technology" edge of the RepositoryTechnology entity.

func (*RepositoryTechnology) Repository

func (rt *RepositoryTechnology) Repository(ctx context.Context) (*Repository, error)

func (*RepositoryTechnology) String

func (rt *RepositoryTechnology) String() string

String implements the fmt.Stringer.

func (*RepositoryTechnology) Technology

func (rt *RepositoryTechnology) Technology(ctx context.Context) (*Technology, error)

func (*RepositoryTechnology) ToEdge

ToEdge converts RepositoryTechnology into RepositoryTechnologyEdge.

func (*RepositoryTechnology) Unwrap

Unwrap unwraps the RepositoryTechnology entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*RepositoryTechnology) Update

Update returns a builder for updating this RepositoryTechnology. Note that you need to call RepositoryTechnology.Unwrap() before calling this method if this RepositoryTechnology was returned from a transaction, and the transaction was committed or rolled back.

type RepositoryTechnologyClient

type RepositoryTechnologyClient struct {
	// contains filtered or unexported fields
}

RepositoryTechnologyClient is a client for the RepositoryTechnology schema.

func NewRepositoryTechnologyClient

func NewRepositoryTechnologyClient(c config) *RepositoryTechnologyClient

NewRepositoryTechnologyClient returns a client for the RepositoryTechnology from the given config.

func (*RepositoryTechnologyClient) Create

Create returns a builder for creating a RepositoryTechnology entity.

func (*RepositoryTechnologyClient) CreateBulk

CreateBulk returns a builder for creating a bulk of RepositoryTechnology entities.

func (*RepositoryTechnologyClient) Delete

Delete returns a delete builder for RepositoryTechnology.

func (*RepositoryTechnologyClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*RepositoryTechnologyClient) DeleteOneID

DeleteOne returns a builder for deleting the given entity by its id.

func (*RepositoryTechnologyClient) Get

Get returns a RepositoryTechnology entity by its id.

func (*RepositoryTechnologyClient) GetX

GetX is like Get, but panics if an error occurs.

func (*RepositoryTechnologyClient) Hooks

func (c *RepositoryTechnologyClient) Hooks() []Hook

Hooks returns the client hooks.

func (*RepositoryTechnologyClient) Query

Query returns a query builder for RepositoryTechnology.

func (*RepositoryTechnologyClient) QueryRepository

QueryRepository queries the repository edge of a RepositoryTechnology.

func (*RepositoryTechnologyClient) QueryTechnology

QueryTechnology queries the technology edge of a RepositoryTechnology.

func (*RepositoryTechnologyClient) Update

Update returns an update builder for RepositoryTechnology.

func (*RepositoryTechnologyClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*RepositoryTechnologyClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*RepositoryTechnologyClient) Use

func (c *RepositoryTechnologyClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `repositorytechnology.Hooks(f(g(h())))`.

type RepositoryTechnologyConnection

type RepositoryTechnologyConnection struct {
	Edges      []*RepositoryTechnologyEdge `json:"edges"`
	PageInfo   PageInfo                    `json:"pageInfo"`
	TotalCount int                         `json:"totalCount"`
}

RepositoryTechnologyConnection is the connection containing edges to RepositoryTechnology.

type RepositoryTechnologyCreate

type RepositoryTechnologyCreate struct {
	// contains filtered or unexported fields
}

RepositoryTechnologyCreate is the builder for creating a RepositoryTechnology entity.

func (*RepositoryTechnologyCreate) Exec

Exec executes the query.

func (*RepositoryTechnologyCreate) ExecX

func (rtc *RepositoryTechnologyCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryTechnologyCreate) Mutation

Mutation returns the RepositoryTechnologyMutation object of the builder.

func (*RepositoryTechnologyCreate) Save

Save creates the RepositoryTechnology in the database.

func (*RepositoryTechnologyCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*RepositoryTechnologyCreate) SetInput

SetInput applies the change-set in the CreateRepositoryTechnologyInput on the create builder.

func (*RepositoryTechnologyCreate) SetRepository

SetRepository sets the "repository" edge to the Repository entity.

func (*RepositoryTechnologyCreate) SetRepositoryID

func (rtc *RepositoryTechnologyCreate) SetRepositoryID(id int) *RepositoryTechnologyCreate

SetRepositoryID sets the "repository" edge to the Repository entity by ID.

func (*RepositoryTechnologyCreate) SetTechnology

SetTechnology sets the "technology" edge to the Technology entity.

func (*RepositoryTechnologyCreate) SetTechnologyID

func (rtc *RepositoryTechnologyCreate) SetTechnologyID(id int) *RepositoryTechnologyCreate

SetTechnologyID sets the "technology" edge to the Technology entity by ID.

func (*RepositoryTechnologyCreate) SetType

SetType sets the "type" field.

type RepositoryTechnologyCreateBulk

type RepositoryTechnologyCreateBulk struct {
	// contains filtered or unexported fields
}

RepositoryTechnologyCreateBulk is the builder for creating many RepositoryTechnology entities in bulk.

func (*RepositoryTechnologyCreateBulk) Exec

Exec executes the query.

func (*RepositoryTechnologyCreateBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryTechnologyCreateBulk) Save

Save creates the RepositoryTechnology entities in the database.

func (*RepositoryTechnologyCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type RepositoryTechnologyDelete

type RepositoryTechnologyDelete struct {
	// contains filtered or unexported fields
}

RepositoryTechnologyDelete is the builder for deleting a RepositoryTechnology entity.

func (*RepositoryTechnologyDelete) Exec

Exec executes the deletion query and returns how many vertices were deleted.

func (*RepositoryTechnologyDelete) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryTechnologyDelete) Where

Where appends a list predicates to the RepositoryTechnologyDelete builder.

type RepositoryTechnologyDeleteOne

type RepositoryTechnologyDeleteOne struct {
	// contains filtered or unexported fields
}

RepositoryTechnologyDeleteOne is the builder for deleting a single RepositoryTechnology entity.

func (*RepositoryTechnologyDeleteOne) Exec

Exec executes the deletion query.

func (*RepositoryTechnologyDeleteOne) ExecX

ExecX is like Exec, but panics if an error occurs.

type RepositoryTechnologyEdge

type RepositoryTechnologyEdge struct {
	Node   *RepositoryTechnology `json:"node"`
	Cursor Cursor                `json:"cursor"`
}

RepositoryTechnologyEdge is the edge representation of RepositoryTechnology.

type RepositoryTechnologyEdges

type RepositoryTechnologyEdges struct {
	// Repository holds the value of the repository edge.
	Repository *Repository `json:"repository,omitempty"`
	// Technology holds the value of the technology edge.
	Technology *Technology `json:"technology,omitempty"`
	// contains filtered or unexported fields
}

RepositoryTechnologyEdges holds the relations/edges for other nodes in the graph.

func (RepositoryTechnologyEdges) RepositoryOrErr

func (e RepositoryTechnologyEdges) RepositoryOrErr() (*Repository, error)

RepositoryOrErr returns the Repository value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (RepositoryTechnologyEdges) TechnologyOrErr

func (e RepositoryTechnologyEdges) TechnologyOrErr() (*Technology, error)

TechnologyOrErr returns the Technology value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type RepositoryTechnologyGroupBy

type RepositoryTechnologyGroupBy struct {
	// contains filtered or unexported fields
}

RepositoryTechnologyGroupBy is the group-by builder for RepositoryTechnology entities.

func (*RepositoryTechnologyGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*RepositoryTechnologyGroupBy) Bool

func (s *RepositoryTechnologyGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologyGroupBy) BoolX

func (s *RepositoryTechnologyGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*RepositoryTechnologyGroupBy) Bools

func (s *RepositoryTechnologyGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologyGroupBy) BoolsX

func (s *RepositoryTechnologyGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*RepositoryTechnologyGroupBy) Float64

func (s *RepositoryTechnologyGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologyGroupBy) Float64X

func (s *RepositoryTechnologyGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*RepositoryTechnologyGroupBy) Float64s

func (s *RepositoryTechnologyGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologyGroupBy) Float64sX

func (s *RepositoryTechnologyGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*RepositoryTechnologyGroupBy) Int

func (s *RepositoryTechnologyGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologyGroupBy) IntX

func (s *RepositoryTechnologyGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*RepositoryTechnologyGroupBy) Ints

func (s *RepositoryTechnologyGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologyGroupBy) IntsX

func (s *RepositoryTechnologyGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*RepositoryTechnologyGroupBy) Scan

func (rtgb *RepositoryTechnologyGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*RepositoryTechnologyGroupBy) ScanX

func (s *RepositoryTechnologyGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*RepositoryTechnologyGroupBy) String

func (s *RepositoryTechnologyGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologyGroupBy) StringX

func (s *RepositoryTechnologyGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*RepositoryTechnologyGroupBy) Strings

func (s *RepositoryTechnologyGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologyGroupBy) StringsX

func (s *RepositoryTechnologyGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type RepositoryTechnologyMutation

type RepositoryTechnologyMutation struct {
	// contains filtered or unexported fields
}

RepositoryTechnologyMutation represents an operation that mutates the RepositoryTechnology nodes in the graph.

func (*RepositoryTechnologyMutation) AddField

func (m *RepositoryTechnologyMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*RepositoryTechnologyMutation) AddedEdges

func (m *RepositoryTechnologyMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*RepositoryTechnologyMutation) AddedField

func (m *RepositoryTechnologyMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*RepositoryTechnologyMutation) AddedFields

func (m *RepositoryTechnologyMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*RepositoryTechnologyMutation) AddedIDs

func (m *RepositoryTechnologyMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*RepositoryTechnologyMutation) ClearEdge

func (m *RepositoryTechnologyMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*RepositoryTechnologyMutation) ClearField

func (m *RepositoryTechnologyMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*RepositoryTechnologyMutation) ClearRepository

func (m *RepositoryTechnologyMutation) ClearRepository()

ClearRepository clears the "repository" edge to the Repository entity.

func (*RepositoryTechnologyMutation) ClearTechnology

func (m *RepositoryTechnologyMutation) ClearTechnology()

ClearTechnology clears the "technology" edge to the Technology entity.

func (*RepositoryTechnologyMutation) ClearedEdges

func (m *RepositoryTechnologyMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*RepositoryTechnologyMutation) ClearedFields

func (m *RepositoryTechnologyMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (RepositoryTechnologyMutation) Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*RepositoryTechnologyMutation) EdgeCleared

func (m *RepositoryTechnologyMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*RepositoryTechnologyMutation) Field

func (m *RepositoryTechnologyMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*RepositoryTechnologyMutation) FieldCleared

func (m *RepositoryTechnologyMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*RepositoryTechnologyMutation) Fields

func (m *RepositoryTechnologyMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*RepositoryTechnologyMutation) GetType

GetType returns the value of the "type" field in the mutation.

func (*RepositoryTechnologyMutation) ID

func (m *RepositoryTechnologyMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*RepositoryTechnologyMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*RepositoryTechnologyMutation) OldField

func (m *RepositoryTechnologyMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*RepositoryTechnologyMutation) OldType

OldType returns the old "type" field's value of the RepositoryTechnology entity. If the RepositoryTechnology object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*RepositoryTechnologyMutation) Op

Op returns the operation name.

func (*RepositoryTechnologyMutation) RemovedEdges

func (m *RepositoryTechnologyMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*RepositoryTechnologyMutation) RemovedIDs

func (m *RepositoryTechnologyMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*RepositoryTechnologyMutation) RepositoryCleared

func (m *RepositoryTechnologyMutation) RepositoryCleared() bool

RepositoryCleared reports if the "repository" edge to the Repository entity was cleared.

func (*RepositoryTechnologyMutation) RepositoryID

func (m *RepositoryTechnologyMutation) RepositoryID() (id int, exists bool)

RepositoryID returns the "repository" edge ID in the mutation.

func (*RepositoryTechnologyMutation) RepositoryIDs

func (m *RepositoryTechnologyMutation) RepositoryIDs() (ids []int)

RepositoryIDs returns the "repository" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use RepositoryID instead. It exists only for internal usage by the builders.

func (*RepositoryTechnologyMutation) ResetEdge

func (m *RepositoryTechnologyMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*RepositoryTechnologyMutation) ResetField

func (m *RepositoryTechnologyMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*RepositoryTechnologyMutation) ResetRepository

func (m *RepositoryTechnologyMutation) ResetRepository()

ResetRepository resets all changes to the "repository" edge.

func (*RepositoryTechnologyMutation) ResetTechnology

func (m *RepositoryTechnologyMutation) ResetTechnology()

ResetTechnology resets all changes to the "technology" edge.

func (*RepositoryTechnologyMutation) ResetType

func (m *RepositoryTechnologyMutation) ResetType()

ResetType resets all changes to the "type" field.

func (*RepositoryTechnologyMutation) SetField

func (m *RepositoryTechnologyMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*RepositoryTechnologyMutation) SetRepositoryID

func (m *RepositoryTechnologyMutation) SetRepositoryID(id int)

SetRepositoryID sets the "repository" edge to the Repository entity by id.

func (*RepositoryTechnologyMutation) SetTechnologyID

func (m *RepositoryTechnologyMutation) SetTechnologyID(id int)

SetTechnologyID sets the "technology" edge to the Technology entity by id.

func (*RepositoryTechnologyMutation) SetType

SetType sets the "type" field.

func (*RepositoryTechnologyMutation) TechnologyCleared

func (m *RepositoryTechnologyMutation) TechnologyCleared() bool

TechnologyCleared reports if the "technology" edge to the Technology entity was cleared.

func (*RepositoryTechnologyMutation) TechnologyID

func (m *RepositoryTechnologyMutation) TechnologyID() (id int, exists bool)

TechnologyID returns the "technology" edge ID in the mutation.

func (*RepositoryTechnologyMutation) TechnologyIDs

func (m *RepositoryTechnologyMutation) TechnologyIDs() (ids []int)

TechnologyIDs returns the "technology" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use TechnologyID instead. It exists only for internal usage by the builders.

func (RepositoryTechnologyMutation) Tx

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*RepositoryTechnologyMutation) Type

Type returns the node type of this mutation (RepositoryTechnology).

func (*RepositoryTechnologyMutation) Where

Where appends a list predicates to the RepositoryTechnologyMutation builder.

type RepositoryTechnologyOrder

type RepositoryTechnologyOrder struct {
	Direction OrderDirection                  `json:"direction"`
	Field     *RepositoryTechnologyOrderField `json:"field"`
}

RepositoryTechnologyOrder defines the ordering of RepositoryTechnology.

type RepositoryTechnologyOrderField

type RepositoryTechnologyOrderField struct {
	// contains filtered or unexported fields
}

RepositoryTechnologyOrderField defines the ordering field of RepositoryTechnology.

func (RepositoryTechnologyOrderField) MarshalGQL

func (f RepositoryTechnologyOrderField) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (RepositoryTechnologyOrderField) String

String implement fmt.Stringer interface.

func (*RepositoryTechnologyOrderField) UnmarshalGQL

func (f *RepositoryTechnologyOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type RepositoryTechnologyPaginateOption

type RepositoryTechnologyPaginateOption func(*repositorytechnologyPager) error

RepositoryTechnologyPaginateOption enables pagination customization.

func WithRepositoryTechnologyFilter

func WithRepositoryTechnologyFilter(filter func(*RepositoryTechnologyQuery) (*RepositoryTechnologyQuery, error)) RepositoryTechnologyPaginateOption

WithRepositoryTechnologyFilter configures pagination filter.

func WithRepositoryTechnologyOrder

func WithRepositoryTechnologyOrder(order *RepositoryTechnologyOrder) RepositoryTechnologyPaginateOption

WithRepositoryTechnologyOrder configures pagination ordering.

type RepositoryTechnologyQuery

type RepositoryTechnologyQuery struct {
	// contains filtered or unexported fields
}

RepositoryTechnologyQuery is the builder for querying RepositoryTechnology entities.

func (*RepositoryTechnologyQuery) All

All executes the query and returns a list of RepositoryTechnologies.

func (*RepositoryTechnologyQuery) AllX

AllX is like All, but panics if an error occurs.

func (*RepositoryTechnologyQuery) Clone

Clone returns a duplicate of the RepositoryTechnologyQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*RepositoryTechnologyQuery) CollectFields

func (rt *RepositoryTechnologyQuery) CollectFields(ctx context.Context, satisfies ...string) (*RepositoryTechnologyQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*RepositoryTechnologyQuery) Count

func (rtq *RepositoryTechnologyQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*RepositoryTechnologyQuery) CountX

func (rtq *RepositoryTechnologyQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*RepositoryTechnologyQuery) Exist

func (rtq *RepositoryTechnologyQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*RepositoryTechnologyQuery) ExistX

func (rtq *RepositoryTechnologyQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*RepositoryTechnologyQuery) First

First returns the first RepositoryTechnology entity from the query. Returns a *NotFoundError when no RepositoryTechnology was found.

func (*RepositoryTechnologyQuery) FirstID

func (rtq *RepositoryTechnologyQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first RepositoryTechnology ID from the query. Returns a *NotFoundError when no RepositoryTechnology ID was found.

func (*RepositoryTechnologyQuery) FirstIDX

func (rtq *RepositoryTechnologyQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*RepositoryTechnologyQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*RepositoryTechnologyQuery) GroupBy

func (rtq *RepositoryTechnologyQuery) GroupBy(field string, fields ...string) *RepositoryTechnologyGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Type repositorytechnology.Type `json:"type,omitempty"`
	Count int `json:"count,omitempty"`
}

client.RepositoryTechnology.Query().
	GroupBy(repositorytechnology.FieldType).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*RepositoryTechnologyQuery) IDs

func (rtq *RepositoryTechnologyQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of RepositoryTechnology IDs.

func (*RepositoryTechnologyQuery) IDsX

func (rtq *RepositoryTechnologyQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*RepositoryTechnologyQuery) Limit

Limit adds a limit step to the query.

func (*RepositoryTechnologyQuery) Offset

Offset adds an offset step to the query.

func (*RepositoryTechnologyQuery) Only

Only returns a single RepositoryTechnology entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one RepositoryTechnology entity is found. Returns a *NotFoundError when no RepositoryTechnology entities are found.

func (*RepositoryTechnologyQuery) OnlyID

func (rtq *RepositoryTechnologyQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only RepositoryTechnology ID in the query. Returns a *NotSingularError when more than one RepositoryTechnology ID is found. Returns a *NotFoundError when no entities are found.

func (*RepositoryTechnologyQuery) OnlyIDX

func (rtq *RepositoryTechnologyQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*RepositoryTechnologyQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*RepositoryTechnologyQuery) Order

Order adds an order step to the query.

func (*RepositoryTechnologyQuery) Paginate

func (rt *RepositoryTechnologyQuery) Paginate(
	ctx context.Context, after *Cursor, first *int,
	before *Cursor, last *int, opts ...RepositoryTechnologyPaginateOption,
) (*RepositoryTechnologyConnection, error)

Paginate executes the query and returns a relay based cursor connection to RepositoryTechnology.

func (*RepositoryTechnologyQuery) QueryRepository

func (rtq *RepositoryTechnologyQuery) QueryRepository() *RepositoryQuery

QueryRepository chains the current query on the "repository" edge.

func (*RepositoryTechnologyQuery) QueryTechnology

func (rtq *RepositoryTechnologyQuery) QueryTechnology() *TechnologyQuery

QueryTechnology chains the current query on the "technology" edge.

func (*RepositoryTechnologyQuery) Select

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Type repositorytechnology.Type `json:"type,omitempty"`
}

client.RepositoryTechnology.Query().
	Select(repositorytechnology.FieldType).
	Scan(ctx, &v)

func (*RepositoryTechnologyQuery) Unique

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*RepositoryTechnologyQuery) Where

Where adds a new predicate for the RepositoryTechnologyQuery builder.

func (*RepositoryTechnologyQuery) WithRepository

func (rtq *RepositoryTechnologyQuery) WithRepository(opts ...func(*RepositoryQuery)) *RepositoryTechnologyQuery

WithRepository tells the query-builder to eager-load the nodes that are connected to the "repository" edge. The optional arguments are used to configure the query builder of the edge.

func (*RepositoryTechnologyQuery) WithTechnology

func (rtq *RepositoryTechnologyQuery) WithTechnology(opts ...func(*TechnologyQuery)) *RepositoryTechnologyQuery

WithTechnology tells the query-builder to eager-load the nodes that are connected to the "technology" edge. The optional arguments are used to configure the query builder of the edge.

type RepositoryTechnologySelect

type RepositoryTechnologySelect struct {
	*RepositoryTechnologyQuery
	// contains filtered or unexported fields
}

RepositoryTechnologySelect is the builder for selecting fields of RepositoryTechnology entities.

func (*RepositoryTechnologySelect) Bool

func (s *RepositoryTechnologySelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologySelect) BoolX

func (s *RepositoryTechnologySelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*RepositoryTechnologySelect) Bools

func (s *RepositoryTechnologySelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologySelect) BoolsX

func (s *RepositoryTechnologySelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*RepositoryTechnologySelect) Float64

func (s *RepositoryTechnologySelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologySelect) Float64X

func (s *RepositoryTechnologySelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*RepositoryTechnologySelect) Float64s

func (s *RepositoryTechnologySelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologySelect) Float64sX

func (s *RepositoryTechnologySelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*RepositoryTechnologySelect) Int

func (s *RepositoryTechnologySelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologySelect) IntX

func (s *RepositoryTechnologySelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*RepositoryTechnologySelect) Ints

func (s *RepositoryTechnologySelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologySelect) IntsX

func (s *RepositoryTechnologySelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*RepositoryTechnologySelect) Scan

func (rts *RepositoryTechnologySelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*RepositoryTechnologySelect) ScanX

func (s *RepositoryTechnologySelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*RepositoryTechnologySelect) String

func (s *RepositoryTechnologySelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologySelect) StringX

func (s *RepositoryTechnologySelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*RepositoryTechnologySelect) Strings

func (s *RepositoryTechnologySelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*RepositoryTechnologySelect) StringsX

func (s *RepositoryTechnologySelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type RepositoryTechnologyUpdate

type RepositoryTechnologyUpdate struct {
	// contains filtered or unexported fields
}

RepositoryTechnologyUpdate is the builder for updating RepositoryTechnology entities.

func (*RepositoryTechnologyUpdate) ClearRepository

ClearRepository clears the "repository" edge to the Repository entity.

func (*RepositoryTechnologyUpdate) ClearTechnology

ClearTechnology clears the "technology" edge to the Technology entity.

func (*RepositoryTechnologyUpdate) Exec

Exec executes the query.

func (*RepositoryTechnologyUpdate) ExecX

func (rtu *RepositoryTechnologyUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryTechnologyUpdate) Mutation

Mutation returns the RepositoryTechnologyMutation object of the builder.

func (*RepositoryTechnologyUpdate) Save

Save executes the query and returns the number of nodes affected by the update operation.

func (*RepositoryTechnologyUpdate) SaveX

SaveX is like Save, but panics if an error occurs.

func (*RepositoryTechnologyUpdate) SetInput

SetInput applies the change-set in the UpdateRepositoryTechnologyInput on the update builder.

func (*RepositoryTechnologyUpdate) SetRepository

SetRepository sets the "repository" edge to the Repository entity.

func (*RepositoryTechnologyUpdate) SetRepositoryID

func (rtu *RepositoryTechnologyUpdate) SetRepositoryID(id int) *RepositoryTechnologyUpdate

SetRepositoryID sets the "repository" edge to the Repository entity by ID.

func (*RepositoryTechnologyUpdate) SetTechnology

SetTechnology sets the "technology" edge to the Technology entity.

func (*RepositoryTechnologyUpdate) SetTechnologyID

func (rtu *RepositoryTechnologyUpdate) SetTechnologyID(id int) *RepositoryTechnologyUpdate

SetTechnologyID sets the "technology" edge to the Technology entity by ID.

func (*RepositoryTechnologyUpdate) SetType

SetType sets the "type" field.

func (*RepositoryTechnologyUpdate) Where

Where appends a list predicates to the RepositoryTechnologyUpdate builder.

type RepositoryTechnologyUpdateOne

type RepositoryTechnologyUpdateOne struct {
	// contains filtered or unexported fields
}

RepositoryTechnologyUpdateOne is the builder for updating a single RepositoryTechnology entity.

func (*RepositoryTechnologyUpdateOne) ClearRepository

ClearRepository clears the "repository" edge to the Repository entity.

func (*RepositoryTechnologyUpdateOne) ClearTechnology

ClearTechnology clears the "technology" edge to the Technology entity.

func (*RepositoryTechnologyUpdateOne) Exec

Exec executes the query on the entity.

func (*RepositoryTechnologyUpdateOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryTechnologyUpdateOne) Mutation

Mutation returns the RepositoryTechnologyMutation object of the builder.

func (*RepositoryTechnologyUpdateOne) Save

Save executes the query and returns the updated RepositoryTechnology entity.

func (*RepositoryTechnologyUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*RepositoryTechnologyUpdateOne) Select

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*RepositoryTechnologyUpdateOne) SetInput

SetInput applies the change-set in the UpdateRepositoryTechnologyInput on the update-one builder.

func (*RepositoryTechnologyUpdateOne) SetRepository

SetRepository sets the "repository" edge to the Repository entity.

func (*RepositoryTechnologyUpdateOne) SetRepositoryID

SetRepositoryID sets the "repository" edge to the Repository entity by ID.

func (*RepositoryTechnologyUpdateOne) SetTechnology

SetTechnology sets the "technology" edge to the Technology entity.

func (*RepositoryTechnologyUpdateOne) SetTechnologyID

SetTechnologyID sets the "technology" edge to the Technology entity by ID.

func (*RepositoryTechnologyUpdateOne) SetType

SetType sets the "type" field.

type RepositoryTechnologyWhereInput

type RepositoryTechnologyWhereInput struct {
	Predicates []predicate.RepositoryTechnology  `json:"-"`
	Not        *RepositoryTechnologyWhereInput   `json:"not,omitempty"`
	Or         []*RepositoryTechnologyWhereInput `json:"or,omitempty"`
	And        []*RepositoryTechnologyWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "type" field predicates.
	Type      *repositorytechnology.Type  `json:"type,omitempty"`
	TypeNEQ   *repositorytechnology.Type  `json:"typeNEQ,omitempty"`
	TypeIn    []repositorytechnology.Type `json:"typeIn,omitempty"`
	TypeNotIn []repositorytechnology.Type `json:"typeNotIn,omitempty"`

	// "repository" edge predicates.
	HasRepository     *bool                   `json:"hasRepository,omitempty"`
	HasRepositoryWith []*RepositoryWhereInput `json:"hasRepositoryWith,omitempty"`

	// "technology" edge predicates.
	HasTechnology     *bool                   `json:"hasTechnology,omitempty"`
	HasTechnologyWith []*TechnologyWhereInput `json:"hasTechnologyWith,omitempty"`
}

RepositoryTechnologyWhereInput represents a where input for filtering RepositoryTechnology queries.

func (*RepositoryTechnologyWhereInput) AddPredicates

func (i *RepositoryTechnologyWhereInput) AddPredicates(predicates ...predicate.RepositoryTechnology)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*RepositoryTechnologyWhereInput) Filter

Filter applies the RepositoryTechnologyWhereInput filter on the RepositoryTechnologyQuery builder.

func (*RepositoryTechnologyWhereInput) P

P returns a predicate for filtering repositorytechnologies. An error is returned if the input is empty or invalid.

type RepositoryUpdate

type RepositoryUpdate struct {
	// contains filtered or unexported fields
}

RepositoryUpdate is the builder for updating Repository entities.

func (*RepositoryUpdate) AddDiscordBotIDs

func (ru *RepositoryUpdate) AddDiscordBotIDs(ids ...int) *RepositoryUpdate

AddDiscordBotIDs adds the "discord_bots" edge to the DiscordBot entity by IDs.

func (*RepositoryUpdate) AddDiscordBots

func (ru *RepositoryUpdate) AddDiscordBots(d ...*DiscordBot) *RepositoryUpdate

AddDiscordBots adds the "discord_bots" edges to the DiscordBot entity.

func (*RepositoryUpdate) AddSiteIDs

func (ru *RepositoryUpdate) AddSiteIDs(ids ...int) *RepositoryUpdate

AddSiteIDs adds the "sites" edge to the Site entity by IDs.

func (*RepositoryUpdate) AddSites

func (ru *RepositoryUpdate) AddSites(s ...*Site) *RepositoryUpdate

AddSites adds the "sites" edges to the Site entity.

func (*RepositoryUpdate) AddTechnologies

func (ru *RepositoryUpdate) AddTechnologies(r ...*RepositoryTechnology) *RepositoryUpdate

AddTechnologies adds the "technologies" edges to the RepositoryTechnology entity.

func (*RepositoryUpdate) AddTechnologyIDs

func (ru *RepositoryUpdate) AddTechnologyIDs(ids ...int) *RepositoryUpdate

AddTechnologyIDs adds the "technologies" edge to the RepositoryTechnology entity by IDs.

func (*RepositoryUpdate) ClearDescription

func (ru *RepositoryUpdate) ClearDescription() *RepositoryUpdate

ClearDescription clears the value of the "description" field.

func (*RepositoryUpdate) ClearDiscordBots

func (ru *RepositoryUpdate) ClearDiscordBots() *RepositoryUpdate

ClearDiscordBots clears all "discord_bots" edges to the DiscordBot entity.

func (*RepositoryUpdate) ClearGithubAccount

func (ru *RepositoryUpdate) ClearGithubAccount() *RepositoryUpdate

ClearGithubAccount clears the "github_account" edge to the GithubAccount entity.

func (*RepositoryUpdate) ClearGithubOrganization

func (ru *RepositoryUpdate) ClearGithubOrganization() *RepositoryUpdate

ClearGithubOrganization clears the "github_organization" edge to the GithubOrganization entity.

func (*RepositoryUpdate) ClearProject

func (ru *RepositoryUpdate) ClearProject() *RepositoryUpdate

ClearProject clears the "project" edge to the Project entity.

func (*RepositoryUpdate) ClearSites

func (ru *RepositoryUpdate) ClearSites() *RepositoryUpdate

ClearSites clears all "sites" edges to the Site entity.

func (*RepositoryUpdate) ClearTechnologies

func (ru *RepositoryUpdate) ClearTechnologies() *RepositoryUpdate

ClearTechnologies clears all "technologies" edges to the RepositoryTechnology entity.

func (*RepositoryUpdate) Exec

func (ru *RepositoryUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*RepositoryUpdate) ExecX

func (ru *RepositoryUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryUpdate) Mutation

func (ru *RepositoryUpdate) Mutation() *RepositoryMutation

Mutation returns the RepositoryMutation object of the builder.

func (*RepositoryUpdate) RemoveDiscordBotIDs

func (ru *RepositoryUpdate) RemoveDiscordBotIDs(ids ...int) *RepositoryUpdate

RemoveDiscordBotIDs removes the "discord_bots" edge to DiscordBot entities by IDs.

func (*RepositoryUpdate) RemoveDiscordBots

func (ru *RepositoryUpdate) RemoveDiscordBots(d ...*DiscordBot) *RepositoryUpdate

RemoveDiscordBots removes "discord_bots" edges to DiscordBot entities.

func (*RepositoryUpdate) RemoveSiteIDs

func (ru *RepositoryUpdate) RemoveSiteIDs(ids ...int) *RepositoryUpdate

RemoveSiteIDs removes the "sites" edge to Site entities by IDs.

func (*RepositoryUpdate) RemoveSites

func (ru *RepositoryUpdate) RemoveSites(s ...*Site) *RepositoryUpdate

RemoveSites removes "sites" edges to Site entities.

func (*RepositoryUpdate) RemoveTechnologies

func (ru *RepositoryUpdate) RemoveTechnologies(r ...*RepositoryTechnology) *RepositoryUpdate

RemoveTechnologies removes "technologies" edges to RepositoryTechnology entities.

func (*RepositoryUpdate) RemoveTechnologyIDs

func (ru *RepositoryUpdate) RemoveTechnologyIDs(ids ...int) *RepositoryUpdate

RemoveTechnologyIDs removes the "technologies" edge to RepositoryTechnology entities by IDs.

func (*RepositoryUpdate) Save

func (ru *RepositoryUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*RepositoryUpdate) SaveX

func (ru *RepositoryUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*RepositoryUpdate) SetDescription

func (ru *RepositoryUpdate) SetDescription(s string) *RepositoryUpdate

SetDescription sets the "description" field.

func (*RepositoryUpdate) SetGithubAccount

func (ru *RepositoryUpdate) SetGithubAccount(g *GithubAccount) *RepositoryUpdate

SetGithubAccount sets the "github_account" edge to the GithubAccount entity.

func (*RepositoryUpdate) SetGithubAccountID

func (ru *RepositoryUpdate) SetGithubAccountID(id int) *RepositoryUpdate

SetGithubAccountID sets the "github_account" edge to the GithubAccount entity by ID.

func (*RepositoryUpdate) SetGithubOrganization

func (ru *RepositoryUpdate) SetGithubOrganization(g *GithubOrganization) *RepositoryUpdate

SetGithubOrganization sets the "github_organization" edge to the GithubOrganization entity.

func (*RepositoryUpdate) SetGithubOrganizationID

func (ru *RepositoryUpdate) SetGithubOrganizationID(id int) *RepositoryUpdate

SetGithubOrganizationID sets the "github_organization" edge to the GithubOrganization entity by ID.

func (*RepositoryUpdate) SetInput

SetInput applies the change-set in the UpdateRepositoryInput on the update builder.

func (*RepositoryUpdate) SetName

func (ru *RepositoryUpdate) SetName(s string) *RepositoryUpdate

SetName sets the "name" field.

func (*RepositoryUpdate) SetNillableDescription

func (ru *RepositoryUpdate) SetNillableDescription(s *string) *RepositoryUpdate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*RepositoryUpdate) SetNillableGithubAccountID

func (ru *RepositoryUpdate) SetNillableGithubAccountID(id *int) *RepositoryUpdate

SetNillableGithubAccountID sets the "github_account" edge to the GithubAccount entity by ID if the given value is not nil.

func (*RepositoryUpdate) SetNillableGithubOrganizationID

func (ru *RepositoryUpdate) SetNillableGithubOrganizationID(id *int) *RepositoryUpdate

SetNillableGithubOrganizationID sets the "github_organization" edge to the GithubOrganization entity by ID if the given value is not nil.

func (*RepositoryUpdate) SetProject

func (ru *RepositoryUpdate) SetProject(p *Project) *RepositoryUpdate

SetProject sets the "project" edge to the Project entity.

func (*RepositoryUpdate) SetProjectID

func (ru *RepositoryUpdate) SetProjectID(id int) *RepositoryUpdate

SetProjectID sets the "project" edge to the Project entity by ID.

func (*RepositoryUpdate) Where

Where appends a list predicates to the RepositoryUpdate builder.

type RepositoryUpdateOne

type RepositoryUpdateOne struct {
	// contains filtered or unexported fields
}

RepositoryUpdateOne is the builder for updating a single Repository entity.

func (*RepositoryUpdateOne) AddDiscordBotIDs

func (ruo *RepositoryUpdateOne) AddDiscordBotIDs(ids ...int) *RepositoryUpdateOne

AddDiscordBotIDs adds the "discord_bots" edge to the DiscordBot entity by IDs.

func (*RepositoryUpdateOne) AddDiscordBots

func (ruo *RepositoryUpdateOne) AddDiscordBots(d ...*DiscordBot) *RepositoryUpdateOne

AddDiscordBots adds the "discord_bots" edges to the DiscordBot entity.

func (*RepositoryUpdateOne) AddSiteIDs

func (ruo *RepositoryUpdateOne) AddSiteIDs(ids ...int) *RepositoryUpdateOne

AddSiteIDs adds the "sites" edge to the Site entity by IDs.

func (*RepositoryUpdateOne) AddSites

func (ruo *RepositoryUpdateOne) AddSites(s ...*Site) *RepositoryUpdateOne

AddSites adds the "sites" edges to the Site entity.

func (*RepositoryUpdateOne) AddTechnologies

func (ruo *RepositoryUpdateOne) AddTechnologies(r ...*RepositoryTechnology) *RepositoryUpdateOne

AddTechnologies adds the "technologies" edges to the RepositoryTechnology entity.

func (*RepositoryUpdateOne) AddTechnologyIDs

func (ruo *RepositoryUpdateOne) AddTechnologyIDs(ids ...int) *RepositoryUpdateOne

AddTechnologyIDs adds the "technologies" edge to the RepositoryTechnology entity by IDs.

func (*RepositoryUpdateOne) ClearDescription

func (ruo *RepositoryUpdateOne) ClearDescription() *RepositoryUpdateOne

ClearDescription clears the value of the "description" field.

func (*RepositoryUpdateOne) ClearDiscordBots

func (ruo *RepositoryUpdateOne) ClearDiscordBots() *RepositoryUpdateOne

ClearDiscordBots clears all "discord_bots" edges to the DiscordBot entity.

func (*RepositoryUpdateOne) ClearGithubAccount

func (ruo *RepositoryUpdateOne) ClearGithubAccount() *RepositoryUpdateOne

ClearGithubAccount clears the "github_account" edge to the GithubAccount entity.

func (*RepositoryUpdateOne) ClearGithubOrganization

func (ruo *RepositoryUpdateOne) ClearGithubOrganization() *RepositoryUpdateOne

ClearGithubOrganization clears the "github_organization" edge to the GithubOrganization entity.

func (*RepositoryUpdateOne) ClearProject

func (ruo *RepositoryUpdateOne) ClearProject() *RepositoryUpdateOne

ClearProject clears the "project" edge to the Project entity.

func (*RepositoryUpdateOne) ClearSites

func (ruo *RepositoryUpdateOne) ClearSites() *RepositoryUpdateOne

ClearSites clears all "sites" edges to the Site entity.

func (*RepositoryUpdateOne) ClearTechnologies

func (ruo *RepositoryUpdateOne) ClearTechnologies() *RepositoryUpdateOne

ClearTechnologies clears all "technologies" edges to the RepositoryTechnology entity.

func (*RepositoryUpdateOne) Exec

func (ruo *RepositoryUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*RepositoryUpdateOne) ExecX

func (ruo *RepositoryUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryUpdateOne) Mutation

func (ruo *RepositoryUpdateOne) Mutation() *RepositoryMutation

Mutation returns the RepositoryMutation object of the builder.

func (*RepositoryUpdateOne) RemoveDiscordBotIDs

func (ruo *RepositoryUpdateOne) RemoveDiscordBotIDs(ids ...int) *RepositoryUpdateOne

RemoveDiscordBotIDs removes the "discord_bots" edge to DiscordBot entities by IDs.

func (*RepositoryUpdateOne) RemoveDiscordBots

func (ruo *RepositoryUpdateOne) RemoveDiscordBots(d ...*DiscordBot) *RepositoryUpdateOne

RemoveDiscordBots removes "discord_bots" edges to DiscordBot entities.

func (*RepositoryUpdateOne) RemoveSiteIDs

func (ruo *RepositoryUpdateOne) RemoveSiteIDs(ids ...int) *RepositoryUpdateOne

RemoveSiteIDs removes the "sites" edge to Site entities by IDs.

func (*RepositoryUpdateOne) RemoveSites

func (ruo *RepositoryUpdateOne) RemoveSites(s ...*Site) *RepositoryUpdateOne

RemoveSites removes "sites" edges to Site entities.

func (*RepositoryUpdateOne) RemoveTechnologies

func (ruo *RepositoryUpdateOne) RemoveTechnologies(r ...*RepositoryTechnology) *RepositoryUpdateOne

RemoveTechnologies removes "technologies" edges to RepositoryTechnology entities.

func (*RepositoryUpdateOne) RemoveTechnologyIDs

func (ruo *RepositoryUpdateOne) RemoveTechnologyIDs(ids ...int) *RepositoryUpdateOne

RemoveTechnologyIDs removes the "technologies" edge to RepositoryTechnology entities by IDs.

func (*RepositoryUpdateOne) Save

func (ruo *RepositoryUpdateOne) Save(ctx context.Context) (*Repository, error)

Save executes the query and returns the updated Repository entity.

func (*RepositoryUpdateOne) SaveX

func (ruo *RepositoryUpdateOne) SaveX(ctx context.Context) *Repository

SaveX is like Save, but panics if an error occurs.

func (*RepositoryUpdateOne) Select

func (ruo *RepositoryUpdateOne) Select(field string, fields ...string) *RepositoryUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*RepositoryUpdateOne) SetDescription

func (ruo *RepositoryUpdateOne) SetDescription(s string) *RepositoryUpdateOne

SetDescription sets the "description" field.

func (*RepositoryUpdateOne) SetGithubAccount

func (ruo *RepositoryUpdateOne) SetGithubAccount(g *GithubAccount) *RepositoryUpdateOne

SetGithubAccount sets the "github_account" edge to the GithubAccount entity.

func (*RepositoryUpdateOne) SetGithubAccountID

func (ruo *RepositoryUpdateOne) SetGithubAccountID(id int) *RepositoryUpdateOne

SetGithubAccountID sets the "github_account" edge to the GithubAccount entity by ID.

func (*RepositoryUpdateOne) SetGithubOrganization

func (ruo *RepositoryUpdateOne) SetGithubOrganization(g *GithubOrganization) *RepositoryUpdateOne

SetGithubOrganization sets the "github_organization" edge to the GithubOrganization entity.

func (*RepositoryUpdateOne) SetGithubOrganizationID

func (ruo *RepositoryUpdateOne) SetGithubOrganizationID(id int) *RepositoryUpdateOne

SetGithubOrganizationID sets the "github_organization" edge to the GithubOrganization entity by ID.

func (*RepositoryUpdateOne) SetInput

SetInput applies the change-set in the UpdateRepositoryInput on the update-one builder.

func (*RepositoryUpdateOne) SetName

SetName sets the "name" field.

func (*RepositoryUpdateOne) SetNillableDescription

func (ruo *RepositoryUpdateOne) SetNillableDescription(s *string) *RepositoryUpdateOne

SetNillableDescription sets the "description" field if the given value is not nil.

func (*RepositoryUpdateOne) SetNillableGithubAccountID

func (ruo *RepositoryUpdateOne) SetNillableGithubAccountID(id *int) *RepositoryUpdateOne

SetNillableGithubAccountID sets the "github_account" edge to the GithubAccount entity by ID if the given value is not nil.

func (*RepositoryUpdateOne) SetNillableGithubOrganizationID

func (ruo *RepositoryUpdateOne) SetNillableGithubOrganizationID(id *int) *RepositoryUpdateOne

SetNillableGithubOrganizationID sets the "github_organization" edge to the GithubOrganization entity by ID if the given value is not nil.

func (*RepositoryUpdateOne) SetProject

func (ruo *RepositoryUpdateOne) SetProject(p *Project) *RepositoryUpdateOne

SetProject sets the "project" edge to the Project entity.

func (*RepositoryUpdateOne) SetProjectID

func (ruo *RepositoryUpdateOne) SetProjectID(id int) *RepositoryUpdateOne

SetProjectID sets the "project" edge to the Project entity by ID.

type RepositoryWhereInput

type RepositoryWhereInput struct {
	Predicates []predicate.Repository  `json:"-"`
	Not        *RepositoryWhereInput   `json:"not,omitempty"`
	Or         []*RepositoryWhereInput `json:"or,omitempty"`
	And        []*RepositoryWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "name" field predicates.
	Name             *string  `json:"name,omitempty"`
	NameNEQ          *string  `json:"nameNEQ,omitempty"`
	NameIn           []string `json:"nameIn,omitempty"`
	NameNotIn        []string `json:"nameNotIn,omitempty"`
	NameGT           *string  `json:"nameGT,omitempty"`
	NameGTE          *string  `json:"nameGTE,omitempty"`
	NameLT           *string  `json:"nameLT,omitempty"`
	NameLTE          *string  `json:"nameLTE,omitempty"`
	NameContains     *string  `json:"nameContains,omitempty"`
	NameHasPrefix    *string  `json:"nameHasPrefix,omitempty"`
	NameHasSuffix    *string  `json:"nameHasSuffix,omitempty"`
	NameEqualFold    *string  `json:"nameEqualFold,omitempty"`
	NameContainsFold *string  `json:"nameContainsFold,omitempty"`

	// "description" field predicates.
	Description             *string  `json:"description,omitempty"`
	DescriptionNEQ          *string  `json:"descriptionNEQ,omitempty"`
	DescriptionIn           []string `json:"descriptionIn,omitempty"`
	DescriptionNotIn        []string `json:"descriptionNotIn,omitempty"`
	DescriptionGT           *string  `json:"descriptionGT,omitempty"`
	DescriptionGTE          *string  `json:"descriptionGTE,omitempty"`
	DescriptionLT           *string  `json:"descriptionLT,omitempty"`
	DescriptionLTE          *string  `json:"descriptionLTE,omitempty"`
	DescriptionContains     *string  `json:"descriptionContains,omitempty"`
	DescriptionHasPrefix    *string  `json:"descriptionHasPrefix,omitempty"`
	DescriptionHasSuffix    *string  `json:"descriptionHasSuffix,omitempty"`
	DescriptionIsNil        bool     `json:"descriptionIsNil,omitempty"`
	DescriptionNotNil       bool     `json:"descriptionNotNil,omitempty"`
	DescriptionEqualFold    *string  `json:"descriptionEqualFold,omitempty"`
	DescriptionContainsFold *string  `json:"descriptionContainsFold,omitempty"`

	// "project" edge predicates.
	HasProject     *bool                `json:"hasProject,omitempty"`
	HasProjectWith []*ProjectWhereInput `json:"hasProjectWith,omitempty"`

	// "github_account" edge predicates.
	HasGithubAccount     *bool                      `json:"hasGithubAccount,omitempty"`
	HasGithubAccountWith []*GithubAccountWhereInput `json:"hasGithubAccountWith,omitempty"`

	// "github_organization" edge predicates.
	HasGithubOrganization     *bool                           `json:"hasGithubOrganization,omitempty"`
	HasGithubOrganizationWith []*GithubOrganizationWhereInput `json:"hasGithubOrganizationWith,omitempty"`

	// "discord_bots" edge predicates.
	HasDiscordBots     *bool                   `json:"hasDiscordBots,omitempty"`
	HasDiscordBotsWith []*DiscordBotWhereInput `json:"hasDiscordBotsWith,omitempty"`

	// "sites" edge predicates.
	HasSites     *bool             `json:"hasSites,omitempty"`
	HasSitesWith []*SiteWhereInput `json:"hasSitesWith,omitempty"`

	// "technologies" edge predicates.
	HasTechnologies     *bool                             `json:"hasTechnologies,omitempty"`
	HasTechnologiesWith []*RepositoryTechnologyWhereInput `json:"hasTechnologiesWith,omitempty"`
}

RepositoryWhereInput represents a where input for filtering Repository queries.

func (*RepositoryWhereInput) AddPredicates

func (i *RepositoryWhereInput) AddPredicates(predicates ...predicate.Repository)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*RepositoryWhereInput) Filter

Filter applies the RepositoryWhereInput filter on the RepositoryQuery builder.

func (*RepositoryWhereInput) P

P returns a predicate for filtering repositories. An error is returned if the input is empty or invalid.

type RollbackFunc

type RollbackFunc func(context.Context, *Tx) error

The RollbackFunc type is an adapter to allow the use of ordinary function as a Rollbacker. If f is a function with the appropriate signature, RollbackFunc(f) is a Rollbacker that calls f.

func (RollbackFunc) Rollback

func (f RollbackFunc) Rollback(ctx context.Context, tx *Tx) error

Rollback calls f(ctx, m).

type RollbackHook

type RollbackHook func(Rollbacker) Rollbacker

RollbackHook defines the "rollback middleware". A function that gets a Rollbacker and returns a Rollbacker. For example:

hook := func(next ent.Rollbacker) ent.Rollbacker {
	return ent.RollbackFunc(func(ctx context.Context, tx *ent.Tx) error {
		// Do some stuff before.
		if err := next.Rollback(ctx, tx); err != nil {
			return err
		}
		// Do some stuff after.
		return nil
	})
}

type Rollbacker

type Rollbacker interface {
	Rollback(context.Context, *Tx) error
}

Rollbacker is the interface that wraps the Rollback method.

type Site

type Site struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// URL holds the value of the "url" field.
	URL string `json:"url,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the SiteQuery when eager-loading is set.
	Edges SiteEdges `json:"edges"`
	// contains filtered or unexported fields
}

Site is the model entity for the Site schema.

func (*Site) Node

func (s *Site) Node(ctx context.Context) (node *Node, err error)

func (*Site) Project

func (s *Site) Project(ctx context.Context) (*Project, error)

func (*Site) QueryProject

func (s *Site) QueryProject() *ProjectQuery

QueryProject queries the "project" edge of the Site entity.

func (*Site) QueryRepository

func (s *Site) QueryRepository() *RepositoryQuery

QueryRepository queries the "repository" edge of the Site entity.

func (*Site) Repository

func (s *Site) Repository(ctx context.Context) (*Repository, error)

func (*Site) String

func (s *Site) String() string

String implements the fmt.Stringer.

func (*Site) ToEdge

func (s *Site) ToEdge(order *SiteOrder) *SiteEdge

ToEdge converts Site into SiteEdge.

func (*Site) Unwrap

func (s *Site) Unwrap() *Site

Unwrap unwraps the Site entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*Site) Update

func (s *Site) Update() *SiteUpdateOne

Update returns a builder for updating this Site. Note that you need to call Site.Unwrap() before calling this method if this Site was returned from a transaction, and the transaction was committed or rolled back.

type SiteClient

type SiteClient struct {
	// contains filtered or unexported fields
}

SiteClient is a client for the Site schema.

func NewSiteClient

func NewSiteClient(c config) *SiteClient

NewSiteClient returns a client for the Site from the given config.

func (*SiteClient) Create

func (c *SiteClient) Create() *SiteCreate

Create returns a builder for creating a Site entity.

func (*SiteClient) CreateBulk

func (c *SiteClient) CreateBulk(builders ...*SiteCreate) *SiteCreateBulk

CreateBulk returns a builder for creating a bulk of Site entities.

func (*SiteClient) Delete

func (c *SiteClient) Delete() *SiteDelete

Delete returns a delete builder for Site.

func (*SiteClient) DeleteOne

func (c *SiteClient) DeleteOne(s *Site) *SiteDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*SiteClient) DeleteOneID

func (c *SiteClient) DeleteOneID(id int) *SiteDeleteOne

DeleteOne returns a builder for deleting the given entity by its id.

func (*SiteClient) Get

func (c *SiteClient) Get(ctx context.Context, id int) (*Site, error)

Get returns a Site entity by its id.

func (*SiteClient) GetX

func (c *SiteClient) GetX(ctx context.Context, id int) *Site

GetX is like Get, but panics if an error occurs.

func (*SiteClient) Hooks

func (c *SiteClient) Hooks() []Hook

Hooks returns the client hooks.

func (*SiteClient) Query

func (c *SiteClient) Query() *SiteQuery

Query returns a query builder for Site.

func (*SiteClient) QueryProject

func (c *SiteClient) QueryProject(s *Site) *ProjectQuery

QueryProject queries the project edge of a Site.

func (*SiteClient) QueryRepository

func (c *SiteClient) QueryRepository(s *Site) *RepositoryQuery

QueryRepository queries the repository edge of a Site.

func (*SiteClient) Update

func (c *SiteClient) Update() *SiteUpdate

Update returns an update builder for Site.

func (*SiteClient) UpdateOne

func (c *SiteClient) UpdateOne(s *Site) *SiteUpdateOne

UpdateOne returns an update builder for the given entity.

func (*SiteClient) UpdateOneID

func (c *SiteClient) UpdateOneID(id int) *SiteUpdateOne

UpdateOneID returns an update builder for the given id.

func (*SiteClient) Use

func (c *SiteClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `site.Hooks(f(g(h())))`.

type SiteConnection

type SiteConnection struct {
	Edges      []*SiteEdge `json:"edges"`
	PageInfo   PageInfo    `json:"pageInfo"`
	TotalCount int         `json:"totalCount"`
}

SiteConnection is the connection containing edges to Site.

type SiteCreate

type SiteCreate struct {
	// contains filtered or unexported fields
}

SiteCreate is the builder for creating a Site entity.

func (*SiteCreate) Exec

func (sc *SiteCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*SiteCreate) ExecX

func (sc *SiteCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SiteCreate) Mutation

func (sc *SiteCreate) Mutation() *SiteMutation

Mutation returns the SiteMutation object of the builder.

func (*SiteCreate) Save

func (sc *SiteCreate) Save(ctx context.Context) (*Site, error)

Save creates the Site in the database.

func (*SiteCreate) SaveX

func (sc *SiteCreate) SaveX(ctx context.Context) *Site

SaveX calls Save and panics if Save returns an error.

func (*SiteCreate) SetInput

func (c *SiteCreate) SetInput(i CreateSiteInput) *SiteCreate

SetInput applies the change-set in the CreateSiteInput on the create builder.

func (*SiteCreate) SetNillableRepositoryID

func (sc *SiteCreate) SetNillableRepositoryID(id *int) *SiteCreate

SetNillableRepositoryID sets the "repository" edge to the Repository entity by ID if the given value is not nil.

func (*SiteCreate) SetProject

func (sc *SiteCreate) SetProject(p *Project) *SiteCreate

SetProject sets the "project" edge to the Project entity.

func (*SiteCreate) SetProjectID

func (sc *SiteCreate) SetProjectID(id int) *SiteCreate

SetProjectID sets the "project" edge to the Project entity by ID.

func (*SiteCreate) SetRepository

func (sc *SiteCreate) SetRepository(r *Repository) *SiteCreate

SetRepository sets the "repository" edge to the Repository entity.

func (*SiteCreate) SetRepositoryID

func (sc *SiteCreate) SetRepositoryID(id int) *SiteCreate

SetRepositoryID sets the "repository" edge to the Repository entity by ID.

func (*SiteCreate) SetURL

func (sc *SiteCreate) SetURL(s string) *SiteCreate

SetURL sets the "url" field.

type SiteCreateBulk

type SiteCreateBulk struct {
	// contains filtered or unexported fields
}

SiteCreateBulk is the builder for creating many Site entities in bulk.

func (*SiteCreateBulk) Exec

func (scb *SiteCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*SiteCreateBulk) ExecX

func (scb *SiteCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SiteCreateBulk) Save

func (scb *SiteCreateBulk) Save(ctx context.Context) ([]*Site, error)

Save creates the Site entities in the database.

func (*SiteCreateBulk) SaveX

func (scb *SiteCreateBulk) SaveX(ctx context.Context) []*Site

SaveX is like Save, but panics if an error occurs.

type SiteDelete

type SiteDelete struct {
	// contains filtered or unexported fields
}

SiteDelete is the builder for deleting a Site entity.

func (*SiteDelete) Exec

func (sd *SiteDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*SiteDelete) ExecX

func (sd *SiteDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*SiteDelete) Where

func (sd *SiteDelete) Where(ps ...predicate.Site) *SiteDelete

Where appends a list predicates to the SiteDelete builder.

type SiteDeleteOne

type SiteDeleteOne struct {
	// contains filtered or unexported fields
}

SiteDeleteOne is the builder for deleting a single Site entity.

func (*SiteDeleteOne) Exec

func (sdo *SiteDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*SiteDeleteOne) ExecX

func (sdo *SiteDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

type SiteEdge

type SiteEdge struct {
	Node   *Site  `json:"node"`
	Cursor Cursor `json:"cursor"`
}

SiteEdge is the edge representation of Site.

type SiteEdges

type SiteEdges struct {
	// Project holds the value of the project edge.
	Project *Project `json:"project,omitempty"`
	// Repository holds the value of the repository edge.
	Repository *Repository `json:"repository,omitempty"`
	// contains filtered or unexported fields
}

SiteEdges holds the relations/edges for other nodes in the graph.

func (SiteEdges) ProjectOrErr

func (e SiteEdges) ProjectOrErr() (*Project, error)

ProjectOrErr returns the Project value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (SiteEdges) RepositoryOrErr

func (e SiteEdges) RepositoryOrErr() (*Repository, error)

RepositoryOrErr returns the Repository value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type SiteGroupBy

type SiteGroupBy struct {
	// contains filtered or unexported fields
}

SiteGroupBy is the group-by builder for Site entities.

func (*SiteGroupBy) Aggregate

func (sgb *SiteGroupBy) Aggregate(fns ...AggregateFunc) *SiteGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*SiteGroupBy) Bool

func (s *SiteGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*SiteGroupBy) BoolX

func (s *SiteGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*SiteGroupBy) Bools

func (s *SiteGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*SiteGroupBy) BoolsX

func (s *SiteGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*SiteGroupBy) Float64

func (s *SiteGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*SiteGroupBy) Float64X

func (s *SiteGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*SiteGroupBy) Float64s

func (s *SiteGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*SiteGroupBy) Float64sX

func (s *SiteGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*SiteGroupBy) Int

func (s *SiteGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*SiteGroupBy) IntX

func (s *SiteGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*SiteGroupBy) Ints

func (s *SiteGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*SiteGroupBy) IntsX

func (s *SiteGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*SiteGroupBy) Scan

func (sgb *SiteGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*SiteGroupBy) ScanX

func (s *SiteGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*SiteGroupBy) String

func (s *SiteGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*SiteGroupBy) StringX

func (s *SiteGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*SiteGroupBy) Strings

func (s *SiteGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*SiteGroupBy) StringsX

func (s *SiteGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type SiteMutation

type SiteMutation struct {
	// contains filtered or unexported fields
}

SiteMutation represents an operation that mutates the Site nodes in the graph.

func (*SiteMutation) AddField

func (m *SiteMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*SiteMutation) AddedEdges

func (m *SiteMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*SiteMutation) AddedField

func (m *SiteMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*SiteMutation) AddedFields

func (m *SiteMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*SiteMutation) AddedIDs

func (m *SiteMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*SiteMutation) ClearEdge

func (m *SiteMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*SiteMutation) ClearField

func (m *SiteMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*SiteMutation) ClearProject

func (m *SiteMutation) ClearProject()

ClearProject clears the "project" edge to the Project entity.

func (*SiteMutation) ClearRepository

func (m *SiteMutation) ClearRepository()

ClearRepository clears the "repository" edge to the Repository entity.

func (*SiteMutation) ClearedEdges

func (m *SiteMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*SiteMutation) ClearedFields

func (m *SiteMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (SiteMutation) Client

func (m SiteMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*SiteMutation) EdgeCleared

func (m *SiteMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*SiteMutation) Field

func (m *SiteMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*SiteMutation) FieldCleared

func (m *SiteMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*SiteMutation) Fields

func (m *SiteMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*SiteMutation) ID

func (m *SiteMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*SiteMutation) IDs

func (m *SiteMutation) IDs(ctx context.Context) ([]int, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*SiteMutation) OldField

func (m *SiteMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*SiteMutation) OldURL

func (m *SiteMutation) OldURL(ctx context.Context) (v string, err error)

OldURL returns the old "url" field's value of the Site entity. If the Site object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*SiteMutation) Op

func (m *SiteMutation) Op() Op

Op returns the operation name.

func (*SiteMutation) ProjectCleared

func (m *SiteMutation) ProjectCleared() bool

ProjectCleared reports if the "project" edge to the Project entity was cleared.

func (*SiteMutation) ProjectID

func (m *SiteMutation) ProjectID() (id int, exists bool)

ProjectID returns the "project" edge ID in the mutation.

func (*SiteMutation) ProjectIDs

func (m *SiteMutation) ProjectIDs() (ids []int)

ProjectIDs returns the "project" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ProjectID instead. It exists only for internal usage by the builders.

func (*SiteMutation) RemovedEdges

func (m *SiteMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*SiteMutation) RemovedIDs

func (m *SiteMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*SiteMutation) RepositoryCleared

func (m *SiteMutation) RepositoryCleared() bool

RepositoryCleared reports if the "repository" edge to the Repository entity was cleared.

func (*SiteMutation) RepositoryID

func (m *SiteMutation) RepositoryID() (id int, exists bool)

RepositoryID returns the "repository" edge ID in the mutation.

func (*SiteMutation) RepositoryIDs

func (m *SiteMutation) RepositoryIDs() (ids []int)

RepositoryIDs returns the "repository" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use RepositoryID instead. It exists only for internal usage by the builders.

func (*SiteMutation) ResetEdge

func (m *SiteMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*SiteMutation) ResetField

func (m *SiteMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*SiteMutation) ResetProject

func (m *SiteMutation) ResetProject()

ResetProject resets all changes to the "project" edge.

func (*SiteMutation) ResetRepository

func (m *SiteMutation) ResetRepository()

ResetRepository resets all changes to the "repository" edge.

func (*SiteMutation) ResetURL

func (m *SiteMutation) ResetURL()

ResetURL resets all changes to the "url" field.

func (*SiteMutation) SetField

func (m *SiteMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*SiteMutation) SetProjectID

func (m *SiteMutation) SetProjectID(id int)

SetProjectID sets the "project" edge to the Project entity by id.

func (*SiteMutation) SetRepositoryID

func (m *SiteMutation) SetRepositoryID(id int)

SetRepositoryID sets the "repository" edge to the Repository entity by id.

func (*SiteMutation) SetURL

func (m *SiteMutation) SetURL(s string)

SetURL sets the "url" field.

func (SiteMutation) Tx

func (m SiteMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*SiteMutation) Type

func (m *SiteMutation) Type() string

Type returns the node type of this mutation (Site).

func (*SiteMutation) URL

func (m *SiteMutation) URL() (r string, exists bool)

URL returns the value of the "url" field in the mutation.

func (*SiteMutation) Where

func (m *SiteMutation) Where(ps ...predicate.Site)

Where appends a list predicates to the SiteMutation builder.

type SiteOrder

type SiteOrder struct {
	Direction OrderDirection  `json:"direction"`
	Field     *SiteOrderField `json:"field"`
}

SiteOrder defines the ordering of Site.

type SiteOrderField

type SiteOrderField struct {
	// contains filtered or unexported fields
}

SiteOrderField defines the ordering field of Site.

func (SiteOrderField) MarshalGQL

func (f SiteOrderField) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (SiteOrderField) String

func (f SiteOrderField) String() string

String implement fmt.Stringer interface.

func (*SiteOrderField) UnmarshalGQL

func (f *SiteOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type SitePaginateOption

type SitePaginateOption func(*sitePager) error

SitePaginateOption enables pagination customization.

func WithSiteFilter

func WithSiteFilter(filter func(*SiteQuery) (*SiteQuery, error)) SitePaginateOption

WithSiteFilter configures pagination filter.

func WithSiteOrder

func WithSiteOrder(order *SiteOrder) SitePaginateOption

WithSiteOrder configures pagination ordering.

type SiteQuery

type SiteQuery struct {
	// contains filtered or unexported fields
}

SiteQuery is the builder for querying Site entities.

func (*SiteQuery) All

func (sq *SiteQuery) All(ctx context.Context) ([]*Site, error)

All executes the query and returns a list of Sites.

func (*SiteQuery) AllX

func (sq *SiteQuery) AllX(ctx context.Context) []*Site

AllX is like All, but panics if an error occurs.

func (*SiteQuery) Clone

func (sq *SiteQuery) Clone() *SiteQuery

Clone returns a duplicate of the SiteQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*SiteQuery) CollectFields

func (s *SiteQuery) CollectFields(ctx context.Context, satisfies ...string) (*SiteQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*SiteQuery) Count

func (sq *SiteQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*SiteQuery) CountX

func (sq *SiteQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*SiteQuery) Exist

func (sq *SiteQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*SiteQuery) ExistX

func (sq *SiteQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*SiteQuery) First

func (sq *SiteQuery) First(ctx context.Context) (*Site, error)

First returns the first Site entity from the query. Returns a *NotFoundError when no Site was found.

func (*SiteQuery) FirstID

func (sq *SiteQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first Site ID from the query. Returns a *NotFoundError when no Site ID was found.

func (*SiteQuery) FirstIDX

func (sq *SiteQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*SiteQuery) FirstX

func (sq *SiteQuery) FirstX(ctx context.Context) *Site

FirstX is like First, but panics if an error occurs.

func (*SiteQuery) GroupBy

func (sq *SiteQuery) GroupBy(field string, fields ...string) *SiteGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	URL string `json:"url,omitempty"`
	Count int `json:"count,omitempty"`
}

client.Site.Query().
	GroupBy(site.FieldURL).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*SiteQuery) IDs

func (sq *SiteQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of Site IDs.

func (*SiteQuery) IDsX

func (sq *SiteQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*SiteQuery) Limit

func (sq *SiteQuery) Limit(limit int) *SiteQuery

Limit adds a limit step to the query.

func (*SiteQuery) Offset

func (sq *SiteQuery) Offset(offset int) *SiteQuery

Offset adds an offset step to the query.

func (*SiteQuery) Only

func (sq *SiteQuery) Only(ctx context.Context) (*Site, error)

Only returns a single Site entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Site entity is found. Returns a *NotFoundError when no Site entities are found.

func (*SiteQuery) OnlyID

func (sq *SiteQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only Site ID in the query. Returns a *NotSingularError when more than one Site ID is found. Returns a *NotFoundError when no entities are found.

func (*SiteQuery) OnlyIDX

func (sq *SiteQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*SiteQuery) OnlyX

func (sq *SiteQuery) OnlyX(ctx context.Context) *Site

OnlyX is like Only, but panics if an error occurs.

func (*SiteQuery) Order

func (sq *SiteQuery) Order(o ...OrderFunc) *SiteQuery

Order adds an order step to the query.

func (*SiteQuery) Paginate

func (s *SiteQuery) Paginate(
	ctx context.Context, after *Cursor, first *int,
	before *Cursor, last *int, opts ...SitePaginateOption,
) (*SiteConnection, error)

Paginate executes the query and returns a relay based cursor connection to Site.

func (*SiteQuery) QueryProject

func (sq *SiteQuery) QueryProject() *ProjectQuery

QueryProject chains the current query on the "project" edge.

func (*SiteQuery) QueryRepository

func (sq *SiteQuery) QueryRepository() *RepositoryQuery

QueryRepository chains the current query on the "repository" edge.

func (*SiteQuery) Select

func (sq *SiteQuery) Select(fields ...string) *SiteSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	URL string `json:"url,omitempty"`
}

client.Site.Query().
	Select(site.FieldURL).
	Scan(ctx, &v)

func (*SiteQuery) Unique

func (sq *SiteQuery) Unique(unique bool) *SiteQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*SiteQuery) Where

func (sq *SiteQuery) Where(ps ...predicate.Site) *SiteQuery

Where adds a new predicate for the SiteQuery builder.

func (*SiteQuery) WithProject

func (sq *SiteQuery) WithProject(opts ...func(*ProjectQuery)) *SiteQuery

WithProject tells the query-builder to eager-load the nodes that are connected to the "project" edge. The optional arguments are used to configure the query builder of the edge.

func (*SiteQuery) WithRepository

func (sq *SiteQuery) WithRepository(opts ...func(*RepositoryQuery)) *SiteQuery

WithRepository tells the query-builder to eager-load the nodes that are connected to the "repository" edge. The optional arguments are used to configure the query builder of the edge.

type SiteSelect

type SiteSelect struct {
	*SiteQuery
	// contains filtered or unexported fields
}

SiteSelect is the builder for selecting fields of Site entities.

func (*SiteSelect) Bool

func (s *SiteSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*SiteSelect) BoolX

func (s *SiteSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*SiteSelect) Bools

func (s *SiteSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*SiteSelect) BoolsX

func (s *SiteSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*SiteSelect) Float64

func (s *SiteSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*SiteSelect) Float64X

func (s *SiteSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*SiteSelect) Float64s

func (s *SiteSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*SiteSelect) Float64sX

func (s *SiteSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*SiteSelect) Int

func (s *SiteSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*SiteSelect) IntX

func (s *SiteSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*SiteSelect) Ints

func (s *SiteSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*SiteSelect) IntsX

func (s *SiteSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*SiteSelect) Scan

func (ss *SiteSelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*SiteSelect) ScanX

func (s *SiteSelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*SiteSelect) String

func (s *SiteSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*SiteSelect) StringX

func (s *SiteSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*SiteSelect) Strings

func (s *SiteSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*SiteSelect) StringsX

func (s *SiteSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type SiteUpdate

type SiteUpdate struct {
	// contains filtered or unexported fields
}

SiteUpdate is the builder for updating Site entities.

func (*SiteUpdate) ClearProject

func (su *SiteUpdate) ClearProject() *SiteUpdate

ClearProject clears the "project" edge to the Project entity.

func (*SiteUpdate) ClearRepository

func (su *SiteUpdate) ClearRepository() *SiteUpdate

ClearRepository clears the "repository" edge to the Repository entity.

func (*SiteUpdate) Exec

func (su *SiteUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*SiteUpdate) ExecX

func (su *SiteUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SiteUpdate) Mutation

func (su *SiteUpdate) Mutation() *SiteMutation

Mutation returns the SiteMutation object of the builder.

func (*SiteUpdate) Save

func (su *SiteUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*SiteUpdate) SaveX

func (su *SiteUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*SiteUpdate) SetInput

func (u *SiteUpdate) SetInput(i UpdateSiteInput) *SiteUpdate

SetInput applies the change-set in the UpdateSiteInput on the update builder.

func (*SiteUpdate) SetNillableRepositoryID

func (su *SiteUpdate) SetNillableRepositoryID(id *int) *SiteUpdate

SetNillableRepositoryID sets the "repository" edge to the Repository entity by ID if the given value is not nil.

func (*SiteUpdate) SetProject

func (su *SiteUpdate) SetProject(p *Project) *SiteUpdate

SetProject sets the "project" edge to the Project entity.

func (*SiteUpdate) SetProjectID

func (su *SiteUpdate) SetProjectID(id int) *SiteUpdate

SetProjectID sets the "project" edge to the Project entity by ID.

func (*SiteUpdate) SetRepository

func (su *SiteUpdate) SetRepository(r *Repository) *SiteUpdate

SetRepository sets the "repository" edge to the Repository entity.

func (*SiteUpdate) SetRepositoryID

func (su *SiteUpdate) SetRepositoryID(id int) *SiteUpdate

SetRepositoryID sets the "repository" edge to the Repository entity by ID.

func (*SiteUpdate) SetURL

func (su *SiteUpdate) SetURL(s string) *SiteUpdate

SetURL sets the "url" field.

func (*SiteUpdate) Where

func (su *SiteUpdate) Where(ps ...predicate.Site) *SiteUpdate

Where appends a list predicates to the SiteUpdate builder.

type SiteUpdateOne

type SiteUpdateOne struct {
	// contains filtered or unexported fields
}

SiteUpdateOne is the builder for updating a single Site entity.

func (*SiteUpdateOne) ClearProject

func (suo *SiteUpdateOne) ClearProject() *SiteUpdateOne

ClearProject clears the "project" edge to the Project entity.

func (*SiteUpdateOne) ClearRepository

func (suo *SiteUpdateOne) ClearRepository() *SiteUpdateOne

ClearRepository clears the "repository" edge to the Repository entity.

func (*SiteUpdateOne) Exec

func (suo *SiteUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*SiteUpdateOne) ExecX

func (suo *SiteUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SiteUpdateOne) Mutation

func (suo *SiteUpdateOne) Mutation() *SiteMutation

Mutation returns the SiteMutation object of the builder.

func (*SiteUpdateOne) Save

func (suo *SiteUpdateOne) Save(ctx context.Context) (*Site, error)

Save executes the query and returns the updated Site entity.

func (*SiteUpdateOne) SaveX

func (suo *SiteUpdateOne) SaveX(ctx context.Context) *Site

SaveX is like Save, but panics if an error occurs.

func (*SiteUpdateOne) Select

func (suo *SiteUpdateOne) Select(field string, fields ...string) *SiteUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*SiteUpdateOne) SetInput

SetInput applies the change-set in the UpdateSiteInput on the update-one builder.

func (*SiteUpdateOne) SetNillableRepositoryID

func (suo *SiteUpdateOne) SetNillableRepositoryID(id *int) *SiteUpdateOne

SetNillableRepositoryID sets the "repository" edge to the Repository entity by ID if the given value is not nil.

func (*SiteUpdateOne) SetProject

func (suo *SiteUpdateOne) SetProject(p *Project) *SiteUpdateOne

SetProject sets the "project" edge to the Project entity.

func (*SiteUpdateOne) SetProjectID

func (suo *SiteUpdateOne) SetProjectID(id int) *SiteUpdateOne

SetProjectID sets the "project" edge to the Project entity by ID.

func (*SiteUpdateOne) SetRepository

func (suo *SiteUpdateOne) SetRepository(r *Repository) *SiteUpdateOne

SetRepository sets the "repository" edge to the Repository entity.

func (*SiteUpdateOne) SetRepositoryID

func (suo *SiteUpdateOne) SetRepositoryID(id int) *SiteUpdateOne

SetRepositoryID sets the "repository" edge to the Repository entity by ID.

func (*SiteUpdateOne) SetURL

func (suo *SiteUpdateOne) SetURL(s string) *SiteUpdateOne

SetURL sets the "url" field.

type SiteWhereInput

type SiteWhereInput struct {
	Predicates []predicate.Site  `json:"-"`
	Not        *SiteWhereInput   `json:"not,omitempty"`
	Or         []*SiteWhereInput `json:"or,omitempty"`
	And        []*SiteWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "url" field predicates.
	URL             *string  `json:"url,omitempty"`
	URLNEQ          *string  `json:"urlNEQ,omitempty"`
	URLIn           []string `json:"urlIn,omitempty"`
	URLNotIn        []string `json:"urlNotIn,omitempty"`
	URLGT           *string  `json:"urlGT,omitempty"`
	URLGTE          *string  `json:"urlGTE,omitempty"`
	URLLT           *string  `json:"urlLT,omitempty"`
	URLLTE          *string  `json:"urlLTE,omitempty"`
	URLContains     *string  `json:"urlContains,omitempty"`
	URLHasPrefix    *string  `json:"urlHasPrefix,omitempty"`
	URLHasSuffix    *string  `json:"urlHasSuffix,omitempty"`
	URLEqualFold    *string  `json:"urlEqualFold,omitempty"`
	URLContainsFold *string  `json:"urlContainsFold,omitempty"`

	// "project" edge predicates.
	HasProject     *bool                `json:"hasProject,omitempty"`
	HasProjectWith []*ProjectWhereInput `json:"hasProjectWith,omitempty"`

	// "repository" edge predicates.
	HasRepository     *bool                   `json:"hasRepository,omitempty"`
	HasRepositoryWith []*RepositoryWhereInput `json:"hasRepositoryWith,omitempty"`
}

SiteWhereInput represents a where input for filtering Site queries.

func (*SiteWhereInput) AddPredicates

func (i *SiteWhereInput) AddPredicates(predicates ...predicate.Site)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*SiteWhereInput) Filter

func (i *SiteWhereInput) Filter(q *SiteQuery) (*SiteQuery, error)

Filter applies the SiteWhereInput filter on the SiteQuery builder.

func (*SiteWhereInput) P

func (i *SiteWhereInput) P() (predicate.Site, error)

P returns a predicate for filtering sites. An error is returned if the input is empty or invalid.

type Sites

type Sites []*Site

Sites is a parsable slice of Site.

type Technologies

type Technologies []*Technology

Technologies is a parsable slice of Technology.

type Technology

type Technology struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Name holds the value of the "name" field.
	Name string `json:"name,omitempty"`
	// Description holds the value of the "description" field.
	Description *string `json:"description,omitempty"`
	// Colour holds the value of the "colour" field.
	Colour *string `json:"colour,omitempty"`
	// Type holds the value of the "type" field.
	Type technology.Type `json:"type,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the TechnologyQuery when eager-loading is set.
	Edges TechnologyEdges `json:"edges"`
	// contains filtered or unexported fields
}

Technology is the model entity for the Technology schema.

func (*Technology) ChildTechnologies

func (t *Technology) ChildTechnologies(ctx context.Context) ([]*TechnologyAssociation, error)

func (*Technology) NamedChildTechnologies

func (t *Technology) NamedChildTechnologies(name string) ([]*TechnologyAssociation, error)

NamedChildTechnologies returns the ChildTechnologies named value or an error if the edge was not loaded in eager-loading with this name.

func (*Technology) NamedParentTechnologies

func (t *Technology) NamedParentTechnologies(name string) ([]*TechnologyAssociation, error)

NamedParentTechnologies returns the ParentTechnologies named value or an error if the edge was not loaded in eager-loading with this name.

func (*Technology) NamedProjects

func (t *Technology) NamedProjects(name string) ([]*ProjectTechnology, error)

NamedProjects returns the Projects named value or an error if the edge was not loaded in eager-loading with this name.

func (*Technology) NamedRepositories

func (t *Technology) NamedRepositories(name string) ([]*RepositoryTechnology, error)

NamedRepositories returns the Repositories named value or an error if the edge was not loaded in eager-loading with this name.

func (*Technology) Node

func (t *Technology) Node(ctx context.Context) (node *Node, err error)

func (*Technology) ParentTechnologies

func (t *Technology) ParentTechnologies(ctx context.Context) ([]*TechnologyAssociation, error)

func (*Technology) Projects

func (t *Technology) Projects(ctx context.Context) ([]*ProjectTechnology, error)

func (*Technology) QueryChildTechnologies

func (t *Technology) QueryChildTechnologies() *TechnologyAssociationQuery

QueryChildTechnologies queries the "child_technologies" edge of the Technology entity.

func (*Technology) QueryParentTechnologies

func (t *Technology) QueryParentTechnologies() *TechnologyAssociationQuery

QueryParentTechnologies queries the "parent_technologies" edge of the Technology entity.

func (*Technology) QueryProjects

func (t *Technology) QueryProjects() *ProjectTechnologyQuery

QueryProjects queries the "projects" edge of the Technology entity.

func (*Technology) QueryRepositories

func (t *Technology) QueryRepositories() *RepositoryTechnologyQuery

QueryRepositories queries the "repositories" edge of the Technology entity.

func (*Technology) Repositories

func (t *Technology) Repositories(ctx context.Context) ([]*RepositoryTechnology, error)

func (*Technology) String

func (t *Technology) String() string

String implements the fmt.Stringer.

func (*Technology) ToEdge

func (t *Technology) ToEdge(order *TechnologyOrder) *TechnologyEdge

ToEdge converts Technology into TechnologyEdge.

func (*Technology) Unwrap

func (t *Technology) Unwrap() *Technology

Unwrap unwraps the Technology entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*Technology) Update

func (t *Technology) Update() *TechnologyUpdateOne

Update returns a builder for updating this Technology. Note that you need to call Technology.Unwrap() before calling this method if this Technology was returned from a transaction, and the transaction was committed or rolled back.

type TechnologyAssociation

type TechnologyAssociation struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Type holds the value of the "type" field.
	Type technologyassociation.Type `json:"type,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the TechnologyAssociationQuery when eager-loading is set.
	Edges TechnologyAssociationEdges `json:"edges"`
	// contains filtered or unexported fields
}

TechnologyAssociation is the model entity for the TechnologyAssociation schema.

func (*TechnologyAssociation) Child

func (*TechnologyAssociation) Node

func (ta *TechnologyAssociation) Node(ctx context.Context) (node *Node, err error)

func (*TechnologyAssociation) Parent

func (*TechnologyAssociation) QueryChild

func (ta *TechnologyAssociation) QueryChild() *TechnologyQuery

QueryChild queries the "child" edge of the TechnologyAssociation entity.

func (*TechnologyAssociation) QueryParent

func (ta *TechnologyAssociation) QueryParent() *TechnologyQuery

QueryParent queries the "parent" edge of the TechnologyAssociation entity.

func (*TechnologyAssociation) String

func (ta *TechnologyAssociation) String() string

String implements the fmt.Stringer.

func (*TechnologyAssociation) ToEdge

ToEdge converts TechnologyAssociation into TechnologyAssociationEdge.

func (*TechnologyAssociation) Unwrap

Unwrap unwraps the TechnologyAssociation entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*TechnologyAssociation) Update

Update returns a builder for updating this TechnologyAssociation. Note that you need to call TechnologyAssociation.Unwrap() before calling this method if this TechnologyAssociation was returned from a transaction, and the transaction was committed or rolled back.

type TechnologyAssociationClient

type TechnologyAssociationClient struct {
	// contains filtered or unexported fields
}

TechnologyAssociationClient is a client for the TechnologyAssociation schema.

func NewTechnologyAssociationClient

func NewTechnologyAssociationClient(c config) *TechnologyAssociationClient

NewTechnologyAssociationClient returns a client for the TechnologyAssociation from the given config.

func (*TechnologyAssociationClient) Create

Create returns a builder for creating a TechnologyAssociation entity.

func (*TechnologyAssociationClient) CreateBulk

CreateBulk returns a builder for creating a bulk of TechnologyAssociation entities.

func (*TechnologyAssociationClient) Delete

Delete returns a delete builder for TechnologyAssociation.

func (*TechnologyAssociationClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*TechnologyAssociationClient) DeleteOneID

DeleteOne returns a builder for deleting the given entity by its id.

func (*TechnologyAssociationClient) Get

Get returns a TechnologyAssociation entity by its id.

func (*TechnologyAssociationClient) GetX

GetX is like Get, but panics if an error occurs.

func (*TechnologyAssociationClient) Hooks

func (c *TechnologyAssociationClient) Hooks() []Hook

Hooks returns the client hooks.

func (*TechnologyAssociationClient) Query

Query returns a query builder for TechnologyAssociation.

func (*TechnologyAssociationClient) QueryChild

QueryChild queries the child edge of a TechnologyAssociation.

func (*TechnologyAssociationClient) QueryParent

QueryParent queries the parent edge of a TechnologyAssociation.

func (*TechnologyAssociationClient) Update

Update returns an update builder for TechnologyAssociation.

func (*TechnologyAssociationClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*TechnologyAssociationClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*TechnologyAssociationClient) Use

func (c *TechnologyAssociationClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `technologyassociation.Hooks(f(g(h())))`.

type TechnologyAssociationConnection

type TechnologyAssociationConnection struct {
	Edges      []*TechnologyAssociationEdge `json:"edges"`
	PageInfo   PageInfo                     `json:"pageInfo"`
	TotalCount int                          `json:"totalCount"`
}

TechnologyAssociationConnection is the connection containing edges to TechnologyAssociation.

type TechnologyAssociationCreate

type TechnologyAssociationCreate struct {
	// contains filtered or unexported fields
}

TechnologyAssociationCreate is the builder for creating a TechnologyAssociation entity.

func (*TechnologyAssociationCreate) Exec

Exec executes the query.

func (*TechnologyAssociationCreate) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*TechnologyAssociationCreate) Mutation

Mutation returns the TechnologyAssociationMutation object of the builder.

func (*TechnologyAssociationCreate) Save

Save creates the TechnologyAssociation in the database.

func (*TechnologyAssociationCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*TechnologyAssociationCreate) SetChild

SetChild sets the "child" edge to the Technology entity.

func (*TechnologyAssociationCreate) SetChildID

SetChildID sets the "child" edge to the Technology entity by ID.

func (*TechnologyAssociationCreate) SetInput

SetInput applies the change-set in the CreateTechnologyAssociationInput on the create builder.

func (*TechnologyAssociationCreate) SetParent

SetParent sets the "parent" edge to the Technology entity.

func (*TechnologyAssociationCreate) SetParentID

SetParentID sets the "parent" edge to the Technology entity by ID.

func (*TechnologyAssociationCreate) SetType

SetType sets the "type" field.

type TechnologyAssociationCreateBulk

type TechnologyAssociationCreateBulk struct {
	// contains filtered or unexported fields
}

TechnologyAssociationCreateBulk is the builder for creating many TechnologyAssociation entities in bulk.

func (*TechnologyAssociationCreateBulk) Exec

Exec executes the query.

func (*TechnologyAssociationCreateBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*TechnologyAssociationCreateBulk) Save

Save creates the TechnologyAssociation entities in the database.

func (*TechnologyAssociationCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type TechnologyAssociationDelete

type TechnologyAssociationDelete struct {
	// contains filtered or unexported fields
}

TechnologyAssociationDelete is the builder for deleting a TechnologyAssociation entity.

func (*TechnologyAssociationDelete) Exec

Exec executes the deletion query and returns how many vertices were deleted.

func (*TechnologyAssociationDelete) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*TechnologyAssociationDelete) Where

Where appends a list predicates to the TechnologyAssociationDelete builder.

type TechnologyAssociationDeleteOne

type TechnologyAssociationDeleteOne struct {
	// contains filtered or unexported fields
}

TechnologyAssociationDeleteOne is the builder for deleting a single TechnologyAssociation entity.

func (*TechnologyAssociationDeleteOne) Exec

Exec executes the deletion query.

func (*TechnologyAssociationDeleteOne) ExecX

ExecX is like Exec, but panics if an error occurs.

type TechnologyAssociationEdge

type TechnologyAssociationEdge struct {
	Node   *TechnologyAssociation `json:"node"`
	Cursor Cursor                 `json:"cursor"`
}

TechnologyAssociationEdge is the edge representation of TechnologyAssociation.

type TechnologyAssociationEdges

type TechnologyAssociationEdges struct {
	// Parent holds the value of the parent edge.
	Parent *Technology `json:"parent,omitempty"`
	// Child holds the value of the child edge.
	Child *Technology `json:"child,omitempty"`
	// contains filtered or unexported fields
}

TechnologyAssociationEdges holds the relations/edges for other nodes in the graph.

func (TechnologyAssociationEdges) ChildOrErr

func (e TechnologyAssociationEdges) ChildOrErr() (*Technology, error)

ChildOrErr returns the Child value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (TechnologyAssociationEdges) ParentOrErr

func (e TechnologyAssociationEdges) ParentOrErr() (*Technology, error)

ParentOrErr returns the Parent value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type TechnologyAssociationGroupBy

type TechnologyAssociationGroupBy struct {
	// contains filtered or unexported fields
}

TechnologyAssociationGroupBy is the group-by builder for TechnologyAssociation entities.

func (*TechnologyAssociationGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*TechnologyAssociationGroupBy) Bool

func (s *TechnologyAssociationGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationGroupBy) BoolX

func (s *TechnologyAssociationGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*TechnologyAssociationGroupBy) Bools

func (s *TechnologyAssociationGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationGroupBy) BoolsX

func (s *TechnologyAssociationGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*TechnologyAssociationGroupBy) Float64

func (s *TechnologyAssociationGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationGroupBy) Float64X

func (s *TechnologyAssociationGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*TechnologyAssociationGroupBy) Float64s

func (s *TechnologyAssociationGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationGroupBy) Float64sX

func (s *TechnologyAssociationGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*TechnologyAssociationGroupBy) Int

func (s *TechnologyAssociationGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationGroupBy) IntX

func (s *TechnologyAssociationGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*TechnologyAssociationGroupBy) Ints

func (s *TechnologyAssociationGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationGroupBy) IntsX

func (s *TechnologyAssociationGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*TechnologyAssociationGroupBy) Scan

func (tagb *TechnologyAssociationGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*TechnologyAssociationGroupBy) ScanX

func (s *TechnologyAssociationGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*TechnologyAssociationGroupBy) String

func (s *TechnologyAssociationGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationGroupBy) StringX

func (s *TechnologyAssociationGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*TechnologyAssociationGroupBy) Strings

func (s *TechnologyAssociationGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationGroupBy) StringsX

func (s *TechnologyAssociationGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type TechnologyAssociationMutation

type TechnologyAssociationMutation struct {
	// contains filtered or unexported fields
}

TechnologyAssociationMutation represents an operation that mutates the TechnologyAssociation nodes in the graph.

func (*TechnologyAssociationMutation) AddField

func (m *TechnologyAssociationMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*TechnologyAssociationMutation) AddedEdges

func (m *TechnologyAssociationMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*TechnologyAssociationMutation) AddedField

func (m *TechnologyAssociationMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*TechnologyAssociationMutation) AddedFields

func (m *TechnologyAssociationMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*TechnologyAssociationMutation) AddedIDs

func (m *TechnologyAssociationMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*TechnologyAssociationMutation) ChildCleared

func (m *TechnologyAssociationMutation) ChildCleared() bool

ChildCleared reports if the "child" edge to the Technology entity was cleared.

func (*TechnologyAssociationMutation) ChildID

func (m *TechnologyAssociationMutation) ChildID() (id int, exists bool)

ChildID returns the "child" edge ID in the mutation.

func (*TechnologyAssociationMutation) ChildIDs

func (m *TechnologyAssociationMutation) ChildIDs() (ids []int)

ChildIDs returns the "child" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ChildID instead. It exists only for internal usage by the builders.

func (*TechnologyAssociationMutation) ClearChild

func (m *TechnologyAssociationMutation) ClearChild()

ClearChild clears the "child" edge to the Technology entity.

func (*TechnologyAssociationMutation) ClearEdge

func (m *TechnologyAssociationMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*TechnologyAssociationMutation) ClearField

func (m *TechnologyAssociationMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*TechnologyAssociationMutation) ClearParent

func (m *TechnologyAssociationMutation) ClearParent()

ClearParent clears the "parent" edge to the Technology entity.

func (*TechnologyAssociationMutation) ClearedEdges

func (m *TechnologyAssociationMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*TechnologyAssociationMutation) ClearedFields

func (m *TechnologyAssociationMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (TechnologyAssociationMutation) Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*TechnologyAssociationMutation) EdgeCleared

func (m *TechnologyAssociationMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*TechnologyAssociationMutation) Field

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*TechnologyAssociationMutation) FieldCleared

func (m *TechnologyAssociationMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*TechnologyAssociationMutation) Fields

func (m *TechnologyAssociationMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*TechnologyAssociationMutation) GetType

GetType returns the value of the "type" field in the mutation.

func (*TechnologyAssociationMutation) ID

func (m *TechnologyAssociationMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*TechnologyAssociationMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*TechnologyAssociationMutation) OldField

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*TechnologyAssociationMutation) OldType

OldType returns the old "type" field's value of the TechnologyAssociation entity. If the TechnologyAssociation object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*TechnologyAssociationMutation) Op

Op returns the operation name.

func (*TechnologyAssociationMutation) ParentCleared

func (m *TechnologyAssociationMutation) ParentCleared() bool

ParentCleared reports if the "parent" edge to the Technology entity was cleared.

func (*TechnologyAssociationMutation) ParentID

func (m *TechnologyAssociationMutation) ParentID() (id int, exists bool)

ParentID returns the "parent" edge ID in the mutation.

func (*TechnologyAssociationMutation) ParentIDs

func (m *TechnologyAssociationMutation) ParentIDs() (ids []int)

ParentIDs returns the "parent" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use ParentID instead. It exists only for internal usage by the builders.

func (*TechnologyAssociationMutation) RemovedEdges

func (m *TechnologyAssociationMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*TechnologyAssociationMutation) RemovedIDs

func (m *TechnologyAssociationMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*TechnologyAssociationMutation) ResetChild

func (m *TechnologyAssociationMutation) ResetChild()

ResetChild resets all changes to the "child" edge.

func (*TechnologyAssociationMutation) ResetEdge

func (m *TechnologyAssociationMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*TechnologyAssociationMutation) ResetField

func (m *TechnologyAssociationMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*TechnologyAssociationMutation) ResetParent

func (m *TechnologyAssociationMutation) ResetParent()

ResetParent resets all changes to the "parent" edge.

func (*TechnologyAssociationMutation) ResetType

func (m *TechnologyAssociationMutation) ResetType()

ResetType resets all changes to the "type" field.

func (*TechnologyAssociationMutation) SetChildID

func (m *TechnologyAssociationMutation) SetChildID(id int)

SetChildID sets the "child" edge to the Technology entity by id.

func (*TechnologyAssociationMutation) SetField

func (m *TechnologyAssociationMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*TechnologyAssociationMutation) SetParentID

func (m *TechnologyAssociationMutation) SetParentID(id int)

SetParentID sets the "parent" edge to the Technology entity by id.

func (*TechnologyAssociationMutation) SetType

SetType sets the "type" field.

func (TechnologyAssociationMutation) Tx

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*TechnologyAssociationMutation) Type

Type returns the node type of this mutation (TechnologyAssociation).

func (*TechnologyAssociationMutation) Where

Where appends a list predicates to the TechnologyAssociationMutation builder.

type TechnologyAssociationOrder

type TechnologyAssociationOrder struct {
	Direction OrderDirection                   `json:"direction"`
	Field     *TechnologyAssociationOrderField `json:"field"`
}

TechnologyAssociationOrder defines the ordering of TechnologyAssociation.

type TechnologyAssociationOrderField

type TechnologyAssociationOrderField struct {
	// contains filtered or unexported fields
}

TechnologyAssociationOrderField defines the ordering field of TechnologyAssociation.

func (TechnologyAssociationOrderField) MarshalGQL

func (f TechnologyAssociationOrderField) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (TechnologyAssociationOrderField) String

String implement fmt.Stringer interface.

func (*TechnologyAssociationOrderField) UnmarshalGQL

func (f *TechnologyAssociationOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type TechnologyAssociationPaginateOption

type TechnologyAssociationPaginateOption func(*technologyassociationPager) error

TechnologyAssociationPaginateOption enables pagination customization.

func WithTechnologyAssociationFilter

WithTechnologyAssociationFilter configures pagination filter.

func WithTechnologyAssociationOrder

func WithTechnologyAssociationOrder(order *TechnologyAssociationOrder) TechnologyAssociationPaginateOption

WithTechnologyAssociationOrder configures pagination ordering.

type TechnologyAssociationQuery

type TechnologyAssociationQuery struct {
	// contains filtered or unexported fields
}

TechnologyAssociationQuery is the builder for querying TechnologyAssociation entities.

func (*TechnologyAssociationQuery) All

All executes the query and returns a list of TechnologyAssociations.

func (*TechnologyAssociationQuery) AllX

AllX is like All, but panics if an error occurs.

func (*TechnologyAssociationQuery) Clone

Clone returns a duplicate of the TechnologyAssociationQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*TechnologyAssociationQuery) CollectFields

func (ta *TechnologyAssociationQuery) CollectFields(ctx context.Context, satisfies ...string) (*TechnologyAssociationQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*TechnologyAssociationQuery) Count

func (taq *TechnologyAssociationQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*TechnologyAssociationQuery) CountX

func (taq *TechnologyAssociationQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*TechnologyAssociationQuery) Exist

Exist returns true if the query has elements in the graph.

func (*TechnologyAssociationQuery) ExistX

ExistX is like Exist, but panics if an error occurs.

func (*TechnologyAssociationQuery) First

First returns the first TechnologyAssociation entity from the query. Returns a *NotFoundError when no TechnologyAssociation was found.

func (*TechnologyAssociationQuery) FirstID

func (taq *TechnologyAssociationQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first TechnologyAssociation ID from the query. Returns a *NotFoundError when no TechnologyAssociation ID was found.

func (*TechnologyAssociationQuery) FirstIDX

func (taq *TechnologyAssociationQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*TechnologyAssociationQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*TechnologyAssociationQuery) GroupBy

func (taq *TechnologyAssociationQuery) GroupBy(field string, fields ...string) *TechnologyAssociationGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Type technologyassociation.Type `json:"type,omitempty"`
	Count int `json:"count,omitempty"`
}

client.TechnologyAssociation.Query().
	GroupBy(technologyassociation.FieldType).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*TechnologyAssociationQuery) IDs

func (taq *TechnologyAssociationQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of TechnologyAssociation IDs.

func (*TechnologyAssociationQuery) IDsX

func (taq *TechnologyAssociationQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*TechnologyAssociationQuery) Limit

Limit adds a limit step to the query.

func (*TechnologyAssociationQuery) Offset

Offset adds an offset step to the query.

func (*TechnologyAssociationQuery) Only

Only returns a single TechnologyAssociation entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one TechnologyAssociation entity is found. Returns a *NotFoundError when no TechnologyAssociation entities are found.

func (*TechnologyAssociationQuery) OnlyID

func (taq *TechnologyAssociationQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only TechnologyAssociation ID in the query. Returns a *NotSingularError when more than one TechnologyAssociation ID is found. Returns a *NotFoundError when no entities are found.

func (*TechnologyAssociationQuery) OnlyIDX

func (taq *TechnologyAssociationQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*TechnologyAssociationQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*TechnologyAssociationQuery) Order

Order adds an order step to the query.

func (*TechnologyAssociationQuery) Paginate

Paginate executes the query and returns a relay based cursor connection to TechnologyAssociation.

func (*TechnologyAssociationQuery) QueryChild

func (taq *TechnologyAssociationQuery) QueryChild() *TechnologyQuery

QueryChild chains the current query on the "child" edge.

func (*TechnologyAssociationQuery) QueryParent

func (taq *TechnologyAssociationQuery) QueryParent() *TechnologyQuery

QueryParent chains the current query on the "parent" edge.

func (*TechnologyAssociationQuery) Select

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Type technologyassociation.Type `json:"type,omitempty"`
}

client.TechnologyAssociation.Query().
	Select(technologyassociation.FieldType).
	Scan(ctx, &v)

func (*TechnologyAssociationQuery) Unique

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*TechnologyAssociationQuery) Where

Where adds a new predicate for the TechnologyAssociationQuery builder.

func (*TechnologyAssociationQuery) WithChild

WithChild tells the query-builder to eager-load the nodes that are connected to the "child" edge. The optional arguments are used to configure the query builder of the edge.

func (*TechnologyAssociationQuery) WithParent

WithParent tells the query-builder to eager-load the nodes that are connected to the "parent" edge. The optional arguments are used to configure the query builder of the edge.

type TechnologyAssociationSelect

type TechnologyAssociationSelect struct {
	*TechnologyAssociationQuery
	// contains filtered or unexported fields
}

TechnologyAssociationSelect is the builder for selecting fields of TechnologyAssociation entities.

func (*TechnologyAssociationSelect) Bool

func (s *TechnologyAssociationSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationSelect) BoolX

func (s *TechnologyAssociationSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*TechnologyAssociationSelect) Bools

func (s *TechnologyAssociationSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationSelect) BoolsX

func (s *TechnologyAssociationSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*TechnologyAssociationSelect) Float64

func (s *TechnologyAssociationSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationSelect) Float64X

func (s *TechnologyAssociationSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*TechnologyAssociationSelect) Float64s

func (s *TechnologyAssociationSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationSelect) Float64sX

func (s *TechnologyAssociationSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*TechnologyAssociationSelect) Int

func (s *TechnologyAssociationSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationSelect) IntX

func (s *TechnologyAssociationSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*TechnologyAssociationSelect) Ints

func (s *TechnologyAssociationSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationSelect) IntsX

func (s *TechnologyAssociationSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*TechnologyAssociationSelect) Scan

func (tas *TechnologyAssociationSelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*TechnologyAssociationSelect) ScanX

func (s *TechnologyAssociationSelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*TechnologyAssociationSelect) String

func (s *TechnologyAssociationSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationSelect) StringX

func (s *TechnologyAssociationSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*TechnologyAssociationSelect) Strings

func (s *TechnologyAssociationSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*TechnologyAssociationSelect) StringsX

func (s *TechnologyAssociationSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type TechnologyAssociationUpdate

type TechnologyAssociationUpdate struct {
	// contains filtered or unexported fields
}

TechnologyAssociationUpdate is the builder for updating TechnologyAssociation entities.

func (*TechnologyAssociationUpdate) ClearChild

ClearChild clears the "child" edge to the Technology entity.

func (*TechnologyAssociationUpdate) ClearParent

ClearParent clears the "parent" edge to the Technology entity.

func (*TechnologyAssociationUpdate) Exec

Exec executes the query.

func (*TechnologyAssociationUpdate) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*TechnologyAssociationUpdate) Mutation

Mutation returns the TechnologyAssociationMutation object of the builder.

func (*TechnologyAssociationUpdate) Save

Save executes the query and returns the number of nodes affected by the update operation.

func (*TechnologyAssociationUpdate) SaveX

SaveX is like Save, but panics if an error occurs.

func (*TechnologyAssociationUpdate) SetChild

SetChild sets the "child" edge to the Technology entity.

func (*TechnologyAssociationUpdate) SetChildID

SetChildID sets the "child" edge to the Technology entity by ID.

func (*TechnologyAssociationUpdate) SetInput

SetInput applies the change-set in the UpdateTechnologyAssociationInput on the update builder.

func (*TechnologyAssociationUpdate) SetParent

SetParent sets the "parent" edge to the Technology entity.

func (*TechnologyAssociationUpdate) SetParentID

SetParentID sets the "parent" edge to the Technology entity by ID.

func (*TechnologyAssociationUpdate) SetType

SetType sets the "type" field.

func (*TechnologyAssociationUpdate) Where

Where appends a list predicates to the TechnologyAssociationUpdate builder.

type TechnologyAssociationUpdateOne

type TechnologyAssociationUpdateOne struct {
	// contains filtered or unexported fields
}

TechnologyAssociationUpdateOne is the builder for updating a single TechnologyAssociation entity.

func (*TechnologyAssociationUpdateOne) ClearChild

ClearChild clears the "child" edge to the Technology entity.

func (*TechnologyAssociationUpdateOne) ClearParent

ClearParent clears the "parent" edge to the Technology entity.

func (*TechnologyAssociationUpdateOne) Exec

Exec executes the query on the entity.

func (*TechnologyAssociationUpdateOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*TechnologyAssociationUpdateOne) Mutation

Mutation returns the TechnologyAssociationMutation object of the builder.

func (*TechnologyAssociationUpdateOne) Save

Save executes the query and returns the updated TechnologyAssociation entity.

func (*TechnologyAssociationUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*TechnologyAssociationUpdateOne) Select

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*TechnologyAssociationUpdateOne) SetChild

SetChild sets the "child" edge to the Technology entity.

func (*TechnologyAssociationUpdateOne) SetChildID

SetChildID sets the "child" edge to the Technology entity by ID.

func (*TechnologyAssociationUpdateOne) SetInput

SetInput applies the change-set in the UpdateTechnologyAssociationInput on the update-one builder.

func (*TechnologyAssociationUpdateOne) SetParent

SetParent sets the "parent" edge to the Technology entity.

func (*TechnologyAssociationUpdateOne) SetParentID

SetParentID sets the "parent" edge to the Technology entity by ID.

func (*TechnologyAssociationUpdateOne) SetType

SetType sets the "type" field.

type TechnologyAssociationWhereInput

type TechnologyAssociationWhereInput struct {
	Predicates []predicate.TechnologyAssociation  `json:"-"`
	Not        *TechnologyAssociationWhereInput   `json:"not,omitempty"`
	Or         []*TechnologyAssociationWhereInput `json:"or,omitempty"`
	And        []*TechnologyAssociationWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "type" field predicates.
	Type      *technologyassociation.Type  `json:"type,omitempty"`
	TypeNEQ   *technologyassociation.Type  `json:"typeNEQ,omitempty"`
	TypeIn    []technologyassociation.Type `json:"typeIn,omitempty"`
	TypeNotIn []technologyassociation.Type `json:"typeNotIn,omitempty"`

	// "parent" edge predicates.
	HasParent     *bool                   `json:"hasParent,omitempty"`
	HasParentWith []*TechnologyWhereInput `json:"hasParentWith,omitempty"`

	// "child" edge predicates.
	HasChild     *bool                   `json:"hasChild,omitempty"`
	HasChildWith []*TechnologyWhereInput `json:"hasChildWith,omitempty"`
}

TechnologyAssociationWhereInput represents a where input for filtering TechnologyAssociation queries.

func (*TechnologyAssociationWhereInput) AddPredicates

func (i *TechnologyAssociationWhereInput) AddPredicates(predicates ...predicate.TechnologyAssociation)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*TechnologyAssociationWhereInput) Filter

Filter applies the TechnologyAssociationWhereInput filter on the TechnologyAssociationQuery builder.

func (*TechnologyAssociationWhereInput) P

P returns a predicate for filtering technologyassociations. An error is returned if the input is empty or invalid.

type TechnologyAssociations

type TechnologyAssociations []*TechnologyAssociation

TechnologyAssociations is a parsable slice of TechnologyAssociation.

type TechnologyClient

type TechnologyClient struct {
	// contains filtered or unexported fields
}

TechnologyClient is a client for the Technology schema.

func NewTechnologyClient

func NewTechnologyClient(c config) *TechnologyClient

NewTechnologyClient returns a client for the Technology from the given config.

func (*TechnologyClient) Create

func (c *TechnologyClient) Create() *TechnologyCreate

Create returns a builder for creating a Technology entity.

func (*TechnologyClient) CreateBulk

func (c *TechnologyClient) CreateBulk(builders ...*TechnologyCreate) *TechnologyCreateBulk

CreateBulk returns a builder for creating a bulk of Technology entities.

func (*TechnologyClient) Delete

func (c *TechnologyClient) Delete() *TechnologyDelete

Delete returns a delete builder for Technology.

func (*TechnologyClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*TechnologyClient) DeleteOneID

func (c *TechnologyClient) DeleteOneID(id int) *TechnologyDeleteOne

DeleteOne returns a builder for deleting the given entity by its id.

func (*TechnologyClient) Get

func (c *TechnologyClient) Get(ctx context.Context, id int) (*Technology, error)

Get returns a Technology entity by its id.

func (*TechnologyClient) GetX

func (c *TechnologyClient) GetX(ctx context.Context, id int) *Technology

GetX is like Get, but panics if an error occurs.

func (*TechnologyClient) Hooks

func (c *TechnologyClient) Hooks() []Hook

Hooks returns the client hooks.

func (*TechnologyClient) Query

func (c *TechnologyClient) Query() *TechnologyQuery

Query returns a query builder for Technology.

func (*TechnologyClient) QueryChildTechnologies

func (c *TechnologyClient) QueryChildTechnologies(t *Technology) *TechnologyAssociationQuery

QueryChildTechnologies queries the child_technologies edge of a Technology.

func (*TechnologyClient) QueryParentTechnologies

func (c *TechnologyClient) QueryParentTechnologies(t *Technology) *TechnologyAssociationQuery

QueryParentTechnologies queries the parent_technologies edge of a Technology.

func (*TechnologyClient) QueryProjects

func (c *TechnologyClient) QueryProjects(t *Technology) *ProjectTechnologyQuery

QueryProjects queries the projects edge of a Technology.

func (*TechnologyClient) QueryRepositories

func (c *TechnologyClient) QueryRepositories(t *Technology) *RepositoryTechnologyQuery

QueryRepositories queries the repositories edge of a Technology.

func (*TechnologyClient) Update

func (c *TechnologyClient) Update() *TechnologyUpdate

Update returns an update builder for Technology.

func (*TechnologyClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*TechnologyClient) UpdateOneID

func (c *TechnologyClient) UpdateOneID(id int) *TechnologyUpdateOne

UpdateOneID returns an update builder for the given id.

func (*TechnologyClient) Use

func (c *TechnologyClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `technology.Hooks(f(g(h())))`.

type TechnologyConnection

type TechnologyConnection struct {
	Edges      []*TechnologyEdge `json:"edges"`
	PageInfo   PageInfo          `json:"pageInfo"`
	TotalCount int               `json:"totalCount"`
}

TechnologyConnection is the connection containing edges to Technology.

type TechnologyCreate

type TechnologyCreate struct {
	// contains filtered or unexported fields
}

TechnologyCreate is the builder for creating a Technology entity.

func (*TechnologyCreate) AddChildTechnologies

func (tc *TechnologyCreate) AddChildTechnologies(t ...*TechnologyAssociation) *TechnologyCreate

AddChildTechnologies adds the "child_technologies" edges to the TechnologyAssociation entity.

func (*TechnologyCreate) AddChildTechnologyIDs

func (tc *TechnologyCreate) AddChildTechnologyIDs(ids ...int) *TechnologyCreate

AddChildTechnologyIDs adds the "child_technologies" edge to the TechnologyAssociation entity by IDs.

func (*TechnologyCreate) AddParentTechnologies

func (tc *TechnologyCreate) AddParentTechnologies(t ...*TechnologyAssociation) *TechnologyCreate

AddParentTechnologies adds the "parent_technologies" edges to the TechnologyAssociation entity.

func (*TechnologyCreate) AddParentTechnologyIDs

func (tc *TechnologyCreate) AddParentTechnologyIDs(ids ...int) *TechnologyCreate

AddParentTechnologyIDs adds the "parent_technologies" edge to the TechnologyAssociation entity by IDs.

func (*TechnologyCreate) AddProjectIDs

func (tc *TechnologyCreate) AddProjectIDs(ids ...int) *TechnologyCreate

AddProjectIDs adds the "projects" edge to the ProjectTechnology entity by IDs.

func (*TechnologyCreate) AddProjects

func (tc *TechnologyCreate) AddProjects(p ...*ProjectTechnology) *TechnologyCreate

AddProjects adds the "projects" edges to the ProjectTechnology entity.

func (*TechnologyCreate) AddRepositories

func (tc *TechnologyCreate) AddRepositories(r ...*RepositoryTechnology) *TechnologyCreate

AddRepositories adds the "repositories" edges to the RepositoryTechnology entity.

func (*TechnologyCreate) AddRepositoryIDs

func (tc *TechnologyCreate) AddRepositoryIDs(ids ...int) *TechnologyCreate

AddRepositoryIDs adds the "repositories" edge to the RepositoryTechnology entity by IDs.

func (*TechnologyCreate) Exec

func (tc *TechnologyCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*TechnologyCreate) ExecX

func (tc *TechnologyCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*TechnologyCreate) Mutation

func (tc *TechnologyCreate) Mutation() *TechnologyMutation

Mutation returns the TechnologyMutation object of the builder.

func (*TechnologyCreate) Save

func (tc *TechnologyCreate) Save(ctx context.Context) (*Technology, error)

Save creates the Technology in the database.

func (*TechnologyCreate) SaveX

func (tc *TechnologyCreate) SaveX(ctx context.Context) *Technology

SaveX calls Save and panics if Save returns an error.

func (*TechnologyCreate) SetColour

func (tc *TechnologyCreate) SetColour(s string) *TechnologyCreate

SetColour sets the "colour" field.

func (*TechnologyCreate) SetDescription

func (tc *TechnologyCreate) SetDescription(s string) *TechnologyCreate

SetDescription sets the "description" field.

func (*TechnologyCreate) SetInput

SetInput applies the change-set in the CreateTechnologyInput on the create builder.

func (*TechnologyCreate) SetName

func (tc *TechnologyCreate) SetName(s string) *TechnologyCreate

SetName sets the "name" field.

func (*TechnologyCreate) SetNillableColour

func (tc *TechnologyCreate) SetNillableColour(s *string) *TechnologyCreate

SetNillableColour sets the "colour" field if the given value is not nil.

func (*TechnologyCreate) SetNillableDescription

func (tc *TechnologyCreate) SetNillableDescription(s *string) *TechnologyCreate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*TechnologyCreate) SetType

SetType sets the "type" field.

type TechnologyCreateBulk

type TechnologyCreateBulk struct {
	// contains filtered or unexported fields
}

TechnologyCreateBulk is the builder for creating many Technology entities in bulk.

func (*TechnologyCreateBulk) Exec

func (tcb *TechnologyCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*TechnologyCreateBulk) ExecX

func (tcb *TechnologyCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*TechnologyCreateBulk) Save

func (tcb *TechnologyCreateBulk) Save(ctx context.Context) ([]*Technology, error)

Save creates the Technology entities in the database.

func (*TechnologyCreateBulk) SaveX

func (tcb *TechnologyCreateBulk) SaveX(ctx context.Context) []*Technology

SaveX is like Save, but panics if an error occurs.

type TechnologyDelete

type TechnologyDelete struct {
	// contains filtered or unexported fields
}

TechnologyDelete is the builder for deleting a Technology entity.

func (*TechnologyDelete) Exec

func (td *TechnologyDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*TechnologyDelete) ExecX

func (td *TechnologyDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*TechnologyDelete) Where

Where appends a list predicates to the TechnologyDelete builder.

type TechnologyDeleteOne

type TechnologyDeleteOne struct {
	// contains filtered or unexported fields
}

TechnologyDeleteOne is the builder for deleting a single Technology entity.

func (*TechnologyDeleteOne) Exec

func (tdo *TechnologyDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*TechnologyDeleteOne) ExecX

func (tdo *TechnologyDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

type TechnologyEdge

type TechnologyEdge struct {
	Node   *Technology `json:"node"`
	Cursor Cursor      `json:"cursor"`
}

TechnologyEdge is the edge representation of Technology.

type TechnologyEdges

type TechnologyEdges struct {
	// ParentTechnologies holds the value of the parent_technologies edge.
	ParentTechnologies []*TechnologyAssociation `json:"parent_technologies,omitempty"`
	// ChildTechnologies holds the value of the child_technologies edge.
	ChildTechnologies []*TechnologyAssociation `json:"child_technologies,omitempty"`
	// Projects holds the value of the projects edge.
	Projects []*ProjectTechnology `json:"projects,omitempty"`
	// Repositories holds the value of the repositories edge.
	Repositories []*RepositoryTechnology `json:"repositories,omitempty"`
	// contains filtered or unexported fields
}

TechnologyEdges holds the relations/edges for other nodes in the graph.

func (TechnologyEdges) ChildTechnologiesOrErr

func (e TechnologyEdges) ChildTechnologiesOrErr() ([]*TechnologyAssociation, error)

ChildTechnologiesOrErr returns the ChildTechnologies value or an error if the edge was not loaded in eager-loading.

func (TechnologyEdges) ParentTechnologiesOrErr

func (e TechnologyEdges) ParentTechnologiesOrErr() ([]*TechnologyAssociation, error)

ParentTechnologiesOrErr returns the ParentTechnologies value or an error if the edge was not loaded in eager-loading.

func (TechnologyEdges) ProjectsOrErr

func (e TechnologyEdges) ProjectsOrErr() ([]*ProjectTechnology, error)

ProjectsOrErr returns the Projects value or an error if the edge was not loaded in eager-loading.

func (TechnologyEdges) RepositoriesOrErr

func (e TechnologyEdges) RepositoriesOrErr() ([]*RepositoryTechnology, error)

RepositoriesOrErr returns the Repositories value or an error if the edge was not loaded in eager-loading.

type TechnologyGroupBy

type TechnologyGroupBy struct {
	// contains filtered or unexported fields
}

TechnologyGroupBy is the group-by builder for Technology entities.

func (*TechnologyGroupBy) Aggregate

func (tgb *TechnologyGroupBy) Aggregate(fns ...AggregateFunc) *TechnologyGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*TechnologyGroupBy) Bool

func (s *TechnologyGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*TechnologyGroupBy) BoolX

func (s *TechnologyGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*TechnologyGroupBy) Bools

func (s *TechnologyGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*TechnologyGroupBy) BoolsX

func (s *TechnologyGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*TechnologyGroupBy) Float64

func (s *TechnologyGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*TechnologyGroupBy) Float64X

func (s *TechnologyGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*TechnologyGroupBy) Float64s

func (s *TechnologyGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*TechnologyGroupBy) Float64sX

func (s *TechnologyGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*TechnologyGroupBy) Int

func (s *TechnologyGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*TechnologyGroupBy) IntX

func (s *TechnologyGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*TechnologyGroupBy) Ints

func (s *TechnologyGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*TechnologyGroupBy) IntsX

func (s *TechnologyGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*TechnologyGroupBy) Scan

func (tgb *TechnologyGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*TechnologyGroupBy) ScanX

func (s *TechnologyGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*TechnologyGroupBy) String

func (s *TechnologyGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*TechnologyGroupBy) StringX

func (s *TechnologyGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*TechnologyGroupBy) Strings

func (s *TechnologyGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*TechnologyGroupBy) StringsX

func (s *TechnologyGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type TechnologyMutation

type TechnologyMutation struct {
	// contains filtered or unexported fields
}

TechnologyMutation represents an operation that mutates the Technology nodes in the graph.

func (*TechnologyMutation) AddChildTechnologyIDs

func (m *TechnologyMutation) AddChildTechnologyIDs(ids ...int)

AddChildTechnologyIDs adds the "child_technologies" edge to the TechnologyAssociation entity by ids.

func (*TechnologyMutation) AddField

func (m *TechnologyMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*TechnologyMutation) AddParentTechnologyIDs

func (m *TechnologyMutation) AddParentTechnologyIDs(ids ...int)

AddParentTechnologyIDs adds the "parent_technologies" edge to the TechnologyAssociation entity by ids.

func (*TechnologyMutation) AddProjectIDs

func (m *TechnologyMutation) AddProjectIDs(ids ...int)

AddProjectIDs adds the "projects" edge to the ProjectTechnology entity by ids.

func (*TechnologyMutation) AddRepositoryIDs

func (m *TechnologyMutation) AddRepositoryIDs(ids ...int)

AddRepositoryIDs adds the "repositories" edge to the RepositoryTechnology entity by ids.

func (*TechnologyMutation) AddedEdges

func (m *TechnologyMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*TechnologyMutation) AddedField

func (m *TechnologyMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*TechnologyMutation) AddedFields

func (m *TechnologyMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*TechnologyMutation) AddedIDs

func (m *TechnologyMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*TechnologyMutation) ChildTechnologiesCleared

func (m *TechnologyMutation) ChildTechnologiesCleared() bool

ChildTechnologiesCleared reports if the "child_technologies" edge to the TechnologyAssociation entity was cleared.

func (*TechnologyMutation) ChildTechnologiesIDs

func (m *TechnologyMutation) ChildTechnologiesIDs() (ids []int)

ChildTechnologiesIDs returns the "child_technologies" edge IDs in the mutation.

func (*TechnologyMutation) ClearChildTechnologies

func (m *TechnologyMutation) ClearChildTechnologies()

ClearChildTechnologies clears the "child_technologies" edge to the TechnologyAssociation entity.

func (*TechnologyMutation) ClearColour

func (m *TechnologyMutation) ClearColour()

ClearColour clears the value of the "colour" field.

func (*TechnologyMutation) ClearDescription

func (m *TechnologyMutation) ClearDescription()

ClearDescription clears the value of the "description" field.

func (*TechnologyMutation) ClearEdge

func (m *TechnologyMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*TechnologyMutation) ClearField

func (m *TechnologyMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*TechnologyMutation) ClearParentTechnologies

func (m *TechnologyMutation) ClearParentTechnologies()

ClearParentTechnologies clears the "parent_technologies" edge to the TechnologyAssociation entity.

func (*TechnologyMutation) ClearProjects

func (m *TechnologyMutation) ClearProjects()

ClearProjects clears the "projects" edge to the ProjectTechnology entity.

func (*TechnologyMutation) ClearRepositories

func (m *TechnologyMutation) ClearRepositories()

ClearRepositories clears the "repositories" edge to the RepositoryTechnology entity.

func (*TechnologyMutation) ClearedEdges

func (m *TechnologyMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*TechnologyMutation) ClearedFields

func (m *TechnologyMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (TechnologyMutation) Client

func (m TechnologyMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*TechnologyMutation) Colour

func (m *TechnologyMutation) Colour() (r string, exists bool)

Colour returns the value of the "colour" field in the mutation.

func (*TechnologyMutation) ColourCleared

func (m *TechnologyMutation) ColourCleared() bool

ColourCleared returns if the "colour" field was cleared in this mutation.

func (*TechnologyMutation) Description

func (m *TechnologyMutation) Description() (r string, exists bool)

Description returns the value of the "description" field in the mutation.

func (*TechnologyMutation) DescriptionCleared

func (m *TechnologyMutation) DescriptionCleared() bool

DescriptionCleared returns if the "description" field was cleared in this mutation.

func (*TechnologyMutation) EdgeCleared

func (m *TechnologyMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*TechnologyMutation) Field

func (m *TechnologyMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*TechnologyMutation) FieldCleared

func (m *TechnologyMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*TechnologyMutation) Fields

func (m *TechnologyMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*TechnologyMutation) GetType

func (m *TechnologyMutation) GetType() (r technology.Type, exists bool)

GetType returns the value of the "type" field in the mutation.

func (*TechnologyMutation) ID

func (m *TechnologyMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*TechnologyMutation) IDs

func (m *TechnologyMutation) IDs(ctx context.Context) ([]int, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*TechnologyMutation) Name

func (m *TechnologyMutation) Name() (r string, exists bool)

Name returns the value of the "name" field in the mutation.

func (*TechnologyMutation) OldColour

func (m *TechnologyMutation) OldColour(ctx context.Context) (v *string, err error)

OldColour returns the old "colour" field's value of the Technology entity. If the Technology object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*TechnologyMutation) OldDescription

func (m *TechnologyMutation) OldDescription(ctx context.Context) (v *string, err error)

OldDescription returns the old "description" field's value of the Technology entity. If the Technology object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*TechnologyMutation) OldField

func (m *TechnologyMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*TechnologyMutation) OldName

func (m *TechnologyMutation) OldName(ctx context.Context) (v string, err error)

OldName returns the old "name" field's value of the Technology entity. If the Technology object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*TechnologyMutation) OldType

func (m *TechnologyMutation) OldType(ctx context.Context) (v technology.Type, err error)

OldType returns the old "type" field's value of the Technology entity. If the Technology object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*TechnologyMutation) Op

func (m *TechnologyMutation) Op() Op

Op returns the operation name.

func (*TechnologyMutation) ParentTechnologiesCleared

func (m *TechnologyMutation) ParentTechnologiesCleared() bool

ParentTechnologiesCleared reports if the "parent_technologies" edge to the TechnologyAssociation entity was cleared.

func (*TechnologyMutation) ParentTechnologiesIDs

func (m *TechnologyMutation) ParentTechnologiesIDs() (ids []int)

ParentTechnologiesIDs returns the "parent_technologies" edge IDs in the mutation.

func (*TechnologyMutation) ProjectsCleared

func (m *TechnologyMutation) ProjectsCleared() bool

ProjectsCleared reports if the "projects" edge to the ProjectTechnology entity was cleared.

func (*TechnologyMutation) ProjectsIDs

func (m *TechnologyMutation) ProjectsIDs() (ids []int)

ProjectsIDs returns the "projects" edge IDs in the mutation.

func (*TechnologyMutation) RemoveChildTechnologyIDs

func (m *TechnologyMutation) RemoveChildTechnologyIDs(ids ...int)

RemoveChildTechnologyIDs removes the "child_technologies" edge to the TechnologyAssociation entity by IDs.

func (*TechnologyMutation) RemoveParentTechnologyIDs

func (m *TechnologyMutation) RemoveParentTechnologyIDs(ids ...int)

RemoveParentTechnologyIDs removes the "parent_technologies" edge to the TechnologyAssociation entity by IDs.

func (*TechnologyMutation) RemoveProjectIDs

func (m *TechnologyMutation) RemoveProjectIDs(ids ...int)

RemoveProjectIDs removes the "projects" edge to the ProjectTechnology entity by IDs.

func (*TechnologyMutation) RemoveRepositoryIDs

func (m *TechnologyMutation) RemoveRepositoryIDs(ids ...int)

RemoveRepositoryIDs removes the "repositories" edge to the RepositoryTechnology entity by IDs.

func (*TechnologyMutation) RemovedChildTechnologiesIDs

func (m *TechnologyMutation) RemovedChildTechnologiesIDs() (ids []int)

RemovedChildTechnologies returns the removed IDs of the "child_technologies" edge to the TechnologyAssociation entity.

func (*TechnologyMutation) RemovedEdges

func (m *TechnologyMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*TechnologyMutation) RemovedIDs

func (m *TechnologyMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*TechnologyMutation) RemovedParentTechnologiesIDs

func (m *TechnologyMutation) RemovedParentTechnologiesIDs() (ids []int)

RemovedParentTechnologies returns the removed IDs of the "parent_technologies" edge to the TechnologyAssociation entity.

func (*TechnologyMutation) RemovedProjectsIDs

func (m *TechnologyMutation) RemovedProjectsIDs() (ids []int)

RemovedProjects returns the removed IDs of the "projects" edge to the ProjectTechnology entity.

func (*TechnologyMutation) RemovedRepositoriesIDs

func (m *TechnologyMutation) RemovedRepositoriesIDs() (ids []int)

RemovedRepositories returns the removed IDs of the "repositories" edge to the RepositoryTechnology entity.

func (*TechnologyMutation) RepositoriesCleared

func (m *TechnologyMutation) RepositoriesCleared() bool

RepositoriesCleared reports if the "repositories" edge to the RepositoryTechnology entity was cleared.

func (*TechnologyMutation) RepositoriesIDs

func (m *TechnologyMutation) RepositoriesIDs() (ids []int)

RepositoriesIDs returns the "repositories" edge IDs in the mutation.

func (*TechnologyMutation) ResetChildTechnologies

func (m *TechnologyMutation) ResetChildTechnologies()

ResetChildTechnologies resets all changes to the "child_technologies" edge.

func (*TechnologyMutation) ResetColour

func (m *TechnologyMutation) ResetColour()

ResetColour resets all changes to the "colour" field.

func (*TechnologyMutation) ResetDescription

func (m *TechnologyMutation) ResetDescription()

ResetDescription resets all changes to the "description" field.

func (*TechnologyMutation) ResetEdge

func (m *TechnologyMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*TechnologyMutation) ResetField

func (m *TechnologyMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*TechnologyMutation) ResetName

func (m *TechnologyMutation) ResetName()

ResetName resets all changes to the "name" field.

func (*TechnologyMutation) ResetParentTechnologies

func (m *TechnologyMutation) ResetParentTechnologies()

ResetParentTechnologies resets all changes to the "parent_technologies" edge.

func (*TechnologyMutation) ResetProjects

func (m *TechnologyMutation) ResetProjects()

ResetProjects resets all changes to the "projects" edge.

func (*TechnologyMutation) ResetRepositories

func (m *TechnologyMutation) ResetRepositories()

ResetRepositories resets all changes to the "repositories" edge.

func (*TechnologyMutation) ResetType

func (m *TechnologyMutation) ResetType()

ResetType resets all changes to the "type" field.

func (*TechnologyMutation) SetColour

func (m *TechnologyMutation) SetColour(s string)

SetColour sets the "colour" field.

func (*TechnologyMutation) SetDescription

func (m *TechnologyMutation) SetDescription(s string)

SetDescription sets the "description" field.

func (*TechnologyMutation) SetField

func (m *TechnologyMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*TechnologyMutation) SetName

func (m *TechnologyMutation) SetName(s string)

SetName sets the "name" field.

func (*TechnologyMutation) SetType

func (m *TechnologyMutation) SetType(t technology.Type)

SetType sets the "type" field.

func (TechnologyMutation) Tx

func (m TechnologyMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*TechnologyMutation) Type

func (m *TechnologyMutation) Type() string

Type returns the node type of this mutation (Technology).

func (*TechnologyMutation) Where

func (m *TechnologyMutation) Where(ps ...predicate.Technology)

Where appends a list predicates to the TechnologyMutation builder.

type TechnologyOrder

type TechnologyOrder struct {
	Direction OrderDirection        `json:"direction"`
	Field     *TechnologyOrderField `json:"field"`
}

TechnologyOrder defines the ordering of Technology.

type TechnologyOrderField

type TechnologyOrderField struct {
	// contains filtered or unexported fields
}

TechnologyOrderField defines the ordering field of Technology.

func (TechnologyOrderField) MarshalGQL

func (f TechnologyOrderField) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (TechnologyOrderField) String

func (f TechnologyOrderField) String() string

String implement fmt.Stringer interface.

func (*TechnologyOrderField) UnmarshalGQL

func (f *TechnologyOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type TechnologyPaginateOption

type TechnologyPaginateOption func(*technologyPager) error

TechnologyPaginateOption enables pagination customization.

func WithTechnologyFilter

func WithTechnologyFilter(filter func(*TechnologyQuery) (*TechnologyQuery, error)) TechnologyPaginateOption

WithTechnologyFilter configures pagination filter.

func WithTechnologyOrder

func WithTechnologyOrder(order *TechnologyOrder) TechnologyPaginateOption

WithTechnologyOrder configures pagination ordering.

type TechnologyQuery

type TechnologyQuery struct {
	// contains filtered or unexported fields
}

TechnologyQuery is the builder for querying Technology entities.

func (*TechnologyQuery) All

func (tq *TechnologyQuery) All(ctx context.Context) ([]*Technology, error)

All executes the query and returns a list of Technologies.

func (*TechnologyQuery) AllX

func (tq *TechnologyQuery) AllX(ctx context.Context) []*Technology

AllX is like All, but panics if an error occurs.

func (*TechnologyQuery) Clone

func (tq *TechnologyQuery) Clone() *TechnologyQuery

Clone returns a duplicate of the TechnologyQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*TechnologyQuery) CollectFields

func (t *TechnologyQuery) CollectFields(ctx context.Context, satisfies ...string) (*TechnologyQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*TechnologyQuery) Count

func (tq *TechnologyQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*TechnologyQuery) CountX

func (tq *TechnologyQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*TechnologyQuery) Exist

func (tq *TechnologyQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*TechnologyQuery) ExistX

func (tq *TechnologyQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*TechnologyQuery) First

func (tq *TechnologyQuery) First(ctx context.Context) (*Technology, error)

First returns the first Technology entity from the query. Returns a *NotFoundError when no Technology was found.

func (*TechnologyQuery) FirstID

func (tq *TechnologyQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first Technology ID from the query. Returns a *NotFoundError when no Technology ID was found.

func (*TechnologyQuery) FirstIDX

func (tq *TechnologyQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*TechnologyQuery) FirstX

func (tq *TechnologyQuery) FirstX(ctx context.Context) *Technology

FirstX is like First, but panics if an error occurs.

func (*TechnologyQuery) GroupBy

func (tq *TechnologyQuery) GroupBy(field string, fields ...string) *TechnologyGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Name string `json:"name,omitempty"`
	Count int `json:"count,omitempty"`
}

client.Technology.Query().
	GroupBy(technology.FieldName).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*TechnologyQuery) IDs

func (tq *TechnologyQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of Technology IDs.

func (*TechnologyQuery) IDsX

func (tq *TechnologyQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*TechnologyQuery) Limit

func (tq *TechnologyQuery) Limit(limit int) *TechnologyQuery

Limit adds a limit step to the query.

func (*TechnologyQuery) Offset

func (tq *TechnologyQuery) Offset(offset int) *TechnologyQuery

Offset adds an offset step to the query.

func (*TechnologyQuery) Only

func (tq *TechnologyQuery) Only(ctx context.Context) (*Technology, error)

Only returns a single Technology entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Technology entity is found. Returns a *NotFoundError when no Technology entities are found.

func (*TechnologyQuery) OnlyID

func (tq *TechnologyQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only Technology ID in the query. Returns a *NotSingularError when more than one Technology ID is found. Returns a *NotFoundError when no entities are found.

func (*TechnologyQuery) OnlyIDX

func (tq *TechnologyQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*TechnologyQuery) OnlyX

func (tq *TechnologyQuery) OnlyX(ctx context.Context) *Technology

OnlyX is like Only, but panics if an error occurs.

func (*TechnologyQuery) Order

func (tq *TechnologyQuery) Order(o ...OrderFunc) *TechnologyQuery

Order adds an order step to the query.

func (*TechnologyQuery) Paginate

func (t *TechnologyQuery) Paginate(
	ctx context.Context, after *Cursor, first *int,
	before *Cursor, last *int, opts ...TechnologyPaginateOption,
) (*TechnologyConnection, error)

Paginate executes the query and returns a relay based cursor connection to Technology.

func (*TechnologyQuery) QueryChildTechnologies

func (tq *TechnologyQuery) QueryChildTechnologies() *TechnologyAssociationQuery

QueryChildTechnologies chains the current query on the "child_technologies" edge.

func (*TechnologyQuery) QueryParentTechnologies

func (tq *TechnologyQuery) QueryParentTechnologies() *TechnologyAssociationQuery

QueryParentTechnologies chains the current query on the "parent_technologies" edge.

func (*TechnologyQuery) QueryProjects

func (tq *TechnologyQuery) QueryProjects() *ProjectTechnologyQuery

QueryProjects chains the current query on the "projects" edge.

func (*TechnologyQuery) QueryRepositories

func (tq *TechnologyQuery) QueryRepositories() *RepositoryTechnologyQuery

QueryRepositories chains the current query on the "repositories" edge.

func (*TechnologyQuery) Select

func (tq *TechnologyQuery) Select(fields ...string) *TechnologySelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Name string `json:"name,omitempty"`
}

client.Technology.Query().
	Select(technology.FieldName).
	Scan(ctx, &v)

func (*TechnologyQuery) Unique

func (tq *TechnologyQuery) Unique(unique bool) *TechnologyQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*TechnologyQuery) Where

Where adds a new predicate for the TechnologyQuery builder.

func (*TechnologyQuery) WithChildTechnologies

func (tq *TechnologyQuery) WithChildTechnologies(opts ...func(*TechnologyAssociationQuery)) *TechnologyQuery

WithChildTechnologies tells the query-builder to eager-load the nodes that are connected to the "child_technologies" edge. The optional arguments are used to configure the query builder of the edge.

func (*TechnologyQuery) WithNamedChildTechnologies

func (tq *TechnologyQuery) WithNamedChildTechnologies(name string, opts ...func(*TechnologyAssociationQuery)) *TechnologyQuery

WithNamedChildTechnologies tells the query-builder to eager-load the nodes that are connected to the "child_technologies" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*TechnologyQuery) WithNamedParentTechnologies

func (tq *TechnologyQuery) WithNamedParentTechnologies(name string, opts ...func(*TechnologyAssociationQuery)) *TechnologyQuery

WithNamedParentTechnologies tells the query-builder to eager-load the nodes that are connected to the "parent_technologies" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*TechnologyQuery) WithNamedProjects

func (tq *TechnologyQuery) WithNamedProjects(name string, opts ...func(*ProjectTechnologyQuery)) *TechnologyQuery

WithNamedProjects tells the query-builder to eager-load the nodes that are connected to the "projects" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*TechnologyQuery) WithNamedRepositories

func (tq *TechnologyQuery) WithNamedRepositories(name string, opts ...func(*RepositoryTechnologyQuery)) *TechnologyQuery

WithNamedRepositories tells the query-builder to eager-load the nodes that are connected to the "repositories" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*TechnologyQuery) WithParentTechnologies

func (tq *TechnologyQuery) WithParentTechnologies(opts ...func(*TechnologyAssociationQuery)) *TechnologyQuery

WithParentTechnologies tells the query-builder to eager-load the nodes that are connected to the "parent_technologies" edge. The optional arguments are used to configure the query builder of the edge.

func (*TechnologyQuery) WithProjects

func (tq *TechnologyQuery) WithProjects(opts ...func(*ProjectTechnologyQuery)) *TechnologyQuery

WithProjects tells the query-builder to eager-load the nodes that are connected to the "projects" edge. The optional arguments are used to configure the query builder of the edge.

func (*TechnologyQuery) WithRepositories

func (tq *TechnologyQuery) WithRepositories(opts ...func(*RepositoryTechnologyQuery)) *TechnologyQuery

WithRepositories tells the query-builder to eager-load the nodes that are connected to the "repositories" edge. The optional arguments are used to configure the query builder of the edge.

type TechnologySelect

type TechnologySelect struct {
	*TechnologyQuery
	// contains filtered or unexported fields
}

TechnologySelect is the builder for selecting fields of Technology entities.

func (*TechnologySelect) Bool

func (s *TechnologySelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*TechnologySelect) BoolX

func (s *TechnologySelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*TechnologySelect) Bools

func (s *TechnologySelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*TechnologySelect) BoolsX

func (s *TechnologySelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*TechnologySelect) Float64

func (s *TechnologySelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*TechnologySelect) Float64X

func (s *TechnologySelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*TechnologySelect) Float64s

func (s *TechnologySelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*TechnologySelect) Float64sX

func (s *TechnologySelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*TechnologySelect) Int

func (s *TechnologySelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*TechnologySelect) IntX

func (s *TechnologySelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*TechnologySelect) Ints

func (s *TechnologySelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*TechnologySelect) IntsX

func (s *TechnologySelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*TechnologySelect) Scan

func (ts *TechnologySelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*TechnologySelect) ScanX

func (s *TechnologySelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*TechnologySelect) String

func (s *TechnologySelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*TechnologySelect) StringX

func (s *TechnologySelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*TechnologySelect) Strings

func (s *TechnologySelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*TechnologySelect) StringsX

func (s *TechnologySelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type TechnologyUpdate

type TechnologyUpdate struct {
	// contains filtered or unexported fields
}

TechnologyUpdate is the builder for updating Technology entities.

func (*TechnologyUpdate) AddChildTechnologies

func (tu *TechnologyUpdate) AddChildTechnologies(t ...*TechnologyAssociation) *TechnologyUpdate

AddChildTechnologies adds the "child_technologies" edges to the TechnologyAssociation entity.

func (*TechnologyUpdate) AddChildTechnologyIDs

func (tu *TechnologyUpdate) AddChildTechnologyIDs(ids ...int) *TechnologyUpdate

AddChildTechnologyIDs adds the "child_technologies" edge to the TechnologyAssociation entity by IDs.

func (*TechnologyUpdate) AddParentTechnologies

func (tu *TechnologyUpdate) AddParentTechnologies(t ...*TechnologyAssociation) *TechnologyUpdate

AddParentTechnologies adds the "parent_technologies" edges to the TechnologyAssociation entity.

func (*TechnologyUpdate) AddParentTechnologyIDs

func (tu *TechnologyUpdate) AddParentTechnologyIDs(ids ...int) *TechnologyUpdate

AddParentTechnologyIDs adds the "parent_technologies" edge to the TechnologyAssociation entity by IDs.

func (*TechnologyUpdate) AddProjectIDs

func (tu *TechnologyUpdate) AddProjectIDs(ids ...int) *TechnologyUpdate

AddProjectIDs adds the "projects" edge to the ProjectTechnology entity by IDs.

func (*TechnologyUpdate) AddProjects

func (tu *TechnologyUpdate) AddProjects(p ...*ProjectTechnology) *TechnologyUpdate

AddProjects adds the "projects" edges to the ProjectTechnology entity.

func (*TechnologyUpdate) AddRepositories

func (tu *TechnologyUpdate) AddRepositories(r ...*RepositoryTechnology) *TechnologyUpdate

AddRepositories adds the "repositories" edges to the RepositoryTechnology entity.

func (*TechnologyUpdate) AddRepositoryIDs

func (tu *TechnologyUpdate) AddRepositoryIDs(ids ...int) *TechnologyUpdate

AddRepositoryIDs adds the "repositories" edge to the RepositoryTechnology entity by IDs.

func (*TechnologyUpdate) ClearChildTechnologies

func (tu *TechnologyUpdate) ClearChildTechnologies() *TechnologyUpdate

ClearChildTechnologies clears all "child_technologies" edges to the TechnologyAssociation entity.

func (*TechnologyUpdate) ClearColour

func (tu *TechnologyUpdate) ClearColour() *TechnologyUpdate

ClearColour clears the value of the "colour" field.

func (*TechnologyUpdate) ClearDescription

func (tu *TechnologyUpdate) ClearDescription() *TechnologyUpdate

ClearDescription clears the value of the "description" field.

func (*TechnologyUpdate) ClearParentTechnologies

func (tu *TechnologyUpdate) ClearParentTechnologies() *TechnologyUpdate

ClearParentTechnologies clears all "parent_technologies" edges to the TechnologyAssociation entity.

func (*TechnologyUpdate) ClearProjects

func (tu *TechnologyUpdate) ClearProjects() *TechnologyUpdate

ClearProjects clears all "projects" edges to the ProjectTechnology entity.

func (*TechnologyUpdate) ClearRepositories

func (tu *TechnologyUpdate) ClearRepositories() *TechnologyUpdate

ClearRepositories clears all "repositories" edges to the RepositoryTechnology entity.

func (*TechnologyUpdate) Exec

func (tu *TechnologyUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*TechnologyUpdate) ExecX

func (tu *TechnologyUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*TechnologyUpdate) Mutation

func (tu *TechnologyUpdate) Mutation() *TechnologyMutation

Mutation returns the TechnologyMutation object of the builder.

func (*TechnologyUpdate) RemoveChildTechnologies

func (tu *TechnologyUpdate) RemoveChildTechnologies(t ...*TechnologyAssociation) *TechnologyUpdate

RemoveChildTechnologies removes "child_technologies" edges to TechnologyAssociation entities.

func (*TechnologyUpdate) RemoveChildTechnologyIDs

func (tu *TechnologyUpdate) RemoveChildTechnologyIDs(ids ...int) *TechnologyUpdate

RemoveChildTechnologyIDs removes the "child_technologies" edge to TechnologyAssociation entities by IDs.

func (*TechnologyUpdate) RemoveParentTechnologies

func (tu *TechnologyUpdate) RemoveParentTechnologies(t ...*TechnologyAssociation) *TechnologyUpdate

RemoveParentTechnologies removes "parent_technologies" edges to TechnologyAssociation entities.

func (*TechnologyUpdate) RemoveParentTechnologyIDs

func (tu *TechnologyUpdate) RemoveParentTechnologyIDs(ids ...int) *TechnologyUpdate

RemoveParentTechnologyIDs removes the "parent_technologies" edge to TechnologyAssociation entities by IDs.

func (*TechnologyUpdate) RemoveProjectIDs

func (tu *TechnologyUpdate) RemoveProjectIDs(ids ...int) *TechnologyUpdate

RemoveProjectIDs removes the "projects" edge to ProjectTechnology entities by IDs.

func (*TechnologyUpdate) RemoveProjects

func (tu *TechnologyUpdate) RemoveProjects(p ...*ProjectTechnology) *TechnologyUpdate

RemoveProjects removes "projects" edges to ProjectTechnology entities.

func (*TechnologyUpdate) RemoveRepositories

func (tu *TechnologyUpdate) RemoveRepositories(r ...*RepositoryTechnology) *TechnologyUpdate

RemoveRepositories removes "repositories" edges to RepositoryTechnology entities.

func (*TechnologyUpdate) RemoveRepositoryIDs

func (tu *TechnologyUpdate) RemoveRepositoryIDs(ids ...int) *TechnologyUpdate

RemoveRepositoryIDs removes the "repositories" edge to RepositoryTechnology entities by IDs.

func (*TechnologyUpdate) Save

func (tu *TechnologyUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*TechnologyUpdate) SaveX

func (tu *TechnologyUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*TechnologyUpdate) SetColour

func (tu *TechnologyUpdate) SetColour(s string) *TechnologyUpdate

SetColour sets the "colour" field.

func (*TechnologyUpdate) SetDescription

func (tu *TechnologyUpdate) SetDescription(s string) *TechnologyUpdate

SetDescription sets the "description" field.

func (*TechnologyUpdate) SetInput

SetInput applies the change-set in the UpdateTechnologyInput on the update builder.

func (*TechnologyUpdate) SetName

func (tu *TechnologyUpdate) SetName(s string) *TechnologyUpdate

SetName sets the "name" field.

func (*TechnologyUpdate) SetNillableColour

func (tu *TechnologyUpdate) SetNillableColour(s *string) *TechnologyUpdate

SetNillableColour sets the "colour" field if the given value is not nil.

func (*TechnologyUpdate) SetNillableDescription

func (tu *TechnologyUpdate) SetNillableDescription(s *string) *TechnologyUpdate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*TechnologyUpdate) SetType

SetType sets the "type" field.

func (*TechnologyUpdate) Where

Where appends a list predicates to the TechnologyUpdate builder.

type TechnologyUpdateOne

type TechnologyUpdateOne struct {
	// contains filtered or unexported fields
}

TechnologyUpdateOne is the builder for updating a single Technology entity.

func (*TechnologyUpdateOne) AddChildTechnologies

func (tuo *TechnologyUpdateOne) AddChildTechnologies(t ...*TechnologyAssociation) *TechnologyUpdateOne

AddChildTechnologies adds the "child_technologies" edges to the TechnologyAssociation entity.

func (*TechnologyUpdateOne) AddChildTechnologyIDs

func (tuo *TechnologyUpdateOne) AddChildTechnologyIDs(ids ...int) *TechnologyUpdateOne

AddChildTechnologyIDs adds the "child_technologies" edge to the TechnologyAssociation entity by IDs.

func (*TechnologyUpdateOne) AddParentTechnologies

func (tuo *TechnologyUpdateOne) AddParentTechnologies(t ...*TechnologyAssociation) *TechnologyUpdateOne

AddParentTechnologies adds the "parent_technologies" edges to the TechnologyAssociation entity.

func (*TechnologyUpdateOne) AddParentTechnologyIDs

func (tuo *TechnologyUpdateOne) AddParentTechnologyIDs(ids ...int) *TechnologyUpdateOne

AddParentTechnologyIDs adds the "parent_technologies" edge to the TechnologyAssociation entity by IDs.

func (*TechnologyUpdateOne) AddProjectIDs

func (tuo *TechnologyUpdateOne) AddProjectIDs(ids ...int) *TechnologyUpdateOne

AddProjectIDs adds the "projects" edge to the ProjectTechnology entity by IDs.

func (*TechnologyUpdateOne) AddProjects

AddProjects adds the "projects" edges to the ProjectTechnology entity.

func (*TechnologyUpdateOne) AddRepositories

func (tuo *TechnologyUpdateOne) AddRepositories(r ...*RepositoryTechnology) *TechnologyUpdateOne

AddRepositories adds the "repositories" edges to the RepositoryTechnology entity.

func (*TechnologyUpdateOne) AddRepositoryIDs

func (tuo *TechnologyUpdateOne) AddRepositoryIDs(ids ...int) *TechnologyUpdateOne

AddRepositoryIDs adds the "repositories" edge to the RepositoryTechnology entity by IDs.

func (*TechnologyUpdateOne) ClearChildTechnologies

func (tuo *TechnologyUpdateOne) ClearChildTechnologies() *TechnologyUpdateOne

ClearChildTechnologies clears all "child_technologies" edges to the TechnologyAssociation entity.

func (*TechnologyUpdateOne) ClearColour

func (tuo *TechnologyUpdateOne) ClearColour() *TechnologyUpdateOne

ClearColour clears the value of the "colour" field.

func (*TechnologyUpdateOne) ClearDescription

func (tuo *TechnologyUpdateOne) ClearDescription() *TechnologyUpdateOne

ClearDescription clears the value of the "description" field.

func (*TechnologyUpdateOne) ClearParentTechnologies

func (tuo *TechnologyUpdateOne) ClearParentTechnologies() *TechnologyUpdateOne

ClearParentTechnologies clears all "parent_technologies" edges to the TechnologyAssociation entity.

func (*TechnologyUpdateOne) ClearProjects

func (tuo *TechnologyUpdateOne) ClearProjects() *TechnologyUpdateOne

ClearProjects clears all "projects" edges to the ProjectTechnology entity.

func (*TechnologyUpdateOne) ClearRepositories

func (tuo *TechnologyUpdateOne) ClearRepositories() *TechnologyUpdateOne

ClearRepositories clears all "repositories" edges to the RepositoryTechnology entity.

func (*TechnologyUpdateOne) Exec

func (tuo *TechnologyUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*TechnologyUpdateOne) ExecX

func (tuo *TechnologyUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*TechnologyUpdateOne) Mutation

func (tuo *TechnologyUpdateOne) Mutation() *TechnologyMutation

Mutation returns the TechnologyMutation object of the builder.

func (*TechnologyUpdateOne) RemoveChildTechnologies

func (tuo *TechnologyUpdateOne) RemoveChildTechnologies(t ...*TechnologyAssociation) *TechnologyUpdateOne

RemoveChildTechnologies removes "child_technologies" edges to TechnologyAssociation entities.

func (*TechnologyUpdateOne) RemoveChildTechnologyIDs

func (tuo *TechnologyUpdateOne) RemoveChildTechnologyIDs(ids ...int) *TechnologyUpdateOne

RemoveChildTechnologyIDs removes the "child_technologies" edge to TechnologyAssociation entities by IDs.

func (*TechnologyUpdateOne) RemoveParentTechnologies

func (tuo *TechnologyUpdateOne) RemoveParentTechnologies(t ...*TechnologyAssociation) *TechnologyUpdateOne

RemoveParentTechnologies removes "parent_technologies" edges to TechnologyAssociation entities.

func (*TechnologyUpdateOne) RemoveParentTechnologyIDs

func (tuo *TechnologyUpdateOne) RemoveParentTechnologyIDs(ids ...int) *TechnologyUpdateOne

RemoveParentTechnologyIDs removes the "parent_technologies" edge to TechnologyAssociation entities by IDs.

func (*TechnologyUpdateOne) RemoveProjectIDs

func (tuo *TechnologyUpdateOne) RemoveProjectIDs(ids ...int) *TechnologyUpdateOne

RemoveProjectIDs removes the "projects" edge to ProjectTechnology entities by IDs.

func (*TechnologyUpdateOne) RemoveProjects

func (tuo *TechnologyUpdateOne) RemoveProjects(p ...*ProjectTechnology) *TechnologyUpdateOne

RemoveProjects removes "projects" edges to ProjectTechnology entities.

func (*TechnologyUpdateOne) RemoveRepositories

func (tuo *TechnologyUpdateOne) RemoveRepositories(r ...*RepositoryTechnology) *TechnologyUpdateOne

RemoveRepositories removes "repositories" edges to RepositoryTechnology entities.

func (*TechnologyUpdateOne) RemoveRepositoryIDs

func (tuo *TechnologyUpdateOne) RemoveRepositoryIDs(ids ...int) *TechnologyUpdateOne

RemoveRepositoryIDs removes the "repositories" edge to RepositoryTechnology entities by IDs.

func (*TechnologyUpdateOne) Save

func (tuo *TechnologyUpdateOne) Save(ctx context.Context) (*Technology, error)

Save executes the query and returns the updated Technology entity.

func (*TechnologyUpdateOne) SaveX

func (tuo *TechnologyUpdateOne) SaveX(ctx context.Context) *Technology

SaveX is like Save, but panics if an error occurs.

func (*TechnologyUpdateOne) Select

func (tuo *TechnologyUpdateOne) Select(field string, fields ...string) *TechnologyUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*TechnologyUpdateOne) SetColour

func (tuo *TechnologyUpdateOne) SetColour(s string) *TechnologyUpdateOne

SetColour sets the "colour" field.

func (*TechnologyUpdateOne) SetDescription

func (tuo *TechnologyUpdateOne) SetDescription(s string) *TechnologyUpdateOne

SetDescription sets the "description" field.

func (*TechnologyUpdateOne) SetInput

SetInput applies the change-set in the UpdateTechnologyInput on the update-one builder.

func (*TechnologyUpdateOne) SetName

SetName sets the "name" field.

func (*TechnologyUpdateOne) SetNillableColour

func (tuo *TechnologyUpdateOne) SetNillableColour(s *string) *TechnologyUpdateOne

SetNillableColour sets the "colour" field if the given value is not nil.

func (*TechnologyUpdateOne) SetNillableDescription

func (tuo *TechnologyUpdateOne) SetNillableDescription(s *string) *TechnologyUpdateOne

SetNillableDescription sets the "description" field if the given value is not nil.

func (*TechnologyUpdateOne) SetType

SetType sets the "type" field.

type TechnologyWhereInput

type TechnologyWhereInput struct {
	Predicates []predicate.Technology  `json:"-"`
	Not        *TechnologyWhereInput   `json:"not,omitempty"`
	Or         []*TechnologyWhereInput `json:"or,omitempty"`
	And        []*TechnologyWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "name" field predicates.
	Name             *string  `json:"name,omitempty"`
	NameNEQ          *string  `json:"nameNEQ,omitempty"`
	NameIn           []string `json:"nameIn,omitempty"`
	NameNotIn        []string `json:"nameNotIn,omitempty"`
	NameGT           *string  `json:"nameGT,omitempty"`
	NameGTE          *string  `json:"nameGTE,omitempty"`
	NameLT           *string  `json:"nameLT,omitempty"`
	NameLTE          *string  `json:"nameLTE,omitempty"`
	NameContains     *string  `json:"nameContains,omitempty"`
	NameHasPrefix    *string  `json:"nameHasPrefix,omitempty"`
	NameHasSuffix    *string  `json:"nameHasSuffix,omitempty"`
	NameEqualFold    *string  `json:"nameEqualFold,omitempty"`
	NameContainsFold *string  `json:"nameContainsFold,omitempty"`

	// "description" field predicates.
	Description             *string  `json:"description,omitempty"`
	DescriptionNEQ          *string  `json:"descriptionNEQ,omitempty"`
	DescriptionIn           []string `json:"descriptionIn,omitempty"`
	DescriptionNotIn        []string `json:"descriptionNotIn,omitempty"`
	DescriptionGT           *string  `json:"descriptionGT,omitempty"`
	DescriptionGTE          *string  `json:"descriptionGTE,omitempty"`
	DescriptionLT           *string  `json:"descriptionLT,omitempty"`
	DescriptionLTE          *string  `json:"descriptionLTE,omitempty"`
	DescriptionContains     *string  `json:"descriptionContains,omitempty"`
	DescriptionHasPrefix    *string  `json:"descriptionHasPrefix,omitempty"`
	DescriptionHasSuffix    *string  `json:"descriptionHasSuffix,omitempty"`
	DescriptionIsNil        bool     `json:"descriptionIsNil,omitempty"`
	DescriptionNotNil       bool     `json:"descriptionNotNil,omitempty"`
	DescriptionEqualFold    *string  `json:"descriptionEqualFold,omitempty"`
	DescriptionContainsFold *string  `json:"descriptionContainsFold,omitempty"`

	// "colour" field predicates.
	Colour             *string  `json:"colour,omitempty"`
	ColourNEQ          *string  `json:"colourNEQ,omitempty"`
	ColourIn           []string `json:"colourIn,omitempty"`
	ColourNotIn        []string `json:"colourNotIn,omitempty"`
	ColourGT           *string  `json:"colourGT,omitempty"`
	ColourGTE          *string  `json:"colourGTE,omitempty"`
	ColourLT           *string  `json:"colourLT,omitempty"`
	ColourLTE          *string  `json:"colourLTE,omitempty"`
	ColourContains     *string  `json:"colourContains,omitempty"`
	ColourHasPrefix    *string  `json:"colourHasPrefix,omitempty"`
	ColourHasSuffix    *string  `json:"colourHasSuffix,omitempty"`
	ColourIsNil        bool     `json:"colourIsNil,omitempty"`
	ColourNotNil       bool     `json:"colourNotNil,omitempty"`
	ColourEqualFold    *string  `json:"colourEqualFold,omitempty"`
	ColourContainsFold *string  `json:"colourContainsFold,omitempty"`

	// "type" field predicates.
	Type      *technology.Type  `json:"type,omitempty"`
	TypeNEQ   *technology.Type  `json:"typeNEQ,omitempty"`
	TypeIn    []technology.Type `json:"typeIn,omitempty"`
	TypeNotIn []technology.Type `json:"typeNotIn,omitempty"`

	// "parent_technologies" edge predicates.
	HasParentTechnologies     *bool                              `json:"hasParentTechnologies,omitempty"`
	HasParentTechnologiesWith []*TechnologyAssociationWhereInput `json:"hasParentTechnologiesWith,omitempty"`

	// "child_technologies" edge predicates.
	HasChildTechnologies     *bool                              `json:"hasChildTechnologies,omitempty"`
	HasChildTechnologiesWith []*TechnologyAssociationWhereInput `json:"hasChildTechnologiesWith,omitempty"`

	// "projects" edge predicates.
	HasProjects     *bool                          `json:"hasProjects,omitempty"`
	HasProjectsWith []*ProjectTechnologyWhereInput `json:"hasProjectsWith,omitempty"`

	// "repositories" edge predicates.
	HasRepositories     *bool                             `json:"hasRepositories,omitempty"`
	HasRepositoriesWith []*RepositoryTechnologyWhereInput `json:"hasRepositoriesWith,omitempty"`
}

TechnologyWhereInput represents a where input for filtering Technology queries.

func (*TechnologyWhereInput) AddPredicates

func (i *TechnologyWhereInput) AddPredicates(predicates ...predicate.Technology)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*TechnologyWhereInput) Filter

Filter applies the TechnologyWhereInput filter on the TechnologyQuery builder.

func (*TechnologyWhereInput) P

P returns a predicate for filtering technologies. An error is returned if the input is empty or invalid.

type Tx

type Tx struct {

	// DiscordAccount is the client for interacting with the DiscordAccount builders.
	DiscordAccount *DiscordAccountClient
	// DiscordBot is the client for interacting with the DiscordBot builders.
	DiscordBot *DiscordBotClient
	// GithubAccount is the client for interacting with the GithubAccount builders.
	GithubAccount *GithubAccountClient
	// GithubOrganization is the client for interacting with the GithubOrganization builders.
	GithubOrganization *GithubOrganizationClient
	// GithubOrganizationMember is the client for interacting with the GithubOrganizationMember builders.
	GithubOrganizationMember *GithubOrganizationMemberClient
	// Project is the client for interacting with the Project builders.
	Project *ProjectClient
	// ProjectAssociation is the client for interacting with the ProjectAssociation builders.
	ProjectAssociation *ProjectAssociationClient
	// ProjectContributor is the client for interacting with the ProjectContributor builders.
	ProjectContributor *ProjectContributorClient
	// ProjectTechnology is the client for interacting with the ProjectTechnology builders.
	ProjectTechnology *ProjectTechnologyClient
	// Repository is the client for interacting with the Repository builders.
	Repository *RepositoryClient
	// RepositoryTechnology is the client for interacting with the RepositoryTechnology builders.
	RepositoryTechnology *RepositoryTechnologyClient
	// Site is the client for interacting with the Site builders.
	Site *SiteClient
	// Technology is the client for interacting with the Technology builders.
	Technology *TechnologyClient
	// TechnologyAssociation is the client for interacting with the TechnologyAssociation builders.
	TechnologyAssociation *TechnologyAssociationClient
	// User is the client for interacting with the User builders.
	User *UserClient
	// contains filtered or unexported fields
}

Tx is a transactional client that is created by calling Client.Tx().

func TxFromContext

func TxFromContext(ctx context.Context) *Tx

TxFromContext returns a Tx stored inside a context, or nil if there isn't one.

func (*Tx) Client

func (tx *Tx) Client() *Client

Client returns a Client that binds to current transaction.

func (*Tx) Commit

func (tx *Tx) Commit() error

Commit commits the transaction.

func (*Tx) OnCommit

func (tx *Tx) OnCommit(f CommitHook)

OnCommit adds a hook to call on commit.

func (*Tx) OnRollback

func (tx *Tx) OnRollback(f RollbackHook)

OnRollback adds a hook to call on rollback.

func (*Tx) Rollback

func (tx *Tx) Rollback() error

Rollback rollbacks the transaction.

type UpdateDiscordAccountInput

type UpdateDiscordAccountInput struct {
	Username      *string
	Discriminator *string
	Owner         *int
	ClearOwner    bool
	Bot           *int
	ClearBot      bool
}

UpdateDiscordAccountInput represents a mutation input for updating discordaccounts.

func (*UpdateDiscordAccountInput) Mutate

Mutate applies the UpdateDiscordAccountInput on the DiscordAccountMutation.

type UpdateDiscordBotInput

type UpdateDiscordBotInput struct {
	Account         *int
	ClearAccount    bool
	Project         *int
	ClearProject    bool
	Repository      *int
	ClearRepository bool
}

UpdateDiscordBotInput represents a mutation input for updating discordbots.

func (*UpdateDiscordBotInput) Mutate

Mutate applies the UpdateDiscordBotInput on the DiscordBotMutation.

type UpdateGithubAccountInput

type UpdateGithubAccountInput struct {
	Username                        *string
	Owner                           *int
	ClearOwner                      bool
	AddOrganizationMembershipIDs    []int
	RemoveOrganizationMembershipIDs []int
	AddRepositoryIDs                []int
	RemoveRepositoryIDs             []int
}

UpdateGithubAccountInput represents a mutation input for updating githubaccounts.

func (*UpdateGithubAccountInput) Mutate

Mutate applies the UpdateGithubAccountInput on the GithubAccountMutation.

type UpdateGithubOrganizationInput

type UpdateGithubOrganizationInput struct {
	Name                *string
	DisplayName         *string
	ClearDisplayName    bool
	AddMemberIDs        []int
	RemoveMemberIDs     []int
	AddRepositoryIDs    []int
	RemoveRepositoryIDs []int
}

UpdateGithubOrganizationInput represents a mutation input for updating githuborganizations.

func (*UpdateGithubOrganizationInput) Mutate

Mutate applies the UpdateGithubOrganizationInput on the GithubOrganizationMutation.

type UpdateGithubOrganizationMemberInput

type UpdateGithubOrganizationMemberInput struct {
	Role              *githuborganizationmember.Role
	Organization      *int
	ClearOrganization bool
	Account           *int
	ClearAccount      bool
}

UpdateGithubOrganizationMemberInput represents a mutation input for updating githuborganizationmembers.

func (*UpdateGithubOrganizationMemberInput) Mutate

Mutate applies the UpdateGithubOrganizationMemberInput on the GithubOrganizationMemberMutation.

type UpdateProjectAssociationInput

type UpdateProjectAssociationInput struct {
	Type        *projectassociation.Type
	Parent      *int
	ClearParent bool
	Child       *int
	ClearChild  bool
}

UpdateProjectAssociationInput represents a mutation input for updating projectassociations.

func (*UpdateProjectAssociationInput) Mutate

Mutate applies the UpdateProjectAssociationInput on the ProjectAssociationMutation.

type UpdateProjectContributorInput

type UpdateProjectContributorInput struct {
	Role         *projectcontributor.Role
	Project      *int
	ClearProject bool
	User         *int
	ClearUser    bool
}

UpdateProjectContributorInput represents a mutation input for updating projectcontributors.

func (*UpdateProjectContributorInput) Mutate

Mutate applies the UpdateProjectContributorInput on the ProjectContributorMutation.

type UpdateProjectInput

type UpdateProjectInput struct {
	Name                   *string
	Description            *string
	ClearDescription       bool
	StartDate              *time.Time
	EndDate                *time.Time
	ClearEndDate           bool
	AddContributorIDs      []int
	RemoveContributorIDs   []int
	AddParentProjectIDs    []int
	RemoveParentProjectIDs []int
	AddChildProjectIDs     []int
	RemoveChildProjectIDs  []int
	AddRepositoryIDs       []int
	RemoveRepositoryIDs    []int
	AddDiscordBotIDs       []int
	RemoveDiscordBotIDs    []int
	AddSiteIDs             []int
	RemoveSiteIDs          []int
	AddTechnologyIDs       []int
	RemoveTechnologyIDs    []int
}

UpdateProjectInput represents a mutation input for updating projects.

func (*UpdateProjectInput) Mutate

func (i *UpdateProjectInput) Mutate(m *ProjectMutation)

Mutate applies the UpdateProjectInput on the ProjectMutation.

type UpdateProjectTechnologyInput

type UpdateProjectTechnologyInput struct {
	Type            *projecttechnology.Type
	Project         *int
	ClearProject    bool
	Technology      *int
	ClearTechnology bool
}

UpdateProjectTechnologyInput represents a mutation input for updating projecttechnologies.

func (*UpdateProjectTechnologyInput) Mutate

Mutate applies the UpdateProjectTechnologyInput on the ProjectTechnologyMutation.

type UpdateRepositoryInput

type UpdateRepositoryInput struct {
	Name                    *string
	Description             *string
	ClearDescription        bool
	Project                 *int
	ClearProject            bool
	GithubAccount           *int
	ClearGithubAccount      bool
	GithubOrganization      *int
	ClearGithubOrganization bool
	AddDiscordBotIDs        []int
	RemoveDiscordBotIDs     []int
	AddSiteIDs              []int
	RemoveSiteIDs           []int
	AddTechnologyIDs        []int
	RemoveTechnologyIDs     []int
}

UpdateRepositoryInput represents a mutation input for updating repositories.

func (*UpdateRepositoryInput) Mutate

Mutate applies the UpdateRepositoryInput on the RepositoryMutation.

type UpdateRepositoryTechnologyInput

type UpdateRepositoryTechnologyInput struct {
	Type            *repositorytechnology.Type
	Repository      *int
	ClearRepository bool
	Technology      *int
	ClearTechnology bool
}

UpdateRepositoryTechnologyInput represents a mutation input for updating repositorytechnologies.

func (*UpdateRepositoryTechnologyInput) Mutate

Mutate applies the UpdateRepositoryTechnologyInput on the RepositoryTechnologyMutation.

type UpdateSiteInput

type UpdateSiteInput struct {
	URL             *string
	Project         *int
	ClearProject    bool
	Repository      *int
	ClearRepository bool
}

UpdateSiteInput represents a mutation input for updating sites.

func (*UpdateSiteInput) Mutate

func (i *UpdateSiteInput) Mutate(m *SiteMutation)

Mutate applies the UpdateSiteInput on the SiteMutation.

type UpdateTechnologyAssociationInput

type UpdateTechnologyAssociationInput struct {
	Type        *technologyassociation.Type
	Parent      *int
	ClearParent bool
	Child       *int
	ClearChild  bool
}

UpdateTechnologyAssociationInput represents a mutation input for updating technologyassociations.

func (*UpdateTechnologyAssociationInput) Mutate

Mutate applies the UpdateTechnologyAssociationInput on the TechnologyAssociationMutation.

type UpdateTechnologyInput

type UpdateTechnologyInput struct {
	Name                      *string
	Description               *string
	ClearDescription          bool
	Colour                    *string
	ClearColour               bool
	Type                      *technology.Type
	AddParentTechnologyIDs    []int
	RemoveParentTechnologyIDs []int
	AddChildTechnologyIDs     []int
	RemoveChildTechnologyIDs  []int
	AddProjectIDs             []int
	RemoveProjectIDs          []int
	AddRepositoryIDs          []int
	RemoveRepositoryIDs       []int
}

UpdateTechnologyInput represents a mutation input for updating technologies.

func (*UpdateTechnologyInput) Mutate

Mutate applies the UpdateTechnologyInput on the TechnologyMutation.

type UpdateUserInput

type UpdateUserInput struct {
	Username                     *string
	AvatarURL                    *string
	ClearAvatarURL               bool
	AddDiscordAccountIDs         []int
	RemoveDiscordAccountIDs      []int
	AddGithubAccountIDs          []int
	RemoveGithubAccountIDs       []int
	AddProjectContributionIDs    []int
	RemoveProjectContributionIDs []int
}

UpdateUserInput represents a mutation input for updating users.

func (*UpdateUserInput) Mutate

func (i *UpdateUserInput) Mutate(m *UserMutation)

Mutate applies the UpdateUserInput on the UserMutation.

type User

type User struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Username holds the value of the "username" field.
	Username string `json:"username,omitempty"`
	// AvatarURL holds the value of the "avatar_url" field.
	AvatarURL *string `json:"avatar_url,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the UserQuery when eager-loading is set.
	Edges UserEdges `json:"edges"`
	// contains filtered or unexported fields
}

User is the model entity for the User schema.

func (*User) DiscordAccounts

func (u *User) DiscordAccounts(ctx context.Context) ([]*DiscordAccount, error)

func (*User) GithubAccounts

func (u *User) GithubAccounts(ctx context.Context) ([]*GithubAccount, error)

func (*User) NamedDiscordAccounts

func (u *User) NamedDiscordAccounts(name string) ([]*DiscordAccount, error)

NamedDiscordAccounts returns the DiscordAccounts named value or an error if the edge was not loaded in eager-loading with this name.

func (*User) NamedGithubAccounts

func (u *User) NamedGithubAccounts(name string) ([]*GithubAccount, error)

NamedGithubAccounts returns the GithubAccounts named value or an error if the edge was not loaded in eager-loading with this name.

func (*User) NamedProjectContributions

func (u *User) NamedProjectContributions(name string) ([]*ProjectContributor, error)

NamedProjectContributions returns the ProjectContributions named value or an error if the edge was not loaded in eager-loading with this name.

func (*User) Node

func (u *User) Node(ctx context.Context) (node *Node, err error)

func (*User) ProjectContributions

func (u *User) ProjectContributions(ctx context.Context) ([]*ProjectContributor, error)

func (*User) QueryDiscordAccounts

func (u *User) QueryDiscordAccounts() *DiscordAccountQuery

QueryDiscordAccounts queries the "discord_accounts" edge of the User entity.

func (*User) QueryGithubAccounts

func (u *User) QueryGithubAccounts() *GithubAccountQuery

QueryGithubAccounts queries the "github_accounts" edge of the User entity.

func (*User) QueryProjectContributions

func (u *User) QueryProjectContributions() *ProjectContributorQuery

QueryProjectContributions queries the "project_contributions" edge of the User entity.

func (*User) String

func (u *User) String() string

String implements the fmt.Stringer.

func (*User) ToEdge

func (u *User) ToEdge(order *UserOrder) *UserEdge

ToEdge converts User into UserEdge.

func (*User) Unwrap

func (u *User) Unwrap() *User

Unwrap unwraps the User entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*User) Update

func (u *User) Update() *UserUpdateOne

Update returns a builder for updating this User. Note that you need to call User.Unwrap() before calling this method if this User was returned from a transaction, and the transaction was committed or rolled back.

type UserClient

type UserClient struct {
	// contains filtered or unexported fields
}

UserClient is a client for the User schema.

func NewUserClient

func NewUserClient(c config) *UserClient

NewUserClient returns a client for the User from the given config.

func (*UserClient) Create

func (c *UserClient) Create() *UserCreate

Create returns a builder for creating a User entity.

func (*UserClient) CreateBulk

func (c *UserClient) CreateBulk(builders ...*UserCreate) *UserCreateBulk

CreateBulk returns a builder for creating a bulk of User entities.

func (*UserClient) Delete

func (c *UserClient) Delete() *UserDelete

Delete returns a delete builder for User.

func (*UserClient) DeleteOne

func (c *UserClient) DeleteOne(u *User) *UserDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*UserClient) DeleteOneID

func (c *UserClient) DeleteOneID(id int) *UserDeleteOne

DeleteOne returns a builder for deleting the given entity by its id.

func (*UserClient) Get

func (c *UserClient) Get(ctx context.Context, id int) (*User, error)

Get returns a User entity by its id.

func (*UserClient) GetX

func (c *UserClient) GetX(ctx context.Context, id int) *User

GetX is like Get, but panics if an error occurs.

func (*UserClient) Hooks

func (c *UserClient) Hooks() []Hook

Hooks returns the client hooks.

func (*UserClient) Query

func (c *UserClient) Query() *UserQuery

Query returns a query builder for User.

func (*UserClient) QueryDiscordAccounts

func (c *UserClient) QueryDiscordAccounts(u *User) *DiscordAccountQuery

QueryDiscordAccounts queries the discord_accounts edge of a User.

func (*UserClient) QueryGithubAccounts

func (c *UserClient) QueryGithubAccounts(u *User) *GithubAccountQuery

QueryGithubAccounts queries the github_accounts edge of a User.

func (*UserClient) QueryProjectContributions

func (c *UserClient) QueryProjectContributions(u *User) *ProjectContributorQuery

QueryProjectContributions queries the project_contributions edge of a User.

func (*UserClient) Update

func (c *UserClient) Update() *UserUpdate

Update returns an update builder for User.

func (*UserClient) UpdateOne

func (c *UserClient) UpdateOne(u *User) *UserUpdateOne

UpdateOne returns an update builder for the given entity.

func (*UserClient) UpdateOneID

func (c *UserClient) UpdateOneID(id int) *UserUpdateOne

UpdateOneID returns an update builder for the given id.

func (*UserClient) Use

func (c *UserClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `user.Hooks(f(g(h())))`.

type UserConnection

type UserConnection struct {
	Edges      []*UserEdge `json:"edges"`
	PageInfo   PageInfo    `json:"pageInfo"`
	TotalCount int         `json:"totalCount"`
}

UserConnection is the connection containing edges to User.

type UserCreate

type UserCreate struct {
	// contains filtered or unexported fields
}

UserCreate is the builder for creating a User entity.

func (*UserCreate) AddDiscordAccountIDs

func (uc *UserCreate) AddDiscordAccountIDs(ids ...int) *UserCreate

AddDiscordAccountIDs adds the "discord_accounts" edge to the DiscordAccount entity by IDs.

func (*UserCreate) AddDiscordAccounts

func (uc *UserCreate) AddDiscordAccounts(d ...*DiscordAccount) *UserCreate

AddDiscordAccounts adds the "discord_accounts" edges to the DiscordAccount entity.

func (*UserCreate) AddGithubAccountIDs

func (uc *UserCreate) AddGithubAccountIDs(ids ...int) *UserCreate

AddGithubAccountIDs adds the "github_accounts" edge to the GithubAccount entity by IDs.

func (*UserCreate) AddGithubAccounts

func (uc *UserCreate) AddGithubAccounts(g ...*GithubAccount) *UserCreate

AddGithubAccounts adds the "github_accounts" edges to the GithubAccount entity.

func (*UserCreate) AddProjectContributionIDs

func (uc *UserCreate) AddProjectContributionIDs(ids ...int) *UserCreate

AddProjectContributionIDs adds the "project_contributions" edge to the ProjectContributor entity by IDs.

func (*UserCreate) AddProjectContributions

func (uc *UserCreate) AddProjectContributions(p ...*ProjectContributor) *UserCreate

AddProjectContributions adds the "project_contributions" edges to the ProjectContributor entity.

func (*UserCreate) Exec

func (uc *UserCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*UserCreate) ExecX

func (uc *UserCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*UserCreate) Mutation

func (uc *UserCreate) Mutation() *UserMutation

Mutation returns the UserMutation object of the builder.

func (*UserCreate) Save

func (uc *UserCreate) Save(ctx context.Context) (*User, error)

Save creates the User in the database.

func (*UserCreate) SaveX

func (uc *UserCreate) SaveX(ctx context.Context) *User

SaveX calls Save and panics if Save returns an error.

func (*UserCreate) SetAvatarURL

func (uc *UserCreate) SetAvatarURL(s string) *UserCreate

SetAvatarURL sets the "avatar_url" field.

func (*UserCreate) SetInput

func (c *UserCreate) SetInput(i CreateUserInput) *UserCreate

SetInput applies the change-set in the CreateUserInput on the create builder.

func (*UserCreate) SetNillableAvatarURL

func (uc *UserCreate) SetNillableAvatarURL(s *string) *UserCreate

SetNillableAvatarURL sets the "avatar_url" field if the given value is not nil.

func (*UserCreate) SetUsername

func (uc *UserCreate) SetUsername(s string) *UserCreate

SetUsername sets the "username" field.

type UserCreateBulk

type UserCreateBulk struct {
	// contains filtered or unexported fields
}

UserCreateBulk is the builder for creating many User entities in bulk.

func (*UserCreateBulk) Exec

func (ucb *UserCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*UserCreateBulk) ExecX

func (ucb *UserCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*UserCreateBulk) Save

func (ucb *UserCreateBulk) Save(ctx context.Context) ([]*User, error)

Save creates the User entities in the database.

func (*UserCreateBulk) SaveX

func (ucb *UserCreateBulk) SaveX(ctx context.Context) []*User

SaveX is like Save, but panics if an error occurs.

type UserDelete

type UserDelete struct {
	// contains filtered or unexported fields
}

UserDelete is the builder for deleting a User entity.

func (*UserDelete) Exec

func (ud *UserDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*UserDelete) ExecX

func (ud *UserDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*UserDelete) Where

func (ud *UserDelete) Where(ps ...predicate.User) *UserDelete

Where appends a list predicates to the UserDelete builder.

type UserDeleteOne

type UserDeleteOne struct {
	// contains filtered or unexported fields
}

UserDeleteOne is the builder for deleting a single User entity.

func (*UserDeleteOne) Exec

func (udo *UserDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*UserDeleteOne) ExecX

func (udo *UserDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

type UserEdge

type UserEdge struct {
	Node   *User  `json:"node"`
	Cursor Cursor `json:"cursor"`
}

UserEdge is the edge representation of User.

type UserEdges

type UserEdges struct {
	// DiscordAccounts holds the value of the discord_accounts edge.
	DiscordAccounts []*DiscordAccount `json:"discord_accounts,omitempty"`
	// GithubAccounts holds the value of the github_accounts edge.
	GithubAccounts []*GithubAccount `json:"github_accounts,omitempty"`
	// ProjectContributions holds the value of the project_contributions edge.
	ProjectContributions []*ProjectContributor `json:"project_contributions,omitempty"`
	// contains filtered or unexported fields
}

UserEdges holds the relations/edges for other nodes in the graph.

func (UserEdges) DiscordAccountsOrErr

func (e UserEdges) DiscordAccountsOrErr() ([]*DiscordAccount, error)

DiscordAccountsOrErr returns the DiscordAccounts value or an error if the edge was not loaded in eager-loading.

func (UserEdges) GithubAccountsOrErr

func (e UserEdges) GithubAccountsOrErr() ([]*GithubAccount, error)

GithubAccountsOrErr returns the GithubAccounts value or an error if the edge was not loaded in eager-loading.

func (UserEdges) ProjectContributionsOrErr

func (e UserEdges) ProjectContributionsOrErr() ([]*ProjectContributor, error)

ProjectContributionsOrErr returns the ProjectContributions value or an error if the edge was not loaded in eager-loading.

type UserGroupBy

type UserGroupBy struct {
	// contains filtered or unexported fields
}

UserGroupBy is the group-by builder for User entities.

func (*UserGroupBy) Aggregate

func (ugb *UserGroupBy) Aggregate(fns ...AggregateFunc) *UserGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*UserGroupBy) Bool

func (s *UserGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*UserGroupBy) BoolX

func (s *UserGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*UserGroupBy) Bools

func (s *UserGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*UserGroupBy) BoolsX

func (s *UserGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*UserGroupBy) Float64

func (s *UserGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*UserGroupBy) Float64X

func (s *UserGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*UserGroupBy) Float64s

func (s *UserGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*UserGroupBy) Float64sX

func (s *UserGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*UserGroupBy) Int

func (s *UserGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*UserGroupBy) IntX

func (s *UserGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*UserGroupBy) Ints

func (s *UserGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*UserGroupBy) IntsX

func (s *UserGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*UserGroupBy) Scan

func (ugb *UserGroupBy) Scan(ctx context.Context, v interface{}) error

Scan applies the group-by query and scans the result into the given value.

func (*UserGroupBy) ScanX

func (s *UserGroupBy) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*UserGroupBy) String

func (s *UserGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*UserGroupBy) StringX

func (s *UserGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*UserGroupBy) Strings

func (s *UserGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*UserGroupBy) StringsX

func (s *UserGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type UserMutation

type UserMutation struct {
	// contains filtered or unexported fields
}

UserMutation represents an operation that mutates the User nodes in the graph.

func (*UserMutation) AddDiscordAccountIDs

func (m *UserMutation) AddDiscordAccountIDs(ids ...int)

AddDiscordAccountIDs adds the "discord_accounts" edge to the DiscordAccount entity by ids.

func (*UserMutation) AddField

func (m *UserMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*UserMutation) AddGithubAccountIDs

func (m *UserMutation) AddGithubAccountIDs(ids ...int)

AddGithubAccountIDs adds the "github_accounts" edge to the GithubAccount entity by ids.

func (*UserMutation) AddProjectContributionIDs

func (m *UserMutation) AddProjectContributionIDs(ids ...int)

AddProjectContributionIDs adds the "project_contributions" edge to the ProjectContributor entity by ids.

func (*UserMutation) AddedEdges

func (m *UserMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*UserMutation) AddedField

func (m *UserMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*UserMutation) AddedFields

func (m *UserMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*UserMutation) AddedIDs

func (m *UserMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*UserMutation) AvatarURL

func (m *UserMutation) AvatarURL() (r string, exists bool)

AvatarURL returns the value of the "avatar_url" field in the mutation.

func (*UserMutation) AvatarURLCleared

func (m *UserMutation) AvatarURLCleared() bool

AvatarURLCleared returns if the "avatar_url" field was cleared in this mutation.

func (*UserMutation) ClearAvatarURL

func (m *UserMutation) ClearAvatarURL()

ClearAvatarURL clears the value of the "avatar_url" field.

func (*UserMutation) ClearDiscordAccounts

func (m *UserMutation) ClearDiscordAccounts()

ClearDiscordAccounts clears the "discord_accounts" edge to the DiscordAccount entity.

func (*UserMutation) ClearEdge

func (m *UserMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*UserMutation) ClearField

func (m *UserMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*UserMutation) ClearGithubAccounts

func (m *UserMutation) ClearGithubAccounts()

ClearGithubAccounts clears the "github_accounts" edge to the GithubAccount entity.

func (*UserMutation) ClearProjectContributions

func (m *UserMutation) ClearProjectContributions()

ClearProjectContributions clears the "project_contributions" edge to the ProjectContributor entity.

func (*UserMutation) ClearedEdges

func (m *UserMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*UserMutation) ClearedFields

func (m *UserMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (UserMutation) Client

func (m UserMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*UserMutation) DiscordAccountsCleared

func (m *UserMutation) DiscordAccountsCleared() bool

DiscordAccountsCleared reports if the "discord_accounts" edge to the DiscordAccount entity was cleared.

func (*UserMutation) DiscordAccountsIDs

func (m *UserMutation) DiscordAccountsIDs() (ids []int)

DiscordAccountsIDs returns the "discord_accounts" edge IDs in the mutation.

func (*UserMutation) EdgeCleared

func (m *UserMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*UserMutation) Field

func (m *UserMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*UserMutation) FieldCleared

func (m *UserMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*UserMutation) Fields

func (m *UserMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*UserMutation) GithubAccountsCleared

func (m *UserMutation) GithubAccountsCleared() bool

GithubAccountsCleared reports if the "github_accounts" edge to the GithubAccount entity was cleared.

func (*UserMutation) GithubAccountsIDs

func (m *UserMutation) GithubAccountsIDs() (ids []int)

GithubAccountsIDs returns the "github_accounts" edge IDs in the mutation.

func (*UserMutation) ID

func (m *UserMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*UserMutation) IDs

func (m *UserMutation) IDs(ctx context.Context) ([]int, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*UserMutation) OldAvatarURL

func (m *UserMutation) OldAvatarURL(ctx context.Context) (v *string, err error)

OldAvatarURL returns the old "avatar_url" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*UserMutation) OldField

func (m *UserMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*UserMutation) OldUsername

func (m *UserMutation) OldUsername(ctx context.Context) (v string, err error)

OldUsername returns the old "username" field's value of the User entity. If the User object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*UserMutation) Op

func (m *UserMutation) Op() Op

Op returns the operation name.

func (*UserMutation) ProjectContributionsCleared

func (m *UserMutation) ProjectContributionsCleared() bool

ProjectContributionsCleared reports if the "project_contributions" edge to the ProjectContributor entity was cleared.

func (*UserMutation) ProjectContributionsIDs

func (m *UserMutation) ProjectContributionsIDs() (ids []int)

ProjectContributionsIDs returns the "project_contributions" edge IDs in the mutation.

func (*UserMutation) RemoveDiscordAccountIDs

func (m *UserMutation) RemoveDiscordAccountIDs(ids ...int)

RemoveDiscordAccountIDs removes the "discord_accounts" edge to the DiscordAccount entity by IDs.

func (*UserMutation) RemoveGithubAccountIDs

func (m *UserMutation) RemoveGithubAccountIDs(ids ...int)

RemoveGithubAccountIDs removes the "github_accounts" edge to the GithubAccount entity by IDs.

func (*UserMutation) RemoveProjectContributionIDs

func (m *UserMutation) RemoveProjectContributionIDs(ids ...int)

RemoveProjectContributionIDs removes the "project_contributions" edge to the ProjectContributor entity by IDs.

func (*UserMutation) RemovedDiscordAccountsIDs

func (m *UserMutation) RemovedDiscordAccountsIDs() (ids []int)

RemovedDiscordAccounts returns the removed IDs of the "discord_accounts" edge to the DiscordAccount entity.

func (*UserMutation) RemovedEdges

func (m *UserMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*UserMutation) RemovedGithubAccountsIDs

func (m *UserMutation) RemovedGithubAccountsIDs() (ids []int)

RemovedGithubAccounts returns the removed IDs of the "github_accounts" edge to the GithubAccount entity.

func (*UserMutation) RemovedIDs

func (m *UserMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*UserMutation) RemovedProjectContributionsIDs

func (m *UserMutation) RemovedProjectContributionsIDs() (ids []int)

RemovedProjectContributions returns the removed IDs of the "project_contributions" edge to the ProjectContributor entity.

func (*UserMutation) ResetAvatarURL

func (m *UserMutation) ResetAvatarURL()

ResetAvatarURL resets all changes to the "avatar_url" field.

func (*UserMutation) ResetDiscordAccounts

func (m *UserMutation) ResetDiscordAccounts()

ResetDiscordAccounts resets all changes to the "discord_accounts" edge.

func (*UserMutation) ResetEdge

func (m *UserMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*UserMutation) ResetField

func (m *UserMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*UserMutation) ResetGithubAccounts

func (m *UserMutation) ResetGithubAccounts()

ResetGithubAccounts resets all changes to the "github_accounts" edge.

func (*UserMutation) ResetProjectContributions

func (m *UserMutation) ResetProjectContributions()

ResetProjectContributions resets all changes to the "project_contributions" edge.

func (*UserMutation) ResetUsername

func (m *UserMutation) ResetUsername()

ResetUsername resets all changes to the "username" field.

func (*UserMutation) SetAvatarURL

func (m *UserMutation) SetAvatarURL(s string)

SetAvatarURL sets the "avatar_url" field.

func (*UserMutation) SetField

func (m *UserMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*UserMutation) SetUsername

func (m *UserMutation) SetUsername(s string)

SetUsername sets the "username" field.

func (UserMutation) Tx

func (m UserMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*UserMutation) Type

func (m *UserMutation) Type() string

Type returns the node type of this mutation (User).

func (*UserMutation) Username

func (m *UserMutation) Username() (r string, exists bool)

Username returns the value of the "username" field in the mutation.

func (*UserMutation) Where

func (m *UserMutation) Where(ps ...predicate.User)

Where appends a list predicates to the UserMutation builder.

type UserOrder

type UserOrder struct {
	Direction OrderDirection  `json:"direction"`
	Field     *UserOrderField `json:"field"`
}

UserOrder defines the ordering of User.

type UserOrderField

type UserOrderField struct {
	// contains filtered or unexported fields
}

UserOrderField defines the ordering field of User.

func (UserOrderField) MarshalGQL

func (f UserOrderField) MarshalGQL(w io.Writer)

MarshalGQL implements graphql.Marshaler interface.

func (UserOrderField) String

func (f UserOrderField) String() string

String implement fmt.Stringer interface.

func (*UserOrderField) UnmarshalGQL

func (f *UserOrderField) UnmarshalGQL(v interface{}) error

UnmarshalGQL implements graphql.Unmarshaler interface.

type UserPaginateOption

type UserPaginateOption func(*userPager) error

UserPaginateOption enables pagination customization.

func WithUserFilter

func WithUserFilter(filter func(*UserQuery) (*UserQuery, error)) UserPaginateOption

WithUserFilter configures pagination filter.

func WithUserOrder

func WithUserOrder(order *UserOrder) UserPaginateOption

WithUserOrder configures pagination ordering.

type UserQuery

type UserQuery struct {
	// contains filtered or unexported fields
}

UserQuery is the builder for querying User entities.

func (*UserQuery) All

func (uq *UserQuery) All(ctx context.Context) ([]*User, error)

All executes the query and returns a list of Users.

func (*UserQuery) AllX

func (uq *UserQuery) AllX(ctx context.Context) []*User

AllX is like All, but panics if an error occurs.

func (*UserQuery) Clone

func (uq *UserQuery) Clone() *UserQuery

Clone returns a duplicate of the UserQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*UserQuery) CollectFields

func (u *UserQuery) CollectFields(ctx context.Context, satisfies ...string) (*UserQuery, error)

CollectFields tells the query-builder to eagerly load connected nodes by resolver context.

func (*UserQuery) Count

func (uq *UserQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*UserQuery) CountX

func (uq *UserQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*UserQuery) Exist

func (uq *UserQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*UserQuery) ExistX

func (uq *UserQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*UserQuery) First

func (uq *UserQuery) First(ctx context.Context) (*User, error)

First returns the first User entity from the query. Returns a *NotFoundError when no User was found.

func (*UserQuery) FirstID

func (uq *UserQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first User ID from the query. Returns a *NotFoundError when no User ID was found.

func (*UserQuery) FirstIDX

func (uq *UserQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*UserQuery) FirstX

func (uq *UserQuery) FirstX(ctx context.Context) *User

FirstX is like First, but panics if an error occurs.

func (*UserQuery) GroupBy

func (uq *UserQuery) GroupBy(field string, fields ...string) *UserGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Username string `json:"username,omitempty"`
	Count int `json:"count,omitempty"`
}

client.User.Query().
	GroupBy(user.FieldUsername).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*UserQuery) IDs

func (uq *UserQuery) IDs(ctx context.Context) ([]int, error)

IDs executes the query and returns a list of User IDs.

func (*UserQuery) IDsX

func (uq *UserQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*UserQuery) Limit

func (uq *UserQuery) Limit(limit int) *UserQuery

Limit adds a limit step to the query.

func (*UserQuery) Offset

func (uq *UserQuery) Offset(offset int) *UserQuery

Offset adds an offset step to the query.

func (*UserQuery) Only

func (uq *UserQuery) Only(ctx context.Context) (*User, error)

Only returns a single User entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one User entity is found. Returns a *NotFoundError when no User entities are found.

func (*UserQuery) OnlyID

func (uq *UserQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only User ID in the query. Returns a *NotSingularError when more than one User ID is found. Returns a *NotFoundError when no entities are found.

func (*UserQuery) OnlyIDX

func (uq *UserQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*UserQuery) OnlyX

func (uq *UserQuery) OnlyX(ctx context.Context) *User

OnlyX is like Only, but panics if an error occurs.

func (*UserQuery) Order

func (uq *UserQuery) Order(o ...OrderFunc) *UserQuery

Order adds an order step to the query.

func (*UserQuery) Paginate

func (u *UserQuery) Paginate(
	ctx context.Context, after *Cursor, first *int,
	before *Cursor, last *int, opts ...UserPaginateOption,
) (*UserConnection, error)

Paginate executes the query and returns a relay based cursor connection to User.

func (*UserQuery) QueryDiscordAccounts

func (uq *UserQuery) QueryDiscordAccounts() *DiscordAccountQuery

QueryDiscordAccounts chains the current query on the "discord_accounts" edge.

func (*UserQuery) QueryGithubAccounts

func (uq *UserQuery) QueryGithubAccounts() *GithubAccountQuery

QueryGithubAccounts chains the current query on the "github_accounts" edge.

func (*UserQuery) QueryProjectContributions

func (uq *UserQuery) QueryProjectContributions() *ProjectContributorQuery

QueryProjectContributions chains the current query on the "project_contributions" edge.

func (*UserQuery) Select

func (uq *UserQuery) Select(fields ...string) *UserSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Username string `json:"username,omitempty"`
}

client.User.Query().
	Select(user.FieldUsername).
	Scan(ctx, &v)

func (*UserQuery) Unique

func (uq *UserQuery) Unique(unique bool) *UserQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*UserQuery) Where

func (uq *UserQuery) Where(ps ...predicate.User) *UserQuery

Where adds a new predicate for the UserQuery builder.

func (*UserQuery) WithDiscordAccounts

func (uq *UserQuery) WithDiscordAccounts(opts ...func(*DiscordAccountQuery)) *UserQuery

WithDiscordAccounts tells the query-builder to eager-load the nodes that are connected to the "discord_accounts" edge. The optional arguments are used to configure the query builder of the edge.

func (*UserQuery) WithGithubAccounts

func (uq *UserQuery) WithGithubAccounts(opts ...func(*GithubAccountQuery)) *UserQuery

WithGithubAccounts tells the query-builder to eager-load the nodes that are connected to the "github_accounts" edge. The optional arguments are used to configure the query builder of the edge.

func (*UserQuery) WithNamedDiscordAccounts

func (uq *UserQuery) WithNamedDiscordAccounts(name string, opts ...func(*DiscordAccountQuery)) *UserQuery

WithNamedDiscordAccounts tells the query-builder to eager-load the nodes that are connected to the "discord_accounts" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*UserQuery) WithNamedGithubAccounts

func (uq *UserQuery) WithNamedGithubAccounts(name string, opts ...func(*GithubAccountQuery)) *UserQuery

WithNamedGithubAccounts tells the query-builder to eager-load the nodes that are connected to the "github_accounts" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*UserQuery) WithNamedProjectContributions

func (uq *UserQuery) WithNamedProjectContributions(name string, opts ...func(*ProjectContributorQuery)) *UserQuery

WithNamedProjectContributions tells the query-builder to eager-load the nodes that are connected to the "project_contributions" edge with the given name. The optional arguments are used to configure the query builder of the edge.

func (*UserQuery) WithProjectContributions

func (uq *UserQuery) WithProjectContributions(opts ...func(*ProjectContributorQuery)) *UserQuery

WithProjectContributions tells the query-builder to eager-load the nodes that are connected to the "project_contributions" edge. The optional arguments are used to configure the query builder of the edge.

type UserSelect

type UserSelect struct {
	*UserQuery
	// contains filtered or unexported fields
}

UserSelect is the builder for selecting fields of User entities.

func (*UserSelect) Bool

func (s *UserSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*UserSelect) BoolX

func (s *UserSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*UserSelect) Bools

func (s *UserSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*UserSelect) BoolsX

func (s *UserSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*UserSelect) Float64

func (s *UserSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*UserSelect) Float64X

func (s *UserSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*UserSelect) Float64s

func (s *UserSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*UserSelect) Float64sX

func (s *UserSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*UserSelect) Int

func (s *UserSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*UserSelect) IntX

func (s *UserSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*UserSelect) Ints

func (s *UserSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*UserSelect) IntsX

func (s *UserSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*UserSelect) Scan

func (us *UserSelect) Scan(ctx context.Context, v interface{}) error

Scan applies the selector query and scans the result into the given value.

func (*UserSelect) ScanX

func (s *UserSelect) ScanX(ctx context.Context, v interface{})

ScanX is like Scan, but panics if an error occurs.

func (*UserSelect) String

func (s *UserSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*UserSelect) StringX

func (s *UserSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*UserSelect) Strings

func (s *UserSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*UserSelect) StringsX

func (s *UserSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type UserUpdate

type UserUpdate struct {
	// contains filtered or unexported fields
}

UserUpdate is the builder for updating User entities.

func (*UserUpdate) AddDiscordAccountIDs

func (uu *UserUpdate) AddDiscordAccountIDs(ids ...int) *UserUpdate

AddDiscordAccountIDs adds the "discord_accounts" edge to the DiscordAccount entity by IDs.

func (*UserUpdate) AddDiscordAccounts

func (uu *UserUpdate) AddDiscordAccounts(d ...*DiscordAccount) *UserUpdate

AddDiscordAccounts adds the "discord_accounts" edges to the DiscordAccount entity.

func (*UserUpdate) AddGithubAccountIDs

func (uu *UserUpdate) AddGithubAccountIDs(ids ...int) *UserUpdate

AddGithubAccountIDs adds the "github_accounts" edge to the GithubAccount entity by IDs.

func (*UserUpdate) AddGithubAccounts

func (uu *UserUpdate) AddGithubAccounts(g ...*GithubAccount) *UserUpdate

AddGithubAccounts adds the "github_accounts" edges to the GithubAccount entity.

func (*UserUpdate) AddProjectContributionIDs

func (uu *UserUpdate) AddProjectContributionIDs(ids ...int) *UserUpdate

AddProjectContributionIDs adds the "project_contributions" edge to the ProjectContributor entity by IDs.

func (*UserUpdate) AddProjectContributions

func (uu *UserUpdate) AddProjectContributions(p ...*ProjectContributor) *UserUpdate

AddProjectContributions adds the "project_contributions" edges to the ProjectContributor entity.

func (*UserUpdate) ClearAvatarURL

func (uu *UserUpdate) ClearAvatarURL() *UserUpdate

ClearAvatarURL clears the value of the "avatar_url" field.

func (*UserUpdate) ClearDiscordAccounts

func (uu *UserUpdate) ClearDiscordAccounts() *UserUpdate

ClearDiscordAccounts clears all "discord_accounts" edges to the DiscordAccount entity.

func (*UserUpdate) ClearGithubAccounts

func (uu *UserUpdate) ClearGithubAccounts() *UserUpdate

ClearGithubAccounts clears all "github_accounts" edges to the GithubAccount entity.

func (*UserUpdate) ClearProjectContributions

func (uu *UserUpdate) ClearProjectContributions() *UserUpdate

ClearProjectContributions clears all "project_contributions" edges to the ProjectContributor entity.

func (*UserUpdate) Exec

func (uu *UserUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*UserUpdate) ExecX

func (uu *UserUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*UserUpdate) Mutation

func (uu *UserUpdate) Mutation() *UserMutation

Mutation returns the UserMutation object of the builder.

func (*UserUpdate) RemoveDiscordAccountIDs

func (uu *UserUpdate) RemoveDiscordAccountIDs(ids ...int) *UserUpdate

RemoveDiscordAccountIDs removes the "discord_accounts" edge to DiscordAccount entities by IDs.

func (*UserUpdate) RemoveDiscordAccounts

func (uu *UserUpdate) RemoveDiscordAccounts(d ...*DiscordAccount) *UserUpdate

RemoveDiscordAccounts removes "discord_accounts" edges to DiscordAccount entities.

func (*UserUpdate) RemoveGithubAccountIDs

func (uu *UserUpdate) RemoveGithubAccountIDs(ids ...int) *UserUpdate

RemoveGithubAccountIDs removes the "github_accounts" edge to GithubAccount entities by IDs.

func (*UserUpdate) RemoveGithubAccounts

func (uu *UserUpdate) RemoveGithubAccounts(g ...*GithubAccount) *UserUpdate

RemoveGithubAccounts removes "github_accounts" edges to GithubAccount entities.

func (*UserUpdate) RemoveProjectContributionIDs

func (uu *UserUpdate) RemoveProjectContributionIDs(ids ...int) *UserUpdate

RemoveProjectContributionIDs removes the "project_contributions" edge to ProjectContributor entities by IDs.

func (*UserUpdate) RemoveProjectContributions

func (uu *UserUpdate) RemoveProjectContributions(p ...*ProjectContributor) *UserUpdate

RemoveProjectContributions removes "project_contributions" edges to ProjectContributor entities.

func (*UserUpdate) Save

func (uu *UserUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*UserUpdate) SaveX

func (uu *UserUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*UserUpdate) SetAvatarURL

func (uu *UserUpdate) SetAvatarURL(s string) *UserUpdate

SetAvatarURL sets the "avatar_url" field.

func (*UserUpdate) SetInput

func (u *UserUpdate) SetInput(i UpdateUserInput) *UserUpdate

SetInput applies the change-set in the UpdateUserInput on the update builder.

func (*UserUpdate) SetNillableAvatarURL

func (uu *UserUpdate) SetNillableAvatarURL(s *string) *UserUpdate

SetNillableAvatarURL sets the "avatar_url" field if the given value is not nil.

func (*UserUpdate) SetUsername

func (uu *UserUpdate) SetUsername(s string) *UserUpdate

SetUsername sets the "username" field.

func (*UserUpdate) Where

func (uu *UserUpdate) Where(ps ...predicate.User) *UserUpdate

Where appends a list predicates to the UserUpdate builder.

type UserUpdateOne

type UserUpdateOne struct {
	// contains filtered or unexported fields
}

UserUpdateOne is the builder for updating a single User entity.

func (*UserUpdateOne) AddDiscordAccountIDs

func (uuo *UserUpdateOne) AddDiscordAccountIDs(ids ...int) *UserUpdateOne

AddDiscordAccountIDs adds the "discord_accounts" edge to the DiscordAccount entity by IDs.

func (*UserUpdateOne) AddDiscordAccounts

func (uuo *UserUpdateOne) AddDiscordAccounts(d ...*DiscordAccount) *UserUpdateOne

AddDiscordAccounts adds the "discord_accounts" edges to the DiscordAccount entity.

func (*UserUpdateOne) AddGithubAccountIDs

func (uuo *UserUpdateOne) AddGithubAccountIDs(ids ...int) *UserUpdateOne

AddGithubAccountIDs adds the "github_accounts" edge to the GithubAccount entity by IDs.

func (*UserUpdateOne) AddGithubAccounts

func (uuo *UserUpdateOne) AddGithubAccounts(g ...*GithubAccount) *UserUpdateOne

AddGithubAccounts adds the "github_accounts" edges to the GithubAccount entity.

func (*UserUpdateOne) AddProjectContributionIDs

func (uuo *UserUpdateOne) AddProjectContributionIDs(ids ...int) *UserUpdateOne

AddProjectContributionIDs adds the "project_contributions" edge to the ProjectContributor entity by IDs.

func (*UserUpdateOne) AddProjectContributions

func (uuo *UserUpdateOne) AddProjectContributions(p ...*ProjectContributor) *UserUpdateOne

AddProjectContributions adds the "project_contributions" edges to the ProjectContributor entity.

func (*UserUpdateOne) ClearAvatarURL

func (uuo *UserUpdateOne) ClearAvatarURL() *UserUpdateOne

ClearAvatarURL clears the value of the "avatar_url" field.

func (*UserUpdateOne) ClearDiscordAccounts

func (uuo *UserUpdateOne) ClearDiscordAccounts() *UserUpdateOne

ClearDiscordAccounts clears all "discord_accounts" edges to the DiscordAccount entity.

func (*UserUpdateOne) ClearGithubAccounts

func (uuo *UserUpdateOne) ClearGithubAccounts() *UserUpdateOne

ClearGithubAccounts clears all "github_accounts" edges to the GithubAccount entity.

func (*UserUpdateOne) ClearProjectContributions

func (uuo *UserUpdateOne) ClearProjectContributions() *UserUpdateOne

ClearProjectContributions clears all "project_contributions" edges to the ProjectContributor entity.

func (*UserUpdateOne) Exec

func (uuo *UserUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*UserUpdateOne) ExecX

func (uuo *UserUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*UserUpdateOne) Mutation

func (uuo *UserUpdateOne) Mutation() *UserMutation

Mutation returns the UserMutation object of the builder.

func (*UserUpdateOne) RemoveDiscordAccountIDs

func (uuo *UserUpdateOne) RemoveDiscordAccountIDs(ids ...int) *UserUpdateOne

RemoveDiscordAccountIDs removes the "discord_accounts" edge to DiscordAccount entities by IDs.

func (*UserUpdateOne) RemoveDiscordAccounts

func (uuo *UserUpdateOne) RemoveDiscordAccounts(d ...*DiscordAccount) *UserUpdateOne

RemoveDiscordAccounts removes "discord_accounts" edges to DiscordAccount entities.

func (*UserUpdateOne) RemoveGithubAccountIDs

func (uuo *UserUpdateOne) RemoveGithubAccountIDs(ids ...int) *UserUpdateOne

RemoveGithubAccountIDs removes the "github_accounts" edge to GithubAccount entities by IDs.

func (*UserUpdateOne) RemoveGithubAccounts

func (uuo *UserUpdateOne) RemoveGithubAccounts(g ...*GithubAccount) *UserUpdateOne

RemoveGithubAccounts removes "github_accounts" edges to GithubAccount entities.

func (*UserUpdateOne) RemoveProjectContributionIDs

func (uuo *UserUpdateOne) RemoveProjectContributionIDs(ids ...int) *UserUpdateOne

RemoveProjectContributionIDs removes the "project_contributions" edge to ProjectContributor entities by IDs.

func (*UserUpdateOne) RemoveProjectContributions

func (uuo *UserUpdateOne) RemoveProjectContributions(p ...*ProjectContributor) *UserUpdateOne

RemoveProjectContributions removes "project_contributions" edges to ProjectContributor entities.

func (*UserUpdateOne) Save

func (uuo *UserUpdateOne) Save(ctx context.Context) (*User, error)

Save executes the query and returns the updated User entity.

func (*UserUpdateOne) SaveX

func (uuo *UserUpdateOne) SaveX(ctx context.Context) *User

SaveX is like Save, but panics if an error occurs.

func (*UserUpdateOne) Select

func (uuo *UserUpdateOne) Select(field string, fields ...string) *UserUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*UserUpdateOne) SetAvatarURL

func (uuo *UserUpdateOne) SetAvatarURL(s string) *UserUpdateOne

SetAvatarURL sets the "avatar_url" field.

func (*UserUpdateOne) SetInput

SetInput applies the change-set in the UpdateUserInput on the update-one builder.

func (*UserUpdateOne) SetNillableAvatarURL

func (uuo *UserUpdateOne) SetNillableAvatarURL(s *string) *UserUpdateOne

SetNillableAvatarURL sets the "avatar_url" field if the given value is not nil.

func (*UserUpdateOne) SetUsername

func (uuo *UserUpdateOne) SetUsername(s string) *UserUpdateOne

SetUsername sets the "username" field.

type UserWhereInput

type UserWhereInput struct {
	Predicates []predicate.User  `json:"-"`
	Not        *UserWhereInput   `json:"not,omitempty"`
	Or         []*UserWhereInput `json:"or,omitempty"`
	And        []*UserWhereInput `json:"and,omitempty"`

	// "id" field predicates.
	ID      *int  `json:"id,omitempty"`
	IDNEQ   *int  `json:"idNEQ,omitempty"`
	IDIn    []int `json:"idIn,omitempty"`
	IDNotIn []int `json:"idNotIn,omitempty"`
	IDGT    *int  `json:"idGT,omitempty"`
	IDGTE   *int  `json:"idGTE,omitempty"`
	IDLT    *int  `json:"idLT,omitempty"`
	IDLTE   *int  `json:"idLTE,omitempty"`

	// "username" field predicates.
	Username             *string  `json:"username,omitempty"`
	UsernameNEQ          *string  `json:"usernameNEQ,omitempty"`
	UsernameIn           []string `json:"usernameIn,omitempty"`
	UsernameNotIn        []string `json:"usernameNotIn,omitempty"`
	UsernameGT           *string  `json:"usernameGT,omitempty"`
	UsernameGTE          *string  `json:"usernameGTE,omitempty"`
	UsernameLT           *string  `json:"usernameLT,omitempty"`
	UsernameLTE          *string  `json:"usernameLTE,omitempty"`
	UsernameContains     *string  `json:"usernameContains,omitempty"`
	UsernameHasPrefix    *string  `json:"usernameHasPrefix,omitempty"`
	UsernameHasSuffix    *string  `json:"usernameHasSuffix,omitempty"`
	UsernameEqualFold    *string  `json:"usernameEqualFold,omitempty"`
	UsernameContainsFold *string  `json:"usernameContainsFold,omitempty"`

	// "avatar_url" field predicates.
	AvatarURL             *string  `json:"avatarURL,omitempty"`
	AvatarURLNEQ          *string  `json:"avatarURLNEQ,omitempty"`
	AvatarURLIn           []string `json:"avatarURLIn,omitempty"`
	AvatarURLNotIn        []string `json:"avatarURLNotIn,omitempty"`
	AvatarURLGT           *string  `json:"avatarURLGT,omitempty"`
	AvatarURLGTE          *string  `json:"avatarURLGTE,omitempty"`
	AvatarURLLT           *string  `json:"avatarURLLT,omitempty"`
	AvatarURLLTE          *string  `json:"avatarURLLTE,omitempty"`
	AvatarURLContains     *string  `json:"avatarURLContains,omitempty"`
	AvatarURLHasPrefix    *string  `json:"avatarURLHasPrefix,omitempty"`
	AvatarURLHasSuffix    *string  `json:"avatarURLHasSuffix,omitempty"`
	AvatarURLIsNil        bool     `json:"avatarURLIsNil,omitempty"`
	AvatarURLNotNil       bool     `json:"avatarURLNotNil,omitempty"`
	AvatarURLEqualFold    *string  `json:"avatarURLEqualFold,omitempty"`
	AvatarURLContainsFold *string  `json:"avatarURLContainsFold,omitempty"`

	// "discord_accounts" edge predicates.
	HasDiscordAccounts     *bool                       `json:"hasDiscordAccounts,omitempty"`
	HasDiscordAccountsWith []*DiscordAccountWhereInput `json:"hasDiscordAccountsWith,omitempty"`

	// "github_accounts" edge predicates.
	HasGithubAccounts     *bool                      `json:"hasGithubAccounts,omitempty"`
	HasGithubAccountsWith []*GithubAccountWhereInput `json:"hasGithubAccountsWith,omitempty"`

	// "project_contributions" edge predicates.
	HasProjectContributions     *bool                           `json:"hasProjectContributions,omitempty"`
	HasProjectContributionsWith []*ProjectContributorWhereInput `json:"hasProjectContributionsWith,omitempty"`
}

UserWhereInput represents a where input for filtering User queries.

func (*UserWhereInput) AddPredicates

func (i *UserWhereInput) AddPredicates(predicates ...predicate.User)

AddPredicates adds custom predicates to the where input to be used during the filtering phase.

func (*UserWhereInput) Filter

func (i *UserWhereInput) Filter(q *UserQuery) (*UserQuery, error)

Filter applies the UserWhereInput filter on the UserQuery builder.

func (*UserWhereInput) P

func (i *UserWhereInput) P() (predicate.User, error)

P returns a predicate for filtering users. An error is returned if the input is empty or invalid.

type Users

type Users []*User

Users is a parsable slice of User.

type ValidationError

type ValidationError struct {
	Name string // Field or edge name.
	// contains filtered or unexported fields
}

ValidationError returns when validating a field or edge fails.

func (*ValidationError) Error

func (e *ValidationError) Error() string

Error implements the error interface.

func (*ValidationError) Unwrap

func (e *ValidationError) Unwrap() error

Unwrap implements the errors.Wrapper interface.

type Value

type Value = ent.Value

ent aliases to avoid import conflicts in user's code.

Source Files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL