ent

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2026 License: MIT Imports: 35 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.
	TypeAssignment           = "Assignment"
	TypeCapabilityModel      = "CapabilityModel"
	TypeDeliveryEvidence     = "DeliveryEvidence"
	TypeInitiative           = "Initiative"
	TypeInitiativeDependency = "InitiativeDependency"
	TypeJudgeResult          = "JudgeResult"
	TypeJudgeRubric          = "JudgeRubric"
	TypeMaturityAssessment   = "MaturityAssessment"
	TypePhase                = "Phase"
	TypeProgram              = "Program"
	TypeRMIDependency        = "RMIDependency"
	TypeRepository           = "Repository"
	TypeRepositoryDependency = "RepositoryDependency"
	TypeRoadmapItem          = "RoadmapItem"
	TypeSpecWorkflow         = "SpecWorkflow"
)

Variables

View Source
var ErrTxStarted = errors.New("ent: cannot start a transaction within a transaction")

ErrTxStarted is returned when trying to start a new transaction from a transactional client.

Functions

func Asc

func Asc(fields ...string) func(*sql.Selector)

Asc applies the given fields in ASC order.

func Desc

func Desc(fields ...string) func(*sql.Selector)

Desc applies the given fields in DESC order.

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.

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 Assignment

type Assignment struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// Worker holds the value of the "worker" field.
	Worker string `json:"worker,omitempty"`
	// Status holds the value of the "status" field.
	Status string `json:"status,omitempty"`
	// LeaseExpiresAt holds the value of the "lease_expires_at" field.
	LeaseExpiresAt time.Time `json:"lease_expires_at,omitempty"`
	// Workspace holds the value of the "workspace" field.
	Workspace string `json:"workspace,omitempty"`
	// Handoff holds the value of the "handoff" field.
	Handoff map[string]interface{} `json:"handoff,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// CompletedAt holds the value of the "completed_at" field.
	CompletedAt *time.Time `json:"completed_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the AssignmentQuery when eager-loading is set.
	Edges AssignmentEdges `json:"edges"`
	// contains filtered or unexported fields
}

Assignment is the model entity for the Assignment schema.

func (*Assignment) QueryRoadmapItem

func (_m *Assignment) QueryRoadmapItem() *RoadmapItemQuery

QueryRoadmapItem queries the "roadmap_item" edge of the Assignment entity.

func (*Assignment) String

func (_m *Assignment) String() string

String implements the fmt.Stringer.

func (*Assignment) Unwrap

func (_m *Assignment) Unwrap() *Assignment

Unwrap unwraps the Assignment 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 (*Assignment) Update

func (_m *Assignment) Update() *AssignmentUpdateOne

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

func (*Assignment) Value

func (_m *Assignment) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the Assignment. This includes values selected through modifiers, order, etc.

type AssignmentClient

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

AssignmentClient is a client for the Assignment schema.

func NewAssignmentClient

func NewAssignmentClient(c config) *AssignmentClient

NewAssignmentClient returns a client for the Assignment from the given config.

func (*AssignmentClient) Create

func (c *AssignmentClient) Create() *AssignmentCreate

Create returns a builder for creating a Assignment entity.

func (*AssignmentClient) CreateBulk

func (c *AssignmentClient) CreateBulk(builders ...*AssignmentCreate) *AssignmentCreateBulk

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

func (*AssignmentClient) Delete

func (c *AssignmentClient) Delete() *AssignmentDelete

Delete returns a delete builder for Assignment.

func (*AssignmentClient) DeleteOne

func (c *AssignmentClient) DeleteOne(_m *Assignment) *AssignmentDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*AssignmentClient) DeleteOneID

func (c *AssignmentClient) DeleteOneID(id string) *AssignmentDeleteOne

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

func (*AssignmentClient) Get

func (c *AssignmentClient) Get(ctx context.Context, id string) (*Assignment, error)

Get returns a Assignment entity by its id.

func (*AssignmentClient) GetX

func (c *AssignmentClient) GetX(ctx context.Context, id string) *Assignment

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

func (*AssignmentClient) Hooks

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

Hooks returns the client hooks.

func (*AssignmentClient) Intercept

func (c *AssignmentClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `assignment.Intercept(f(g(h())))`.

func (*AssignmentClient) Interceptors

func (c *AssignmentClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*AssignmentClient) MapCreateBulk

func (c *AssignmentClient) MapCreateBulk(slice any, setFunc func(*AssignmentCreate, int)) *AssignmentCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*AssignmentClient) Query

func (c *AssignmentClient) Query() *AssignmentQuery

Query returns a query builder for Assignment.

func (*AssignmentClient) QueryRoadmapItem

func (c *AssignmentClient) QueryRoadmapItem(_m *Assignment) *RoadmapItemQuery

QueryRoadmapItem queries the roadmap_item edge of a Assignment.

func (*AssignmentClient) Update

func (c *AssignmentClient) Update() *AssignmentUpdate

Update returns an update builder for Assignment.

func (*AssignmentClient) UpdateOne

func (c *AssignmentClient) UpdateOne(_m *Assignment) *AssignmentUpdateOne

UpdateOne returns an update builder for the given entity.

func (*AssignmentClient) UpdateOneID

func (c *AssignmentClient) UpdateOneID(id string) *AssignmentUpdateOne

UpdateOneID returns an update builder for the given id.

func (*AssignmentClient) Use

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

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

type AssignmentCreate

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

AssignmentCreate is the builder for creating a Assignment entity.

func (*AssignmentCreate) Exec

func (_c *AssignmentCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*AssignmentCreate) ExecX

func (_c *AssignmentCreate) ExecX(ctx context.Context)

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

func (*AssignmentCreate) Mutation

func (_c *AssignmentCreate) Mutation() *AssignmentMutation

Mutation returns the AssignmentMutation object of the builder.

func (*AssignmentCreate) Save

func (_c *AssignmentCreate) Save(ctx context.Context) (*Assignment, error)

Save creates the Assignment in the database.

func (*AssignmentCreate) SaveX

func (_c *AssignmentCreate) SaveX(ctx context.Context) *Assignment

SaveX calls Save and panics if Save returns an error.

func (*AssignmentCreate) SetCompletedAt

func (_c *AssignmentCreate) SetCompletedAt(v time.Time) *AssignmentCreate

SetCompletedAt sets the "completed_at" field.

func (*AssignmentCreate) SetCreatedAt

func (_c *AssignmentCreate) SetCreatedAt(v time.Time) *AssignmentCreate

SetCreatedAt sets the "created_at" field.

func (*AssignmentCreate) SetHandoff

func (_c *AssignmentCreate) SetHandoff(v map[string]interface{}) *AssignmentCreate

SetHandoff sets the "handoff" field.

func (*AssignmentCreate) SetID

SetID sets the "id" field.

func (*AssignmentCreate) SetLeaseExpiresAt

func (_c *AssignmentCreate) SetLeaseExpiresAt(v time.Time) *AssignmentCreate

SetLeaseExpiresAt sets the "lease_expires_at" field.

func (*AssignmentCreate) SetNillableCompletedAt

func (_c *AssignmentCreate) SetNillableCompletedAt(v *time.Time) *AssignmentCreate

SetNillableCompletedAt sets the "completed_at" field if the given value is not nil.

func (*AssignmentCreate) SetNillableWorkspace

func (_c *AssignmentCreate) SetNillableWorkspace(v *string) *AssignmentCreate

SetNillableWorkspace sets the "workspace" field if the given value is not nil.

func (*AssignmentCreate) SetRoadmapItem

func (_c *AssignmentCreate) SetRoadmapItem(v *RoadmapItem) *AssignmentCreate

SetRoadmapItem sets the "roadmap_item" edge to the RoadmapItem entity.

func (*AssignmentCreate) SetRoadmapItemID

func (_c *AssignmentCreate) SetRoadmapItemID(id string) *AssignmentCreate

SetRoadmapItemID sets the "roadmap_item" edge to the RoadmapItem entity by ID.

func (*AssignmentCreate) SetStatus

func (_c *AssignmentCreate) SetStatus(v string) *AssignmentCreate

SetStatus sets the "status" field.

func (*AssignmentCreate) SetUpdatedAt

func (_c *AssignmentCreate) SetUpdatedAt(v time.Time) *AssignmentCreate

SetUpdatedAt sets the "updated_at" field.

func (*AssignmentCreate) SetWorker

func (_c *AssignmentCreate) SetWorker(v string) *AssignmentCreate

SetWorker sets the "worker" field.

func (*AssignmentCreate) SetWorkspace

func (_c *AssignmentCreate) SetWorkspace(v string) *AssignmentCreate

SetWorkspace sets the "workspace" field.

type AssignmentCreateBulk

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

AssignmentCreateBulk is the builder for creating many Assignment entities in bulk.

func (*AssignmentCreateBulk) Exec

func (_c *AssignmentCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*AssignmentCreateBulk) ExecX

func (_c *AssignmentCreateBulk) ExecX(ctx context.Context)

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

func (*AssignmentCreateBulk) Save

func (_c *AssignmentCreateBulk) Save(ctx context.Context) ([]*Assignment, error)

Save creates the Assignment entities in the database.

func (*AssignmentCreateBulk) SaveX

func (_c *AssignmentCreateBulk) SaveX(ctx context.Context) []*Assignment

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

type AssignmentDelete

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

AssignmentDelete is the builder for deleting a Assignment entity.

func (*AssignmentDelete) Exec

func (_d *AssignmentDelete) Exec(ctx context.Context) (int, error)

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

func (*AssignmentDelete) ExecX

func (_d *AssignmentDelete) ExecX(ctx context.Context) int

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

func (*AssignmentDelete) Where

Where appends a list predicates to the AssignmentDelete builder.

type AssignmentDeleteOne

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

AssignmentDeleteOne is the builder for deleting a single Assignment entity.

func (*AssignmentDeleteOne) Exec

func (_d *AssignmentDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*AssignmentDeleteOne) ExecX

func (_d *AssignmentDeleteOne) ExecX(ctx context.Context)

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

func (*AssignmentDeleteOne) Where

Where appends a list predicates to the AssignmentDelete builder.

type AssignmentEdges

type AssignmentEdges struct {
	// RoadmapItem holds the value of the roadmap_item edge.
	RoadmapItem *RoadmapItem `json:"roadmap_item,omitempty"`
	// contains filtered or unexported fields
}

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

func (AssignmentEdges) RoadmapItemOrErr

func (e AssignmentEdges) RoadmapItemOrErr() (*RoadmapItem, error)

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

type AssignmentGroupBy

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

AssignmentGroupBy is the group-by builder for Assignment entities.

func (*AssignmentGroupBy) Aggregate

func (_g *AssignmentGroupBy) Aggregate(fns ...AggregateFunc) *AssignmentGroupBy

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

func (*AssignmentGroupBy) Bool

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

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

func (*AssignmentGroupBy) BoolX

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

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

func (*AssignmentGroupBy) Bools

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

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

func (*AssignmentGroupBy) BoolsX

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

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

func (*AssignmentGroupBy) Float64

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

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

func (*AssignmentGroupBy) Float64X

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

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

func (*AssignmentGroupBy) Float64s

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

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

func (*AssignmentGroupBy) Float64sX

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

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

func (*AssignmentGroupBy) Int

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

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

func (*AssignmentGroupBy) IntX

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

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

func (*AssignmentGroupBy) Ints

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

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

func (*AssignmentGroupBy) IntsX

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

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

func (*AssignmentGroupBy) Scan

func (_g *AssignmentGroupBy) Scan(ctx context.Context, v any) error

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

func (*AssignmentGroupBy) ScanX

func (s *AssignmentGroupBy) ScanX(ctx context.Context, v any)

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

func (*AssignmentGroupBy) String

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

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

func (*AssignmentGroupBy) StringX

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

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

func (*AssignmentGroupBy) Strings

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

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

func (*AssignmentGroupBy) StringsX

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

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

type AssignmentMutation

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

AssignmentMutation represents an operation that mutates the Assignment nodes in the graph.

func (*AssignmentMutation) AddField

func (m *AssignmentMutation) 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 (*AssignmentMutation) AddedEdges

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

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

func (*AssignmentMutation) AddedField

func (m *AssignmentMutation) 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 (*AssignmentMutation) AddedFields

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

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

func (*AssignmentMutation) AddedIDs

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

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

func (*AssignmentMutation) ClearCompletedAt

func (m *AssignmentMutation) ClearCompletedAt()

ClearCompletedAt clears the value of the "completed_at" field.

func (*AssignmentMutation) ClearEdge

func (m *AssignmentMutation) 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 (*AssignmentMutation) ClearField

func (m *AssignmentMutation) 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 (*AssignmentMutation) ClearHandoff

func (m *AssignmentMutation) ClearHandoff()

ClearHandoff clears the value of the "handoff" field.

func (*AssignmentMutation) ClearRoadmapItem

func (m *AssignmentMutation) ClearRoadmapItem()

ClearRoadmapItem clears the "roadmap_item" edge to the RoadmapItem entity.

func (*AssignmentMutation) ClearWorkspace

func (m *AssignmentMutation) ClearWorkspace()

ClearWorkspace clears the value of the "workspace" field.

func (*AssignmentMutation) ClearedEdges

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

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

func (*AssignmentMutation) ClearedFields

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

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

func (AssignmentMutation) Client

func (m AssignmentMutation) 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 (*AssignmentMutation) CompletedAt

func (m *AssignmentMutation) CompletedAt() (r time.Time, exists bool)

CompletedAt returns the value of the "completed_at" field in the mutation.

func (*AssignmentMutation) CompletedAtCleared

func (m *AssignmentMutation) CompletedAtCleared() bool

CompletedAtCleared returns if the "completed_at" field was cleared in this mutation.

func (*AssignmentMutation) CreatedAt

func (m *AssignmentMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*AssignmentMutation) EdgeCleared

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

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

func (*AssignmentMutation) Field

func (m *AssignmentMutation) 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 (*AssignmentMutation) FieldCleared

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

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

func (*AssignmentMutation) Fields

func (m *AssignmentMutation) 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 (*AssignmentMutation) Handoff

func (m *AssignmentMutation) Handoff() (r map[string]interface{}, exists bool)

Handoff returns the value of the "handoff" field in the mutation.

func (*AssignmentMutation) HandoffCleared

func (m *AssignmentMutation) HandoffCleared() bool

HandoffCleared returns if the "handoff" field was cleared in this mutation.

func (*AssignmentMutation) ID

func (m *AssignmentMutation) ID() (id string, 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 (*AssignmentMutation) IDs

func (m *AssignmentMutation) IDs(ctx context.Context) ([]string, 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 (*AssignmentMutation) LeaseExpiresAt

func (m *AssignmentMutation) LeaseExpiresAt() (r time.Time, exists bool)

LeaseExpiresAt returns the value of the "lease_expires_at" field in the mutation.

func (*AssignmentMutation) OldCompletedAt

func (m *AssignmentMutation) OldCompletedAt(ctx context.Context) (v *time.Time, err error)

OldCompletedAt returns the old "completed_at" field's value of the Assignment entity. If the Assignment 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 (*AssignmentMutation) OldCreatedAt

func (m *AssignmentMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the Assignment entity. If the Assignment 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 (*AssignmentMutation) OldField

func (m *AssignmentMutation) 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 (*AssignmentMutation) OldHandoff

func (m *AssignmentMutation) OldHandoff(ctx context.Context) (v map[string]interface{}, err error)

OldHandoff returns the old "handoff" field's value of the Assignment entity. If the Assignment 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 (*AssignmentMutation) OldLeaseExpiresAt

func (m *AssignmentMutation) OldLeaseExpiresAt(ctx context.Context) (v time.Time, err error)

OldLeaseExpiresAt returns the old "lease_expires_at" field's value of the Assignment entity. If the Assignment 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 (*AssignmentMutation) OldStatus

func (m *AssignmentMutation) OldStatus(ctx context.Context) (v string, err error)

OldStatus returns the old "status" field's value of the Assignment entity. If the Assignment 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 (*AssignmentMutation) OldUpdatedAt

func (m *AssignmentMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the Assignment entity. If the Assignment 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 (*AssignmentMutation) OldWorker

func (m *AssignmentMutation) OldWorker(ctx context.Context) (v string, err error)

OldWorker returns the old "worker" field's value of the Assignment entity. If the Assignment 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 (*AssignmentMutation) OldWorkspace

func (m *AssignmentMutation) OldWorkspace(ctx context.Context) (v string, err error)

OldWorkspace returns the old "workspace" field's value of the Assignment entity. If the Assignment 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 (*AssignmentMutation) Op

func (m *AssignmentMutation) Op() Op

Op returns the operation name.

func (*AssignmentMutation) RemovedEdges

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

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

func (*AssignmentMutation) RemovedIDs

func (m *AssignmentMutation) 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 (*AssignmentMutation) ResetCompletedAt

func (m *AssignmentMutation) ResetCompletedAt()

ResetCompletedAt resets all changes to the "completed_at" field.

func (*AssignmentMutation) ResetCreatedAt

func (m *AssignmentMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*AssignmentMutation) ResetEdge

func (m *AssignmentMutation) 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 (*AssignmentMutation) ResetField

func (m *AssignmentMutation) 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 (*AssignmentMutation) ResetHandoff

func (m *AssignmentMutation) ResetHandoff()

ResetHandoff resets all changes to the "handoff" field.

func (*AssignmentMutation) ResetLeaseExpiresAt

func (m *AssignmentMutation) ResetLeaseExpiresAt()

ResetLeaseExpiresAt resets all changes to the "lease_expires_at" field.

func (*AssignmentMutation) ResetRoadmapItem

func (m *AssignmentMutation) ResetRoadmapItem()

ResetRoadmapItem resets all changes to the "roadmap_item" edge.

func (*AssignmentMutation) ResetStatus

func (m *AssignmentMutation) ResetStatus()

ResetStatus resets all changes to the "status" field.

func (*AssignmentMutation) ResetUpdatedAt

func (m *AssignmentMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*AssignmentMutation) ResetWorker

func (m *AssignmentMutation) ResetWorker()

ResetWorker resets all changes to the "worker" field.

func (*AssignmentMutation) ResetWorkspace

func (m *AssignmentMutation) ResetWorkspace()

ResetWorkspace resets all changes to the "workspace" field.

func (*AssignmentMutation) RoadmapItemCleared

func (m *AssignmentMutation) RoadmapItemCleared() bool

RoadmapItemCleared reports if the "roadmap_item" edge to the RoadmapItem entity was cleared.

func (*AssignmentMutation) RoadmapItemID

func (m *AssignmentMutation) RoadmapItemID() (id string, exists bool)

RoadmapItemID returns the "roadmap_item" edge ID in the mutation.

func (*AssignmentMutation) RoadmapItemIDs

func (m *AssignmentMutation) RoadmapItemIDs() (ids []string)

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

func (*AssignmentMutation) SetCompletedAt

func (m *AssignmentMutation) SetCompletedAt(t time.Time)

SetCompletedAt sets the "completed_at" field.

func (*AssignmentMutation) SetCreatedAt

func (m *AssignmentMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*AssignmentMutation) SetField

func (m *AssignmentMutation) 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 (*AssignmentMutation) SetHandoff

func (m *AssignmentMutation) SetHandoff(value map[string]interface{})

SetHandoff sets the "handoff" field.

func (*AssignmentMutation) SetID

func (m *AssignmentMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of Assignment entities.

func (*AssignmentMutation) SetLeaseExpiresAt

func (m *AssignmentMutation) SetLeaseExpiresAt(t time.Time)

SetLeaseExpiresAt sets the "lease_expires_at" field.

func (*AssignmentMutation) SetOp

func (m *AssignmentMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*AssignmentMutation) SetRoadmapItemID

func (m *AssignmentMutation) SetRoadmapItemID(id string)

SetRoadmapItemID sets the "roadmap_item" edge to the RoadmapItem entity by id.

func (*AssignmentMutation) SetStatus

func (m *AssignmentMutation) SetStatus(s string)

SetStatus sets the "status" field.

func (*AssignmentMutation) SetUpdatedAt

func (m *AssignmentMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (*AssignmentMutation) SetWorker

func (m *AssignmentMutation) SetWorker(s string)

SetWorker sets the "worker" field.

func (*AssignmentMutation) SetWorkspace

func (m *AssignmentMutation) SetWorkspace(s string)

SetWorkspace sets the "workspace" field.

func (*AssignmentMutation) Status

func (m *AssignmentMutation) Status() (r string, exists bool)

Status returns the value of the "status" field in the mutation.

func (AssignmentMutation) Tx

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

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

func (*AssignmentMutation) Type

func (m *AssignmentMutation) Type() string

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

func (*AssignmentMutation) UpdatedAt

func (m *AssignmentMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*AssignmentMutation) Where

func (m *AssignmentMutation) Where(ps ...predicate.Assignment)

Where appends a list predicates to the AssignmentMutation builder.

func (*AssignmentMutation) WhereP

func (m *AssignmentMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the AssignmentMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

func (*AssignmentMutation) Worker

func (m *AssignmentMutation) Worker() (r string, exists bool)

Worker returns the value of the "worker" field in the mutation.

func (*AssignmentMutation) Workspace

func (m *AssignmentMutation) Workspace() (r string, exists bool)

Workspace returns the value of the "workspace" field in the mutation.

func (*AssignmentMutation) WorkspaceCleared

func (m *AssignmentMutation) WorkspaceCleared() bool

WorkspaceCleared returns if the "workspace" field was cleared in this mutation.

type AssignmentQuery

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

AssignmentQuery is the builder for querying Assignment entities.

func (*AssignmentQuery) Aggregate

func (_q *AssignmentQuery) Aggregate(fns ...AggregateFunc) *AssignmentSelect

Aggregate returns a AssignmentSelect configured with the given aggregations.

func (*AssignmentQuery) All

func (_q *AssignmentQuery) All(ctx context.Context) ([]*Assignment, error)

All executes the query and returns a list of Assignments.

func (*AssignmentQuery) AllX

func (_q *AssignmentQuery) AllX(ctx context.Context) []*Assignment

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

func (*AssignmentQuery) Clone

func (_q *AssignmentQuery) Clone() *AssignmentQuery

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

func (*AssignmentQuery) Count

func (_q *AssignmentQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*AssignmentQuery) CountX

func (_q *AssignmentQuery) CountX(ctx context.Context) int

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

func (*AssignmentQuery) Exist

func (_q *AssignmentQuery) Exist(ctx context.Context) (bool, error)

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

func (*AssignmentQuery) ExistX

func (_q *AssignmentQuery) ExistX(ctx context.Context) bool

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

func (*AssignmentQuery) First

func (_q *AssignmentQuery) First(ctx context.Context) (*Assignment, error)

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

func (*AssignmentQuery) FirstID

func (_q *AssignmentQuery) FirstID(ctx context.Context) (id string, err error)

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

func (*AssignmentQuery) FirstIDX

func (_q *AssignmentQuery) FirstIDX(ctx context.Context) string

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

func (*AssignmentQuery) FirstX

func (_q *AssignmentQuery) FirstX(ctx context.Context) *Assignment

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

func (*AssignmentQuery) GroupBy

func (_q *AssignmentQuery) GroupBy(field string, fields ...string) *AssignmentGroupBy

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 {
	Worker string `json:"worker,omitempty"`
	Count int `json:"count,omitempty"`
}

client.Assignment.Query().
	GroupBy(assignment.FieldWorker).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*AssignmentQuery) IDs

func (_q *AssignmentQuery) IDs(ctx context.Context) (ids []string, err error)

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

func (*AssignmentQuery) IDsX

func (_q *AssignmentQuery) IDsX(ctx context.Context) []string

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

func (*AssignmentQuery) Limit

func (_q *AssignmentQuery) Limit(limit int) *AssignmentQuery

Limit the number of records to be returned by this query.

func (*AssignmentQuery) Offset

func (_q *AssignmentQuery) Offset(offset int) *AssignmentQuery

Offset to start from.

func (*AssignmentQuery) Only

func (_q *AssignmentQuery) Only(ctx context.Context) (*Assignment, error)

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

func (*AssignmentQuery) OnlyID

func (_q *AssignmentQuery) OnlyID(ctx context.Context) (id string, err error)

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

func (*AssignmentQuery) OnlyIDX

func (_q *AssignmentQuery) OnlyIDX(ctx context.Context) string

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

func (*AssignmentQuery) OnlyX

func (_q *AssignmentQuery) OnlyX(ctx context.Context) *Assignment

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

func (*AssignmentQuery) Order

Order specifies how the records should be ordered.

func (*AssignmentQuery) QueryRoadmapItem

func (_q *AssignmentQuery) QueryRoadmapItem() *RoadmapItemQuery

QueryRoadmapItem chains the current query on the "roadmap_item" edge.

func (*AssignmentQuery) Select

func (_q *AssignmentQuery) Select(fields ...string) *AssignmentSelect

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 {
	Worker string `json:"worker,omitempty"`
}

client.Assignment.Query().
	Select(assignment.FieldWorker).
	Scan(ctx, &v)

func (*AssignmentQuery) Unique

func (_q *AssignmentQuery) Unique(unique bool) *AssignmentQuery

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 (*AssignmentQuery) Where

Where adds a new predicate for the AssignmentQuery builder.

func (*AssignmentQuery) WithRoadmapItem

func (_q *AssignmentQuery) WithRoadmapItem(opts ...func(*RoadmapItemQuery)) *AssignmentQuery

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

type AssignmentSelect

type AssignmentSelect struct {
	*AssignmentQuery
	// contains filtered or unexported fields
}

AssignmentSelect is the builder for selecting fields of Assignment entities.

func (*AssignmentSelect) Aggregate

func (_s *AssignmentSelect) Aggregate(fns ...AggregateFunc) *AssignmentSelect

Aggregate adds the given aggregation functions to the selector query.

func (*AssignmentSelect) Bool

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

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

func (*AssignmentSelect) BoolX

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

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

func (*AssignmentSelect) Bools

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

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

func (*AssignmentSelect) BoolsX

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

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

func (*AssignmentSelect) Float64

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

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

func (*AssignmentSelect) Float64X

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

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

func (*AssignmentSelect) Float64s

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

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

func (*AssignmentSelect) Float64sX

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

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

func (*AssignmentSelect) Int

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

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

func (*AssignmentSelect) IntX

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

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

func (*AssignmentSelect) Ints

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

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

func (*AssignmentSelect) IntsX

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

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

func (*AssignmentSelect) Scan

func (_s *AssignmentSelect) Scan(ctx context.Context, v any) error

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

func (*AssignmentSelect) ScanX

func (s *AssignmentSelect) ScanX(ctx context.Context, v any)

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

func (*AssignmentSelect) String

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

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

func (*AssignmentSelect) StringX

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

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

func (*AssignmentSelect) Strings

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

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

func (*AssignmentSelect) StringsX

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

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

type AssignmentUpdate

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

AssignmentUpdate is the builder for updating Assignment entities.

func (*AssignmentUpdate) ClearCompletedAt

func (_u *AssignmentUpdate) ClearCompletedAt() *AssignmentUpdate

ClearCompletedAt clears the value of the "completed_at" field.

func (*AssignmentUpdate) ClearHandoff

func (_u *AssignmentUpdate) ClearHandoff() *AssignmentUpdate

ClearHandoff clears the value of the "handoff" field.

func (*AssignmentUpdate) ClearRoadmapItem

func (_u *AssignmentUpdate) ClearRoadmapItem() *AssignmentUpdate

ClearRoadmapItem clears the "roadmap_item" edge to the RoadmapItem entity.

func (*AssignmentUpdate) ClearWorkspace

func (_u *AssignmentUpdate) ClearWorkspace() *AssignmentUpdate

ClearWorkspace clears the value of the "workspace" field.

func (*AssignmentUpdate) Exec

func (_u *AssignmentUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*AssignmentUpdate) ExecX

func (_u *AssignmentUpdate) ExecX(ctx context.Context)

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

func (*AssignmentUpdate) Mutation

func (_u *AssignmentUpdate) Mutation() *AssignmentMutation

Mutation returns the AssignmentMutation object of the builder.

func (*AssignmentUpdate) Save

func (_u *AssignmentUpdate) Save(ctx context.Context) (int, error)

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

func (*AssignmentUpdate) SaveX

func (_u *AssignmentUpdate) SaveX(ctx context.Context) int

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

func (*AssignmentUpdate) SetCompletedAt

func (_u *AssignmentUpdate) SetCompletedAt(v time.Time) *AssignmentUpdate

SetCompletedAt sets the "completed_at" field.

func (*AssignmentUpdate) SetCreatedAt

func (_u *AssignmentUpdate) SetCreatedAt(v time.Time) *AssignmentUpdate

SetCreatedAt sets the "created_at" field.

func (*AssignmentUpdate) SetHandoff

func (_u *AssignmentUpdate) SetHandoff(v map[string]interface{}) *AssignmentUpdate

SetHandoff sets the "handoff" field.

func (*AssignmentUpdate) SetLeaseExpiresAt

func (_u *AssignmentUpdate) SetLeaseExpiresAt(v time.Time) *AssignmentUpdate

SetLeaseExpiresAt sets the "lease_expires_at" field.

func (*AssignmentUpdate) SetNillableCompletedAt

func (_u *AssignmentUpdate) SetNillableCompletedAt(v *time.Time) *AssignmentUpdate

SetNillableCompletedAt sets the "completed_at" field if the given value is not nil.

func (*AssignmentUpdate) SetNillableCreatedAt

func (_u *AssignmentUpdate) SetNillableCreatedAt(v *time.Time) *AssignmentUpdate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*AssignmentUpdate) SetNillableLeaseExpiresAt

func (_u *AssignmentUpdate) SetNillableLeaseExpiresAt(v *time.Time) *AssignmentUpdate

SetNillableLeaseExpiresAt sets the "lease_expires_at" field if the given value is not nil.

func (*AssignmentUpdate) SetNillableStatus

func (_u *AssignmentUpdate) SetNillableStatus(v *string) *AssignmentUpdate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*AssignmentUpdate) SetNillableUpdatedAt

func (_u *AssignmentUpdate) SetNillableUpdatedAt(v *time.Time) *AssignmentUpdate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*AssignmentUpdate) SetNillableWorker

func (_u *AssignmentUpdate) SetNillableWorker(v *string) *AssignmentUpdate

SetNillableWorker sets the "worker" field if the given value is not nil.

func (*AssignmentUpdate) SetNillableWorkspace

func (_u *AssignmentUpdate) SetNillableWorkspace(v *string) *AssignmentUpdate

SetNillableWorkspace sets the "workspace" field if the given value is not nil.

func (*AssignmentUpdate) SetRoadmapItem

func (_u *AssignmentUpdate) SetRoadmapItem(v *RoadmapItem) *AssignmentUpdate

SetRoadmapItem sets the "roadmap_item" edge to the RoadmapItem entity.

func (*AssignmentUpdate) SetRoadmapItemID

func (_u *AssignmentUpdate) SetRoadmapItemID(id string) *AssignmentUpdate

SetRoadmapItemID sets the "roadmap_item" edge to the RoadmapItem entity by ID.

func (*AssignmentUpdate) SetStatus

func (_u *AssignmentUpdate) SetStatus(v string) *AssignmentUpdate

SetStatus sets the "status" field.

func (*AssignmentUpdate) SetUpdatedAt

func (_u *AssignmentUpdate) SetUpdatedAt(v time.Time) *AssignmentUpdate

SetUpdatedAt sets the "updated_at" field.

func (*AssignmentUpdate) SetWorker

func (_u *AssignmentUpdate) SetWorker(v string) *AssignmentUpdate

SetWorker sets the "worker" field.

func (*AssignmentUpdate) SetWorkspace

func (_u *AssignmentUpdate) SetWorkspace(v string) *AssignmentUpdate

SetWorkspace sets the "workspace" field.

func (*AssignmentUpdate) Where

Where appends a list predicates to the AssignmentUpdate builder.

type AssignmentUpdateOne

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

AssignmentUpdateOne is the builder for updating a single Assignment entity.

func (*AssignmentUpdateOne) ClearCompletedAt

func (_u *AssignmentUpdateOne) ClearCompletedAt() *AssignmentUpdateOne

ClearCompletedAt clears the value of the "completed_at" field.

func (*AssignmentUpdateOne) ClearHandoff

func (_u *AssignmentUpdateOne) ClearHandoff() *AssignmentUpdateOne

ClearHandoff clears the value of the "handoff" field.

func (*AssignmentUpdateOne) ClearRoadmapItem

func (_u *AssignmentUpdateOne) ClearRoadmapItem() *AssignmentUpdateOne

ClearRoadmapItem clears the "roadmap_item" edge to the RoadmapItem entity.

func (*AssignmentUpdateOne) ClearWorkspace

func (_u *AssignmentUpdateOne) ClearWorkspace() *AssignmentUpdateOne

ClearWorkspace clears the value of the "workspace" field.

func (*AssignmentUpdateOne) Exec

func (_u *AssignmentUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*AssignmentUpdateOne) ExecX

func (_u *AssignmentUpdateOne) ExecX(ctx context.Context)

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

func (*AssignmentUpdateOne) Mutation

func (_u *AssignmentUpdateOne) Mutation() *AssignmentMutation

Mutation returns the AssignmentMutation object of the builder.

func (*AssignmentUpdateOne) Save

Save executes the query and returns the updated Assignment entity.

func (*AssignmentUpdateOne) SaveX

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

func (*AssignmentUpdateOne) Select

func (_u *AssignmentUpdateOne) Select(field string, fields ...string) *AssignmentUpdateOne

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

func (*AssignmentUpdateOne) SetCompletedAt

func (_u *AssignmentUpdateOne) SetCompletedAt(v time.Time) *AssignmentUpdateOne

SetCompletedAt sets the "completed_at" field.

func (*AssignmentUpdateOne) SetCreatedAt

func (_u *AssignmentUpdateOne) SetCreatedAt(v time.Time) *AssignmentUpdateOne

SetCreatedAt sets the "created_at" field.

func (*AssignmentUpdateOne) SetHandoff

func (_u *AssignmentUpdateOne) SetHandoff(v map[string]interface{}) *AssignmentUpdateOne

SetHandoff sets the "handoff" field.

func (*AssignmentUpdateOne) SetLeaseExpiresAt

func (_u *AssignmentUpdateOne) SetLeaseExpiresAt(v time.Time) *AssignmentUpdateOne

SetLeaseExpiresAt sets the "lease_expires_at" field.

func (*AssignmentUpdateOne) SetNillableCompletedAt

func (_u *AssignmentUpdateOne) SetNillableCompletedAt(v *time.Time) *AssignmentUpdateOne

SetNillableCompletedAt sets the "completed_at" field if the given value is not nil.

func (*AssignmentUpdateOne) SetNillableCreatedAt

func (_u *AssignmentUpdateOne) SetNillableCreatedAt(v *time.Time) *AssignmentUpdateOne

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*AssignmentUpdateOne) SetNillableLeaseExpiresAt

func (_u *AssignmentUpdateOne) SetNillableLeaseExpiresAt(v *time.Time) *AssignmentUpdateOne

SetNillableLeaseExpiresAt sets the "lease_expires_at" field if the given value is not nil.

func (*AssignmentUpdateOne) SetNillableStatus

func (_u *AssignmentUpdateOne) SetNillableStatus(v *string) *AssignmentUpdateOne

SetNillableStatus sets the "status" field if the given value is not nil.

func (*AssignmentUpdateOne) SetNillableUpdatedAt

func (_u *AssignmentUpdateOne) SetNillableUpdatedAt(v *time.Time) *AssignmentUpdateOne

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*AssignmentUpdateOne) SetNillableWorker

func (_u *AssignmentUpdateOne) SetNillableWorker(v *string) *AssignmentUpdateOne

SetNillableWorker sets the "worker" field if the given value is not nil.

func (*AssignmentUpdateOne) SetNillableWorkspace

func (_u *AssignmentUpdateOne) SetNillableWorkspace(v *string) *AssignmentUpdateOne

SetNillableWorkspace sets the "workspace" field if the given value is not nil.

func (*AssignmentUpdateOne) SetRoadmapItem

func (_u *AssignmentUpdateOne) SetRoadmapItem(v *RoadmapItem) *AssignmentUpdateOne

SetRoadmapItem sets the "roadmap_item" edge to the RoadmapItem entity.

func (*AssignmentUpdateOne) SetRoadmapItemID

func (_u *AssignmentUpdateOne) SetRoadmapItemID(id string) *AssignmentUpdateOne

SetRoadmapItemID sets the "roadmap_item" edge to the RoadmapItem entity by ID.

func (*AssignmentUpdateOne) SetStatus

SetStatus sets the "status" field.

func (*AssignmentUpdateOne) SetUpdatedAt

func (_u *AssignmentUpdateOne) SetUpdatedAt(v time.Time) *AssignmentUpdateOne

SetUpdatedAt sets the "updated_at" field.

func (*AssignmentUpdateOne) SetWorker

SetWorker sets the "worker" field.

func (*AssignmentUpdateOne) SetWorkspace

func (_u *AssignmentUpdateOne) SetWorkspace(v string) *AssignmentUpdateOne

SetWorkspace sets the "workspace" field.

func (*AssignmentUpdateOne) Where

Where appends a list predicates to the AssignmentUpdate builder.

type Assignments

type Assignments []*Assignment

Assignments is a parsable slice of Assignment.

type CapabilityModel

type CapabilityModel struct {

	// ID of the ent.
	ID string `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"`
	// Dimensions holds the value of the "dimensions" field.
	Dimensions []schema.Dimension `json:"dimensions,omitempty"`
	// MaxLevel holds the value of the "max_level" field.
	MaxLevel int `json:"max_level,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the CapabilityModelQuery when eager-loading is set.
	Edges CapabilityModelEdges `json:"edges"`
	// contains filtered or unexported fields
}

CapabilityModel is the model entity for the CapabilityModel schema.

func (*CapabilityModel) QueryAssessments

func (_m *CapabilityModel) QueryAssessments() *MaturityAssessmentQuery

QueryAssessments queries the "assessments" edge of the CapabilityModel entity.

func (*CapabilityModel) String

func (_m *CapabilityModel) String() string

String implements the fmt.Stringer.

func (*CapabilityModel) Unwrap

func (_m *CapabilityModel) Unwrap() *CapabilityModel

Unwrap unwraps the CapabilityModel 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 (*CapabilityModel) Update

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

func (*CapabilityModel) Value

func (_m *CapabilityModel) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the CapabilityModel. This includes values selected through modifiers, order, etc.

type CapabilityModelClient

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

CapabilityModelClient is a client for the CapabilityModel schema.

func NewCapabilityModelClient

func NewCapabilityModelClient(c config) *CapabilityModelClient

NewCapabilityModelClient returns a client for the CapabilityModel from the given config.

func (*CapabilityModelClient) Create

Create returns a builder for creating a CapabilityModel entity.

func (*CapabilityModelClient) CreateBulk

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

func (*CapabilityModelClient) Delete

Delete returns a delete builder for CapabilityModel.

func (*CapabilityModelClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*CapabilityModelClient) DeleteOneID

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

func (*CapabilityModelClient) Get

Get returns a CapabilityModel entity by its id.

func (*CapabilityModelClient) GetX

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

func (*CapabilityModelClient) Hooks

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

Hooks returns the client hooks.

func (*CapabilityModelClient) Intercept

func (c *CapabilityModelClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `capabilitymodel.Intercept(f(g(h())))`.

func (*CapabilityModelClient) Interceptors

func (c *CapabilityModelClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*CapabilityModelClient) MapCreateBulk

func (c *CapabilityModelClient) MapCreateBulk(slice any, setFunc func(*CapabilityModelCreate, int)) *CapabilityModelCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*CapabilityModelClient) Query

Query returns a query builder for CapabilityModel.

func (*CapabilityModelClient) QueryAssessments

QueryAssessments queries the assessments edge of a CapabilityModel.

func (*CapabilityModelClient) Update

Update returns an update builder for CapabilityModel.

func (*CapabilityModelClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*CapabilityModelClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*CapabilityModelClient) Use

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

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

type CapabilityModelCreate

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

CapabilityModelCreate is the builder for creating a CapabilityModel entity.

func (*CapabilityModelCreate) AddAssessmentIDs

func (_c *CapabilityModelCreate) AddAssessmentIDs(ids ...string) *CapabilityModelCreate

AddAssessmentIDs adds the "assessments" edge to the MaturityAssessment entity by IDs.

func (*CapabilityModelCreate) AddAssessments

AddAssessments adds the "assessments" edges to the MaturityAssessment entity.

func (*CapabilityModelCreate) Exec

Exec executes the query.

func (*CapabilityModelCreate) ExecX

func (_c *CapabilityModelCreate) ExecX(ctx context.Context)

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

func (*CapabilityModelCreate) Mutation

Mutation returns the CapabilityModelMutation object of the builder.

func (*CapabilityModelCreate) Save

Save creates the CapabilityModel in the database.

func (*CapabilityModelCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*CapabilityModelCreate) SetDescription

func (_c *CapabilityModelCreate) SetDescription(v string) *CapabilityModelCreate

SetDescription sets the "description" field.

func (*CapabilityModelCreate) SetDimensions

SetDimensions sets the "dimensions" field.

func (*CapabilityModelCreate) SetID

SetID sets the "id" field.

func (*CapabilityModelCreate) SetMaxLevel

func (_c *CapabilityModelCreate) SetMaxLevel(v int) *CapabilityModelCreate

SetMaxLevel sets the "max_level" field.

func (*CapabilityModelCreate) SetName

SetName sets the "name" field.

func (*CapabilityModelCreate) SetNillableDescription

func (_c *CapabilityModelCreate) SetNillableDescription(v *string) *CapabilityModelCreate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*CapabilityModelCreate) SetNillableMaxLevel

func (_c *CapabilityModelCreate) SetNillableMaxLevel(v *int) *CapabilityModelCreate

SetNillableMaxLevel sets the "max_level" field if the given value is not nil.

type CapabilityModelCreateBulk

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

CapabilityModelCreateBulk is the builder for creating many CapabilityModel entities in bulk.

func (*CapabilityModelCreateBulk) Exec

Exec executes the query.

func (*CapabilityModelCreateBulk) ExecX

func (_c *CapabilityModelCreateBulk) ExecX(ctx context.Context)

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

func (*CapabilityModelCreateBulk) Save

Save creates the CapabilityModel entities in the database.

func (*CapabilityModelCreateBulk) SaveX

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

type CapabilityModelDelete

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

CapabilityModelDelete is the builder for deleting a CapabilityModel entity.

func (*CapabilityModelDelete) Exec

func (_d *CapabilityModelDelete) Exec(ctx context.Context) (int, error)

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

func (*CapabilityModelDelete) ExecX

func (_d *CapabilityModelDelete) ExecX(ctx context.Context) int

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

func (*CapabilityModelDelete) Where

Where appends a list predicates to the CapabilityModelDelete builder.

type CapabilityModelDeleteOne

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

CapabilityModelDeleteOne is the builder for deleting a single CapabilityModel entity.

func (*CapabilityModelDeleteOne) Exec

Exec executes the deletion query.

func (*CapabilityModelDeleteOne) ExecX

func (_d *CapabilityModelDeleteOne) ExecX(ctx context.Context)

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

func (*CapabilityModelDeleteOne) Where

Where appends a list predicates to the CapabilityModelDelete builder.

type CapabilityModelEdges

type CapabilityModelEdges struct {
	// Assessments holds the value of the assessments edge.
	Assessments []*MaturityAssessment `json:"assessments,omitempty"`
	// contains filtered or unexported fields
}

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

func (CapabilityModelEdges) AssessmentsOrErr

func (e CapabilityModelEdges) AssessmentsOrErr() ([]*MaturityAssessment, error)

AssessmentsOrErr returns the Assessments value or an error if the edge was not loaded in eager-loading.

type CapabilityModelGroupBy

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

CapabilityModelGroupBy is the group-by builder for CapabilityModel entities.

func (*CapabilityModelGroupBy) Aggregate

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

func (*CapabilityModelGroupBy) Bool

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

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

func (*CapabilityModelGroupBy) BoolX

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

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

func (*CapabilityModelGroupBy) Bools

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

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

func (*CapabilityModelGroupBy) BoolsX

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

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

func (*CapabilityModelGroupBy) Float64

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

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

func (*CapabilityModelGroupBy) Float64X

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

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

func (*CapabilityModelGroupBy) Float64s

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

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

func (*CapabilityModelGroupBy) Float64sX

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

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

func (*CapabilityModelGroupBy) Int

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

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

func (*CapabilityModelGroupBy) IntX

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

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

func (*CapabilityModelGroupBy) Ints

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

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

func (*CapabilityModelGroupBy) IntsX

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

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

func (*CapabilityModelGroupBy) Scan

func (_g *CapabilityModelGroupBy) Scan(ctx context.Context, v any) error

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

func (*CapabilityModelGroupBy) ScanX

func (s *CapabilityModelGroupBy) ScanX(ctx context.Context, v any)

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

func (*CapabilityModelGroupBy) String

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

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

func (*CapabilityModelGroupBy) StringX

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

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

func (*CapabilityModelGroupBy) Strings

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

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

func (*CapabilityModelGroupBy) StringsX

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

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

type CapabilityModelMutation

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

CapabilityModelMutation represents an operation that mutates the CapabilityModel nodes in the graph.

func (*CapabilityModelMutation) AddAssessmentIDs

func (m *CapabilityModelMutation) AddAssessmentIDs(ids ...string)

AddAssessmentIDs adds the "assessments" edge to the MaturityAssessment entity by ids.

func (*CapabilityModelMutation) AddField

func (m *CapabilityModelMutation) 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 (*CapabilityModelMutation) AddMaxLevel

func (m *CapabilityModelMutation) AddMaxLevel(i int)

AddMaxLevel adds i to the "max_level" field.

func (*CapabilityModelMutation) AddedEdges

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

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

func (*CapabilityModelMutation) AddedField

func (m *CapabilityModelMutation) 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 (*CapabilityModelMutation) AddedFields

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

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

func (*CapabilityModelMutation) AddedIDs

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

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

func (*CapabilityModelMutation) AddedMaxLevel

func (m *CapabilityModelMutation) AddedMaxLevel() (r int, exists bool)

AddedMaxLevel returns the value that was added to the "max_level" field in this mutation.

func (*CapabilityModelMutation) AppendDimensions

func (m *CapabilityModelMutation) AppendDimensions(s []schema.Dimension)

AppendDimensions adds s to the "dimensions" field.

func (*CapabilityModelMutation) AppendedDimensions

func (m *CapabilityModelMutation) AppendedDimensions() ([]schema.Dimension, bool)

AppendedDimensions returns the list of values that were appended to the "dimensions" field in this mutation.

func (*CapabilityModelMutation) AssessmentsCleared

func (m *CapabilityModelMutation) AssessmentsCleared() bool

AssessmentsCleared reports if the "assessments" edge to the MaturityAssessment entity was cleared.

func (*CapabilityModelMutation) AssessmentsIDs

func (m *CapabilityModelMutation) AssessmentsIDs() (ids []string)

AssessmentsIDs returns the "assessments" edge IDs in the mutation.

func (*CapabilityModelMutation) ClearAssessments

func (m *CapabilityModelMutation) ClearAssessments()

ClearAssessments clears the "assessments" edge to the MaturityAssessment entity.

func (*CapabilityModelMutation) ClearDescription

func (m *CapabilityModelMutation) ClearDescription()

ClearDescription clears the value of the "description" field.

func (*CapabilityModelMutation) ClearDimensions

func (m *CapabilityModelMutation) ClearDimensions()

ClearDimensions clears the value of the "dimensions" field.

func (*CapabilityModelMutation) ClearEdge

func (m *CapabilityModelMutation) 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 (*CapabilityModelMutation) ClearField

func (m *CapabilityModelMutation) 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 (*CapabilityModelMutation) ClearedEdges

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

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

func (*CapabilityModelMutation) ClearedFields

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

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

func (CapabilityModelMutation) Client

func (m CapabilityModelMutation) 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 (*CapabilityModelMutation) Description

func (m *CapabilityModelMutation) Description() (r string, exists bool)

Description returns the value of the "description" field in the mutation.

func (*CapabilityModelMutation) DescriptionCleared

func (m *CapabilityModelMutation) DescriptionCleared() bool

DescriptionCleared returns if the "description" field was cleared in this mutation.

func (*CapabilityModelMutation) Dimensions

func (m *CapabilityModelMutation) Dimensions() (r []schema.Dimension, exists bool)

Dimensions returns the value of the "dimensions" field in the mutation.

func (*CapabilityModelMutation) DimensionsCleared

func (m *CapabilityModelMutation) DimensionsCleared() bool

DimensionsCleared returns if the "dimensions" field was cleared in this mutation.

func (*CapabilityModelMutation) EdgeCleared

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

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

func (*CapabilityModelMutation) Field

func (m *CapabilityModelMutation) 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 (*CapabilityModelMutation) FieldCleared

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

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

func (*CapabilityModelMutation) Fields

func (m *CapabilityModelMutation) 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 (*CapabilityModelMutation) ID

func (m *CapabilityModelMutation) ID() (id string, 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 (*CapabilityModelMutation) 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 (*CapabilityModelMutation) MaxLevel

func (m *CapabilityModelMutation) MaxLevel() (r int, exists bool)

MaxLevel returns the value of the "max_level" field in the mutation.

func (*CapabilityModelMutation) Name

func (m *CapabilityModelMutation) Name() (r string, exists bool)

Name returns the value of the "name" field in the mutation.

func (*CapabilityModelMutation) OldDescription

func (m *CapabilityModelMutation) OldDescription(ctx context.Context) (v string, err error)

OldDescription returns the old "description" field's value of the CapabilityModel entity. If the CapabilityModel 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 (*CapabilityModelMutation) OldDimensions

func (m *CapabilityModelMutation) OldDimensions(ctx context.Context) (v []schema.Dimension, err error)

OldDimensions returns the old "dimensions" field's value of the CapabilityModel entity. If the CapabilityModel 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 (*CapabilityModelMutation) OldField

func (m *CapabilityModelMutation) 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 (*CapabilityModelMutation) OldMaxLevel

func (m *CapabilityModelMutation) OldMaxLevel(ctx context.Context) (v int, err error)

OldMaxLevel returns the old "max_level" field's value of the CapabilityModel entity. If the CapabilityModel 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 (*CapabilityModelMutation) OldName

func (m *CapabilityModelMutation) OldName(ctx context.Context) (v string, err error)

OldName returns the old "name" field's value of the CapabilityModel entity. If the CapabilityModel 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 (*CapabilityModelMutation) Op

func (m *CapabilityModelMutation) Op() Op

Op returns the operation name.

func (*CapabilityModelMutation) RemoveAssessmentIDs

func (m *CapabilityModelMutation) RemoveAssessmentIDs(ids ...string)

RemoveAssessmentIDs removes the "assessments" edge to the MaturityAssessment entity by IDs.

func (*CapabilityModelMutation) RemovedAssessmentsIDs

func (m *CapabilityModelMutation) RemovedAssessmentsIDs() (ids []string)

RemovedAssessments returns the removed IDs of the "assessments" edge to the MaturityAssessment entity.

func (*CapabilityModelMutation) RemovedEdges

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

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

func (*CapabilityModelMutation) RemovedIDs

func (m *CapabilityModelMutation) 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 (*CapabilityModelMutation) ResetAssessments

func (m *CapabilityModelMutation) ResetAssessments()

ResetAssessments resets all changes to the "assessments" edge.

func (*CapabilityModelMutation) ResetDescription

func (m *CapabilityModelMutation) ResetDescription()

ResetDescription resets all changes to the "description" field.

func (*CapabilityModelMutation) ResetDimensions

func (m *CapabilityModelMutation) ResetDimensions()

ResetDimensions resets all changes to the "dimensions" field.

func (*CapabilityModelMutation) ResetEdge

func (m *CapabilityModelMutation) 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 (*CapabilityModelMutation) ResetField

func (m *CapabilityModelMutation) 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 (*CapabilityModelMutation) ResetMaxLevel

func (m *CapabilityModelMutation) ResetMaxLevel()

ResetMaxLevel resets all changes to the "max_level" field.

func (*CapabilityModelMutation) ResetName

func (m *CapabilityModelMutation) ResetName()

ResetName resets all changes to the "name" field.

func (*CapabilityModelMutation) SetDescription

func (m *CapabilityModelMutation) SetDescription(s string)

SetDescription sets the "description" field.

func (*CapabilityModelMutation) SetDimensions

func (m *CapabilityModelMutation) SetDimensions(s []schema.Dimension)

SetDimensions sets the "dimensions" field.

func (*CapabilityModelMutation) SetField

func (m *CapabilityModelMutation) 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 (*CapabilityModelMutation) SetID

func (m *CapabilityModelMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of CapabilityModel entities.

func (*CapabilityModelMutation) SetMaxLevel

func (m *CapabilityModelMutation) SetMaxLevel(i int)

SetMaxLevel sets the "max_level" field.

func (*CapabilityModelMutation) SetName

func (m *CapabilityModelMutation) SetName(s string)

SetName sets the "name" field.

func (*CapabilityModelMutation) SetOp

func (m *CapabilityModelMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (CapabilityModelMutation) Tx

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

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

func (*CapabilityModelMutation) Type

func (m *CapabilityModelMutation) Type() string

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

func (*CapabilityModelMutation) Where

Where appends a list predicates to the CapabilityModelMutation builder.

func (*CapabilityModelMutation) WhereP

func (m *CapabilityModelMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the CapabilityModelMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type CapabilityModelQuery

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

CapabilityModelQuery is the builder for querying CapabilityModel entities.

func (*CapabilityModelQuery) Aggregate

Aggregate returns a CapabilityModelSelect configured with the given aggregations.

func (*CapabilityModelQuery) All

All executes the query and returns a list of CapabilityModels.

func (*CapabilityModelQuery) AllX

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

func (*CapabilityModelQuery) Clone

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

func (*CapabilityModelQuery) Count

func (_q *CapabilityModelQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*CapabilityModelQuery) CountX

func (_q *CapabilityModelQuery) CountX(ctx context.Context) int

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

func (*CapabilityModelQuery) Exist

func (_q *CapabilityModelQuery) Exist(ctx context.Context) (bool, error)

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

func (*CapabilityModelQuery) ExistX

func (_q *CapabilityModelQuery) ExistX(ctx context.Context) bool

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

func (*CapabilityModelQuery) First

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

func (*CapabilityModelQuery) FirstID

func (_q *CapabilityModelQuery) FirstID(ctx context.Context) (id string, err error)

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

func (*CapabilityModelQuery) FirstIDX

func (_q *CapabilityModelQuery) FirstIDX(ctx context.Context) string

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

func (*CapabilityModelQuery) FirstX

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

func (*CapabilityModelQuery) GroupBy

func (_q *CapabilityModelQuery) GroupBy(field string, fields ...string) *CapabilityModelGroupBy

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.CapabilityModel.Query().
	GroupBy(capabilitymodel.FieldName).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*CapabilityModelQuery) IDs

func (_q *CapabilityModelQuery) IDs(ctx context.Context) (ids []string, err error)

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

func (*CapabilityModelQuery) IDsX

func (_q *CapabilityModelQuery) IDsX(ctx context.Context) []string

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

func (*CapabilityModelQuery) Limit

func (_q *CapabilityModelQuery) Limit(limit int) *CapabilityModelQuery

Limit the number of records to be returned by this query.

func (*CapabilityModelQuery) Offset

func (_q *CapabilityModelQuery) Offset(offset int) *CapabilityModelQuery

Offset to start from.

func (*CapabilityModelQuery) Only

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

func (*CapabilityModelQuery) OnlyID

func (_q *CapabilityModelQuery) OnlyID(ctx context.Context) (id string, err error)

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

func (*CapabilityModelQuery) OnlyIDX

func (_q *CapabilityModelQuery) OnlyIDX(ctx context.Context) string

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

func (*CapabilityModelQuery) OnlyX

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

func (*CapabilityModelQuery) Order

Order specifies how the records should be ordered.

func (*CapabilityModelQuery) QueryAssessments

func (_q *CapabilityModelQuery) QueryAssessments() *MaturityAssessmentQuery

QueryAssessments chains the current query on the "assessments" edge.

func (*CapabilityModelQuery) Select

func (_q *CapabilityModelQuery) Select(fields ...string) *CapabilityModelSelect

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.CapabilityModel.Query().
	Select(capabilitymodel.FieldName).
	Scan(ctx, &v)

func (*CapabilityModelQuery) Unique

func (_q *CapabilityModelQuery) Unique(unique bool) *CapabilityModelQuery

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 (*CapabilityModelQuery) Where

Where adds a new predicate for the CapabilityModelQuery builder.

func (*CapabilityModelQuery) WithAssessments

func (_q *CapabilityModelQuery) WithAssessments(opts ...func(*MaturityAssessmentQuery)) *CapabilityModelQuery

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

type CapabilityModelSelect

type CapabilityModelSelect struct {
	*CapabilityModelQuery
	// contains filtered or unexported fields
}

CapabilityModelSelect is the builder for selecting fields of CapabilityModel entities.

func (*CapabilityModelSelect) Aggregate

Aggregate adds the given aggregation functions to the selector query.

func (*CapabilityModelSelect) Bool

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

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

func (*CapabilityModelSelect) BoolX

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

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

func (*CapabilityModelSelect) Bools

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

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

func (*CapabilityModelSelect) BoolsX

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

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

func (*CapabilityModelSelect) Float64

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

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

func (*CapabilityModelSelect) Float64X

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

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

func (*CapabilityModelSelect) Float64s

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

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

func (*CapabilityModelSelect) Float64sX

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

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

func (*CapabilityModelSelect) Int

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

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

func (*CapabilityModelSelect) IntX

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

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

func (*CapabilityModelSelect) Ints

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

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

func (*CapabilityModelSelect) IntsX

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

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

func (*CapabilityModelSelect) Scan

func (_s *CapabilityModelSelect) Scan(ctx context.Context, v any) error

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

func (*CapabilityModelSelect) ScanX

func (s *CapabilityModelSelect) ScanX(ctx context.Context, v any)

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

func (*CapabilityModelSelect) String

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

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

func (*CapabilityModelSelect) StringX

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

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

func (*CapabilityModelSelect) Strings

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

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

func (*CapabilityModelSelect) StringsX

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

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

type CapabilityModelUpdate

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

CapabilityModelUpdate is the builder for updating CapabilityModel entities.

func (*CapabilityModelUpdate) AddAssessmentIDs

func (_u *CapabilityModelUpdate) AddAssessmentIDs(ids ...string) *CapabilityModelUpdate

AddAssessmentIDs adds the "assessments" edge to the MaturityAssessment entity by IDs.

func (*CapabilityModelUpdate) AddAssessments

AddAssessments adds the "assessments" edges to the MaturityAssessment entity.

func (*CapabilityModelUpdate) AddMaxLevel

func (_u *CapabilityModelUpdate) AddMaxLevel(v int) *CapabilityModelUpdate

AddMaxLevel adds value to the "max_level" field.

func (*CapabilityModelUpdate) AppendDimensions

func (_u *CapabilityModelUpdate) AppendDimensions(v []schema.Dimension) *CapabilityModelUpdate

AppendDimensions appends value to the "dimensions" field.

func (*CapabilityModelUpdate) ClearAssessments

func (_u *CapabilityModelUpdate) ClearAssessments() *CapabilityModelUpdate

ClearAssessments clears all "assessments" edges to the MaturityAssessment entity.

func (*CapabilityModelUpdate) ClearDescription

func (_u *CapabilityModelUpdate) ClearDescription() *CapabilityModelUpdate

ClearDescription clears the value of the "description" field.

func (*CapabilityModelUpdate) ClearDimensions

func (_u *CapabilityModelUpdate) ClearDimensions() *CapabilityModelUpdate

ClearDimensions clears the value of the "dimensions" field.

func (*CapabilityModelUpdate) Exec

Exec executes the query.

func (*CapabilityModelUpdate) ExecX

func (_u *CapabilityModelUpdate) ExecX(ctx context.Context)

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

func (*CapabilityModelUpdate) Mutation

Mutation returns the CapabilityModelMutation object of the builder.

func (*CapabilityModelUpdate) RemoveAssessmentIDs

func (_u *CapabilityModelUpdate) RemoveAssessmentIDs(ids ...string) *CapabilityModelUpdate

RemoveAssessmentIDs removes the "assessments" edge to MaturityAssessment entities by IDs.

func (*CapabilityModelUpdate) RemoveAssessments

func (_u *CapabilityModelUpdate) RemoveAssessments(v ...*MaturityAssessment) *CapabilityModelUpdate

RemoveAssessments removes "assessments" edges to MaturityAssessment entities.

func (*CapabilityModelUpdate) Save

func (_u *CapabilityModelUpdate) Save(ctx context.Context) (int, error)

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

func (*CapabilityModelUpdate) SaveX

func (_u *CapabilityModelUpdate) SaveX(ctx context.Context) int

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

func (*CapabilityModelUpdate) SetDescription

func (_u *CapabilityModelUpdate) SetDescription(v string) *CapabilityModelUpdate

SetDescription sets the "description" field.

func (*CapabilityModelUpdate) SetDimensions

SetDimensions sets the "dimensions" field.

func (*CapabilityModelUpdate) SetMaxLevel

func (_u *CapabilityModelUpdate) SetMaxLevel(v int) *CapabilityModelUpdate

SetMaxLevel sets the "max_level" field.

func (*CapabilityModelUpdate) SetName

SetName sets the "name" field.

func (*CapabilityModelUpdate) SetNillableDescription

func (_u *CapabilityModelUpdate) SetNillableDescription(v *string) *CapabilityModelUpdate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*CapabilityModelUpdate) SetNillableMaxLevel

func (_u *CapabilityModelUpdate) SetNillableMaxLevel(v *int) *CapabilityModelUpdate

SetNillableMaxLevel sets the "max_level" field if the given value is not nil.

func (*CapabilityModelUpdate) SetNillableName

func (_u *CapabilityModelUpdate) SetNillableName(v *string) *CapabilityModelUpdate

SetNillableName sets the "name" field if the given value is not nil.

func (*CapabilityModelUpdate) Where

Where appends a list predicates to the CapabilityModelUpdate builder.

type CapabilityModelUpdateOne

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

CapabilityModelUpdateOne is the builder for updating a single CapabilityModel entity.

func (*CapabilityModelUpdateOne) AddAssessmentIDs

func (_u *CapabilityModelUpdateOne) AddAssessmentIDs(ids ...string) *CapabilityModelUpdateOne

AddAssessmentIDs adds the "assessments" edge to the MaturityAssessment entity by IDs.

func (*CapabilityModelUpdateOne) AddAssessments

AddAssessments adds the "assessments" edges to the MaturityAssessment entity.

func (*CapabilityModelUpdateOne) AddMaxLevel

AddMaxLevel adds value to the "max_level" field.

func (*CapabilityModelUpdateOne) AppendDimensions

AppendDimensions appends value to the "dimensions" field.

func (*CapabilityModelUpdateOne) ClearAssessments

func (_u *CapabilityModelUpdateOne) ClearAssessments() *CapabilityModelUpdateOne

ClearAssessments clears all "assessments" edges to the MaturityAssessment entity.

func (*CapabilityModelUpdateOne) ClearDescription

func (_u *CapabilityModelUpdateOne) ClearDescription() *CapabilityModelUpdateOne

ClearDescription clears the value of the "description" field.

func (*CapabilityModelUpdateOne) ClearDimensions

func (_u *CapabilityModelUpdateOne) ClearDimensions() *CapabilityModelUpdateOne

ClearDimensions clears the value of the "dimensions" field.

func (*CapabilityModelUpdateOne) Exec

Exec executes the query on the entity.

func (*CapabilityModelUpdateOne) ExecX

func (_u *CapabilityModelUpdateOne) ExecX(ctx context.Context)

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

func (*CapabilityModelUpdateOne) Mutation

Mutation returns the CapabilityModelMutation object of the builder.

func (*CapabilityModelUpdateOne) RemoveAssessmentIDs

func (_u *CapabilityModelUpdateOne) RemoveAssessmentIDs(ids ...string) *CapabilityModelUpdateOne

RemoveAssessmentIDs removes the "assessments" edge to MaturityAssessment entities by IDs.

func (*CapabilityModelUpdateOne) RemoveAssessments

RemoveAssessments removes "assessments" edges to MaturityAssessment entities.

func (*CapabilityModelUpdateOne) Save

Save executes the query and returns the updated CapabilityModel entity.

func (*CapabilityModelUpdateOne) SaveX

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

func (*CapabilityModelUpdateOne) Select

func (_u *CapabilityModelUpdateOne) Select(field string, fields ...string) *CapabilityModelUpdateOne

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

func (*CapabilityModelUpdateOne) SetDescription

SetDescription sets the "description" field.

func (*CapabilityModelUpdateOne) SetDimensions

SetDimensions sets the "dimensions" field.

func (*CapabilityModelUpdateOne) SetMaxLevel

SetMaxLevel sets the "max_level" field.

func (*CapabilityModelUpdateOne) SetName

SetName sets the "name" field.

func (*CapabilityModelUpdateOne) SetNillableDescription

func (_u *CapabilityModelUpdateOne) SetNillableDescription(v *string) *CapabilityModelUpdateOne

SetNillableDescription sets the "description" field if the given value is not nil.

func (*CapabilityModelUpdateOne) SetNillableMaxLevel

func (_u *CapabilityModelUpdateOne) SetNillableMaxLevel(v *int) *CapabilityModelUpdateOne

SetNillableMaxLevel sets the "max_level" field if the given value is not nil.

func (*CapabilityModelUpdateOne) SetNillableName

func (_u *CapabilityModelUpdateOne) SetNillableName(v *string) *CapabilityModelUpdateOne

SetNillableName sets the "name" field if the given value is not nil.

func (*CapabilityModelUpdateOne) Where

Where appends a list predicates to the CapabilityModelUpdate builder.

type CapabilityModels

type CapabilityModels []*CapabilityModel

CapabilityModels is a parsable slice of CapabilityModel.

type Client

type Client struct {

	// Schema is the client for creating, migrating and dropping schema.
	Schema *migrate.Schema
	// Assignment is the client for interacting with the Assignment builders.
	Assignment *AssignmentClient
	// CapabilityModel is the client for interacting with the CapabilityModel builders.
	CapabilityModel *CapabilityModelClient
	// DeliveryEvidence is the client for interacting with the DeliveryEvidence builders.
	DeliveryEvidence *DeliveryEvidenceClient
	// Initiative is the client for interacting with the Initiative builders.
	Initiative *InitiativeClient
	// InitiativeDependency is the client for interacting with the InitiativeDependency builders.
	InitiativeDependency *InitiativeDependencyClient
	// JudgeResult is the client for interacting with the JudgeResult builders.
	JudgeResult *JudgeResultClient
	// JudgeRubric is the client for interacting with the JudgeRubric builders.
	JudgeRubric *JudgeRubricClient
	// MaturityAssessment is the client for interacting with the MaturityAssessment builders.
	MaturityAssessment *MaturityAssessmentClient
	// Phase is the client for interacting with the Phase builders.
	Phase *PhaseClient
	// Program is the client for interacting with the Program builders.
	Program *ProgramClient
	// RMIDependency is the client for interacting with the RMIDependency builders.
	RMIDependency *RMIDependencyClient
	// Repository is the client for interacting with the Repository builders.
	Repository *RepositoryClient
	// RepositoryDependency is the client for interacting with the RepositoryDependency builders.
	RepositoryDependency *RepositoryDependencyClient
	// RoadmapItem is the client for interacting with the RoadmapItem builders.
	RoadmapItem *RoadmapItemClient
	// SpecWorkflow is the client for interacting with the SpecWorkflow builders.
	SpecWorkflow *SpecWorkflowClient
	// 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().
	Assignment.
	Query().
	Count(ctx)

func (*Client) Intercept

func (c *Client) Intercept(interceptors ...Interceptor)

Intercept adds the query interceptors to all the entity clients. In order to add interceptors to a specific client, call: `client.Node.Intercept(...)`.

func (*Client) Mutate

func (c *Client) Mutate(ctx context.Context, m Mutation) (Value, error)

Mutate implements the ent.Mutator interface.

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 DeliveryEvidence

type DeliveryEvidence struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// EvidenceType holds the value of the "evidence_type" field.
	EvidenceType string `json:"evidence_type,omitempty"`
	// Reference holds the value of the "reference" field.
	Reference string `json:"reference,omitempty"`
	// CommitType holds the value of the "commit_type" field.
	CommitType string `json:"commit_type,omitempty"`
	// CommitScope holds the value of the "commit_scope" field.
	CommitScope string `json:"commit_scope,omitempty"`
	// OccurredAt holds the value of the "occurred_at" field.
	OccurredAt *time.Time `json:"occurred_at,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the DeliveryEvidenceQuery when eager-loading is set.
	Edges DeliveryEvidenceEdges `json:"edges"`
	// contains filtered or unexported fields
}

DeliveryEvidence is the model entity for the DeliveryEvidence schema.

func (*DeliveryEvidence) QueryRoadmapItem

func (_m *DeliveryEvidence) QueryRoadmapItem() *RoadmapItemQuery

QueryRoadmapItem queries the "roadmap_item" edge of the DeliveryEvidence entity.

func (*DeliveryEvidence) String

func (_m *DeliveryEvidence) String() string

String implements the fmt.Stringer.

func (*DeliveryEvidence) Unwrap

func (_m *DeliveryEvidence) Unwrap() *DeliveryEvidence

Unwrap unwraps the DeliveryEvidence 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 (*DeliveryEvidence) Update

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

func (*DeliveryEvidence) Value

func (_m *DeliveryEvidence) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the DeliveryEvidence. This includes values selected through modifiers, order, etc.

type DeliveryEvidenceClient

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

DeliveryEvidenceClient is a client for the DeliveryEvidence schema.

func NewDeliveryEvidenceClient

func NewDeliveryEvidenceClient(c config) *DeliveryEvidenceClient

NewDeliveryEvidenceClient returns a client for the DeliveryEvidence from the given config.

func (*DeliveryEvidenceClient) Create

Create returns a builder for creating a DeliveryEvidence entity.

func (*DeliveryEvidenceClient) CreateBulk

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

func (*DeliveryEvidenceClient) Delete

Delete returns a delete builder for DeliveryEvidence.

func (*DeliveryEvidenceClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*DeliveryEvidenceClient) DeleteOneID

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

func (*DeliveryEvidenceClient) Get

Get returns a DeliveryEvidence entity by its id.

func (*DeliveryEvidenceClient) GetX

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

func (*DeliveryEvidenceClient) Hooks

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

Hooks returns the client hooks.

func (*DeliveryEvidenceClient) Intercept

func (c *DeliveryEvidenceClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `deliveryevidence.Intercept(f(g(h())))`.

func (*DeliveryEvidenceClient) Interceptors

func (c *DeliveryEvidenceClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*DeliveryEvidenceClient) MapCreateBulk

func (c *DeliveryEvidenceClient) MapCreateBulk(slice any, setFunc func(*DeliveryEvidenceCreate, int)) *DeliveryEvidenceCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*DeliveryEvidenceClient) Query

Query returns a query builder for DeliveryEvidence.

func (*DeliveryEvidenceClient) QueryRoadmapItem

func (c *DeliveryEvidenceClient) QueryRoadmapItem(_m *DeliveryEvidence) *RoadmapItemQuery

QueryRoadmapItem queries the roadmap_item edge of a DeliveryEvidence.

func (*DeliveryEvidenceClient) Update

Update returns an update builder for DeliveryEvidence.

func (*DeliveryEvidenceClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*DeliveryEvidenceClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*DeliveryEvidenceClient) Use

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

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

type DeliveryEvidenceCreate

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

DeliveryEvidenceCreate is the builder for creating a DeliveryEvidence entity.

func (*DeliveryEvidenceCreate) Exec

Exec executes the query.

func (*DeliveryEvidenceCreate) ExecX

func (_c *DeliveryEvidenceCreate) ExecX(ctx context.Context)

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

func (*DeliveryEvidenceCreate) Mutation

Mutation returns the DeliveryEvidenceMutation object of the builder.

func (*DeliveryEvidenceCreate) Save

Save creates the DeliveryEvidence in the database.

func (*DeliveryEvidenceCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*DeliveryEvidenceCreate) SetCommitScope

func (_c *DeliveryEvidenceCreate) SetCommitScope(v string) *DeliveryEvidenceCreate

SetCommitScope sets the "commit_scope" field.

func (*DeliveryEvidenceCreate) SetCommitType

SetCommitType sets the "commit_type" field.

func (*DeliveryEvidenceCreate) SetCreatedAt

SetCreatedAt sets the "created_at" field.

func (*DeliveryEvidenceCreate) SetEvidenceType

func (_c *DeliveryEvidenceCreate) SetEvidenceType(v string) *DeliveryEvidenceCreate

SetEvidenceType sets the "evidence_type" field.

func (*DeliveryEvidenceCreate) SetID

SetID sets the "id" field.

func (*DeliveryEvidenceCreate) SetNillableCommitScope

func (_c *DeliveryEvidenceCreate) SetNillableCommitScope(v *string) *DeliveryEvidenceCreate

SetNillableCommitScope sets the "commit_scope" field if the given value is not nil.

func (*DeliveryEvidenceCreate) SetNillableCommitType

func (_c *DeliveryEvidenceCreate) SetNillableCommitType(v *string) *DeliveryEvidenceCreate

SetNillableCommitType sets the "commit_type" field if the given value is not nil.

func (*DeliveryEvidenceCreate) SetNillableOccurredAt

func (_c *DeliveryEvidenceCreate) SetNillableOccurredAt(v *time.Time) *DeliveryEvidenceCreate

SetNillableOccurredAt sets the "occurred_at" field if the given value is not nil.

func (*DeliveryEvidenceCreate) SetOccurredAt

SetOccurredAt sets the "occurred_at" field.

func (*DeliveryEvidenceCreate) SetReference

SetReference sets the "reference" field.

func (*DeliveryEvidenceCreate) SetRoadmapItem

SetRoadmapItem sets the "roadmap_item" edge to the RoadmapItem entity.

func (*DeliveryEvidenceCreate) SetRoadmapItemID

func (_c *DeliveryEvidenceCreate) SetRoadmapItemID(id string) *DeliveryEvidenceCreate

SetRoadmapItemID sets the "roadmap_item" edge to the RoadmapItem entity by ID.

type DeliveryEvidenceCreateBulk

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

DeliveryEvidenceCreateBulk is the builder for creating many DeliveryEvidence entities in bulk.

func (*DeliveryEvidenceCreateBulk) Exec

Exec executes the query.

func (*DeliveryEvidenceCreateBulk) ExecX

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

func (*DeliveryEvidenceCreateBulk) Save

Save creates the DeliveryEvidence entities in the database.

func (*DeliveryEvidenceCreateBulk) SaveX

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

type DeliveryEvidenceDelete

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

DeliveryEvidenceDelete is the builder for deleting a DeliveryEvidence entity.

func (*DeliveryEvidenceDelete) Exec

func (_d *DeliveryEvidenceDelete) Exec(ctx context.Context) (int, error)

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

func (*DeliveryEvidenceDelete) ExecX

func (_d *DeliveryEvidenceDelete) ExecX(ctx context.Context) int

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

func (*DeliveryEvidenceDelete) Where

Where appends a list predicates to the DeliveryEvidenceDelete builder.

type DeliveryEvidenceDeleteOne

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

DeliveryEvidenceDeleteOne is the builder for deleting a single DeliveryEvidence entity.

func (*DeliveryEvidenceDeleteOne) Exec

Exec executes the deletion query.

func (*DeliveryEvidenceDeleteOne) ExecX

func (_d *DeliveryEvidenceDeleteOne) ExecX(ctx context.Context)

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

func (*DeliveryEvidenceDeleteOne) Where

Where appends a list predicates to the DeliveryEvidenceDelete builder.

type DeliveryEvidenceEdges

type DeliveryEvidenceEdges struct {
	// RoadmapItem holds the value of the roadmap_item edge.
	RoadmapItem *RoadmapItem `json:"roadmap_item,omitempty"`
	// contains filtered or unexported fields
}

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

func (DeliveryEvidenceEdges) RoadmapItemOrErr

func (e DeliveryEvidenceEdges) RoadmapItemOrErr() (*RoadmapItem, error)

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

type DeliveryEvidenceGroupBy

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

DeliveryEvidenceGroupBy is the group-by builder for DeliveryEvidence entities.

func (*DeliveryEvidenceGroupBy) Aggregate

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

func (*DeliveryEvidenceGroupBy) Bool

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

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

func (*DeliveryEvidenceGroupBy) BoolX

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

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

func (*DeliveryEvidenceGroupBy) Bools

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

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

func (*DeliveryEvidenceGroupBy) BoolsX

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

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

func (*DeliveryEvidenceGroupBy) Float64

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

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

func (*DeliveryEvidenceGroupBy) Float64X

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

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

func (*DeliveryEvidenceGroupBy) Float64s

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

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

func (*DeliveryEvidenceGroupBy) Float64sX

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

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

func (*DeliveryEvidenceGroupBy) Int

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

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

func (*DeliveryEvidenceGroupBy) IntX

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

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

func (*DeliveryEvidenceGroupBy) Ints

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

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

func (*DeliveryEvidenceGroupBy) IntsX

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

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

func (*DeliveryEvidenceGroupBy) Scan

func (_g *DeliveryEvidenceGroupBy) Scan(ctx context.Context, v any) error

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

func (*DeliveryEvidenceGroupBy) ScanX

func (s *DeliveryEvidenceGroupBy) ScanX(ctx context.Context, v any)

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

func (*DeliveryEvidenceGroupBy) String

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

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

func (*DeliveryEvidenceGroupBy) StringX

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

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

func (*DeliveryEvidenceGroupBy) Strings

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

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

func (*DeliveryEvidenceGroupBy) StringsX

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

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

type DeliveryEvidenceMutation

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

DeliveryEvidenceMutation represents an operation that mutates the DeliveryEvidence nodes in the graph.

func (*DeliveryEvidenceMutation) AddField

func (m *DeliveryEvidenceMutation) 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 (*DeliveryEvidenceMutation) AddedEdges

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

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

func (*DeliveryEvidenceMutation) AddedField

func (m *DeliveryEvidenceMutation) 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 (*DeliveryEvidenceMutation) AddedFields

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

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

func (*DeliveryEvidenceMutation) AddedIDs

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

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

func (*DeliveryEvidenceMutation) ClearCommitScope

func (m *DeliveryEvidenceMutation) ClearCommitScope()

ClearCommitScope clears the value of the "commit_scope" field.

func (*DeliveryEvidenceMutation) ClearCommitType

func (m *DeliveryEvidenceMutation) ClearCommitType()

ClearCommitType clears the value of the "commit_type" field.

func (*DeliveryEvidenceMutation) ClearEdge

func (m *DeliveryEvidenceMutation) 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 (*DeliveryEvidenceMutation) ClearField

func (m *DeliveryEvidenceMutation) 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 (*DeliveryEvidenceMutation) ClearOccurredAt

func (m *DeliveryEvidenceMutation) ClearOccurredAt()

ClearOccurredAt clears the value of the "occurred_at" field.

func (*DeliveryEvidenceMutation) ClearRoadmapItem

func (m *DeliveryEvidenceMutation) ClearRoadmapItem()

ClearRoadmapItem clears the "roadmap_item" edge to the RoadmapItem entity.

func (*DeliveryEvidenceMutation) ClearedEdges

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

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

func (*DeliveryEvidenceMutation) ClearedFields

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

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

func (DeliveryEvidenceMutation) Client

func (m DeliveryEvidenceMutation) 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 (*DeliveryEvidenceMutation) CommitScope

func (m *DeliveryEvidenceMutation) CommitScope() (r string, exists bool)

CommitScope returns the value of the "commit_scope" field in the mutation.

func (*DeliveryEvidenceMutation) CommitScopeCleared

func (m *DeliveryEvidenceMutation) CommitScopeCleared() bool

CommitScopeCleared returns if the "commit_scope" field was cleared in this mutation.

func (*DeliveryEvidenceMutation) CommitType

func (m *DeliveryEvidenceMutation) CommitType() (r string, exists bool)

CommitType returns the value of the "commit_type" field in the mutation.

func (*DeliveryEvidenceMutation) CommitTypeCleared

func (m *DeliveryEvidenceMutation) CommitTypeCleared() bool

CommitTypeCleared returns if the "commit_type" field was cleared in this mutation.

func (*DeliveryEvidenceMutation) CreatedAt

func (m *DeliveryEvidenceMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*DeliveryEvidenceMutation) EdgeCleared

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

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

func (*DeliveryEvidenceMutation) EvidenceType

func (m *DeliveryEvidenceMutation) EvidenceType() (r string, exists bool)

EvidenceType returns the value of the "evidence_type" field in the mutation.

func (*DeliveryEvidenceMutation) Field

func (m *DeliveryEvidenceMutation) 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 (*DeliveryEvidenceMutation) FieldCleared

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

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

func (*DeliveryEvidenceMutation) Fields

func (m *DeliveryEvidenceMutation) 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 (*DeliveryEvidenceMutation) ID

func (m *DeliveryEvidenceMutation) ID() (id string, 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 (*DeliveryEvidenceMutation) 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 (*DeliveryEvidenceMutation) OccurredAt

func (m *DeliveryEvidenceMutation) OccurredAt() (r time.Time, exists bool)

OccurredAt returns the value of the "occurred_at" field in the mutation.

func (*DeliveryEvidenceMutation) OccurredAtCleared

func (m *DeliveryEvidenceMutation) OccurredAtCleared() bool

OccurredAtCleared returns if the "occurred_at" field was cleared in this mutation.

func (*DeliveryEvidenceMutation) OldCommitScope

func (m *DeliveryEvidenceMutation) OldCommitScope(ctx context.Context) (v string, err error)

OldCommitScope returns the old "commit_scope" field's value of the DeliveryEvidence entity. If the DeliveryEvidence 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 (*DeliveryEvidenceMutation) OldCommitType

func (m *DeliveryEvidenceMutation) OldCommitType(ctx context.Context) (v string, err error)

OldCommitType returns the old "commit_type" field's value of the DeliveryEvidence entity. If the DeliveryEvidence 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 (*DeliveryEvidenceMutation) OldCreatedAt

func (m *DeliveryEvidenceMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the DeliveryEvidence entity. If the DeliveryEvidence 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 (*DeliveryEvidenceMutation) OldEvidenceType

func (m *DeliveryEvidenceMutation) OldEvidenceType(ctx context.Context) (v string, err error)

OldEvidenceType returns the old "evidence_type" field's value of the DeliveryEvidence entity. If the DeliveryEvidence 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 (*DeliveryEvidenceMutation) OldField

func (m *DeliveryEvidenceMutation) 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 (*DeliveryEvidenceMutation) OldOccurredAt

func (m *DeliveryEvidenceMutation) OldOccurredAt(ctx context.Context) (v *time.Time, err error)

OldOccurredAt returns the old "occurred_at" field's value of the DeliveryEvidence entity. If the DeliveryEvidence 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 (*DeliveryEvidenceMutation) OldReference

func (m *DeliveryEvidenceMutation) OldReference(ctx context.Context) (v string, err error)

OldReference returns the old "reference" field's value of the DeliveryEvidence entity. If the DeliveryEvidence 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 (*DeliveryEvidenceMutation) Op

func (m *DeliveryEvidenceMutation) Op() Op

Op returns the operation name.

func (*DeliveryEvidenceMutation) Reference

func (m *DeliveryEvidenceMutation) Reference() (r string, exists bool)

Reference returns the value of the "reference" field in the mutation.

func (*DeliveryEvidenceMutation) RemovedEdges

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

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

func (*DeliveryEvidenceMutation) RemovedIDs

func (m *DeliveryEvidenceMutation) 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 (*DeliveryEvidenceMutation) ResetCommitScope

func (m *DeliveryEvidenceMutation) ResetCommitScope()

ResetCommitScope resets all changes to the "commit_scope" field.

func (*DeliveryEvidenceMutation) ResetCommitType

func (m *DeliveryEvidenceMutation) ResetCommitType()

ResetCommitType resets all changes to the "commit_type" field.

func (*DeliveryEvidenceMutation) ResetCreatedAt

func (m *DeliveryEvidenceMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*DeliveryEvidenceMutation) ResetEdge

func (m *DeliveryEvidenceMutation) 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 (*DeliveryEvidenceMutation) ResetEvidenceType

func (m *DeliveryEvidenceMutation) ResetEvidenceType()

ResetEvidenceType resets all changes to the "evidence_type" field.

func (*DeliveryEvidenceMutation) ResetField

func (m *DeliveryEvidenceMutation) 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 (*DeliveryEvidenceMutation) ResetOccurredAt

func (m *DeliveryEvidenceMutation) ResetOccurredAt()

ResetOccurredAt resets all changes to the "occurred_at" field.

func (*DeliveryEvidenceMutation) ResetReference

func (m *DeliveryEvidenceMutation) ResetReference()

ResetReference resets all changes to the "reference" field.

func (*DeliveryEvidenceMutation) ResetRoadmapItem

func (m *DeliveryEvidenceMutation) ResetRoadmapItem()

ResetRoadmapItem resets all changes to the "roadmap_item" edge.

func (*DeliveryEvidenceMutation) RoadmapItemCleared

func (m *DeliveryEvidenceMutation) RoadmapItemCleared() bool

RoadmapItemCleared reports if the "roadmap_item" edge to the RoadmapItem entity was cleared.

func (*DeliveryEvidenceMutation) RoadmapItemID

func (m *DeliveryEvidenceMutation) RoadmapItemID() (id string, exists bool)

RoadmapItemID returns the "roadmap_item" edge ID in the mutation.

func (*DeliveryEvidenceMutation) RoadmapItemIDs

func (m *DeliveryEvidenceMutation) RoadmapItemIDs() (ids []string)

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

func (*DeliveryEvidenceMutation) SetCommitScope

func (m *DeliveryEvidenceMutation) SetCommitScope(s string)

SetCommitScope sets the "commit_scope" field.

func (*DeliveryEvidenceMutation) SetCommitType

func (m *DeliveryEvidenceMutation) SetCommitType(s string)

SetCommitType sets the "commit_type" field.

func (*DeliveryEvidenceMutation) SetCreatedAt

func (m *DeliveryEvidenceMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*DeliveryEvidenceMutation) SetEvidenceType

func (m *DeliveryEvidenceMutation) SetEvidenceType(s string)

SetEvidenceType sets the "evidence_type" field.

func (*DeliveryEvidenceMutation) SetField

func (m *DeliveryEvidenceMutation) 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 (*DeliveryEvidenceMutation) SetID

func (m *DeliveryEvidenceMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of DeliveryEvidence entities.

func (*DeliveryEvidenceMutation) SetOccurredAt

func (m *DeliveryEvidenceMutation) SetOccurredAt(t time.Time)

SetOccurredAt sets the "occurred_at" field.

func (*DeliveryEvidenceMutation) SetOp

func (m *DeliveryEvidenceMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*DeliveryEvidenceMutation) SetReference

func (m *DeliveryEvidenceMutation) SetReference(s string)

SetReference sets the "reference" field.

func (*DeliveryEvidenceMutation) SetRoadmapItemID

func (m *DeliveryEvidenceMutation) SetRoadmapItemID(id string)

SetRoadmapItemID sets the "roadmap_item" edge to the RoadmapItem entity by id.

func (DeliveryEvidenceMutation) Tx

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

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

func (*DeliveryEvidenceMutation) Type

func (m *DeliveryEvidenceMutation) Type() string

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

func (*DeliveryEvidenceMutation) Where

Where appends a list predicates to the DeliveryEvidenceMutation builder.

func (*DeliveryEvidenceMutation) WhereP

func (m *DeliveryEvidenceMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the DeliveryEvidenceMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type DeliveryEvidenceQuery

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

DeliveryEvidenceQuery is the builder for querying DeliveryEvidence entities.

func (*DeliveryEvidenceQuery) Aggregate

Aggregate returns a DeliveryEvidenceSelect configured with the given aggregations.

func (*DeliveryEvidenceQuery) All

All executes the query and returns a list of DeliveryEvidences.

func (*DeliveryEvidenceQuery) AllX

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

func (*DeliveryEvidenceQuery) Clone

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

func (*DeliveryEvidenceQuery) Count

func (_q *DeliveryEvidenceQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*DeliveryEvidenceQuery) CountX

func (_q *DeliveryEvidenceQuery) CountX(ctx context.Context) int

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

func (*DeliveryEvidenceQuery) Exist

func (_q *DeliveryEvidenceQuery) Exist(ctx context.Context) (bool, error)

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

func (*DeliveryEvidenceQuery) ExistX

func (_q *DeliveryEvidenceQuery) ExistX(ctx context.Context) bool

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

func (*DeliveryEvidenceQuery) First

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

func (*DeliveryEvidenceQuery) FirstID

func (_q *DeliveryEvidenceQuery) FirstID(ctx context.Context) (id string, err error)

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

func (*DeliveryEvidenceQuery) FirstIDX

func (_q *DeliveryEvidenceQuery) FirstIDX(ctx context.Context) string

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

func (*DeliveryEvidenceQuery) FirstX

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

func (*DeliveryEvidenceQuery) GroupBy

func (_q *DeliveryEvidenceQuery) GroupBy(field string, fields ...string) *DeliveryEvidenceGroupBy

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 {
	EvidenceType string `json:"evidence_type,omitempty"`
	Count int `json:"count,omitempty"`
}

client.DeliveryEvidence.Query().
	GroupBy(deliveryevidence.FieldEvidenceType).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*DeliveryEvidenceQuery) IDs

func (_q *DeliveryEvidenceQuery) IDs(ctx context.Context) (ids []string, err error)

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

func (*DeliveryEvidenceQuery) IDsX

func (_q *DeliveryEvidenceQuery) IDsX(ctx context.Context) []string

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

func (*DeliveryEvidenceQuery) Limit

Limit the number of records to be returned by this query.

func (*DeliveryEvidenceQuery) Offset

func (_q *DeliveryEvidenceQuery) Offset(offset int) *DeliveryEvidenceQuery

Offset to start from.

func (*DeliveryEvidenceQuery) Only

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

func (*DeliveryEvidenceQuery) OnlyID

func (_q *DeliveryEvidenceQuery) OnlyID(ctx context.Context) (id string, err error)

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

func (*DeliveryEvidenceQuery) OnlyIDX

func (_q *DeliveryEvidenceQuery) OnlyIDX(ctx context.Context) string

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

func (*DeliveryEvidenceQuery) OnlyX

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

func (*DeliveryEvidenceQuery) Order

Order specifies how the records should be ordered.

func (*DeliveryEvidenceQuery) QueryRoadmapItem

func (_q *DeliveryEvidenceQuery) QueryRoadmapItem() *RoadmapItemQuery

QueryRoadmapItem chains the current query on the "roadmap_item" edge.

func (*DeliveryEvidenceQuery) Select

func (_q *DeliveryEvidenceQuery) Select(fields ...string) *DeliveryEvidenceSelect

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 {
	EvidenceType string `json:"evidence_type,omitempty"`
}

client.DeliveryEvidence.Query().
	Select(deliveryevidence.FieldEvidenceType).
	Scan(ctx, &v)

func (*DeliveryEvidenceQuery) Unique

func (_q *DeliveryEvidenceQuery) Unique(unique bool) *DeliveryEvidenceQuery

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 (*DeliveryEvidenceQuery) Where

Where adds a new predicate for the DeliveryEvidenceQuery builder.

func (*DeliveryEvidenceQuery) WithRoadmapItem

func (_q *DeliveryEvidenceQuery) WithRoadmapItem(opts ...func(*RoadmapItemQuery)) *DeliveryEvidenceQuery

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

type DeliveryEvidenceSelect

type DeliveryEvidenceSelect struct {
	*DeliveryEvidenceQuery
	// contains filtered or unexported fields
}

DeliveryEvidenceSelect is the builder for selecting fields of DeliveryEvidence entities.

func (*DeliveryEvidenceSelect) Aggregate

Aggregate adds the given aggregation functions to the selector query.

func (*DeliveryEvidenceSelect) Bool

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

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

func (*DeliveryEvidenceSelect) BoolX

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

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

func (*DeliveryEvidenceSelect) Bools

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

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

func (*DeliveryEvidenceSelect) BoolsX

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

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

func (*DeliveryEvidenceSelect) Float64

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

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

func (*DeliveryEvidenceSelect) Float64X

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

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

func (*DeliveryEvidenceSelect) Float64s

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

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

func (*DeliveryEvidenceSelect) Float64sX

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

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

func (*DeliveryEvidenceSelect) Int

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

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

func (*DeliveryEvidenceSelect) IntX

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

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

func (*DeliveryEvidenceSelect) Ints

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

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

func (*DeliveryEvidenceSelect) IntsX

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

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

func (*DeliveryEvidenceSelect) Scan

func (_s *DeliveryEvidenceSelect) Scan(ctx context.Context, v any) error

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

func (*DeliveryEvidenceSelect) ScanX

func (s *DeliveryEvidenceSelect) ScanX(ctx context.Context, v any)

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

func (*DeliveryEvidenceSelect) String

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

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

func (*DeliveryEvidenceSelect) StringX

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

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

func (*DeliveryEvidenceSelect) Strings

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

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

func (*DeliveryEvidenceSelect) StringsX

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

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

type DeliveryEvidenceUpdate

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

DeliveryEvidenceUpdate is the builder for updating DeliveryEvidence entities.

func (*DeliveryEvidenceUpdate) ClearCommitScope

func (_u *DeliveryEvidenceUpdate) ClearCommitScope() *DeliveryEvidenceUpdate

ClearCommitScope clears the value of the "commit_scope" field.

func (*DeliveryEvidenceUpdate) ClearCommitType

func (_u *DeliveryEvidenceUpdate) ClearCommitType() *DeliveryEvidenceUpdate

ClearCommitType clears the value of the "commit_type" field.

func (*DeliveryEvidenceUpdate) ClearOccurredAt

func (_u *DeliveryEvidenceUpdate) ClearOccurredAt() *DeliveryEvidenceUpdate

ClearOccurredAt clears the value of the "occurred_at" field.

func (*DeliveryEvidenceUpdate) ClearRoadmapItem

func (_u *DeliveryEvidenceUpdate) ClearRoadmapItem() *DeliveryEvidenceUpdate

ClearRoadmapItem clears the "roadmap_item" edge to the RoadmapItem entity.

func (*DeliveryEvidenceUpdate) Exec

Exec executes the query.

func (*DeliveryEvidenceUpdate) ExecX

func (_u *DeliveryEvidenceUpdate) ExecX(ctx context.Context)

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

func (*DeliveryEvidenceUpdate) Mutation

Mutation returns the DeliveryEvidenceMutation object of the builder.

func (*DeliveryEvidenceUpdate) Save

func (_u *DeliveryEvidenceUpdate) Save(ctx context.Context) (int, error)

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

func (*DeliveryEvidenceUpdate) SaveX

func (_u *DeliveryEvidenceUpdate) SaveX(ctx context.Context) int

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

func (*DeliveryEvidenceUpdate) SetCommitScope

func (_u *DeliveryEvidenceUpdate) SetCommitScope(v string) *DeliveryEvidenceUpdate

SetCommitScope sets the "commit_scope" field.

func (*DeliveryEvidenceUpdate) SetCommitType

SetCommitType sets the "commit_type" field.

func (*DeliveryEvidenceUpdate) SetCreatedAt

SetCreatedAt sets the "created_at" field.

func (*DeliveryEvidenceUpdate) SetEvidenceType

func (_u *DeliveryEvidenceUpdate) SetEvidenceType(v string) *DeliveryEvidenceUpdate

SetEvidenceType sets the "evidence_type" field.

func (*DeliveryEvidenceUpdate) SetNillableCommitScope

func (_u *DeliveryEvidenceUpdate) SetNillableCommitScope(v *string) *DeliveryEvidenceUpdate

SetNillableCommitScope sets the "commit_scope" field if the given value is not nil.

func (*DeliveryEvidenceUpdate) SetNillableCommitType

func (_u *DeliveryEvidenceUpdate) SetNillableCommitType(v *string) *DeliveryEvidenceUpdate

SetNillableCommitType sets the "commit_type" field if the given value is not nil.

func (*DeliveryEvidenceUpdate) SetNillableCreatedAt

func (_u *DeliveryEvidenceUpdate) SetNillableCreatedAt(v *time.Time) *DeliveryEvidenceUpdate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*DeliveryEvidenceUpdate) SetNillableEvidenceType

func (_u *DeliveryEvidenceUpdate) SetNillableEvidenceType(v *string) *DeliveryEvidenceUpdate

SetNillableEvidenceType sets the "evidence_type" field if the given value is not nil.

func (*DeliveryEvidenceUpdate) SetNillableOccurredAt

func (_u *DeliveryEvidenceUpdate) SetNillableOccurredAt(v *time.Time) *DeliveryEvidenceUpdate

SetNillableOccurredAt sets the "occurred_at" field if the given value is not nil.

func (*DeliveryEvidenceUpdate) SetNillableReference

func (_u *DeliveryEvidenceUpdate) SetNillableReference(v *string) *DeliveryEvidenceUpdate

SetNillableReference sets the "reference" field if the given value is not nil.

func (*DeliveryEvidenceUpdate) SetOccurredAt

SetOccurredAt sets the "occurred_at" field.

func (*DeliveryEvidenceUpdate) SetReference

SetReference sets the "reference" field.

func (*DeliveryEvidenceUpdate) SetRoadmapItem

SetRoadmapItem sets the "roadmap_item" edge to the RoadmapItem entity.

func (*DeliveryEvidenceUpdate) SetRoadmapItemID

func (_u *DeliveryEvidenceUpdate) SetRoadmapItemID(id string) *DeliveryEvidenceUpdate

SetRoadmapItemID sets the "roadmap_item" edge to the RoadmapItem entity by ID.

func (*DeliveryEvidenceUpdate) Where

Where appends a list predicates to the DeliveryEvidenceUpdate builder.

type DeliveryEvidenceUpdateOne

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

DeliveryEvidenceUpdateOne is the builder for updating a single DeliveryEvidence entity.

func (*DeliveryEvidenceUpdateOne) ClearCommitScope

func (_u *DeliveryEvidenceUpdateOne) ClearCommitScope() *DeliveryEvidenceUpdateOne

ClearCommitScope clears the value of the "commit_scope" field.

func (*DeliveryEvidenceUpdateOne) ClearCommitType

ClearCommitType clears the value of the "commit_type" field.

func (*DeliveryEvidenceUpdateOne) ClearOccurredAt

ClearOccurredAt clears the value of the "occurred_at" field.

func (*DeliveryEvidenceUpdateOne) ClearRoadmapItem

func (_u *DeliveryEvidenceUpdateOne) ClearRoadmapItem() *DeliveryEvidenceUpdateOne

ClearRoadmapItem clears the "roadmap_item" edge to the RoadmapItem entity.

func (*DeliveryEvidenceUpdateOne) Exec

Exec executes the query on the entity.

func (*DeliveryEvidenceUpdateOne) ExecX

func (_u *DeliveryEvidenceUpdateOne) ExecX(ctx context.Context)

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

func (*DeliveryEvidenceUpdateOne) Mutation

Mutation returns the DeliveryEvidenceMutation object of the builder.

func (*DeliveryEvidenceUpdateOne) Save

Save executes the query and returns the updated DeliveryEvidence entity.

func (*DeliveryEvidenceUpdateOne) SaveX

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

func (*DeliveryEvidenceUpdateOne) Select

func (_u *DeliveryEvidenceUpdateOne) Select(field string, fields ...string) *DeliveryEvidenceUpdateOne

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

func (*DeliveryEvidenceUpdateOne) SetCommitScope

SetCommitScope sets the "commit_scope" field.

func (*DeliveryEvidenceUpdateOne) SetCommitType

SetCommitType sets the "commit_type" field.

func (*DeliveryEvidenceUpdateOne) SetCreatedAt

SetCreatedAt sets the "created_at" field.

func (*DeliveryEvidenceUpdateOne) SetEvidenceType

SetEvidenceType sets the "evidence_type" field.

func (*DeliveryEvidenceUpdateOne) SetNillableCommitScope

func (_u *DeliveryEvidenceUpdateOne) SetNillableCommitScope(v *string) *DeliveryEvidenceUpdateOne

SetNillableCommitScope sets the "commit_scope" field if the given value is not nil.

func (*DeliveryEvidenceUpdateOne) SetNillableCommitType

func (_u *DeliveryEvidenceUpdateOne) SetNillableCommitType(v *string) *DeliveryEvidenceUpdateOne

SetNillableCommitType sets the "commit_type" field if the given value is not nil.

func (*DeliveryEvidenceUpdateOne) SetNillableCreatedAt

func (_u *DeliveryEvidenceUpdateOne) SetNillableCreatedAt(v *time.Time) *DeliveryEvidenceUpdateOne

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*DeliveryEvidenceUpdateOne) SetNillableEvidenceType

func (_u *DeliveryEvidenceUpdateOne) SetNillableEvidenceType(v *string) *DeliveryEvidenceUpdateOne

SetNillableEvidenceType sets the "evidence_type" field if the given value is not nil.

func (*DeliveryEvidenceUpdateOne) SetNillableOccurredAt

func (_u *DeliveryEvidenceUpdateOne) SetNillableOccurredAt(v *time.Time) *DeliveryEvidenceUpdateOne

SetNillableOccurredAt sets the "occurred_at" field if the given value is not nil.

func (*DeliveryEvidenceUpdateOne) SetNillableReference

func (_u *DeliveryEvidenceUpdateOne) SetNillableReference(v *string) *DeliveryEvidenceUpdateOne

SetNillableReference sets the "reference" field if the given value is not nil.

func (*DeliveryEvidenceUpdateOne) SetOccurredAt

SetOccurredAt sets the "occurred_at" field.

func (*DeliveryEvidenceUpdateOne) SetReference

SetReference sets the "reference" field.

func (*DeliveryEvidenceUpdateOne) SetRoadmapItem

SetRoadmapItem sets the "roadmap_item" edge to the RoadmapItem entity.

func (*DeliveryEvidenceUpdateOne) SetRoadmapItemID

SetRoadmapItemID sets the "roadmap_item" edge to the RoadmapItem entity by ID.

func (*DeliveryEvidenceUpdateOne) Where

Where appends a list predicates to the DeliveryEvidenceUpdate builder.

type DeliveryEvidences

type DeliveryEvidences []*DeliveryEvidence

DeliveryEvidences is a parsable slice of DeliveryEvidence.

type Hook

type Hook = ent.Hook

ent aliases to avoid import conflicts in user's code.

type Initiative

type Initiative struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// Organization holds the value of the "organization" field.
	Organization string `json:"organization,omitempty"`
	// Title holds the value of the "title" field.
	Title string `json:"title,omitempty"`
	// Description holds the value of the "description" field.
	Description string `json:"description,omitempty"`
	// Status holds the value of the "status" field.
	Status string `json:"status,omitempty"`
	// InitType holds the value of the "init_type" field.
	InitType string `json:"init_type,omitempty"`
	// Priority holds the value of the "priority" field.
	Priority string `json:"priority,omitempty"`
	// HomeRepo holds the value of the "home_repo" field.
	HomeRepo string `json:"home_repo,omitempty"`
	// Workspace holds the value of the "workspace" field.
	Workspace string `json:"workspace,omitempty"`
	// Specs holds the value of the "specs" field.
	Specs map[string]string `json:"specs,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// PlannedAt holds the value of the "planned_at" field.
	PlannedAt *time.Time `json:"planned_at,omitempty"`
	// ExecutingAt holds the value of the "executing_at" field.
	ExecutingAt *time.Time `json:"executing_at,omitempty"`
	// DeliveryCompleteAt holds the value of the "delivery_complete_at" field.
	DeliveryCompleteAt *time.Time `json:"delivery_complete_at,omitempty"`
	// ReleasedAt holds the value of the "released_at" field.
	ReleasedAt *time.Time `json:"released_at,omitempty"`
	// ClosedAt holds the value of the "closed_at" field.
	ClosedAt *time.Time `json:"closed_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the InitiativeQuery when eager-loading is set.
	Edges InitiativeEdges `json:"edges"`
	// contains filtered or unexported fields
}

Initiative is the model entity for the Initiative schema.

func (*Initiative) QueryPhases

func (_m *Initiative) QueryPhases() *PhaseQuery

QueryPhases queries the "phases" edge of the Initiative entity.

func (*Initiative) QueryProgram

func (_m *Initiative) QueryProgram() *ProgramQuery

QueryProgram queries the "program" edge of the Initiative entity.

func (*Initiative) QueryRoadmapItems

func (_m *Initiative) QueryRoadmapItems() *RoadmapItemQuery

QueryRoadmapItems queries the "roadmap_items" edge of the Initiative entity.

func (*Initiative) QueryWorkflow

func (_m *Initiative) QueryWorkflow() *SpecWorkflowQuery

QueryWorkflow queries the "workflow" edge of the Initiative entity.

func (*Initiative) String

func (_m *Initiative) String() string

String implements the fmt.Stringer.

func (*Initiative) Unwrap

func (_m *Initiative) Unwrap() *Initiative

Unwrap unwraps the Initiative 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 (*Initiative) Update

func (_m *Initiative) Update() *InitiativeUpdateOne

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

func (*Initiative) Value

func (_m *Initiative) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the Initiative. This includes values selected through modifiers, order, etc.

type InitiativeClient

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

InitiativeClient is a client for the Initiative schema.

func NewInitiativeClient

func NewInitiativeClient(c config) *InitiativeClient

NewInitiativeClient returns a client for the Initiative from the given config.

func (*InitiativeClient) Create

func (c *InitiativeClient) Create() *InitiativeCreate

Create returns a builder for creating a Initiative entity.

func (*InitiativeClient) CreateBulk

func (c *InitiativeClient) CreateBulk(builders ...*InitiativeCreate) *InitiativeCreateBulk

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

func (*InitiativeClient) Delete

func (c *InitiativeClient) Delete() *InitiativeDelete

Delete returns a delete builder for Initiative.

func (*InitiativeClient) DeleteOne

func (c *InitiativeClient) DeleteOne(_m *Initiative) *InitiativeDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*InitiativeClient) DeleteOneID

func (c *InitiativeClient) DeleteOneID(id string) *InitiativeDeleteOne

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

func (*InitiativeClient) Get

func (c *InitiativeClient) Get(ctx context.Context, id string) (*Initiative, error)

Get returns a Initiative entity by its id.

func (*InitiativeClient) GetX

func (c *InitiativeClient) GetX(ctx context.Context, id string) *Initiative

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

func (*InitiativeClient) Hooks

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

Hooks returns the client hooks.

func (*InitiativeClient) Intercept

func (c *InitiativeClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `initiative.Intercept(f(g(h())))`.

func (*InitiativeClient) Interceptors

func (c *InitiativeClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*InitiativeClient) MapCreateBulk

func (c *InitiativeClient) MapCreateBulk(slice any, setFunc func(*InitiativeCreate, int)) *InitiativeCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*InitiativeClient) Query

func (c *InitiativeClient) Query() *InitiativeQuery

Query returns a query builder for Initiative.

func (*InitiativeClient) QueryPhases

func (c *InitiativeClient) QueryPhases(_m *Initiative) *PhaseQuery

QueryPhases queries the phases edge of a Initiative.

func (*InitiativeClient) QueryProgram

func (c *InitiativeClient) QueryProgram(_m *Initiative) *ProgramQuery

QueryProgram queries the program edge of a Initiative.

func (*InitiativeClient) QueryRoadmapItems

func (c *InitiativeClient) QueryRoadmapItems(_m *Initiative) *RoadmapItemQuery

QueryRoadmapItems queries the roadmap_items edge of a Initiative.

func (*InitiativeClient) QueryWorkflow

func (c *InitiativeClient) QueryWorkflow(_m *Initiative) *SpecWorkflowQuery

QueryWorkflow queries the workflow edge of a Initiative.

func (*InitiativeClient) Update

func (c *InitiativeClient) Update() *InitiativeUpdate

Update returns an update builder for Initiative.

func (*InitiativeClient) UpdateOne

func (c *InitiativeClient) UpdateOne(_m *Initiative) *InitiativeUpdateOne

UpdateOne returns an update builder for the given entity.

func (*InitiativeClient) UpdateOneID

func (c *InitiativeClient) UpdateOneID(id string) *InitiativeUpdateOne

UpdateOneID returns an update builder for the given id.

func (*InitiativeClient) Use

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

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

type InitiativeCreate

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

InitiativeCreate is the builder for creating a Initiative entity.

func (*InitiativeCreate) AddPhaseIDs

func (_c *InitiativeCreate) AddPhaseIDs(ids ...string) *InitiativeCreate

AddPhaseIDs adds the "phases" edge to the Phase entity by IDs.

func (*InitiativeCreate) AddPhases

func (_c *InitiativeCreate) AddPhases(v ...*Phase) *InitiativeCreate

AddPhases adds the "phases" edges to the Phase entity.

func (*InitiativeCreate) AddRoadmapItemIDs

func (_c *InitiativeCreate) AddRoadmapItemIDs(ids ...string) *InitiativeCreate

AddRoadmapItemIDs adds the "roadmap_items" edge to the RoadmapItem entity by IDs.

func (*InitiativeCreate) AddRoadmapItems

func (_c *InitiativeCreate) AddRoadmapItems(v ...*RoadmapItem) *InitiativeCreate

AddRoadmapItems adds the "roadmap_items" edges to the RoadmapItem entity.

func (*InitiativeCreate) Exec

func (_c *InitiativeCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*InitiativeCreate) ExecX

func (_c *InitiativeCreate) ExecX(ctx context.Context)

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

func (*InitiativeCreate) Mutation

func (_c *InitiativeCreate) Mutation() *InitiativeMutation

Mutation returns the InitiativeMutation object of the builder.

func (*InitiativeCreate) Save

func (_c *InitiativeCreate) Save(ctx context.Context) (*Initiative, error)

Save creates the Initiative in the database.

func (*InitiativeCreate) SaveX

func (_c *InitiativeCreate) SaveX(ctx context.Context) *Initiative

SaveX calls Save and panics if Save returns an error.

func (*InitiativeCreate) SetClosedAt

func (_c *InitiativeCreate) SetClosedAt(v time.Time) *InitiativeCreate

SetClosedAt sets the "closed_at" field.

func (*InitiativeCreate) SetCreatedAt

func (_c *InitiativeCreate) SetCreatedAt(v time.Time) *InitiativeCreate

SetCreatedAt sets the "created_at" field.

func (*InitiativeCreate) SetDeliveryCompleteAt

func (_c *InitiativeCreate) SetDeliveryCompleteAt(v time.Time) *InitiativeCreate

SetDeliveryCompleteAt sets the "delivery_complete_at" field.

func (*InitiativeCreate) SetDescription

func (_c *InitiativeCreate) SetDescription(v string) *InitiativeCreate

SetDescription sets the "description" field.

func (*InitiativeCreate) SetExecutingAt

func (_c *InitiativeCreate) SetExecutingAt(v time.Time) *InitiativeCreate

SetExecutingAt sets the "executing_at" field.

func (*InitiativeCreate) SetHomeRepo

func (_c *InitiativeCreate) SetHomeRepo(v string) *InitiativeCreate

SetHomeRepo sets the "home_repo" field.

func (*InitiativeCreate) SetID

SetID sets the "id" field.

func (*InitiativeCreate) SetInitType

func (_c *InitiativeCreate) SetInitType(v string) *InitiativeCreate

SetInitType sets the "init_type" field.

func (*InitiativeCreate) SetNillableClosedAt

func (_c *InitiativeCreate) SetNillableClosedAt(v *time.Time) *InitiativeCreate

SetNillableClosedAt sets the "closed_at" field if the given value is not nil.

func (*InitiativeCreate) SetNillableDeliveryCompleteAt

func (_c *InitiativeCreate) SetNillableDeliveryCompleteAt(v *time.Time) *InitiativeCreate

SetNillableDeliveryCompleteAt sets the "delivery_complete_at" field if the given value is not nil.

func (*InitiativeCreate) SetNillableDescription

func (_c *InitiativeCreate) SetNillableDescription(v *string) *InitiativeCreate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*InitiativeCreate) SetNillableExecutingAt

func (_c *InitiativeCreate) SetNillableExecutingAt(v *time.Time) *InitiativeCreate

SetNillableExecutingAt sets the "executing_at" field if the given value is not nil.

func (*InitiativeCreate) SetNillableHomeRepo

func (_c *InitiativeCreate) SetNillableHomeRepo(v *string) *InitiativeCreate

SetNillableHomeRepo sets the "home_repo" field if the given value is not nil.

func (*InitiativeCreate) SetNillableInitType

func (_c *InitiativeCreate) SetNillableInitType(v *string) *InitiativeCreate

SetNillableInitType sets the "init_type" field if the given value is not nil.

func (*InitiativeCreate) SetNillablePlannedAt

func (_c *InitiativeCreate) SetNillablePlannedAt(v *time.Time) *InitiativeCreate

SetNillablePlannedAt sets the "planned_at" field if the given value is not nil.

func (*InitiativeCreate) SetNillablePriority

func (_c *InitiativeCreate) SetNillablePriority(v *string) *InitiativeCreate

SetNillablePriority sets the "priority" field if the given value is not nil.

func (*InitiativeCreate) SetNillableProgramID

func (_c *InitiativeCreate) SetNillableProgramID(id *string) *InitiativeCreate

SetNillableProgramID sets the "program" edge to the Program entity by ID if the given value is not nil.

func (*InitiativeCreate) SetNillableReleasedAt

func (_c *InitiativeCreate) SetNillableReleasedAt(v *time.Time) *InitiativeCreate

SetNillableReleasedAt sets the "released_at" field if the given value is not nil.

func (*InitiativeCreate) SetNillableWorkflowID

func (_c *InitiativeCreate) SetNillableWorkflowID(id *string) *InitiativeCreate

SetNillableWorkflowID sets the "workflow" edge to the SpecWorkflow entity by ID if the given value is not nil.

func (*InitiativeCreate) SetNillableWorkspace

func (_c *InitiativeCreate) SetNillableWorkspace(v *string) *InitiativeCreate

SetNillableWorkspace sets the "workspace" field if the given value is not nil.

func (*InitiativeCreate) SetOrganization

func (_c *InitiativeCreate) SetOrganization(v string) *InitiativeCreate

SetOrganization sets the "organization" field.

func (*InitiativeCreate) SetPlannedAt

func (_c *InitiativeCreate) SetPlannedAt(v time.Time) *InitiativeCreate

SetPlannedAt sets the "planned_at" field.

func (*InitiativeCreate) SetPriority

func (_c *InitiativeCreate) SetPriority(v string) *InitiativeCreate

SetPriority sets the "priority" field.

func (*InitiativeCreate) SetProgram

func (_c *InitiativeCreate) SetProgram(v *Program) *InitiativeCreate

SetProgram sets the "program" edge to the Program entity.

func (*InitiativeCreate) SetProgramID

func (_c *InitiativeCreate) SetProgramID(id string) *InitiativeCreate

SetProgramID sets the "program" edge to the Program entity by ID.

func (*InitiativeCreate) SetReleasedAt

func (_c *InitiativeCreate) SetReleasedAt(v time.Time) *InitiativeCreate

SetReleasedAt sets the "released_at" field.

func (*InitiativeCreate) SetSpecs

func (_c *InitiativeCreate) SetSpecs(v map[string]string) *InitiativeCreate

SetSpecs sets the "specs" field.

func (*InitiativeCreate) SetStatus

func (_c *InitiativeCreate) SetStatus(v string) *InitiativeCreate

SetStatus sets the "status" field.

func (*InitiativeCreate) SetTitle

func (_c *InitiativeCreate) SetTitle(v string) *InitiativeCreate

SetTitle sets the "title" field.

func (*InitiativeCreate) SetUpdatedAt

func (_c *InitiativeCreate) SetUpdatedAt(v time.Time) *InitiativeCreate

SetUpdatedAt sets the "updated_at" field.

func (*InitiativeCreate) SetWorkflow

func (_c *InitiativeCreate) SetWorkflow(v *SpecWorkflow) *InitiativeCreate

SetWorkflow sets the "workflow" edge to the SpecWorkflow entity.

func (*InitiativeCreate) SetWorkflowID

func (_c *InitiativeCreate) SetWorkflowID(id string) *InitiativeCreate

SetWorkflowID sets the "workflow" edge to the SpecWorkflow entity by ID.

func (*InitiativeCreate) SetWorkspace

func (_c *InitiativeCreate) SetWorkspace(v string) *InitiativeCreate

SetWorkspace sets the "workspace" field.

type InitiativeCreateBulk

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

InitiativeCreateBulk is the builder for creating many Initiative entities in bulk.

func (*InitiativeCreateBulk) Exec

func (_c *InitiativeCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*InitiativeCreateBulk) ExecX

func (_c *InitiativeCreateBulk) ExecX(ctx context.Context)

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

func (*InitiativeCreateBulk) Save

func (_c *InitiativeCreateBulk) Save(ctx context.Context) ([]*Initiative, error)

Save creates the Initiative entities in the database.

func (*InitiativeCreateBulk) SaveX

func (_c *InitiativeCreateBulk) SaveX(ctx context.Context) []*Initiative

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

type InitiativeDelete

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

InitiativeDelete is the builder for deleting a Initiative entity.

func (*InitiativeDelete) Exec

func (_d *InitiativeDelete) Exec(ctx context.Context) (int, error)

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

func (*InitiativeDelete) ExecX

func (_d *InitiativeDelete) ExecX(ctx context.Context) int

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

func (*InitiativeDelete) Where

Where appends a list predicates to the InitiativeDelete builder.

type InitiativeDeleteOne

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

InitiativeDeleteOne is the builder for deleting a single Initiative entity.

func (*InitiativeDeleteOne) Exec

func (_d *InitiativeDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*InitiativeDeleteOne) ExecX

func (_d *InitiativeDeleteOne) ExecX(ctx context.Context)

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

func (*InitiativeDeleteOne) Where

Where appends a list predicates to the InitiativeDelete builder.

type InitiativeDependencies

type InitiativeDependencies []*InitiativeDependency

InitiativeDependencies is a parsable slice of InitiativeDependency.

type InitiativeDependency

type InitiativeDependency struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// SourceInitiativeID holds the value of the "source_initiative_id" field.
	SourceInitiativeID string `json:"source_initiative_id,omitempty"`
	// TargetInitiativeID holds the value of the "target_initiative_id" field.
	TargetInitiativeID string `json:"target_initiative_id,omitempty"`
	// Relationship holds the value of the "relationship" field.
	Relationship string `json:"relationship,omitempty"`
	// contains filtered or unexported fields
}

InitiativeDependency is the model entity for the InitiativeDependency schema.

func (*InitiativeDependency) String

func (_m *InitiativeDependency) String() string

String implements the fmt.Stringer.

func (*InitiativeDependency) Unwrap

Unwrap unwraps the InitiativeDependency 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 (*InitiativeDependency) Update

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

func (*InitiativeDependency) Value

func (_m *InitiativeDependency) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the InitiativeDependency. This includes values selected through modifiers, order, etc.

type InitiativeDependencyClient

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

InitiativeDependencyClient is a client for the InitiativeDependency schema.

func NewInitiativeDependencyClient

func NewInitiativeDependencyClient(c config) *InitiativeDependencyClient

NewInitiativeDependencyClient returns a client for the InitiativeDependency from the given config.

func (*InitiativeDependencyClient) Create

Create returns a builder for creating a InitiativeDependency entity.

func (*InitiativeDependencyClient) CreateBulk

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

func (*InitiativeDependencyClient) Delete

Delete returns a delete builder for InitiativeDependency.

func (*InitiativeDependencyClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*InitiativeDependencyClient) DeleteOneID

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

func (*InitiativeDependencyClient) Get

Get returns a InitiativeDependency entity by its id.

func (*InitiativeDependencyClient) GetX

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

func (*InitiativeDependencyClient) Hooks

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

Hooks returns the client hooks.

func (*InitiativeDependencyClient) Intercept

func (c *InitiativeDependencyClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `initiativedependency.Intercept(f(g(h())))`.

func (*InitiativeDependencyClient) Interceptors

func (c *InitiativeDependencyClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*InitiativeDependencyClient) MapCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*InitiativeDependencyClient) Query

Query returns a query builder for InitiativeDependency.

func (*InitiativeDependencyClient) Update

Update returns an update builder for InitiativeDependency.

func (*InitiativeDependencyClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*InitiativeDependencyClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*InitiativeDependencyClient) Use

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

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

type InitiativeDependencyCreate

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

InitiativeDependencyCreate is the builder for creating a InitiativeDependency entity.

func (*InitiativeDependencyCreate) Exec

Exec executes the query.

func (*InitiativeDependencyCreate) ExecX

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

func (*InitiativeDependencyCreate) Mutation

Mutation returns the InitiativeDependencyMutation object of the builder.

func (*InitiativeDependencyCreate) Save

Save creates the InitiativeDependency in the database.

func (*InitiativeDependencyCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*InitiativeDependencyCreate) SetRelationship

SetRelationship sets the "relationship" field.

func (*InitiativeDependencyCreate) SetSourceInitiativeID

func (_c *InitiativeDependencyCreate) SetSourceInitiativeID(v string) *InitiativeDependencyCreate

SetSourceInitiativeID sets the "source_initiative_id" field.

func (*InitiativeDependencyCreate) SetTargetInitiativeID

func (_c *InitiativeDependencyCreate) SetTargetInitiativeID(v string) *InitiativeDependencyCreate

SetTargetInitiativeID sets the "target_initiative_id" field.

type InitiativeDependencyCreateBulk

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

InitiativeDependencyCreateBulk is the builder for creating many InitiativeDependency entities in bulk.

func (*InitiativeDependencyCreateBulk) Exec

Exec executes the query.

func (*InitiativeDependencyCreateBulk) ExecX

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

func (*InitiativeDependencyCreateBulk) Save

Save creates the InitiativeDependency entities in the database.

func (*InitiativeDependencyCreateBulk) SaveX

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

type InitiativeDependencyDelete

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

InitiativeDependencyDelete is the builder for deleting a InitiativeDependency entity.

func (*InitiativeDependencyDelete) Exec

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

func (*InitiativeDependencyDelete) ExecX

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

func (*InitiativeDependencyDelete) Where

Where appends a list predicates to the InitiativeDependencyDelete builder.

type InitiativeDependencyDeleteOne

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

InitiativeDependencyDeleteOne is the builder for deleting a single InitiativeDependency entity.

func (*InitiativeDependencyDeleteOne) Exec

Exec executes the deletion query.

func (*InitiativeDependencyDeleteOne) ExecX

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

func (*InitiativeDependencyDeleteOne) Where

Where appends a list predicates to the InitiativeDependencyDelete builder.

type InitiativeDependencyGroupBy

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

InitiativeDependencyGroupBy is the group-by builder for InitiativeDependency entities.

func (*InitiativeDependencyGroupBy) Aggregate

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

func (*InitiativeDependencyGroupBy) Bool

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

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

func (*InitiativeDependencyGroupBy) BoolX

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

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

func (*InitiativeDependencyGroupBy) Bools

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

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

func (*InitiativeDependencyGroupBy) BoolsX

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

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

func (*InitiativeDependencyGroupBy) Float64

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

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

func (*InitiativeDependencyGroupBy) Float64X

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

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

func (*InitiativeDependencyGroupBy) Float64s

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

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

func (*InitiativeDependencyGroupBy) Float64sX

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

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

func (*InitiativeDependencyGroupBy) Int

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

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

func (*InitiativeDependencyGroupBy) IntX

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

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

func (*InitiativeDependencyGroupBy) Ints

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

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

func (*InitiativeDependencyGroupBy) IntsX

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

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

func (*InitiativeDependencyGroupBy) Scan

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

func (*InitiativeDependencyGroupBy) ScanX

func (s *InitiativeDependencyGroupBy) ScanX(ctx context.Context, v any)

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

func (*InitiativeDependencyGroupBy) String

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

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

func (*InitiativeDependencyGroupBy) StringX

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

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

func (*InitiativeDependencyGroupBy) Strings

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

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

func (*InitiativeDependencyGroupBy) StringsX

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

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

type InitiativeDependencyMutation

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

InitiativeDependencyMutation represents an operation that mutates the InitiativeDependency nodes in the graph.

func (*InitiativeDependencyMutation) AddField

func (m *InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) AddedEdges

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

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

func (*InitiativeDependencyMutation) AddedField

func (m *InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) AddedFields

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

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

func (*InitiativeDependencyMutation) AddedIDs

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

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

func (*InitiativeDependencyMutation) ClearEdge

func (m *InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) ClearField

func (m *InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) ClearedEdges

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

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

func (*InitiativeDependencyMutation) ClearedFields

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

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

func (InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) EdgeCleared

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

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

func (*InitiativeDependencyMutation) Field

func (m *InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) FieldCleared

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

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

func (*InitiativeDependencyMutation) Fields

func (m *InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) ID

func (m *InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) OldField

func (m *InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) OldRelationship

func (m *InitiativeDependencyMutation) OldRelationship(ctx context.Context) (v string, err error)

OldRelationship returns the old "relationship" field's value of the InitiativeDependency entity. If the InitiativeDependency 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 (*InitiativeDependencyMutation) OldSourceInitiativeID

func (m *InitiativeDependencyMutation) OldSourceInitiativeID(ctx context.Context) (v string, err error)

OldSourceInitiativeID returns the old "source_initiative_id" field's value of the InitiativeDependency entity. If the InitiativeDependency 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 (*InitiativeDependencyMutation) OldTargetInitiativeID

func (m *InitiativeDependencyMutation) OldTargetInitiativeID(ctx context.Context) (v string, err error)

OldTargetInitiativeID returns the old "target_initiative_id" field's value of the InitiativeDependency entity. If the InitiativeDependency 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 (*InitiativeDependencyMutation) Op

Op returns the operation name.

func (*InitiativeDependencyMutation) Relationship

func (m *InitiativeDependencyMutation) Relationship() (r string, exists bool)

Relationship returns the value of the "relationship" field in the mutation.

func (*InitiativeDependencyMutation) RemovedEdges

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

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

func (*InitiativeDependencyMutation) RemovedIDs

func (m *InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) ResetEdge

func (m *InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) ResetField

func (m *InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) ResetRelationship

func (m *InitiativeDependencyMutation) ResetRelationship()

ResetRelationship resets all changes to the "relationship" field.

func (*InitiativeDependencyMutation) ResetSourceInitiativeID

func (m *InitiativeDependencyMutation) ResetSourceInitiativeID()

ResetSourceInitiativeID resets all changes to the "source_initiative_id" field.

func (*InitiativeDependencyMutation) ResetTargetInitiativeID

func (m *InitiativeDependencyMutation) ResetTargetInitiativeID()

ResetTargetInitiativeID resets all changes to the "target_initiative_id" field.

func (*InitiativeDependencyMutation) SetField

func (m *InitiativeDependencyMutation) 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 (*InitiativeDependencyMutation) SetOp

func (m *InitiativeDependencyMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*InitiativeDependencyMutation) SetRelationship

func (m *InitiativeDependencyMutation) SetRelationship(s string)

SetRelationship sets the "relationship" field.

func (*InitiativeDependencyMutation) SetSourceInitiativeID

func (m *InitiativeDependencyMutation) SetSourceInitiativeID(s string)

SetSourceInitiativeID sets the "source_initiative_id" field.

func (*InitiativeDependencyMutation) SetTargetInitiativeID

func (m *InitiativeDependencyMutation) SetTargetInitiativeID(s string)

SetTargetInitiativeID sets the "target_initiative_id" field.

func (*InitiativeDependencyMutation) SourceInitiativeID

func (m *InitiativeDependencyMutation) SourceInitiativeID() (r string, exists bool)

SourceInitiativeID returns the value of the "source_initiative_id" field in the mutation.

func (*InitiativeDependencyMutation) TargetInitiativeID

func (m *InitiativeDependencyMutation) TargetInitiativeID() (r string, exists bool)

TargetInitiativeID returns the value of the "target_initiative_id" field in the mutation.

func (InitiativeDependencyMutation) Tx

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

func (*InitiativeDependencyMutation) Type

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

func (*InitiativeDependencyMutation) Where

Where appends a list predicates to the InitiativeDependencyMutation builder.

func (*InitiativeDependencyMutation) WhereP

func (m *InitiativeDependencyMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the InitiativeDependencyMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type InitiativeDependencyQuery

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

InitiativeDependencyQuery is the builder for querying InitiativeDependency entities.

func (*InitiativeDependencyQuery) Aggregate

Aggregate returns a InitiativeDependencySelect configured with the given aggregations.

func (*InitiativeDependencyQuery) All

All executes the query and returns a list of InitiativeDependencies.

func (*InitiativeDependencyQuery) AllX

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

func (*InitiativeDependencyQuery) Clone

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

func (*InitiativeDependencyQuery) Count

Count returns the count of the given query.

func (*InitiativeDependencyQuery) CountX

func (_q *InitiativeDependencyQuery) CountX(ctx context.Context) int

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

func (*InitiativeDependencyQuery) Exist

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

func (*InitiativeDependencyQuery) ExistX

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

func (*InitiativeDependencyQuery) First

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

func (*InitiativeDependencyQuery) FirstID

func (_q *InitiativeDependencyQuery) FirstID(ctx context.Context) (id int, err error)

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

func (*InitiativeDependencyQuery) FirstIDX

func (_q *InitiativeDependencyQuery) FirstIDX(ctx context.Context) int

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

func (*InitiativeDependencyQuery) FirstX

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

func (*InitiativeDependencyQuery) GroupBy

func (_q *InitiativeDependencyQuery) GroupBy(field string, fields ...string) *InitiativeDependencyGroupBy

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 {
	SourceInitiativeID string `json:"source_initiative_id,omitempty"`
	Count int `json:"count,omitempty"`
}

client.InitiativeDependency.Query().
	GroupBy(initiativedependency.FieldSourceInitiativeID).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*InitiativeDependencyQuery) IDs

func (_q *InitiativeDependencyQuery) IDs(ctx context.Context) (ids []int, err error)

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

func (*InitiativeDependencyQuery) IDsX

func (_q *InitiativeDependencyQuery) IDsX(ctx context.Context) []int

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

func (*InitiativeDependencyQuery) Limit

Limit the number of records to be returned by this query.

func (*InitiativeDependencyQuery) Offset

Offset to start from.

func (*InitiativeDependencyQuery) Only

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

func (*InitiativeDependencyQuery) OnlyID

func (_q *InitiativeDependencyQuery) OnlyID(ctx context.Context) (id int, err error)

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

func (*InitiativeDependencyQuery) OnlyIDX

func (_q *InitiativeDependencyQuery) OnlyIDX(ctx context.Context) int

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

func (*InitiativeDependencyQuery) OnlyX

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

func (*InitiativeDependencyQuery) Order

Order specifies how the records should be ordered.

func (*InitiativeDependencyQuery) 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 {
	SourceInitiativeID string `json:"source_initiative_id,omitempty"`
}

client.InitiativeDependency.Query().
	Select(initiativedependency.FieldSourceInitiativeID).
	Scan(ctx, &v)

func (*InitiativeDependencyQuery) 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 (*InitiativeDependencyQuery) Where

Where adds a new predicate for the InitiativeDependencyQuery builder.

type InitiativeDependencySelect

type InitiativeDependencySelect struct {
	*InitiativeDependencyQuery
	// contains filtered or unexported fields
}

InitiativeDependencySelect is the builder for selecting fields of InitiativeDependency entities.

func (*InitiativeDependencySelect) Aggregate

Aggregate adds the given aggregation functions to the selector query.

func (*InitiativeDependencySelect) Bool

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

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

func (*InitiativeDependencySelect) BoolX

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

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

func (*InitiativeDependencySelect) Bools

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

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

func (*InitiativeDependencySelect) BoolsX

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

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

func (*InitiativeDependencySelect) Float64

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

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

func (*InitiativeDependencySelect) Float64X

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

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

func (*InitiativeDependencySelect) Float64s

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

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

func (*InitiativeDependencySelect) Float64sX

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

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

func (*InitiativeDependencySelect) Int

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

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

func (*InitiativeDependencySelect) IntX

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

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

func (*InitiativeDependencySelect) Ints

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

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

func (*InitiativeDependencySelect) IntsX

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

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

func (*InitiativeDependencySelect) Scan

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

func (*InitiativeDependencySelect) ScanX

func (s *InitiativeDependencySelect) ScanX(ctx context.Context, v any)

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

func (*InitiativeDependencySelect) String

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

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

func (*InitiativeDependencySelect) StringX

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

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

func (*InitiativeDependencySelect) Strings

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

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

func (*InitiativeDependencySelect) StringsX

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

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

type InitiativeDependencyUpdate

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

InitiativeDependencyUpdate is the builder for updating InitiativeDependency entities.

func (*InitiativeDependencyUpdate) Exec

Exec executes the query.

func (*InitiativeDependencyUpdate) ExecX

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

func (*InitiativeDependencyUpdate) Mutation

Mutation returns the InitiativeDependencyMutation object of the builder.

func (*InitiativeDependencyUpdate) Save

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

func (*InitiativeDependencyUpdate) SaveX

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

func (*InitiativeDependencyUpdate) SetNillableRelationship

func (_u *InitiativeDependencyUpdate) SetNillableRelationship(v *string) *InitiativeDependencyUpdate

SetNillableRelationship sets the "relationship" field if the given value is not nil.

func (*InitiativeDependencyUpdate) SetNillableSourceInitiativeID

func (_u *InitiativeDependencyUpdate) SetNillableSourceInitiativeID(v *string) *InitiativeDependencyUpdate

SetNillableSourceInitiativeID sets the "source_initiative_id" field if the given value is not nil.

func (*InitiativeDependencyUpdate) SetNillableTargetInitiativeID

func (_u *InitiativeDependencyUpdate) SetNillableTargetInitiativeID(v *string) *InitiativeDependencyUpdate

SetNillableTargetInitiativeID sets the "target_initiative_id" field if the given value is not nil.

func (*InitiativeDependencyUpdate) SetRelationship

SetRelationship sets the "relationship" field.

func (*InitiativeDependencyUpdate) SetSourceInitiativeID

func (_u *InitiativeDependencyUpdate) SetSourceInitiativeID(v string) *InitiativeDependencyUpdate

SetSourceInitiativeID sets the "source_initiative_id" field.

func (*InitiativeDependencyUpdate) SetTargetInitiativeID

func (_u *InitiativeDependencyUpdate) SetTargetInitiativeID(v string) *InitiativeDependencyUpdate

SetTargetInitiativeID sets the "target_initiative_id" field.

func (*InitiativeDependencyUpdate) Where

Where appends a list predicates to the InitiativeDependencyUpdate builder.

type InitiativeDependencyUpdateOne

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

InitiativeDependencyUpdateOne is the builder for updating a single InitiativeDependency entity.

func (*InitiativeDependencyUpdateOne) Exec

Exec executes the query on the entity.

func (*InitiativeDependencyUpdateOne) ExecX

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

func (*InitiativeDependencyUpdateOne) Mutation

Mutation returns the InitiativeDependencyMutation object of the builder.

func (*InitiativeDependencyUpdateOne) Save

Save executes the query and returns the updated InitiativeDependency entity.

func (*InitiativeDependencyUpdateOne) SaveX

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

func (*InitiativeDependencyUpdateOne) 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 (*InitiativeDependencyUpdateOne) SetNillableRelationship

func (_u *InitiativeDependencyUpdateOne) SetNillableRelationship(v *string) *InitiativeDependencyUpdateOne

SetNillableRelationship sets the "relationship" field if the given value is not nil.

func (*InitiativeDependencyUpdateOne) SetNillableSourceInitiativeID

func (_u *InitiativeDependencyUpdateOne) SetNillableSourceInitiativeID(v *string) *InitiativeDependencyUpdateOne

SetNillableSourceInitiativeID sets the "source_initiative_id" field if the given value is not nil.

func (*InitiativeDependencyUpdateOne) SetNillableTargetInitiativeID

func (_u *InitiativeDependencyUpdateOne) SetNillableTargetInitiativeID(v *string) *InitiativeDependencyUpdateOne

SetNillableTargetInitiativeID sets the "target_initiative_id" field if the given value is not nil.

func (*InitiativeDependencyUpdateOne) SetRelationship

SetRelationship sets the "relationship" field.

func (*InitiativeDependencyUpdateOne) SetSourceInitiativeID

SetSourceInitiativeID sets the "source_initiative_id" field.

func (*InitiativeDependencyUpdateOne) SetTargetInitiativeID

SetTargetInitiativeID sets the "target_initiative_id" field.

func (*InitiativeDependencyUpdateOne) Where

Where appends a list predicates to the InitiativeDependencyUpdate builder.

type InitiativeEdges

type InitiativeEdges struct {
	// Phases holds the value of the phases edge.
	Phases []*Phase `json:"phases,omitempty"`
	// RoadmapItems holds the value of the roadmap_items edge.
	RoadmapItems []*RoadmapItem `json:"roadmap_items,omitempty"`
	// Program holds the value of the program edge.
	Program *Program `json:"program,omitempty"`
	// Workflow holds the value of the workflow edge.
	Workflow *SpecWorkflow `json:"workflow,omitempty"`
	// contains filtered or unexported fields
}

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

func (InitiativeEdges) PhasesOrErr

func (e InitiativeEdges) PhasesOrErr() ([]*Phase, error)

PhasesOrErr returns the Phases value or an error if the edge was not loaded in eager-loading.

func (InitiativeEdges) ProgramOrErr

func (e InitiativeEdges) ProgramOrErr() (*Program, error)

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

func (InitiativeEdges) RoadmapItemsOrErr

func (e InitiativeEdges) RoadmapItemsOrErr() ([]*RoadmapItem, error)

RoadmapItemsOrErr returns the RoadmapItems value or an error if the edge was not loaded in eager-loading.

func (InitiativeEdges) WorkflowOrErr

func (e InitiativeEdges) WorkflowOrErr() (*SpecWorkflow, error)

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

type InitiativeGroupBy

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

InitiativeGroupBy is the group-by builder for Initiative entities.

func (*InitiativeGroupBy) Aggregate

func (_g *InitiativeGroupBy) Aggregate(fns ...AggregateFunc) *InitiativeGroupBy

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

func (*InitiativeGroupBy) Bool

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

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

func (*InitiativeGroupBy) BoolX

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

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

func (*InitiativeGroupBy) Bools

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

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

func (*InitiativeGroupBy) BoolsX

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

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

func (*InitiativeGroupBy) Float64

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

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

func (*InitiativeGroupBy) Float64X

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

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

func (*InitiativeGroupBy) Float64s

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

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

func (*InitiativeGroupBy) Float64sX

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

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

func (*InitiativeGroupBy) Int

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

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

func (*InitiativeGroupBy) IntX

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

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

func (*InitiativeGroupBy) Ints

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

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

func (*InitiativeGroupBy) IntsX

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

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

func (*InitiativeGroupBy) Scan

func (_g *InitiativeGroupBy) Scan(ctx context.Context, v any) error

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

func (*InitiativeGroupBy) ScanX

func (s *InitiativeGroupBy) ScanX(ctx context.Context, v any)

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

func (*InitiativeGroupBy) String

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

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

func (*InitiativeGroupBy) StringX

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

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

func (*InitiativeGroupBy) Strings

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

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

func (*InitiativeGroupBy) StringsX

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

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

type InitiativeMutation

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

InitiativeMutation represents an operation that mutates the Initiative nodes in the graph.

func (*InitiativeMutation) AddField

func (m *InitiativeMutation) 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 (*InitiativeMutation) AddPhaseIDs

func (m *InitiativeMutation) AddPhaseIDs(ids ...string)

AddPhaseIDs adds the "phases" edge to the Phase entity by ids.

func (*InitiativeMutation) AddRoadmapItemIDs

func (m *InitiativeMutation) AddRoadmapItemIDs(ids ...string)

AddRoadmapItemIDs adds the "roadmap_items" edge to the RoadmapItem entity by ids.

func (*InitiativeMutation) AddedEdges

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

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

func (*InitiativeMutation) AddedField

func (m *InitiativeMutation) 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 (*InitiativeMutation) AddedFields

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

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

func (*InitiativeMutation) AddedIDs

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

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

func (*InitiativeMutation) ClearClosedAt

func (m *InitiativeMutation) ClearClosedAt()

ClearClosedAt clears the value of the "closed_at" field.

func (*InitiativeMutation) ClearDeliveryCompleteAt

func (m *InitiativeMutation) ClearDeliveryCompleteAt()

ClearDeliveryCompleteAt clears the value of the "delivery_complete_at" field.

func (*InitiativeMutation) ClearDescription

func (m *InitiativeMutation) ClearDescription()

ClearDescription clears the value of the "description" field.

func (*InitiativeMutation) ClearEdge

func (m *InitiativeMutation) 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 (*InitiativeMutation) ClearExecutingAt

func (m *InitiativeMutation) ClearExecutingAt()

ClearExecutingAt clears the value of the "executing_at" field.

func (*InitiativeMutation) ClearField

func (m *InitiativeMutation) 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 (*InitiativeMutation) ClearHomeRepo

func (m *InitiativeMutation) ClearHomeRepo()

ClearHomeRepo clears the value of the "home_repo" field.

func (*InitiativeMutation) ClearPhases

func (m *InitiativeMutation) ClearPhases()

ClearPhases clears the "phases" edge to the Phase entity.

func (*InitiativeMutation) ClearPlannedAt

func (m *InitiativeMutation) ClearPlannedAt()

ClearPlannedAt clears the value of the "planned_at" field.

func (*InitiativeMutation) ClearPriority

func (m *InitiativeMutation) ClearPriority()

ClearPriority clears the value of the "priority" field.

func (*InitiativeMutation) ClearProgram

func (m *InitiativeMutation) ClearProgram()

ClearProgram clears the "program" edge to the Program entity.

func (*InitiativeMutation) ClearReleasedAt

func (m *InitiativeMutation) ClearReleasedAt()

ClearReleasedAt clears the value of the "released_at" field.

func (*InitiativeMutation) ClearRoadmapItems

func (m *InitiativeMutation) ClearRoadmapItems()

ClearRoadmapItems clears the "roadmap_items" edge to the RoadmapItem entity.

func (*InitiativeMutation) ClearSpecs

func (m *InitiativeMutation) ClearSpecs()

ClearSpecs clears the value of the "specs" field.

func (*InitiativeMutation) ClearWorkflow

func (m *InitiativeMutation) ClearWorkflow()

ClearWorkflow clears the "workflow" edge to the SpecWorkflow entity.

func (*InitiativeMutation) ClearWorkspace

func (m *InitiativeMutation) ClearWorkspace()

ClearWorkspace clears the value of the "workspace" field.

func (*InitiativeMutation) ClearedEdges

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

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

func (*InitiativeMutation) ClearedFields

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

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

func (InitiativeMutation) Client

func (m InitiativeMutation) 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 (*InitiativeMutation) ClosedAt

func (m *InitiativeMutation) ClosedAt() (r time.Time, exists bool)

ClosedAt returns the value of the "closed_at" field in the mutation.

func (*InitiativeMutation) ClosedAtCleared

func (m *InitiativeMutation) ClosedAtCleared() bool

ClosedAtCleared returns if the "closed_at" field was cleared in this mutation.

func (*InitiativeMutation) CreatedAt

func (m *InitiativeMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*InitiativeMutation) DeliveryCompleteAt

func (m *InitiativeMutation) DeliveryCompleteAt() (r time.Time, exists bool)

DeliveryCompleteAt returns the value of the "delivery_complete_at" field in the mutation.

func (*InitiativeMutation) DeliveryCompleteAtCleared

func (m *InitiativeMutation) DeliveryCompleteAtCleared() bool

DeliveryCompleteAtCleared returns if the "delivery_complete_at" field was cleared in this mutation.

func (*InitiativeMutation) Description

func (m *InitiativeMutation) Description() (r string, exists bool)

Description returns the value of the "description" field in the mutation.

func (*InitiativeMutation) DescriptionCleared

func (m *InitiativeMutation) DescriptionCleared() bool

DescriptionCleared returns if the "description" field was cleared in this mutation.

func (*InitiativeMutation) EdgeCleared

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

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

func (*InitiativeMutation) ExecutingAt

func (m *InitiativeMutation) ExecutingAt() (r time.Time, exists bool)

ExecutingAt returns the value of the "executing_at" field in the mutation.

func (*InitiativeMutation) ExecutingAtCleared

func (m *InitiativeMutation) ExecutingAtCleared() bool

ExecutingAtCleared returns if the "executing_at" field was cleared in this mutation.

func (*InitiativeMutation) Field

func (m *InitiativeMutation) 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 (*InitiativeMutation) FieldCleared

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

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

func (*InitiativeMutation) Fields

func (m *InitiativeMutation) 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 (*InitiativeMutation) HomeRepo

func (m *InitiativeMutation) HomeRepo() (r string, exists bool)

HomeRepo returns the value of the "home_repo" field in the mutation.

func (*InitiativeMutation) HomeRepoCleared

func (m *InitiativeMutation) HomeRepoCleared() bool

HomeRepoCleared returns if the "home_repo" field was cleared in this mutation.

func (*InitiativeMutation) ID

func (m *InitiativeMutation) ID() (id string, 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 (*InitiativeMutation) IDs

func (m *InitiativeMutation) IDs(ctx context.Context) ([]string, 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 (*InitiativeMutation) InitType

func (m *InitiativeMutation) InitType() (r string, exists bool)

InitType returns the value of the "init_type" field in the mutation.

func (*InitiativeMutation) OldClosedAt

func (m *InitiativeMutation) OldClosedAt(ctx context.Context) (v *time.Time, err error)

OldClosedAt returns the old "closed_at" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldCreatedAt

func (m *InitiativeMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldDeliveryCompleteAt

func (m *InitiativeMutation) OldDeliveryCompleteAt(ctx context.Context) (v *time.Time, err error)

OldDeliveryCompleteAt returns the old "delivery_complete_at" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldDescription

func (m *InitiativeMutation) OldDescription(ctx context.Context) (v string, err error)

OldDescription returns the old "description" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldExecutingAt

func (m *InitiativeMutation) OldExecutingAt(ctx context.Context) (v *time.Time, err error)

OldExecutingAt returns the old "executing_at" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldField

func (m *InitiativeMutation) 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 (*InitiativeMutation) OldHomeRepo

func (m *InitiativeMutation) OldHomeRepo(ctx context.Context) (v string, err error)

OldHomeRepo returns the old "home_repo" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldInitType

func (m *InitiativeMutation) OldInitType(ctx context.Context) (v string, err error)

OldInitType returns the old "init_type" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldOrganization

func (m *InitiativeMutation) OldOrganization(ctx context.Context) (v string, err error)

OldOrganization returns the old "organization" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldPlannedAt

func (m *InitiativeMutation) OldPlannedAt(ctx context.Context) (v *time.Time, err error)

OldPlannedAt returns the old "planned_at" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldPriority

func (m *InitiativeMutation) OldPriority(ctx context.Context) (v string, err error)

OldPriority returns the old "priority" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldReleasedAt

func (m *InitiativeMutation) OldReleasedAt(ctx context.Context) (v *time.Time, err error)

OldReleasedAt returns the old "released_at" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldSpecs

func (m *InitiativeMutation) OldSpecs(ctx context.Context) (v map[string]string, err error)

OldSpecs returns the old "specs" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldStatus

func (m *InitiativeMutation) OldStatus(ctx context.Context) (v string, err error)

OldStatus returns the old "status" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldTitle

func (m *InitiativeMutation) OldTitle(ctx context.Context) (v string, err error)

OldTitle returns the old "title" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldUpdatedAt

func (m *InitiativeMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) OldWorkspace

func (m *InitiativeMutation) OldWorkspace(ctx context.Context) (v string, err error)

OldWorkspace returns the old "workspace" field's value of the Initiative entity. If the Initiative 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 (*InitiativeMutation) Op

func (m *InitiativeMutation) Op() Op

Op returns the operation name.

func (*InitiativeMutation) Organization

func (m *InitiativeMutation) Organization() (r string, exists bool)

Organization returns the value of the "organization" field in the mutation.

func (*InitiativeMutation) PhasesCleared

func (m *InitiativeMutation) PhasesCleared() bool

PhasesCleared reports if the "phases" edge to the Phase entity was cleared.

func (*InitiativeMutation) PhasesIDs

func (m *InitiativeMutation) PhasesIDs() (ids []string)

PhasesIDs returns the "phases" edge IDs in the mutation.

func (*InitiativeMutation) PlannedAt

func (m *InitiativeMutation) PlannedAt() (r time.Time, exists bool)

PlannedAt returns the value of the "planned_at" field in the mutation.

func (*InitiativeMutation) PlannedAtCleared

func (m *InitiativeMutation) PlannedAtCleared() bool

PlannedAtCleared returns if the "planned_at" field was cleared in this mutation.

func (*InitiativeMutation) Priority

func (m *InitiativeMutation) Priority() (r string, exists bool)

Priority returns the value of the "priority" field in the mutation.

func (*InitiativeMutation) PriorityCleared

func (m *InitiativeMutation) PriorityCleared() bool

PriorityCleared returns if the "priority" field was cleared in this mutation.

func (*InitiativeMutation) ProgramCleared

func (m *InitiativeMutation) ProgramCleared() bool

ProgramCleared reports if the "program" edge to the Program entity was cleared.

func (*InitiativeMutation) ProgramID

func (m *InitiativeMutation) ProgramID() (id string, exists bool)

ProgramID returns the "program" edge ID in the mutation.

func (*InitiativeMutation) ProgramIDs

func (m *InitiativeMutation) ProgramIDs() (ids []string)

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

func (*InitiativeMutation) ReleasedAt

func (m *InitiativeMutation) ReleasedAt() (r time.Time, exists bool)

ReleasedAt returns the value of the "released_at" field in the mutation.

func (*InitiativeMutation) ReleasedAtCleared

func (m *InitiativeMutation) ReleasedAtCleared() bool

ReleasedAtCleared returns if the "released_at" field was cleared in this mutation.

func (*InitiativeMutation) RemovePhaseIDs

func (m *InitiativeMutation) RemovePhaseIDs(ids ...string)

RemovePhaseIDs removes the "phases" edge to the Phase entity by IDs.

func (*InitiativeMutation) RemoveRoadmapItemIDs

func (m *InitiativeMutation) RemoveRoadmapItemIDs(ids ...string)

RemoveRoadmapItemIDs removes the "roadmap_items" edge to the RoadmapItem entity by IDs.

func (*InitiativeMutation) RemovedEdges

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

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

func (*InitiativeMutation) RemovedIDs

func (m *InitiativeMutation) 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 (*InitiativeMutation) RemovedPhasesIDs

func (m *InitiativeMutation) RemovedPhasesIDs() (ids []string)

RemovedPhases returns the removed IDs of the "phases" edge to the Phase entity.

func (*InitiativeMutation) RemovedRoadmapItemsIDs

func (m *InitiativeMutation) RemovedRoadmapItemsIDs() (ids []string)

RemovedRoadmapItems returns the removed IDs of the "roadmap_items" edge to the RoadmapItem entity.

func (*InitiativeMutation) ResetClosedAt

func (m *InitiativeMutation) ResetClosedAt()

ResetClosedAt resets all changes to the "closed_at" field.

func (*InitiativeMutation) ResetCreatedAt

func (m *InitiativeMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*InitiativeMutation) ResetDeliveryCompleteAt

func (m *InitiativeMutation) ResetDeliveryCompleteAt()

ResetDeliveryCompleteAt resets all changes to the "delivery_complete_at" field.

func (*InitiativeMutation) ResetDescription

func (m *InitiativeMutation) ResetDescription()

ResetDescription resets all changes to the "description" field.

func (*InitiativeMutation) ResetEdge

func (m *InitiativeMutation) 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 (*InitiativeMutation) ResetExecutingAt

func (m *InitiativeMutation) ResetExecutingAt()

ResetExecutingAt resets all changes to the "executing_at" field.

func (*InitiativeMutation) ResetField

func (m *InitiativeMutation) 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 (*InitiativeMutation) ResetHomeRepo

func (m *InitiativeMutation) ResetHomeRepo()

ResetHomeRepo resets all changes to the "home_repo" field.

func (*InitiativeMutation) ResetInitType

func (m *InitiativeMutation) ResetInitType()

ResetInitType resets all changes to the "init_type" field.

func (*InitiativeMutation) ResetOrganization

func (m *InitiativeMutation) ResetOrganization()

ResetOrganization resets all changes to the "organization" field.

func (*InitiativeMutation) ResetPhases

func (m *InitiativeMutation) ResetPhases()

ResetPhases resets all changes to the "phases" edge.

func (*InitiativeMutation) ResetPlannedAt

func (m *InitiativeMutation) ResetPlannedAt()

ResetPlannedAt resets all changes to the "planned_at" field.

func (*InitiativeMutation) ResetPriority

func (m *InitiativeMutation) ResetPriority()

ResetPriority resets all changes to the "priority" field.

func (*InitiativeMutation) ResetProgram

func (m *InitiativeMutation) ResetProgram()

ResetProgram resets all changes to the "program" edge.

func (*InitiativeMutation) ResetReleasedAt

func (m *InitiativeMutation) ResetReleasedAt()

ResetReleasedAt resets all changes to the "released_at" field.

func (*InitiativeMutation) ResetRoadmapItems

func (m *InitiativeMutation) ResetRoadmapItems()

ResetRoadmapItems resets all changes to the "roadmap_items" edge.

func (*InitiativeMutation) ResetSpecs

func (m *InitiativeMutation) ResetSpecs()

ResetSpecs resets all changes to the "specs" field.

func (*InitiativeMutation) ResetStatus

func (m *InitiativeMutation) ResetStatus()

ResetStatus resets all changes to the "status" field.

func (*InitiativeMutation) ResetTitle

func (m *InitiativeMutation) ResetTitle()

ResetTitle resets all changes to the "title" field.

func (*InitiativeMutation) ResetUpdatedAt

func (m *InitiativeMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*InitiativeMutation) ResetWorkflow

func (m *InitiativeMutation) ResetWorkflow()

ResetWorkflow resets all changes to the "workflow" edge.

func (*InitiativeMutation) ResetWorkspace

func (m *InitiativeMutation) ResetWorkspace()

ResetWorkspace resets all changes to the "workspace" field.

func (*InitiativeMutation) RoadmapItemsCleared

func (m *InitiativeMutation) RoadmapItemsCleared() bool

RoadmapItemsCleared reports if the "roadmap_items" edge to the RoadmapItem entity was cleared.

func (*InitiativeMutation) RoadmapItemsIDs

func (m *InitiativeMutation) RoadmapItemsIDs() (ids []string)

RoadmapItemsIDs returns the "roadmap_items" edge IDs in the mutation.

func (*InitiativeMutation) SetClosedAt

func (m *InitiativeMutation) SetClosedAt(t time.Time)

SetClosedAt sets the "closed_at" field.

func (*InitiativeMutation) SetCreatedAt

func (m *InitiativeMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*InitiativeMutation) SetDeliveryCompleteAt

func (m *InitiativeMutation) SetDeliveryCompleteAt(t time.Time)

SetDeliveryCompleteAt sets the "delivery_complete_at" field.

func (*InitiativeMutation) SetDescription

func (m *InitiativeMutation) SetDescription(s string)

SetDescription sets the "description" field.

func (*InitiativeMutation) SetExecutingAt

func (m *InitiativeMutation) SetExecutingAt(t time.Time)

SetExecutingAt sets the "executing_at" field.

func (*InitiativeMutation) SetField

func (m *InitiativeMutation) 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 (*InitiativeMutation) SetHomeRepo

func (m *InitiativeMutation) SetHomeRepo(s string)

SetHomeRepo sets the "home_repo" field.

func (*InitiativeMutation) SetID

func (m *InitiativeMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of Initiative entities.

func (*InitiativeMutation) SetInitType

func (m *InitiativeMutation) SetInitType(s string)

SetInitType sets the "init_type" field.

func (*InitiativeMutation) SetOp

func (m *InitiativeMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*InitiativeMutation) SetOrganization

func (m *InitiativeMutation) SetOrganization(s string)

SetOrganization sets the "organization" field.

func (*InitiativeMutation) SetPlannedAt

func (m *InitiativeMutation) SetPlannedAt(t time.Time)

SetPlannedAt sets the "planned_at" field.

func (*InitiativeMutation) SetPriority

func (m *InitiativeMutation) SetPriority(s string)

SetPriority sets the "priority" field.

func (*InitiativeMutation) SetProgramID

func (m *InitiativeMutation) SetProgramID(id string)

SetProgramID sets the "program" edge to the Program entity by id.

func (*InitiativeMutation) SetReleasedAt

func (m *InitiativeMutation) SetReleasedAt(t time.Time)

SetReleasedAt sets the "released_at" field.

func (*InitiativeMutation) SetSpecs

func (m *InitiativeMutation) SetSpecs(value map[string]string)

SetSpecs sets the "specs" field.

func (*InitiativeMutation) SetStatus

func (m *InitiativeMutation) SetStatus(s string)

SetStatus sets the "status" field.

func (*InitiativeMutation) SetTitle

func (m *InitiativeMutation) SetTitle(s string)

SetTitle sets the "title" field.

func (*InitiativeMutation) SetUpdatedAt

func (m *InitiativeMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (*InitiativeMutation) SetWorkflowID

func (m *InitiativeMutation) SetWorkflowID(id string)

SetWorkflowID sets the "workflow" edge to the SpecWorkflow entity by id.

func (*InitiativeMutation) SetWorkspace

func (m *InitiativeMutation) SetWorkspace(s string)

SetWorkspace sets the "workspace" field.

func (*InitiativeMutation) Specs

func (m *InitiativeMutation) Specs() (r map[string]string, exists bool)

Specs returns the value of the "specs" field in the mutation.

func (*InitiativeMutation) SpecsCleared

func (m *InitiativeMutation) SpecsCleared() bool

SpecsCleared returns if the "specs" field was cleared in this mutation.

func (*InitiativeMutation) Status

func (m *InitiativeMutation) Status() (r string, exists bool)

Status returns the value of the "status" field in the mutation.

func (*InitiativeMutation) Title

func (m *InitiativeMutation) Title() (r string, exists bool)

Title returns the value of the "title" field in the mutation.

func (InitiativeMutation) Tx

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

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

func (*InitiativeMutation) Type

func (m *InitiativeMutation) Type() string

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

func (*InitiativeMutation) UpdatedAt

func (m *InitiativeMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*InitiativeMutation) Where

func (m *InitiativeMutation) Where(ps ...predicate.Initiative)

Where appends a list predicates to the InitiativeMutation builder.

func (*InitiativeMutation) WhereP

func (m *InitiativeMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the InitiativeMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

func (*InitiativeMutation) WorkflowCleared

func (m *InitiativeMutation) WorkflowCleared() bool

WorkflowCleared reports if the "workflow" edge to the SpecWorkflow entity was cleared.

func (*InitiativeMutation) WorkflowID

func (m *InitiativeMutation) WorkflowID() (id string, exists bool)

WorkflowID returns the "workflow" edge ID in the mutation.

func (*InitiativeMutation) WorkflowIDs

func (m *InitiativeMutation) WorkflowIDs() (ids []string)

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

func (*InitiativeMutation) Workspace

func (m *InitiativeMutation) Workspace() (r string, exists bool)

Workspace returns the value of the "workspace" field in the mutation.

func (*InitiativeMutation) WorkspaceCleared

func (m *InitiativeMutation) WorkspaceCleared() bool

WorkspaceCleared returns if the "workspace" field was cleared in this mutation.

type InitiativeQuery

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

InitiativeQuery is the builder for querying Initiative entities.

func (*InitiativeQuery) Aggregate

func (_q *InitiativeQuery) Aggregate(fns ...AggregateFunc) *InitiativeSelect

Aggregate returns a InitiativeSelect configured with the given aggregations.

func (*InitiativeQuery) All

func (_q *InitiativeQuery) All(ctx context.Context) ([]*Initiative, error)

All executes the query and returns a list of Initiatives.

func (*InitiativeQuery) AllX

func (_q *InitiativeQuery) AllX(ctx context.Context) []*Initiative

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

func (*InitiativeQuery) Clone

func (_q *InitiativeQuery) Clone() *InitiativeQuery

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

func (*InitiativeQuery) Count

func (_q *InitiativeQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*InitiativeQuery) CountX

func (_q *InitiativeQuery) CountX(ctx context.Context) int

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

func (*InitiativeQuery) Exist

func (_q *InitiativeQuery) Exist(ctx context.Context) (bool, error)

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

func (*InitiativeQuery) ExistX

func (_q *InitiativeQuery) ExistX(ctx context.Context) bool

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

func (*InitiativeQuery) First

func (_q *InitiativeQuery) First(ctx context.Context) (*Initiative, error)

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

func (*InitiativeQuery) FirstID

func (_q *InitiativeQuery) FirstID(ctx context.Context) (id string, err error)

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

func (*InitiativeQuery) FirstIDX

func (_q *InitiativeQuery) FirstIDX(ctx context.Context) string

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

func (*InitiativeQuery) FirstX

func (_q *InitiativeQuery) FirstX(ctx context.Context) *Initiative

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

func (*InitiativeQuery) GroupBy

func (_q *InitiativeQuery) GroupBy(field string, fields ...string) *InitiativeGroupBy

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 {
	Organization string `json:"organization,omitempty"`
	Count int `json:"count,omitempty"`
}

client.Initiative.Query().
	GroupBy(initiative.FieldOrganization).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*InitiativeQuery) IDs

func (_q *InitiativeQuery) IDs(ctx context.Context) (ids []string, err error)

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

func (*InitiativeQuery) IDsX

func (_q *InitiativeQuery) IDsX(ctx context.Context) []string

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

func (*InitiativeQuery) Limit

func (_q *InitiativeQuery) Limit(limit int) *InitiativeQuery

Limit the number of records to be returned by this query.

func (*InitiativeQuery) Offset

func (_q *InitiativeQuery) Offset(offset int) *InitiativeQuery

Offset to start from.

func (*InitiativeQuery) Only

func (_q *InitiativeQuery) Only(ctx context.Context) (*Initiative, error)

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

func (*InitiativeQuery) OnlyID

func (_q *InitiativeQuery) OnlyID(ctx context.Context) (id string, err error)

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

func (*InitiativeQuery) OnlyIDX

func (_q *InitiativeQuery) OnlyIDX(ctx context.Context) string

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

func (*InitiativeQuery) OnlyX

func (_q *InitiativeQuery) OnlyX(ctx context.Context) *Initiative

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

func (*InitiativeQuery) Order

Order specifies how the records should be ordered.

func (*InitiativeQuery) QueryPhases

func (_q *InitiativeQuery) QueryPhases() *PhaseQuery

QueryPhases chains the current query on the "phases" edge.

func (*InitiativeQuery) QueryProgram

func (_q *InitiativeQuery) QueryProgram() *ProgramQuery

QueryProgram chains the current query on the "program" edge.

func (*InitiativeQuery) QueryRoadmapItems

func (_q *InitiativeQuery) QueryRoadmapItems() *RoadmapItemQuery

QueryRoadmapItems chains the current query on the "roadmap_items" edge.

func (*InitiativeQuery) QueryWorkflow

func (_q *InitiativeQuery) QueryWorkflow() *SpecWorkflowQuery

QueryWorkflow chains the current query on the "workflow" edge.

func (*InitiativeQuery) Select

func (_q *InitiativeQuery) Select(fields ...string) *InitiativeSelect

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 {
	Organization string `json:"organization,omitempty"`
}

client.Initiative.Query().
	Select(initiative.FieldOrganization).
	Scan(ctx, &v)

func (*InitiativeQuery) Unique

func (_q *InitiativeQuery) Unique(unique bool) *InitiativeQuery

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 (*InitiativeQuery) Where

Where adds a new predicate for the InitiativeQuery builder.

func (*InitiativeQuery) WithPhases

func (_q *InitiativeQuery) WithPhases(opts ...func(*PhaseQuery)) *InitiativeQuery

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

func (*InitiativeQuery) WithProgram

func (_q *InitiativeQuery) WithProgram(opts ...func(*ProgramQuery)) *InitiativeQuery

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

func (*InitiativeQuery) WithRoadmapItems

func (_q *InitiativeQuery) WithRoadmapItems(opts ...func(*RoadmapItemQuery)) *InitiativeQuery

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

func (*InitiativeQuery) WithWorkflow

func (_q *InitiativeQuery) WithWorkflow(opts ...func(*SpecWorkflowQuery)) *InitiativeQuery

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

type InitiativeSelect

type InitiativeSelect struct {
	*InitiativeQuery
	// contains filtered or unexported fields
}

InitiativeSelect is the builder for selecting fields of Initiative entities.

func (*InitiativeSelect) Aggregate

func (_s *InitiativeSelect) Aggregate(fns ...AggregateFunc) *InitiativeSelect

Aggregate adds the given aggregation functions to the selector query.

func (*InitiativeSelect) Bool

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

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

func (*InitiativeSelect) BoolX

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

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

func (*InitiativeSelect) Bools

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

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

func (*InitiativeSelect) BoolsX

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

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

func (*InitiativeSelect) Float64

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

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

func (*InitiativeSelect) Float64X

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

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

func (*InitiativeSelect) Float64s

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

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

func (*InitiativeSelect) Float64sX

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

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

func (*InitiativeSelect) Int

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

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

func (*InitiativeSelect) IntX

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

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

func (*InitiativeSelect) Ints

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

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

func (*InitiativeSelect) IntsX

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

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

func (*InitiativeSelect) Scan

func (_s *InitiativeSelect) Scan(ctx context.Context, v any) error

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

func (*InitiativeSelect) ScanX

func (s *InitiativeSelect) ScanX(ctx context.Context, v any)

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

func (*InitiativeSelect) String

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

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

func (*InitiativeSelect) StringX

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

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

func (*InitiativeSelect) Strings

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

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

func (*InitiativeSelect) StringsX

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

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

type InitiativeUpdate

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

InitiativeUpdate is the builder for updating Initiative entities.

func (*InitiativeUpdate) AddPhaseIDs

func (_u *InitiativeUpdate) AddPhaseIDs(ids ...string) *InitiativeUpdate

AddPhaseIDs adds the "phases" edge to the Phase entity by IDs.

func (*InitiativeUpdate) AddPhases

func (_u *InitiativeUpdate) AddPhases(v ...*Phase) *InitiativeUpdate

AddPhases adds the "phases" edges to the Phase entity.

func (*InitiativeUpdate) AddRoadmapItemIDs

func (_u *InitiativeUpdate) AddRoadmapItemIDs(ids ...string) *InitiativeUpdate

AddRoadmapItemIDs adds the "roadmap_items" edge to the RoadmapItem entity by IDs.

func (*InitiativeUpdate) AddRoadmapItems

func (_u *InitiativeUpdate) AddRoadmapItems(v ...*RoadmapItem) *InitiativeUpdate

AddRoadmapItems adds the "roadmap_items" edges to the RoadmapItem entity.

func (*InitiativeUpdate) ClearClosedAt

func (_u *InitiativeUpdate) ClearClosedAt() *InitiativeUpdate

ClearClosedAt clears the value of the "closed_at" field.

func (*InitiativeUpdate) ClearDeliveryCompleteAt

func (_u *InitiativeUpdate) ClearDeliveryCompleteAt() *InitiativeUpdate

ClearDeliveryCompleteAt clears the value of the "delivery_complete_at" field.

func (*InitiativeUpdate) ClearDescription

func (_u *InitiativeUpdate) ClearDescription() *InitiativeUpdate

ClearDescription clears the value of the "description" field.

func (*InitiativeUpdate) ClearExecutingAt

func (_u *InitiativeUpdate) ClearExecutingAt() *InitiativeUpdate

ClearExecutingAt clears the value of the "executing_at" field.

func (*InitiativeUpdate) ClearHomeRepo

func (_u *InitiativeUpdate) ClearHomeRepo() *InitiativeUpdate

ClearHomeRepo clears the value of the "home_repo" field.

func (*InitiativeUpdate) ClearPhases

func (_u *InitiativeUpdate) ClearPhases() *InitiativeUpdate

ClearPhases clears all "phases" edges to the Phase entity.

func (*InitiativeUpdate) ClearPlannedAt

func (_u *InitiativeUpdate) ClearPlannedAt() *InitiativeUpdate

ClearPlannedAt clears the value of the "planned_at" field.

func (*InitiativeUpdate) ClearPriority

func (_u *InitiativeUpdate) ClearPriority() *InitiativeUpdate

ClearPriority clears the value of the "priority" field.

func (*InitiativeUpdate) ClearProgram

func (_u *InitiativeUpdate) ClearProgram() *InitiativeUpdate

ClearProgram clears the "program" edge to the Program entity.

func (*InitiativeUpdate) ClearReleasedAt

func (_u *InitiativeUpdate) ClearReleasedAt() *InitiativeUpdate

ClearReleasedAt clears the value of the "released_at" field.

func (*InitiativeUpdate) ClearRoadmapItems

func (_u *InitiativeUpdate) ClearRoadmapItems() *InitiativeUpdate

ClearRoadmapItems clears all "roadmap_items" edges to the RoadmapItem entity.

func (*InitiativeUpdate) ClearSpecs

func (_u *InitiativeUpdate) ClearSpecs() *InitiativeUpdate

ClearSpecs clears the value of the "specs" field.

func (*InitiativeUpdate) ClearWorkflow

func (_u *InitiativeUpdate) ClearWorkflow() *InitiativeUpdate

ClearWorkflow clears the "workflow" edge to the SpecWorkflow entity.

func (*InitiativeUpdate) ClearWorkspace

func (_u *InitiativeUpdate) ClearWorkspace() *InitiativeUpdate

ClearWorkspace clears the value of the "workspace" field.

func (*InitiativeUpdate) Exec

func (_u *InitiativeUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*InitiativeUpdate) ExecX

func (_u *InitiativeUpdate) ExecX(ctx context.Context)

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

func (*InitiativeUpdate) Mutation

func (_u *InitiativeUpdate) Mutation() *InitiativeMutation

Mutation returns the InitiativeMutation object of the builder.

func (*InitiativeUpdate) RemovePhaseIDs

func (_u *InitiativeUpdate) RemovePhaseIDs(ids ...string) *InitiativeUpdate

RemovePhaseIDs removes the "phases" edge to Phase entities by IDs.

func (*InitiativeUpdate) RemovePhases

func (_u *InitiativeUpdate) RemovePhases(v ...*Phase) *InitiativeUpdate

RemovePhases removes "phases" edges to Phase entities.

func (*InitiativeUpdate) RemoveRoadmapItemIDs

func (_u *InitiativeUpdate) RemoveRoadmapItemIDs(ids ...string) *InitiativeUpdate

RemoveRoadmapItemIDs removes the "roadmap_items" edge to RoadmapItem entities by IDs.

func (*InitiativeUpdate) RemoveRoadmapItems

func (_u *InitiativeUpdate) RemoveRoadmapItems(v ...*RoadmapItem) *InitiativeUpdate

RemoveRoadmapItems removes "roadmap_items" edges to RoadmapItem entities.

func (*InitiativeUpdate) Save

func (_u *InitiativeUpdate) Save(ctx context.Context) (int, error)

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

func (*InitiativeUpdate) SaveX

func (_u *InitiativeUpdate) SaveX(ctx context.Context) int

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

func (*InitiativeUpdate) SetClosedAt

func (_u *InitiativeUpdate) SetClosedAt(v time.Time) *InitiativeUpdate

SetClosedAt sets the "closed_at" field.

func (*InitiativeUpdate) SetCreatedAt

func (_u *InitiativeUpdate) SetCreatedAt(v time.Time) *InitiativeUpdate

SetCreatedAt sets the "created_at" field.

func (*InitiativeUpdate) SetDeliveryCompleteAt

func (_u *InitiativeUpdate) SetDeliveryCompleteAt(v time.Time) *InitiativeUpdate

SetDeliveryCompleteAt sets the "delivery_complete_at" field.

func (*InitiativeUpdate) SetDescription

func (_u *InitiativeUpdate) SetDescription(v string) *InitiativeUpdate

SetDescription sets the "description" field.

func (*InitiativeUpdate) SetExecutingAt

func (_u *InitiativeUpdate) SetExecutingAt(v time.Time) *InitiativeUpdate

SetExecutingAt sets the "executing_at" field.

func (*InitiativeUpdate) SetHomeRepo

func (_u *InitiativeUpdate) SetHomeRepo(v string) *InitiativeUpdate

SetHomeRepo sets the "home_repo" field.

func (*InitiativeUpdate) SetInitType

func (_u *InitiativeUpdate) SetInitType(v string) *InitiativeUpdate

SetInitType sets the "init_type" field.

func (*InitiativeUpdate) SetNillableClosedAt

func (_u *InitiativeUpdate) SetNillableClosedAt(v *time.Time) *InitiativeUpdate

SetNillableClosedAt sets the "closed_at" field if the given value is not nil.

func (*InitiativeUpdate) SetNillableCreatedAt

func (_u *InitiativeUpdate) SetNillableCreatedAt(v *time.Time) *InitiativeUpdate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*InitiativeUpdate) SetNillableDeliveryCompleteAt

func (_u *InitiativeUpdate) SetNillableDeliveryCompleteAt(v *time.Time) *InitiativeUpdate

SetNillableDeliveryCompleteAt sets the "delivery_complete_at" field if the given value is not nil.

func (*InitiativeUpdate) SetNillableDescription

func (_u *InitiativeUpdate) SetNillableDescription(v *string) *InitiativeUpdate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*InitiativeUpdate) SetNillableExecutingAt

func (_u *InitiativeUpdate) SetNillableExecutingAt(v *time.Time) *InitiativeUpdate

SetNillableExecutingAt sets the "executing_at" field if the given value is not nil.

func (*InitiativeUpdate) SetNillableHomeRepo

func (_u *InitiativeUpdate) SetNillableHomeRepo(v *string) *InitiativeUpdate

SetNillableHomeRepo sets the "home_repo" field if the given value is not nil.

func (*InitiativeUpdate) SetNillableInitType

func (_u *InitiativeUpdate) SetNillableInitType(v *string) *InitiativeUpdate

SetNillableInitType sets the "init_type" field if the given value is not nil.

func (*InitiativeUpdate) SetNillableOrganization

func (_u *InitiativeUpdate) SetNillableOrganization(v *string) *InitiativeUpdate

SetNillableOrganization sets the "organization" field if the given value is not nil.

func (*InitiativeUpdate) SetNillablePlannedAt

func (_u *InitiativeUpdate) SetNillablePlannedAt(v *time.Time) *InitiativeUpdate

SetNillablePlannedAt sets the "planned_at" field if the given value is not nil.

func (*InitiativeUpdate) SetNillablePriority

func (_u *InitiativeUpdate) SetNillablePriority(v *string) *InitiativeUpdate

SetNillablePriority sets the "priority" field if the given value is not nil.

func (*InitiativeUpdate) SetNillableProgramID

func (_u *InitiativeUpdate) SetNillableProgramID(id *string) *InitiativeUpdate

SetNillableProgramID sets the "program" edge to the Program entity by ID if the given value is not nil.

func (*InitiativeUpdate) SetNillableReleasedAt

func (_u *InitiativeUpdate) SetNillableReleasedAt(v *time.Time) *InitiativeUpdate

SetNillableReleasedAt sets the "released_at" field if the given value is not nil.

func (*InitiativeUpdate) SetNillableStatus

func (_u *InitiativeUpdate) SetNillableStatus(v *string) *InitiativeUpdate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*InitiativeUpdate) SetNillableTitle

func (_u *InitiativeUpdate) SetNillableTitle(v *string) *InitiativeUpdate

SetNillableTitle sets the "title" field if the given value is not nil.

func (*InitiativeUpdate) SetNillableUpdatedAt

func (_u *InitiativeUpdate) SetNillableUpdatedAt(v *time.Time) *InitiativeUpdate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*InitiativeUpdate) SetNillableWorkflowID

func (_u *InitiativeUpdate) SetNillableWorkflowID(id *string) *InitiativeUpdate

SetNillableWorkflowID sets the "workflow" edge to the SpecWorkflow entity by ID if the given value is not nil.

func (*InitiativeUpdate) SetNillableWorkspace

func (_u *InitiativeUpdate) SetNillableWorkspace(v *string) *InitiativeUpdate

SetNillableWorkspace sets the "workspace" field if the given value is not nil.

func (*InitiativeUpdate) SetOrganization

func (_u *InitiativeUpdate) SetOrganization(v string) *InitiativeUpdate

SetOrganization sets the "organization" field.

func (*InitiativeUpdate) SetPlannedAt

func (_u *InitiativeUpdate) SetPlannedAt(v time.Time) *InitiativeUpdate

SetPlannedAt sets the "planned_at" field.

func (*InitiativeUpdate) SetPriority

func (_u *InitiativeUpdate) SetPriority(v string) *InitiativeUpdate

SetPriority sets the "priority" field.

func (*InitiativeUpdate) SetProgram

func (_u *InitiativeUpdate) SetProgram(v *Program) *InitiativeUpdate

SetProgram sets the "program" edge to the Program entity.

func (*InitiativeUpdate) SetProgramID

func (_u *InitiativeUpdate) SetProgramID(id string) *InitiativeUpdate

SetProgramID sets the "program" edge to the Program entity by ID.

func (*InitiativeUpdate) SetReleasedAt

func (_u *InitiativeUpdate) SetReleasedAt(v time.Time) *InitiativeUpdate

SetReleasedAt sets the "released_at" field.

func (*InitiativeUpdate) SetSpecs

func (_u *InitiativeUpdate) SetSpecs(v map[string]string) *InitiativeUpdate

SetSpecs sets the "specs" field.

func (*InitiativeUpdate) SetStatus

func (_u *InitiativeUpdate) SetStatus(v string) *InitiativeUpdate

SetStatus sets the "status" field.

func (*InitiativeUpdate) SetTitle

func (_u *InitiativeUpdate) SetTitle(v string) *InitiativeUpdate

SetTitle sets the "title" field.

func (*InitiativeUpdate) SetUpdatedAt

func (_u *InitiativeUpdate) SetUpdatedAt(v time.Time) *InitiativeUpdate

SetUpdatedAt sets the "updated_at" field.

func (*InitiativeUpdate) SetWorkflow

func (_u *InitiativeUpdate) SetWorkflow(v *SpecWorkflow) *InitiativeUpdate

SetWorkflow sets the "workflow" edge to the SpecWorkflow entity.

func (*InitiativeUpdate) SetWorkflowID

func (_u *InitiativeUpdate) SetWorkflowID(id string) *InitiativeUpdate

SetWorkflowID sets the "workflow" edge to the SpecWorkflow entity by ID.

func (*InitiativeUpdate) SetWorkspace

func (_u *InitiativeUpdate) SetWorkspace(v string) *InitiativeUpdate

SetWorkspace sets the "workspace" field.

func (*InitiativeUpdate) Where

Where appends a list predicates to the InitiativeUpdate builder.

type InitiativeUpdateOne

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

InitiativeUpdateOne is the builder for updating a single Initiative entity.

func (*InitiativeUpdateOne) AddPhaseIDs

func (_u *InitiativeUpdateOne) AddPhaseIDs(ids ...string) *InitiativeUpdateOne

AddPhaseIDs adds the "phases" edge to the Phase entity by IDs.

func (*InitiativeUpdateOne) AddPhases

func (_u *InitiativeUpdateOne) AddPhases(v ...*Phase) *InitiativeUpdateOne

AddPhases adds the "phases" edges to the Phase entity.

func (*InitiativeUpdateOne) AddRoadmapItemIDs

func (_u *InitiativeUpdateOne) AddRoadmapItemIDs(ids ...string) *InitiativeUpdateOne

AddRoadmapItemIDs adds the "roadmap_items" edge to the RoadmapItem entity by IDs.

func (*InitiativeUpdateOne) AddRoadmapItems

func (_u *InitiativeUpdateOne) AddRoadmapItems(v ...*RoadmapItem) *InitiativeUpdateOne

AddRoadmapItems adds the "roadmap_items" edges to the RoadmapItem entity.

func (*InitiativeUpdateOne) ClearClosedAt

func (_u *InitiativeUpdateOne) ClearClosedAt() *InitiativeUpdateOne

ClearClosedAt clears the value of the "closed_at" field.

func (*InitiativeUpdateOne) ClearDeliveryCompleteAt

func (_u *InitiativeUpdateOne) ClearDeliveryCompleteAt() *InitiativeUpdateOne

ClearDeliveryCompleteAt clears the value of the "delivery_complete_at" field.

func (*InitiativeUpdateOne) ClearDescription

func (_u *InitiativeUpdateOne) ClearDescription() *InitiativeUpdateOne

ClearDescription clears the value of the "description" field.

func (*InitiativeUpdateOne) ClearExecutingAt

func (_u *InitiativeUpdateOne) ClearExecutingAt() *InitiativeUpdateOne

ClearExecutingAt clears the value of the "executing_at" field.

func (*InitiativeUpdateOne) ClearHomeRepo

func (_u *InitiativeUpdateOne) ClearHomeRepo() *InitiativeUpdateOne

ClearHomeRepo clears the value of the "home_repo" field.

func (*InitiativeUpdateOne) ClearPhases

func (_u *InitiativeUpdateOne) ClearPhases() *InitiativeUpdateOne

ClearPhases clears all "phases" edges to the Phase entity.

func (*InitiativeUpdateOne) ClearPlannedAt

func (_u *InitiativeUpdateOne) ClearPlannedAt() *InitiativeUpdateOne

ClearPlannedAt clears the value of the "planned_at" field.

func (*InitiativeUpdateOne) ClearPriority

func (_u *InitiativeUpdateOne) ClearPriority() *InitiativeUpdateOne

ClearPriority clears the value of the "priority" field.

func (*InitiativeUpdateOne) ClearProgram

func (_u *InitiativeUpdateOne) ClearProgram() *InitiativeUpdateOne

ClearProgram clears the "program" edge to the Program entity.

func (*InitiativeUpdateOne) ClearReleasedAt

func (_u *InitiativeUpdateOne) ClearReleasedAt() *InitiativeUpdateOne

ClearReleasedAt clears the value of the "released_at" field.

func (*InitiativeUpdateOne) ClearRoadmapItems

func (_u *InitiativeUpdateOne) ClearRoadmapItems() *InitiativeUpdateOne

ClearRoadmapItems clears all "roadmap_items" edges to the RoadmapItem entity.

func (*InitiativeUpdateOne) ClearSpecs

func (_u *InitiativeUpdateOne) ClearSpecs() *InitiativeUpdateOne

ClearSpecs clears the value of the "specs" field.

func (*InitiativeUpdateOne) ClearWorkflow

func (_u *InitiativeUpdateOne) ClearWorkflow() *InitiativeUpdateOne

ClearWorkflow clears the "workflow" edge to the SpecWorkflow entity.

func (*InitiativeUpdateOne) ClearWorkspace

func (_u *InitiativeUpdateOne) ClearWorkspace() *InitiativeUpdateOne

ClearWorkspace clears the value of the "workspace" field.

func (*InitiativeUpdateOne) Exec

func (_u *InitiativeUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*InitiativeUpdateOne) ExecX

func (_u *InitiativeUpdateOne) ExecX(ctx context.Context)

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

func (*InitiativeUpdateOne) Mutation

func (_u *InitiativeUpdateOne) Mutation() *InitiativeMutation

Mutation returns the InitiativeMutation object of the builder.

func (*InitiativeUpdateOne) RemovePhaseIDs

func (_u *InitiativeUpdateOne) RemovePhaseIDs(ids ...string) *InitiativeUpdateOne

RemovePhaseIDs removes the "phases" edge to Phase entities by IDs.

func (*InitiativeUpdateOne) RemovePhases

func (_u *InitiativeUpdateOne) RemovePhases(v ...*Phase) *InitiativeUpdateOne

RemovePhases removes "phases" edges to Phase entities.

func (*InitiativeUpdateOne) RemoveRoadmapItemIDs

func (_u *InitiativeUpdateOne) RemoveRoadmapItemIDs(ids ...string) *InitiativeUpdateOne

RemoveRoadmapItemIDs removes the "roadmap_items" edge to RoadmapItem entities by IDs.

func (*InitiativeUpdateOne) RemoveRoadmapItems

func (_u *InitiativeUpdateOne) RemoveRoadmapItems(v ...*RoadmapItem) *InitiativeUpdateOne

RemoveRoadmapItems removes "roadmap_items" edges to RoadmapItem entities.

func (*InitiativeUpdateOne) Save

Save executes the query and returns the updated Initiative entity.

func (*InitiativeUpdateOne) SaveX

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

func (*InitiativeUpdateOne) Select

func (_u *InitiativeUpdateOne) Select(field string, fields ...string) *InitiativeUpdateOne

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

func (*InitiativeUpdateOne) SetClosedAt

func (_u *InitiativeUpdateOne) SetClosedAt(v time.Time) *InitiativeUpdateOne

SetClosedAt sets the "closed_at" field.

func (*InitiativeUpdateOne) SetCreatedAt

func (_u *InitiativeUpdateOne) SetCreatedAt(v time.Time) *InitiativeUpdateOne

SetCreatedAt sets the "created_at" field.

func (*InitiativeUpdateOne) SetDeliveryCompleteAt

func (_u *InitiativeUpdateOne) SetDeliveryCompleteAt(v time.Time) *InitiativeUpdateOne

SetDeliveryCompleteAt sets the "delivery_complete_at" field.

func (*InitiativeUpdateOne) SetDescription

func (_u *InitiativeUpdateOne) SetDescription(v string) *InitiativeUpdateOne

SetDescription sets the "description" field.

func (*InitiativeUpdateOne) SetExecutingAt

func (_u *InitiativeUpdateOne) SetExecutingAt(v time.Time) *InitiativeUpdateOne

SetExecutingAt sets the "executing_at" field.

func (*InitiativeUpdateOne) SetHomeRepo

func (_u *InitiativeUpdateOne) SetHomeRepo(v string) *InitiativeUpdateOne

SetHomeRepo sets the "home_repo" field.

func (*InitiativeUpdateOne) SetInitType

func (_u *InitiativeUpdateOne) SetInitType(v string) *InitiativeUpdateOne

SetInitType sets the "init_type" field.

func (*InitiativeUpdateOne) SetNillableClosedAt

func (_u *InitiativeUpdateOne) SetNillableClosedAt(v *time.Time) *InitiativeUpdateOne

SetNillableClosedAt sets the "closed_at" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableCreatedAt

func (_u *InitiativeUpdateOne) SetNillableCreatedAt(v *time.Time) *InitiativeUpdateOne

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableDeliveryCompleteAt

func (_u *InitiativeUpdateOne) SetNillableDeliveryCompleteAt(v *time.Time) *InitiativeUpdateOne

SetNillableDeliveryCompleteAt sets the "delivery_complete_at" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableDescription

func (_u *InitiativeUpdateOne) SetNillableDescription(v *string) *InitiativeUpdateOne

SetNillableDescription sets the "description" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableExecutingAt

func (_u *InitiativeUpdateOne) SetNillableExecutingAt(v *time.Time) *InitiativeUpdateOne

SetNillableExecutingAt sets the "executing_at" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableHomeRepo

func (_u *InitiativeUpdateOne) SetNillableHomeRepo(v *string) *InitiativeUpdateOne

SetNillableHomeRepo sets the "home_repo" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableInitType

func (_u *InitiativeUpdateOne) SetNillableInitType(v *string) *InitiativeUpdateOne

SetNillableInitType sets the "init_type" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableOrganization

func (_u *InitiativeUpdateOne) SetNillableOrganization(v *string) *InitiativeUpdateOne

SetNillableOrganization sets the "organization" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillablePlannedAt

func (_u *InitiativeUpdateOne) SetNillablePlannedAt(v *time.Time) *InitiativeUpdateOne

SetNillablePlannedAt sets the "planned_at" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillablePriority

func (_u *InitiativeUpdateOne) SetNillablePriority(v *string) *InitiativeUpdateOne

SetNillablePriority sets the "priority" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableProgramID

func (_u *InitiativeUpdateOne) SetNillableProgramID(id *string) *InitiativeUpdateOne

SetNillableProgramID sets the "program" edge to the Program entity by ID if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableReleasedAt

func (_u *InitiativeUpdateOne) SetNillableReleasedAt(v *time.Time) *InitiativeUpdateOne

SetNillableReleasedAt sets the "released_at" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableStatus

func (_u *InitiativeUpdateOne) SetNillableStatus(v *string) *InitiativeUpdateOne

SetNillableStatus sets the "status" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableTitle

func (_u *InitiativeUpdateOne) SetNillableTitle(v *string) *InitiativeUpdateOne

SetNillableTitle sets the "title" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableUpdatedAt

func (_u *InitiativeUpdateOne) SetNillableUpdatedAt(v *time.Time) *InitiativeUpdateOne

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableWorkflowID

func (_u *InitiativeUpdateOne) SetNillableWorkflowID(id *string) *InitiativeUpdateOne

SetNillableWorkflowID sets the "workflow" edge to the SpecWorkflow entity by ID if the given value is not nil.

func (*InitiativeUpdateOne) SetNillableWorkspace

func (_u *InitiativeUpdateOne) SetNillableWorkspace(v *string) *InitiativeUpdateOne

SetNillableWorkspace sets the "workspace" field if the given value is not nil.

func (*InitiativeUpdateOne) SetOrganization

func (_u *InitiativeUpdateOne) SetOrganization(v string) *InitiativeUpdateOne

SetOrganization sets the "organization" field.

func (*InitiativeUpdateOne) SetPlannedAt

func (_u *InitiativeUpdateOne) SetPlannedAt(v time.Time) *InitiativeUpdateOne

SetPlannedAt sets the "planned_at" field.

func (*InitiativeUpdateOne) SetPriority

func (_u *InitiativeUpdateOne) SetPriority(v string) *InitiativeUpdateOne

SetPriority sets the "priority" field.

func (*InitiativeUpdateOne) SetProgram

func (_u *InitiativeUpdateOne) SetProgram(v *Program) *InitiativeUpdateOne

SetProgram sets the "program" edge to the Program entity.

func (*InitiativeUpdateOne) SetProgramID

func (_u *InitiativeUpdateOne) SetProgramID(id string) *InitiativeUpdateOne

SetProgramID sets the "program" edge to the Program entity by ID.

func (*InitiativeUpdateOne) SetReleasedAt

func (_u *InitiativeUpdateOne) SetReleasedAt(v time.Time) *InitiativeUpdateOne

SetReleasedAt sets the "released_at" field.

func (*InitiativeUpdateOne) SetSpecs

SetSpecs sets the "specs" field.

func (*InitiativeUpdateOne) SetStatus

SetStatus sets the "status" field.

func (*InitiativeUpdateOne) SetTitle

SetTitle sets the "title" field.

func (*InitiativeUpdateOne) SetUpdatedAt

func (_u *InitiativeUpdateOne) SetUpdatedAt(v time.Time) *InitiativeUpdateOne

SetUpdatedAt sets the "updated_at" field.

func (*InitiativeUpdateOne) SetWorkflow

SetWorkflow sets the "workflow" edge to the SpecWorkflow entity.

func (*InitiativeUpdateOne) SetWorkflowID

func (_u *InitiativeUpdateOne) SetWorkflowID(id string) *InitiativeUpdateOne

SetWorkflowID sets the "workflow" edge to the SpecWorkflow entity by ID.

func (*InitiativeUpdateOne) SetWorkspace

func (_u *InitiativeUpdateOne) SetWorkspace(v string) *InitiativeUpdateOne

SetWorkspace sets the "workspace" field.

func (*InitiativeUpdateOne) Where

Where appends a list predicates to the InitiativeUpdate builder.

type Initiatives

type Initiatives []*Initiative

Initiatives is a parsable slice of Initiative.

type InterceptFunc

type InterceptFunc = ent.InterceptFunc

ent aliases to avoid import conflicts in user's code.

type Interceptor

type Interceptor = ent.Interceptor

ent aliases to avoid import conflicts in user's code.

type JudgeResult

type JudgeResult struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// InitiativeID holds the value of the "initiative_id" field.
	InitiativeID string `json:"initiative_id,omitempty"`
	// SpecPath holds the value of the "spec_path" field.
	SpecPath string `json:"spec_path,omitempty"`
	// Score holds the value of the "score" field.
	Score float64 `json:"score,omitempty"`
	// Rationale holds the value of the "rationale" field.
	Rationale string `json:"rationale,omitempty"`
	// Model holds the value of the "model" field.
	Model string `json:"model,omitempty"`
	// EvaluatedAt holds the value of the "evaluated_at" field.
	EvaluatedAt time.Time `json:"evaluated_at,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the JudgeResultQuery when eager-loading is set.
	Edges JudgeResultEdges `json:"edges"`
	// contains filtered or unexported fields
}

JudgeResult is the model entity for the JudgeResult schema.

func (*JudgeResult) QueryRubric

func (_m *JudgeResult) QueryRubric() *JudgeRubricQuery

QueryRubric queries the "rubric" edge of the JudgeResult entity.

func (*JudgeResult) String

func (_m *JudgeResult) String() string

String implements the fmt.Stringer.

func (*JudgeResult) Unwrap

func (_m *JudgeResult) Unwrap() *JudgeResult

Unwrap unwraps the JudgeResult 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 (*JudgeResult) Update

func (_m *JudgeResult) Update() *JudgeResultUpdateOne

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

func (*JudgeResult) Value

func (_m *JudgeResult) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the JudgeResult. This includes values selected through modifiers, order, etc.

type JudgeResultClient

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

JudgeResultClient is a client for the JudgeResult schema.

func NewJudgeResultClient

func NewJudgeResultClient(c config) *JudgeResultClient

NewJudgeResultClient returns a client for the JudgeResult from the given config.

func (*JudgeResultClient) Create

func (c *JudgeResultClient) Create() *JudgeResultCreate

Create returns a builder for creating a JudgeResult entity.

func (*JudgeResultClient) CreateBulk

func (c *JudgeResultClient) CreateBulk(builders ...*JudgeResultCreate) *JudgeResultCreateBulk

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

func (*JudgeResultClient) Delete

func (c *JudgeResultClient) Delete() *JudgeResultDelete

Delete returns a delete builder for JudgeResult.

func (*JudgeResultClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*JudgeResultClient) DeleteOneID

func (c *JudgeResultClient) DeleteOneID(id string) *JudgeResultDeleteOne

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

func (*JudgeResultClient) Get

Get returns a JudgeResult entity by its id.

func (*JudgeResultClient) GetX

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

func (*JudgeResultClient) Hooks

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

Hooks returns the client hooks.

func (*JudgeResultClient) Intercept

func (c *JudgeResultClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `judgeresult.Intercept(f(g(h())))`.

func (*JudgeResultClient) Interceptors

func (c *JudgeResultClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*JudgeResultClient) MapCreateBulk

func (c *JudgeResultClient) MapCreateBulk(slice any, setFunc func(*JudgeResultCreate, int)) *JudgeResultCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*JudgeResultClient) Query

func (c *JudgeResultClient) Query() *JudgeResultQuery

Query returns a query builder for JudgeResult.

func (*JudgeResultClient) QueryRubric

func (c *JudgeResultClient) QueryRubric(_m *JudgeResult) *JudgeRubricQuery

QueryRubric queries the rubric edge of a JudgeResult.

func (*JudgeResultClient) Update

func (c *JudgeResultClient) Update() *JudgeResultUpdate

Update returns an update builder for JudgeResult.

func (*JudgeResultClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*JudgeResultClient) UpdateOneID

func (c *JudgeResultClient) UpdateOneID(id string) *JudgeResultUpdateOne

UpdateOneID returns an update builder for the given id.

func (*JudgeResultClient) Use

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

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

type JudgeResultCreate

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

JudgeResultCreate is the builder for creating a JudgeResult entity.

func (*JudgeResultCreate) Exec

func (_c *JudgeResultCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*JudgeResultCreate) ExecX

func (_c *JudgeResultCreate) ExecX(ctx context.Context)

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

func (*JudgeResultCreate) Mutation

func (_c *JudgeResultCreate) Mutation() *JudgeResultMutation

Mutation returns the JudgeResultMutation object of the builder.

func (*JudgeResultCreate) Save

Save creates the JudgeResult in the database.

func (*JudgeResultCreate) SaveX

func (_c *JudgeResultCreate) SaveX(ctx context.Context) *JudgeResult

SaveX calls Save and panics if Save returns an error.

func (*JudgeResultCreate) SetEvaluatedAt

func (_c *JudgeResultCreate) SetEvaluatedAt(v time.Time) *JudgeResultCreate

SetEvaluatedAt sets the "evaluated_at" field.

func (*JudgeResultCreate) SetID

SetID sets the "id" field.

func (*JudgeResultCreate) SetInitiativeID

func (_c *JudgeResultCreate) SetInitiativeID(v string) *JudgeResultCreate

SetInitiativeID sets the "initiative_id" field.

func (*JudgeResultCreate) SetModel

func (_c *JudgeResultCreate) SetModel(v string) *JudgeResultCreate

SetModel sets the "model" field.

func (*JudgeResultCreate) SetNillableModel

func (_c *JudgeResultCreate) SetNillableModel(v *string) *JudgeResultCreate

SetNillableModel sets the "model" field if the given value is not nil.

func (*JudgeResultCreate) SetNillableRationale

func (_c *JudgeResultCreate) SetNillableRationale(v *string) *JudgeResultCreate

SetNillableRationale sets the "rationale" field if the given value is not nil.

func (*JudgeResultCreate) SetNillableRubricID

func (_c *JudgeResultCreate) SetNillableRubricID(id *string) *JudgeResultCreate

SetNillableRubricID sets the "rubric" edge to the JudgeRubric entity by ID if the given value is not nil.

func (*JudgeResultCreate) SetNillableScore

func (_c *JudgeResultCreate) SetNillableScore(v *float64) *JudgeResultCreate

SetNillableScore sets the "score" field if the given value is not nil.

func (*JudgeResultCreate) SetRationale

func (_c *JudgeResultCreate) SetRationale(v string) *JudgeResultCreate

SetRationale sets the "rationale" field.

func (*JudgeResultCreate) SetRubric

func (_c *JudgeResultCreate) SetRubric(v *JudgeRubric) *JudgeResultCreate

SetRubric sets the "rubric" edge to the JudgeRubric entity.

func (*JudgeResultCreate) SetRubricID

func (_c *JudgeResultCreate) SetRubricID(id string) *JudgeResultCreate

SetRubricID sets the "rubric" edge to the JudgeRubric entity by ID.

func (*JudgeResultCreate) SetScore

func (_c *JudgeResultCreate) SetScore(v float64) *JudgeResultCreate

SetScore sets the "score" field.

func (*JudgeResultCreate) SetSpecPath

func (_c *JudgeResultCreate) SetSpecPath(v string) *JudgeResultCreate

SetSpecPath sets the "spec_path" field.

type JudgeResultCreateBulk

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

JudgeResultCreateBulk is the builder for creating many JudgeResult entities in bulk.

func (*JudgeResultCreateBulk) Exec

Exec executes the query.

func (*JudgeResultCreateBulk) ExecX

func (_c *JudgeResultCreateBulk) ExecX(ctx context.Context)

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

func (*JudgeResultCreateBulk) Save

Save creates the JudgeResult entities in the database.

func (*JudgeResultCreateBulk) SaveX

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

type JudgeResultDelete

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

JudgeResultDelete is the builder for deleting a JudgeResult entity.

func (*JudgeResultDelete) Exec

func (_d *JudgeResultDelete) Exec(ctx context.Context) (int, error)

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

func (*JudgeResultDelete) ExecX

func (_d *JudgeResultDelete) ExecX(ctx context.Context) int

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

func (*JudgeResultDelete) Where

Where appends a list predicates to the JudgeResultDelete builder.

type JudgeResultDeleteOne

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

JudgeResultDeleteOne is the builder for deleting a single JudgeResult entity.

func (*JudgeResultDeleteOne) Exec

func (_d *JudgeResultDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*JudgeResultDeleteOne) ExecX

func (_d *JudgeResultDeleteOne) ExecX(ctx context.Context)

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

func (*JudgeResultDeleteOne) Where

Where appends a list predicates to the JudgeResultDelete builder.

type JudgeResultEdges

type JudgeResultEdges struct {
	// Rubric holds the value of the rubric edge.
	Rubric *JudgeRubric `json:"rubric,omitempty"`
	// contains filtered or unexported fields
}

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

func (JudgeResultEdges) RubricOrErr

func (e JudgeResultEdges) RubricOrErr() (*JudgeRubric, error)

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

type JudgeResultGroupBy

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

JudgeResultGroupBy is the group-by builder for JudgeResult entities.

func (*JudgeResultGroupBy) Aggregate

func (_g *JudgeResultGroupBy) Aggregate(fns ...AggregateFunc) *JudgeResultGroupBy

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

func (*JudgeResultGroupBy) Bool

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

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

func (*JudgeResultGroupBy) BoolX

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

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

func (*JudgeResultGroupBy) Bools

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

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

func (*JudgeResultGroupBy) BoolsX

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

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

func (*JudgeResultGroupBy) Float64

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

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

func (*JudgeResultGroupBy) Float64X

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

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

func (*JudgeResultGroupBy) Float64s

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

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

func (*JudgeResultGroupBy) Float64sX

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

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

func (*JudgeResultGroupBy) Int

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

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

func (*JudgeResultGroupBy) IntX

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

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

func (*JudgeResultGroupBy) Ints

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

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

func (*JudgeResultGroupBy) IntsX

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

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

func (*JudgeResultGroupBy) Scan

func (_g *JudgeResultGroupBy) Scan(ctx context.Context, v any) error

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

func (*JudgeResultGroupBy) ScanX

func (s *JudgeResultGroupBy) ScanX(ctx context.Context, v any)

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

func (*JudgeResultGroupBy) String

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

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

func (*JudgeResultGroupBy) StringX

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

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

func (*JudgeResultGroupBy) Strings

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

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

func (*JudgeResultGroupBy) StringsX

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

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

type JudgeResultMutation

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

JudgeResultMutation represents an operation that mutates the JudgeResult nodes in the graph.

func (*JudgeResultMutation) AddField

func (m *JudgeResultMutation) 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 (*JudgeResultMutation) AddScore

func (m *JudgeResultMutation) AddScore(f float64)

AddScore adds f to the "score" field.

func (*JudgeResultMutation) AddedEdges

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

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

func (*JudgeResultMutation) AddedField

func (m *JudgeResultMutation) 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 (*JudgeResultMutation) AddedFields

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

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

func (*JudgeResultMutation) AddedIDs

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

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

func (*JudgeResultMutation) AddedScore

func (m *JudgeResultMutation) AddedScore() (r float64, exists bool)

AddedScore returns the value that was added to the "score" field in this mutation.

func (*JudgeResultMutation) ClearEdge

func (m *JudgeResultMutation) 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 (*JudgeResultMutation) ClearField

func (m *JudgeResultMutation) 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 (*JudgeResultMutation) ClearModel

func (m *JudgeResultMutation) ClearModel()

ClearModel clears the value of the "model" field.

func (*JudgeResultMutation) ClearRationale

func (m *JudgeResultMutation) ClearRationale()

ClearRationale clears the value of the "rationale" field.

func (*JudgeResultMutation) ClearRubric

func (m *JudgeResultMutation) ClearRubric()

ClearRubric clears the "rubric" edge to the JudgeRubric entity.

func (*JudgeResultMutation) ClearScore

func (m *JudgeResultMutation) ClearScore()

ClearScore clears the value of the "score" field.

func (*JudgeResultMutation) ClearedEdges

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

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

func (*JudgeResultMutation) ClearedFields

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

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

func (JudgeResultMutation) Client

func (m JudgeResultMutation) 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 (*JudgeResultMutation) EdgeCleared

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

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

func (*JudgeResultMutation) EvaluatedAt

func (m *JudgeResultMutation) EvaluatedAt() (r time.Time, exists bool)

EvaluatedAt returns the value of the "evaluated_at" field in the mutation.

func (*JudgeResultMutation) Field

func (m *JudgeResultMutation) 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 (*JudgeResultMutation) FieldCleared

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

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

func (*JudgeResultMutation) Fields

func (m *JudgeResultMutation) 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 (*JudgeResultMutation) ID

func (m *JudgeResultMutation) ID() (id string, 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 (*JudgeResultMutation) IDs

func (m *JudgeResultMutation) IDs(ctx context.Context) ([]string, 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 (*JudgeResultMutation) InitiativeID

func (m *JudgeResultMutation) InitiativeID() (r string, exists bool)

InitiativeID returns the value of the "initiative_id" field in the mutation.

func (*JudgeResultMutation) Model

func (m *JudgeResultMutation) Model() (r string, exists bool)

Model returns the value of the "model" field in the mutation.

func (*JudgeResultMutation) ModelCleared

func (m *JudgeResultMutation) ModelCleared() bool

ModelCleared returns if the "model" field was cleared in this mutation.

func (*JudgeResultMutation) OldEvaluatedAt

func (m *JudgeResultMutation) OldEvaluatedAt(ctx context.Context) (v time.Time, err error)

OldEvaluatedAt returns the old "evaluated_at" field's value of the JudgeResult entity. If the JudgeResult 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 (*JudgeResultMutation) OldField

func (m *JudgeResultMutation) 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 (*JudgeResultMutation) OldInitiativeID

func (m *JudgeResultMutation) OldInitiativeID(ctx context.Context) (v string, err error)

OldInitiativeID returns the old "initiative_id" field's value of the JudgeResult entity. If the JudgeResult 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 (*JudgeResultMutation) OldModel

func (m *JudgeResultMutation) OldModel(ctx context.Context) (v string, err error)

OldModel returns the old "model" field's value of the JudgeResult entity. If the JudgeResult 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 (*JudgeResultMutation) OldRationale

func (m *JudgeResultMutation) OldRationale(ctx context.Context) (v string, err error)

OldRationale returns the old "rationale" field's value of the JudgeResult entity. If the JudgeResult 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 (*JudgeResultMutation) OldScore

func (m *JudgeResultMutation) OldScore(ctx context.Context) (v float64, err error)

OldScore returns the old "score" field's value of the JudgeResult entity. If the JudgeResult 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 (*JudgeResultMutation) OldSpecPath

func (m *JudgeResultMutation) OldSpecPath(ctx context.Context) (v string, err error)

OldSpecPath returns the old "spec_path" field's value of the JudgeResult entity. If the JudgeResult 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 (*JudgeResultMutation) Op

func (m *JudgeResultMutation) Op() Op

Op returns the operation name.

func (*JudgeResultMutation) Rationale

func (m *JudgeResultMutation) Rationale() (r string, exists bool)

Rationale returns the value of the "rationale" field in the mutation.

func (*JudgeResultMutation) RationaleCleared

func (m *JudgeResultMutation) RationaleCleared() bool

RationaleCleared returns if the "rationale" field was cleared in this mutation.

func (*JudgeResultMutation) RemovedEdges

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

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

func (*JudgeResultMutation) RemovedIDs

func (m *JudgeResultMutation) 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 (*JudgeResultMutation) ResetEdge

func (m *JudgeResultMutation) 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 (*JudgeResultMutation) ResetEvaluatedAt

func (m *JudgeResultMutation) ResetEvaluatedAt()

ResetEvaluatedAt resets all changes to the "evaluated_at" field.

func (*JudgeResultMutation) ResetField

func (m *JudgeResultMutation) 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 (*JudgeResultMutation) ResetInitiativeID

func (m *JudgeResultMutation) ResetInitiativeID()

ResetInitiativeID resets all changes to the "initiative_id" field.

func (*JudgeResultMutation) ResetModel

func (m *JudgeResultMutation) ResetModel()

ResetModel resets all changes to the "model" field.

func (*JudgeResultMutation) ResetRationale

func (m *JudgeResultMutation) ResetRationale()

ResetRationale resets all changes to the "rationale" field.

func (*JudgeResultMutation) ResetRubric

func (m *JudgeResultMutation) ResetRubric()

ResetRubric resets all changes to the "rubric" edge.

func (*JudgeResultMutation) ResetScore

func (m *JudgeResultMutation) ResetScore()

ResetScore resets all changes to the "score" field.

func (*JudgeResultMutation) ResetSpecPath

func (m *JudgeResultMutation) ResetSpecPath()

ResetSpecPath resets all changes to the "spec_path" field.

func (*JudgeResultMutation) RubricCleared

func (m *JudgeResultMutation) RubricCleared() bool

RubricCleared reports if the "rubric" edge to the JudgeRubric entity was cleared.

func (*JudgeResultMutation) RubricID

func (m *JudgeResultMutation) RubricID() (id string, exists bool)

RubricID returns the "rubric" edge ID in the mutation.

func (*JudgeResultMutation) RubricIDs

func (m *JudgeResultMutation) RubricIDs() (ids []string)

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

func (*JudgeResultMutation) Score

func (m *JudgeResultMutation) Score() (r float64, exists bool)

Score returns the value of the "score" field in the mutation.

func (*JudgeResultMutation) ScoreCleared

func (m *JudgeResultMutation) ScoreCleared() bool

ScoreCleared returns if the "score" field was cleared in this mutation.

func (*JudgeResultMutation) SetEvaluatedAt

func (m *JudgeResultMutation) SetEvaluatedAt(t time.Time)

SetEvaluatedAt sets the "evaluated_at" field.

func (*JudgeResultMutation) SetField

func (m *JudgeResultMutation) 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 (*JudgeResultMutation) SetID

func (m *JudgeResultMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of JudgeResult entities.

func (*JudgeResultMutation) SetInitiativeID

func (m *JudgeResultMutation) SetInitiativeID(s string)

SetInitiativeID sets the "initiative_id" field.

func (*JudgeResultMutation) SetModel

func (m *JudgeResultMutation) SetModel(s string)

SetModel sets the "model" field.

func (*JudgeResultMutation) SetOp

func (m *JudgeResultMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*JudgeResultMutation) SetRationale

func (m *JudgeResultMutation) SetRationale(s string)

SetRationale sets the "rationale" field.

func (*JudgeResultMutation) SetRubricID

func (m *JudgeResultMutation) SetRubricID(id string)

SetRubricID sets the "rubric" edge to the JudgeRubric entity by id.

func (*JudgeResultMutation) SetScore

func (m *JudgeResultMutation) SetScore(f float64)

SetScore sets the "score" field.

func (*JudgeResultMutation) SetSpecPath

func (m *JudgeResultMutation) SetSpecPath(s string)

SetSpecPath sets the "spec_path" field.

func (*JudgeResultMutation) SpecPath

func (m *JudgeResultMutation) SpecPath() (r string, exists bool)

SpecPath returns the value of the "spec_path" field in the mutation.

func (JudgeResultMutation) Tx

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

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

func (*JudgeResultMutation) Type

func (m *JudgeResultMutation) Type() string

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

func (*JudgeResultMutation) Where

func (m *JudgeResultMutation) Where(ps ...predicate.JudgeResult)

Where appends a list predicates to the JudgeResultMutation builder.

func (*JudgeResultMutation) WhereP

func (m *JudgeResultMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the JudgeResultMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type JudgeResultQuery

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

JudgeResultQuery is the builder for querying JudgeResult entities.

func (*JudgeResultQuery) Aggregate

func (_q *JudgeResultQuery) Aggregate(fns ...AggregateFunc) *JudgeResultSelect

Aggregate returns a JudgeResultSelect configured with the given aggregations.

func (*JudgeResultQuery) All

func (_q *JudgeResultQuery) All(ctx context.Context) ([]*JudgeResult, error)

All executes the query and returns a list of JudgeResults.

func (*JudgeResultQuery) AllX

func (_q *JudgeResultQuery) AllX(ctx context.Context) []*JudgeResult

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

func (*JudgeResultQuery) Clone

func (_q *JudgeResultQuery) Clone() *JudgeResultQuery

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

func (*JudgeResultQuery) Count

func (_q *JudgeResultQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*JudgeResultQuery) CountX

func (_q *JudgeResultQuery) CountX(ctx context.Context) int

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

func (*JudgeResultQuery) Exist

func (_q *JudgeResultQuery) Exist(ctx context.Context) (bool, error)

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

func (*JudgeResultQuery) ExistX

func (_q *JudgeResultQuery) ExistX(ctx context.Context) bool

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

func (*JudgeResultQuery) First

func (_q *JudgeResultQuery) First(ctx context.Context) (*JudgeResult, error)

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

func (*JudgeResultQuery) FirstID

func (_q *JudgeResultQuery) FirstID(ctx context.Context) (id string, err error)

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

func (*JudgeResultQuery) FirstIDX

func (_q *JudgeResultQuery) FirstIDX(ctx context.Context) string

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

func (*JudgeResultQuery) FirstX

func (_q *JudgeResultQuery) FirstX(ctx context.Context) *JudgeResult

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

func (*JudgeResultQuery) GroupBy

func (_q *JudgeResultQuery) GroupBy(field string, fields ...string) *JudgeResultGroupBy

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 {
	InitiativeID string `json:"initiative_id,omitempty"`
	Count int `json:"count,omitempty"`
}

client.JudgeResult.Query().
	GroupBy(judgeresult.FieldInitiativeID).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*JudgeResultQuery) IDs

func (_q *JudgeResultQuery) IDs(ctx context.Context) (ids []string, err error)

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

func (*JudgeResultQuery) IDsX

func (_q *JudgeResultQuery) IDsX(ctx context.Context) []string

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

func (*JudgeResultQuery) Limit

func (_q *JudgeResultQuery) Limit(limit int) *JudgeResultQuery

Limit the number of records to be returned by this query.

func (*JudgeResultQuery) Offset

func (_q *JudgeResultQuery) Offset(offset int) *JudgeResultQuery

Offset to start from.

func (*JudgeResultQuery) Only

func (_q *JudgeResultQuery) Only(ctx context.Context) (*JudgeResult, error)

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

func (*JudgeResultQuery) OnlyID

func (_q *JudgeResultQuery) OnlyID(ctx context.Context) (id string, err error)

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

func (*JudgeResultQuery) OnlyIDX

func (_q *JudgeResultQuery) OnlyIDX(ctx context.Context) string

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

func (*JudgeResultQuery) OnlyX

func (_q *JudgeResultQuery) OnlyX(ctx context.Context) *JudgeResult

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

func (*JudgeResultQuery) Order

Order specifies how the records should be ordered.

func (*JudgeResultQuery) QueryRubric

func (_q *JudgeResultQuery) QueryRubric() *JudgeRubricQuery

QueryRubric chains the current query on the "rubric" edge.

func (*JudgeResultQuery) Select

func (_q *JudgeResultQuery) Select(fields ...string) *JudgeResultSelect

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 {
	InitiativeID string `json:"initiative_id,omitempty"`
}

client.JudgeResult.Query().
	Select(judgeresult.FieldInitiativeID).
	Scan(ctx, &v)

func (*JudgeResultQuery) Unique

func (_q *JudgeResultQuery) Unique(unique bool) *JudgeResultQuery

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 (*JudgeResultQuery) Where

Where adds a new predicate for the JudgeResultQuery builder.

func (*JudgeResultQuery) WithRubric

func (_q *JudgeResultQuery) WithRubric(opts ...func(*JudgeRubricQuery)) *JudgeResultQuery

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

type JudgeResultSelect

type JudgeResultSelect struct {
	*JudgeResultQuery
	// contains filtered or unexported fields
}

JudgeResultSelect is the builder for selecting fields of JudgeResult entities.

func (*JudgeResultSelect) Aggregate

func (_s *JudgeResultSelect) Aggregate(fns ...AggregateFunc) *JudgeResultSelect

Aggregate adds the given aggregation functions to the selector query.

func (*JudgeResultSelect) Bool

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

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

func (*JudgeResultSelect) BoolX

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

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

func (*JudgeResultSelect) Bools

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

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

func (*JudgeResultSelect) BoolsX

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

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

func (*JudgeResultSelect) Float64

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

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

func (*JudgeResultSelect) Float64X

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

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

func (*JudgeResultSelect) Float64s

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

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

func (*JudgeResultSelect) Float64sX

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

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

func (*JudgeResultSelect) Int

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

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

func (*JudgeResultSelect) IntX

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

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

func (*JudgeResultSelect) Ints

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

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

func (*JudgeResultSelect) IntsX

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

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

func (*JudgeResultSelect) Scan

func (_s *JudgeResultSelect) Scan(ctx context.Context, v any) error

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

func (*JudgeResultSelect) ScanX

func (s *JudgeResultSelect) ScanX(ctx context.Context, v any)

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

func (*JudgeResultSelect) String

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

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

func (*JudgeResultSelect) StringX

func (s *JudgeResultSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*JudgeResultSelect) Strings

func (s *JudgeResultSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*JudgeResultSelect) StringsX

func (s *JudgeResultSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type JudgeResultUpdate

type JudgeResultUpdate struct {
	// contains filtered or unexported fields
}

JudgeResultUpdate is the builder for updating JudgeResult entities.

func (*JudgeResultUpdate) AddScore

func (_u *JudgeResultUpdate) AddScore(v float64) *JudgeResultUpdate

AddScore adds value to the "score" field.

func (*JudgeResultUpdate) ClearModel

func (_u *JudgeResultUpdate) ClearModel() *JudgeResultUpdate

ClearModel clears the value of the "model" field.

func (*JudgeResultUpdate) ClearRationale

func (_u *JudgeResultUpdate) ClearRationale() *JudgeResultUpdate

ClearRationale clears the value of the "rationale" field.

func (*JudgeResultUpdate) ClearRubric

func (_u *JudgeResultUpdate) ClearRubric() *JudgeResultUpdate

ClearRubric clears the "rubric" edge to the JudgeRubric entity.

func (*JudgeResultUpdate) ClearScore

func (_u *JudgeResultUpdate) ClearScore() *JudgeResultUpdate

ClearScore clears the value of the "score" field.

func (*JudgeResultUpdate) Exec

func (_u *JudgeResultUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*JudgeResultUpdate) ExecX

func (_u *JudgeResultUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*JudgeResultUpdate) Mutation

func (_u *JudgeResultUpdate) Mutation() *JudgeResultMutation

Mutation returns the JudgeResultMutation object of the builder.

func (*JudgeResultUpdate) Save

func (_u *JudgeResultUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*JudgeResultUpdate) SaveX

func (_u *JudgeResultUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*JudgeResultUpdate) SetEvaluatedAt

func (_u *JudgeResultUpdate) SetEvaluatedAt(v time.Time) *JudgeResultUpdate

SetEvaluatedAt sets the "evaluated_at" field.

func (*JudgeResultUpdate) SetInitiativeID

func (_u *JudgeResultUpdate) SetInitiativeID(v string) *JudgeResultUpdate

SetInitiativeID sets the "initiative_id" field.

func (*JudgeResultUpdate) SetModel

func (_u *JudgeResultUpdate) SetModel(v string) *JudgeResultUpdate

SetModel sets the "model" field.

func (*JudgeResultUpdate) SetNillableEvaluatedAt

func (_u *JudgeResultUpdate) SetNillableEvaluatedAt(v *time.Time) *JudgeResultUpdate

SetNillableEvaluatedAt sets the "evaluated_at" field if the given value is not nil.

func (*JudgeResultUpdate) SetNillableInitiativeID

func (_u *JudgeResultUpdate) SetNillableInitiativeID(v *string) *JudgeResultUpdate

SetNillableInitiativeID sets the "initiative_id" field if the given value is not nil.

func (*JudgeResultUpdate) SetNillableModel

func (_u *JudgeResultUpdate) SetNillableModel(v *string) *JudgeResultUpdate

SetNillableModel sets the "model" field if the given value is not nil.

func (*JudgeResultUpdate) SetNillableRationale

func (_u *JudgeResultUpdate) SetNillableRationale(v *string) *JudgeResultUpdate

SetNillableRationale sets the "rationale" field if the given value is not nil.

func (*JudgeResultUpdate) SetNillableRubricID

func (_u *JudgeResultUpdate) SetNillableRubricID(id *string) *JudgeResultUpdate

SetNillableRubricID sets the "rubric" edge to the JudgeRubric entity by ID if the given value is not nil.

func (*JudgeResultUpdate) SetNillableScore

func (_u *JudgeResultUpdate) SetNillableScore(v *float64) *JudgeResultUpdate

SetNillableScore sets the "score" field if the given value is not nil.

func (*JudgeResultUpdate) SetNillableSpecPath

func (_u *JudgeResultUpdate) SetNillableSpecPath(v *string) *JudgeResultUpdate

SetNillableSpecPath sets the "spec_path" field if the given value is not nil.

func (*JudgeResultUpdate) SetRationale

func (_u *JudgeResultUpdate) SetRationale(v string) *JudgeResultUpdate

SetRationale sets the "rationale" field.

func (*JudgeResultUpdate) SetRubric

func (_u *JudgeResultUpdate) SetRubric(v *JudgeRubric) *JudgeResultUpdate

SetRubric sets the "rubric" edge to the JudgeRubric entity.

func (*JudgeResultUpdate) SetRubricID

func (_u *JudgeResultUpdate) SetRubricID(id string) *JudgeResultUpdate

SetRubricID sets the "rubric" edge to the JudgeRubric entity by ID.

func (*JudgeResultUpdate) SetScore

func (_u *JudgeResultUpdate) SetScore(v float64) *JudgeResultUpdate

SetScore sets the "score" field.

func (*JudgeResultUpdate) SetSpecPath

func (_u *JudgeResultUpdate) SetSpecPath(v string) *JudgeResultUpdate

SetSpecPath sets the "spec_path" field.

func (*JudgeResultUpdate) Where

Where appends a list predicates to the JudgeResultUpdate builder.

type JudgeResultUpdateOne

type JudgeResultUpdateOne struct {
	// contains filtered or unexported fields
}

JudgeResultUpdateOne is the builder for updating a single JudgeResult entity.

func (*JudgeResultUpdateOne) AddScore

AddScore adds value to the "score" field.

func (*JudgeResultUpdateOne) ClearModel

func (_u *JudgeResultUpdateOne) ClearModel() *JudgeResultUpdateOne

ClearModel clears the value of the "model" field.

func (*JudgeResultUpdateOne) ClearRationale

func (_u *JudgeResultUpdateOne) ClearRationale() *JudgeResultUpdateOne

ClearRationale clears the value of the "rationale" field.

func (*JudgeResultUpdateOne) ClearRubric

func (_u *JudgeResultUpdateOne) ClearRubric() *JudgeResultUpdateOne

ClearRubric clears the "rubric" edge to the JudgeRubric entity.

func (*JudgeResultUpdateOne) ClearScore

func (_u *JudgeResultUpdateOne) ClearScore() *JudgeResultUpdateOne

ClearScore clears the value of the "score" field.

func (*JudgeResultUpdateOne) Exec

func (_u *JudgeResultUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*JudgeResultUpdateOne) ExecX

func (_u *JudgeResultUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*JudgeResultUpdateOne) Mutation

func (_u *JudgeResultUpdateOne) Mutation() *JudgeResultMutation

Mutation returns the JudgeResultMutation object of the builder.

func (*JudgeResultUpdateOne) Save

Save executes the query and returns the updated JudgeResult entity.

func (*JudgeResultUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*JudgeResultUpdateOne) Select

func (_u *JudgeResultUpdateOne) Select(field string, fields ...string) *JudgeResultUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*JudgeResultUpdateOne) SetEvaluatedAt

func (_u *JudgeResultUpdateOne) SetEvaluatedAt(v time.Time) *JudgeResultUpdateOne

SetEvaluatedAt sets the "evaluated_at" field.

func (*JudgeResultUpdateOne) SetInitiativeID

func (_u *JudgeResultUpdateOne) SetInitiativeID(v string) *JudgeResultUpdateOne

SetInitiativeID sets the "initiative_id" field.

func (*JudgeResultUpdateOne) SetModel

SetModel sets the "model" field.

func (*JudgeResultUpdateOne) SetNillableEvaluatedAt

func (_u *JudgeResultUpdateOne) SetNillableEvaluatedAt(v *time.Time) *JudgeResultUpdateOne

SetNillableEvaluatedAt sets the "evaluated_at" field if the given value is not nil.

func (*JudgeResultUpdateOne) SetNillableInitiativeID

func (_u *JudgeResultUpdateOne) SetNillableInitiativeID(v *string) *JudgeResultUpdateOne

SetNillableInitiativeID sets the "initiative_id" field if the given value is not nil.

func (*JudgeResultUpdateOne) SetNillableModel

func (_u *JudgeResultUpdateOne) SetNillableModel(v *string) *JudgeResultUpdateOne

SetNillableModel sets the "model" field if the given value is not nil.

func (*JudgeResultUpdateOne) SetNillableRationale

func (_u *JudgeResultUpdateOne) SetNillableRationale(v *string) *JudgeResultUpdateOne

SetNillableRationale sets the "rationale" field if the given value is not nil.

func (*JudgeResultUpdateOne) SetNillableRubricID

func (_u *JudgeResultUpdateOne) SetNillableRubricID(id *string) *JudgeResultUpdateOne

SetNillableRubricID sets the "rubric" edge to the JudgeRubric entity by ID if the given value is not nil.

func (*JudgeResultUpdateOne) SetNillableScore

func (_u *JudgeResultUpdateOne) SetNillableScore(v *float64) *JudgeResultUpdateOne

SetNillableScore sets the "score" field if the given value is not nil.

func (*JudgeResultUpdateOne) SetNillableSpecPath

func (_u *JudgeResultUpdateOne) SetNillableSpecPath(v *string) *JudgeResultUpdateOne

SetNillableSpecPath sets the "spec_path" field if the given value is not nil.

func (*JudgeResultUpdateOne) SetRationale

func (_u *JudgeResultUpdateOne) SetRationale(v string) *JudgeResultUpdateOne

SetRationale sets the "rationale" field.

func (*JudgeResultUpdateOne) SetRubric

SetRubric sets the "rubric" edge to the JudgeRubric entity.

func (*JudgeResultUpdateOne) SetRubricID

func (_u *JudgeResultUpdateOne) SetRubricID(id string) *JudgeResultUpdateOne

SetRubricID sets the "rubric" edge to the JudgeRubric entity by ID.

func (*JudgeResultUpdateOne) SetScore

SetScore sets the "score" field.

func (*JudgeResultUpdateOne) SetSpecPath

func (_u *JudgeResultUpdateOne) SetSpecPath(v string) *JudgeResultUpdateOne

SetSpecPath sets the "spec_path" field.

func (*JudgeResultUpdateOne) Where

Where appends a list predicates to the JudgeResultUpdate builder.

type JudgeResults

type JudgeResults []*JudgeResult

JudgeResults is a parsable slice of JudgeResult.

type JudgeRubric

type JudgeRubric struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// SpecType holds the value of the "spec_type" field.
	SpecType string `json:"spec_type,omitempty"`
	// Criteria holds the value of the "criteria" field.
	Criteria map[string]interface{} `json:"criteria,omitempty"`
	// PromptTemplate holds the value of the "prompt_template" field.
	PromptTemplate string `json:"prompt_template,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the JudgeRubricQuery when eager-loading is set.
	Edges JudgeRubricEdges `json:"edges"`
	// contains filtered or unexported fields
}

JudgeRubric is the model entity for the JudgeRubric schema.

func (*JudgeRubric) QueryResults

func (_m *JudgeRubric) QueryResults() *JudgeResultQuery

QueryResults queries the "results" edge of the JudgeRubric entity.

func (*JudgeRubric) QueryWorkflow

func (_m *JudgeRubric) QueryWorkflow() *SpecWorkflowQuery

QueryWorkflow queries the "workflow" edge of the JudgeRubric entity.

func (*JudgeRubric) String

func (_m *JudgeRubric) String() string

String implements the fmt.Stringer.

func (*JudgeRubric) Unwrap

func (_m *JudgeRubric) Unwrap() *JudgeRubric

Unwrap unwraps the JudgeRubric 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 (*JudgeRubric) Update

func (_m *JudgeRubric) Update() *JudgeRubricUpdateOne

Update returns a builder for updating this JudgeRubric. Note that you need to call JudgeRubric.Unwrap() before calling this method if this JudgeRubric was returned from a transaction, and the transaction was committed or rolled back.

func (*JudgeRubric) Value

func (_m *JudgeRubric) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the JudgeRubric. This includes values selected through modifiers, order, etc.

type JudgeRubricClient

type JudgeRubricClient struct {
	// contains filtered or unexported fields
}

JudgeRubricClient is a client for the JudgeRubric schema.

func NewJudgeRubricClient

func NewJudgeRubricClient(c config) *JudgeRubricClient

NewJudgeRubricClient returns a client for the JudgeRubric from the given config.

func (*JudgeRubricClient) Create

func (c *JudgeRubricClient) Create() *JudgeRubricCreate

Create returns a builder for creating a JudgeRubric entity.

func (*JudgeRubricClient) CreateBulk

func (c *JudgeRubricClient) CreateBulk(builders ...*JudgeRubricCreate) *JudgeRubricCreateBulk

CreateBulk returns a builder for creating a bulk of JudgeRubric entities.

func (*JudgeRubricClient) Delete

func (c *JudgeRubricClient) Delete() *JudgeRubricDelete

Delete returns a delete builder for JudgeRubric.

func (*JudgeRubricClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*JudgeRubricClient) DeleteOneID

func (c *JudgeRubricClient) DeleteOneID(id string) *JudgeRubricDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*JudgeRubricClient) Get

Get returns a JudgeRubric entity by its id.

func (*JudgeRubricClient) GetX

GetX is like Get, but panics if an error occurs.

func (*JudgeRubricClient) Hooks

func (c *JudgeRubricClient) Hooks() []Hook

Hooks returns the client hooks.

func (*JudgeRubricClient) Intercept

func (c *JudgeRubricClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `judgerubric.Intercept(f(g(h())))`.

func (*JudgeRubricClient) Interceptors

func (c *JudgeRubricClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*JudgeRubricClient) MapCreateBulk

func (c *JudgeRubricClient) MapCreateBulk(slice any, setFunc func(*JudgeRubricCreate, int)) *JudgeRubricCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*JudgeRubricClient) Query

func (c *JudgeRubricClient) Query() *JudgeRubricQuery

Query returns a query builder for JudgeRubric.

func (*JudgeRubricClient) QueryResults

func (c *JudgeRubricClient) QueryResults(_m *JudgeRubric) *JudgeResultQuery

QueryResults queries the results edge of a JudgeRubric.

func (*JudgeRubricClient) QueryWorkflow

func (c *JudgeRubricClient) QueryWorkflow(_m *JudgeRubric) *SpecWorkflowQuery

QueryWorkflow queries the workflow edge of a JudgeRubric.

func (*JudgeRubricClient) Update

func (c *JudgeRubricClient) Update() *JudgeRubricUpdate

Update returns an update builder for JudgeRubric.

func (*JudgeRubricClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*JudgeRubricClient) UpdateOneID

func (c *JudgeRubricClient) UpdateOneID(id string) *JudgeRubricUpdateOne

UpdateOneID returns an update builder for the given id.

func (*JudgeRubricClient) Use

func (c *JudgeRubricClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `judgerubric.Hooks(f(g(h())))`.

type JudgeRubricCreate

type JudgeRubricCreate struct {
	// contains filtered or unexported fields
}

JudgeRubricCreate is the builder for creating a JudgeRubric entity.

func (*JudgeRubricCreate) AddResultIDs

func (_c *JudgeRubricCreate) AddResultIDs(ids ...string) *JudgeRubricCreate

AddResultIDs adds the "results" edge to the JudgeResult entity by IDs.

func (*JudgeRubricCreate) AddResults

func (_c *JudgeRubricCreate) AddResults(v ...*JudgeResult) *JudgeRubricCreate

AddResults adds the "results" edges to the JudgeResult entity.

func (*JudgeRubricCreate) Exec

func (_c *JudgeRubricCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*JudgeRubricCreate) ExecX

func (_c *JudgeRubricCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*JudgeRubricCreate) Mutation

func (_c *JudgeRubricCreate) Mutation() *JudgeRubricMutation

Mutation returns the JudgeRubricMutation object of the builder.

func (*JudgeRubricCreate) Save

Save creates the JudgeRubric in the database.

func (*JudgeRubricCreate) SaveX

func (_c *JudgeRubricCreate) SaveX(ctx context.Context) *JudgeRubric

SaveX calls Save and panics if Save returns an error.

func (*JudgeRubricCreate) SetCriteria

func (_c *JudgeRubricCreate) SetCriteria(v map[string]interface{}) *JudgeRubricCreate

SetCriteria sets the "criteria" field.

func (*JudgeRubricCreate) SetID

SetID sets the "id" field.

func (*JudgeRubricCreate) SetNillablePromptTemplate

func (_c *JudgeRubricCreate) SetNillablePromptTemplate(v *string) *JudgeRubricCreate

SetNillablePromptTemplate sets the "prompt_template" field if the given value is not nil.

func (*JudgeRubricCreate) SetNillableWorkflowID

func (_c *JudgeRubricCreate) SetNillableWorkflowID(id *string) *JudgeRubricCreate

SetNillableWorkflowID sets the "workflow" edge to the SpecWorkflow entity by ID if the given value is not nil.

func (*JudgeRubricCreate) SetPromptTemplate

func (_c *JudgeRubricCreate) SetPromptTemplate(v string) *JudgeRubricCreate

SetPromptTemplate sets the "prompt_template" field.

func (*JudgeRubricCreate) SetSpecType

func (_c *JudgeRubricCreate) SetSpecType(v string) *JudgeRubricCreate

SetSpecType sets the "spec_type" field.

func (*JudgeRubricCreate) SetWorkflow

func (_c *JudgeRubricCreate) SetWorkflow(v *SpecWorkflow) *JudgeRubricCreate

SetWorkflow sets the "workflow" edge to the SpecWorkflow entity.

func (*JudgeRubricCreate) SetWorkflowID

func (_c *JudgeRubricCreate) SetWorkflowID(id string) *JudgeRubricCreate

SetWorkflowID sets the "workflow" edge to the SpecWorkflow entity by ID.

type JudgeRubricCreateBulk

type JudgeRubricCreateBulk struct {
	// contains filtered or unexported fields
}

JudgeRubricCreateBulk is the builder for creating many JudgeRubric entities in bulk.

func (*JudgeRubricCreateBulk) Exec

Exec executes the query.

func (*JudgeRubricCreateBulk) ExecX

func (_c *JudgeRubricCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*JudgeRubricCreateBulk) Save

Save creates the JudgeRubric entities in the database.

func (*JudgeRubricCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type JudgeRubricDelete

type JudgeRubricDelete struct {
	// contains filtered or unexported fields
}

JudgeRubricDelete is the builder for deleting a JudgeRubric entity.

func (*JudgeRubricDelete) Exec

func (_d *JudgeRubricDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*JudgeRubricDelete) ExecX

func (_d *JudgeRubricDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*JudgeRubricDelete) Where

Where appends a list predicates to the JudgeRubricDelete builder.

type JudgeRubricDeleteOne

type JudgeRubricDeleteOne struct {
	// contains filtered or unexported fields
}

JudgeRubricDeleteOne is the builder for deleting a single JudgeRubric entity.

func (*JudgeRubricDeleteOne) Exec

func (_d *JudgeRubricDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*JudgeRubricDeleteOne) ExecX

func (_d *JudgeRubricDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*JudgeRubricDeleteOne) Where

Where appends a list predicates to the JudgeRubricDelete builder.

type JudgeRubricEdges

type JudgeRubricEdges struct {
	// Workflow holds the value of the workflow edge.
	Workflow *SpecWorkflow `json:"workflow,omitempty"`
	// Results holds the value of the results edge.
	Results []*JudgeResult `json:"results,omitempty"`
	// contains filtered or unexported fields
}

JudgeRubricEdges holds the relations/edges for other nodes in the graph.

func (JudgeRubricEdges) ResultsOrErr

func (e JudgeRubricEdges) ResultsOrErr() ([]*JudgeResult, error)

ResultsOrErr returns the Results value or an error if the edge was not loaded in eager-loading.

func (JudgeRubricEdges) WorkflowOrErr

func (e JudgeRubricEdges) WorkflowOrErr() (*SpecWorkflow, error)

WorkflowOrErr returns the Workflow value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type JudgeRubricGroupBy

type JudgeRubricGroupBy struct {
	// contains filtered or unexported fields
}

JudgeRubricGroupBy is the group-by builder for JudgeRubric entities.

func (*JudgeRubricGroupBy) Aggregate

func (_g *JudgeRubricGroupBy) Aggregate(fns ...AggregateFunc) *JudgeRubricGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*JudgeRubricGroupBy) Bool

func (s *JudgeRubricGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*JudgeRubricGroupBy) BoolX

func (s *JudgeRubricGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*JudgeRubricGroupBy) Bools

func (s *JudgeRubricGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*JudgeRubricGroupBy) BoolsX

func (s *JudgeRubricGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*JudgeRubricGroupBy) Float64

func (s *JudgeRubricGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*JudgeRubricGroupBy) Float64X

func (s *JudgeRubricGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*JudgeRubricGroupBy) Float64s

func (s *JudgeRubricGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*JudgeRubricGroupBy) Float64sX

func (s *JudgeRubricGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*JudgeRubricGroupBy) Int

func (s *JudgeRubricGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*JudgeRubricGroupBy) IntX

func (s *JudgeRubricGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*JudgeRubricGroupBy) Ints

func (s *JudgeRubricGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*JudgeRubricGroupBy) IntsX

func (s *JudgeRubricGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*JudgeRubricGroupBy) Scan

func (_g *JudgeRubricGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*JudgeRubricGroupBy) ScanX

func (s *JudgeRubricGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*JudgeRubricGroupBy) String

func (s *JudgeRubricGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*JudgeRubricGroupBy) StringX

func (s *JudgeRubricGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*JudgeRubricGroupBy) Strings

func (s *JudgeRubricGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*JudgeRubricGroupBy) StringsX

func (s *JudgeRubricGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type JudgeRubricMutation

type JudgeRubricMutation struct {
	// contains filtered or unexported fields
}

JudgeRubricMutation represents an operation that mutates the JudgeRubric nodes in the graph.

func (*JudgeRubricMutation) AddField

func (m *JudgeRubricMutation) 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 (*JudgeRubricMutation) AddResultIDs

func (m *JudgeRubricMutation) AddResultIDs(ids ...string)

AddResultIDs adds the "results" edge to the JudgeResult entity by ids.

func (*JudgeRubricMutation) AddedEdges

func (m *JudgeRubricMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*JudgeRubricMutation) AddedField

func (m *JudgeRubricMutation) 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 (*JudgeRubricMutation) AddedFields

func (m *JudgeRubricMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*JudgeRubricMutation) AddedIDs

func (m *JudgeRubricMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*JudgeRubricMutation) ClearCriteria

func (m *JudgeRubricMutation) ClearCriteria()

ClearCriteria clears the value of the "criteria" field.

func (*JudgeRubricMutation) ClearEdge

func (m *JudgeRubricMutation) 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 (*JudgeRubricMutation) ClearField

func (m *JudgeRubricMutation) 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 (*JudgeRubricMutation) ClearPromptTemplate

func (m *JudgeRubricMutation) ClearPromptTemplate()

ClearPromptTemplate clears the value of the "prompt_template" field.

func (*JudgeRubricMutation) ClearResults

func (m *JudgeRubricMutation) ClearResults()

ClearResults clears the "results" edge to the JudgeResult entity.

func (*JudgeRubricMutation) ClearWorkflow

func (m *JudgeRubricMutation) ClearWorkflow()

ClearWorkflow clears the "workflow" edge to the SpecWorkflow entity.

func (*JudgeRubricMutation) ClearedEdges

func (m *JudgeRubricMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*JudgeRubricMutation) ClearedFields

func (m *JudgeRubricMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (JudgeRubricMutation) Client

func (m JudgeRubricMutation) 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 (*JudgeRubricMutation) Criteria

func (m *JudgeRubricMutation) Criteria() (r map[string]interface{}, exists bool)

Criteria returns the value of the "criteria" field in the mutation.

func (*JudgeRubricMutation) CriteriaCleared

func (m *JudgeRubricMutation) CriteriaCleared() bool

CriteriaCleared returns if the "criteria" field was cleared in this mutation.

func (*JudgeRubricMutation) EdgeCleared

func (m *JudgeRubricMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*JudgeRubricMutation) Field

func (m *JudgeRubricMutation) 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 (*JudgeRubricMutation) FieldCleared

func (m *JudgeRubricMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*JudgeRubricMutation) Fields

func (m *JudgeRubricMutation) 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 (*JudgeRubricMutation) ID

func (m *JudgeRubricMutation) ID() (id string, 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 (*JudgeRubricMutation) IDs

func (m *JudgeRubricMutation) IDs(ctx context.Context) ([]string, 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 (*JudgeRubricMutation) OldCriteria

func (m *JudgeRubricMutation) OldCriteria(ctx context.Context) (v map[string]interface{}, err error)

OldCriteria returns the old "criteria" field's value of the JudgeRubric entity. If the JudgeRubric 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 (*JudgeRubricMutation) OldField

func (m *JudgeRubricMutation) 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 (*JudgeRubricMutation) OldPromptTemplate

func (m *JudgeRubricMutation) OldPromptTemplate(ctx context.Context) (v string, err error)

OldPromptTemplate returns the old "prompt_template" field's value of the JudgeRubric entity. If the JudgeRubric 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 (*JudgeRubricMutation) OldSpecType

func (m *JudgeRubricMutation) OldSpecType(ctx context.Context) (v string, err error)

OldSpecType returns the old "spec_type" field's value of the JudgeRubric entity. If the JudgeRubric 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 (*JudgeRubricMutation) Op

func (m *JudgeRubricMutation) Op() Op

Op returns the operation name.

func (*JudgeRubricMutation) PromptTemplate

func (m *JudgeRubricMutation) PromptTemplate() (r string, exists bool)

PromptTemplate returns the value of the "prompt_template" field in the mutation.

func (*JudgeRubricMutation) PromptTemplateCleared

func (m *JudgeRubricMutation) PromptTemplateCleared() bool

PromptTemplateCleared returns if the "prompt_template" field was cleared in this mutation.

func (*JudgeRubricMutation) RemoveResultIDs

func (m *JudgeRubricMutation) RemoveResultIDs(ids ...string)

RemoveResultIDs removes the "results" edge to the JudgeResult entity by IDs.

func (*JudgeRubricMutation) RemovedEdges

func (m *JudgeRubricMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*JudgeRubricMutation) RemovedIDs

func (m *JudgeRubricMutation) 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 (*JudgeRubricMutation) RemovedResultsIDs

func (m *JudgeRubricMutation) RemovedResultsIDs() (ids []string)

RemovedResults returns the removed IDs of the "results" edge to the JudgeResult entity.

func (*JudgeRubricMutation) ResetCriteria

func (m *JudgeRubricMutation) ResetCriteria()

ResetCriteria resets all changes to the "criteria" field.

func (*JudgeRubricMutation) ResetEdge

func (m *JudgeRubricMutation) 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 (*JudgeRubricMutation) ResetField

func (m *JudgeRubricMutation) 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 (*JudgeRubricMutation) ResetPromptTemplate

func (m *JudgeRubricMutation) ResetPromptTemplate()

ResetPromptTemplate resets all changes to the "prompt_template" field.

func (*JudgeRubricMutation) ResetResults

func (m *JudgeRubricMutation) ResetResults()

ResetResults resets all changes to the "results" edge.

func (*JudgeRubricMutation) ResetSpecType

func (m *JudgeRubricMutation) ResetSpecType()

ResetSpecType resets all changes to the "spec_type" field.

func (*JudgeRubricMutation) ResetWorkflow

func (m *JudgeRubricMutation) ResetWorkflow()

ResetWorkflow resets all changes to the "workflow" edge.

func (*JudgeRubricMutation) ResultsCleared

func (m *JudgeRubricMutation) ResultsCleared() bool

ResultsCleared reports if the "results" edge to the JudgeResult entity was cleared.

func (*JudgeRubricMutation) ResultsIDs

func (m *JudgeRubricMutation) ResultsIDs() (ids []string)

ResultsIDs returns the "results" edge IDs in the mutation.

func (*JudgeRubricMutation) SetCriteria

func (m *JudgeRubricMutation) SetCriteria(value map[string]interface{})

SetCriteria sets the "criteria" field.

func (*JudgeRubricMutation) SetField

func (m *JudgeRubricMutation) 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 (*JudgeRubricMutation) SetID

func (m *JudgeRubricMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of JudgeRubric entities.

func (*JudgeRubricMutation) SetOp

func (m *JudgeRubricMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*JudgeRubricMutation) SetPromptTemplate

func (m *JudgeRubricMutation) SetPromptTemplate(s string)

SetPromptTemplate sets the "prompt_template" field.

func (*JudgeRubricMutation) SetSpecType

func (m *JudgeRubricMutation) SetSpecType(s string)

SetSpecType sets the "spec_type" field.

func (*JudgeRubricMutation) SetWorkflowID

func (m *JudgeRubricMutation) SetWorkflowID(id string)

SetWorkflowID sets the "workflow" edge to the SpecWorkflow entity by id.

func (*JudgeRubricMutation) SpecType

func (m *JudgeRubricMutation) SpecType() (r string, exists bool)

SpecType returns the value of the "spec_type" field in the mutation.

func (JudgeRubricMutation) Tx

func (m JudgeRubricMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*JudgeRubricMutation) Type

func (m *JudgeRubricMutation) Type() string

Type returns the node type of this mutation (JudgeRubric).

func (*JudgeRubricMutation) Where

func (m *JudgeRubricMutation) Where(ps ...predicate.JudgeRubric)

Where appends a list predicates to the JudgeRubricMutation builder.

func (*JudgeRubricMutation) WhereP

func (m *JudgeRubricMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the JudgeRubricMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

func (*JudgeRubricMutation) WorkflowCleared

func (m *JudgeRubricMutation) WorkflowCleared() bool

WorkflowCleared reports if the "workflow" edge to the SpecWorkflow entity was cleared.

func (*JudgeRubricMutation) WorkflowID

func (m *JudgeRubricMutation) WorkflowID() (id string, exists bool)

WorkflowID returns the "workflow" edge ID in the mutation.

func (*JudgeRubricMutation) WorkflowIDs

func (m *JudgeRubricMutation) WorkflowIDs() (ids []string)

WorkflowIDs returns the "workflow" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use WorkflowID instead. It exists only for internal usage by the builders.

type JudgeRubricQuery

type JudgeRubricQuery struct {
	// contains filtered or unexported fields
}

JudgeRubricQuery is the builder for querying JudgeRubric entities.

func (*JudgeRubricQuery) Aggregate

func (_q *JudgeRubricQuery) Aggregate(fns ...AggregateFunc) *JudgeRubricSelect

Aggregate returns a JudgeRubricSelect configured with the given aggregations.

func (*JudgeRubricQuery) All

func (_q *JudgeRubricQuery) All(ctx context.Context) ([]*JudgeRubric, error)

All executes the query and returns a list of JudgeRubrics.

func (*JudgeRubricQuery) AllX

func (_q *JudgeRubricQuery) AllX(ctx context.Context) []*JudgeRubric

AllX is like All, but panics if an error occurs.

func (*JudgeRubricQuery) Clone

func (_q *JudgeRubricQuery) Clone() *JudgeRubricQuery

Clone returns a duplicate of the JudgeRubricQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*JudgeRubricQuery) Count

func (_q *JudgeRubricQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*JudgeRubricQuery) CountX

func (_q *JudgeRubricQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*JudgeRubricQuery) Exist

func (_q *JudgeRubricQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*JudgeRubricQuery) ExistX

func (_q *JudgeRubricQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*JudgeRubricQuery) First

func (_q *JudgeRubricQuery) First(ctx context.Context) (*JudgeRubric, error)

First returns the first JudgeRubric entity from the query. Returns a *NotFoundError when no JudgeRubric was found.

func (*JudgeRubricQuery) FirstID

func (_q *JudgeRubricQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first JudgeRubric ID from the query. Returns a *NotFoundError when no JudgeRubric ID was found.

func (*JudgeRubricQuery) FirstIDX

func (_q *JudgeRubricQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*JudgeRubricQuery) FirstX

func (_q *JudgeRubricQuery) FirstX(ctx context.Context) *JudgeRubric

FirstX is like First, but panics if an error occurs.

func (*JudgeRubricQuery) GroupBy

func (_q *JudgeRubricQuery) GroupBy(field string, fields ...string) *JudgeRubricGroupBy

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 {
	SpecType string `json:"spec_type,omitempty"`
	Count int `json:"count,omitempty"`
}

client.JudgeRubric.Query().
	GroupBy(judgerubric.FieldSpecType).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*JudgeRubricQuery) IDs

func (_q *JudgeRubricQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of JudgeRubric IDs.

func (*JudgeRubricQuery) IDsX

func (_q *JudgeRubricQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*JudgeRubricQuery) Limit

func (_q *JudgeRubricQuery) Limit(limit int) *JudgeRubricQuery

Limit the number of records to be returned by this query.

func (*JudgeRubricQuery) Offset

func (_q *JudgeRubricQuery) Offset(offset int) *JudgeRubricQuery

Offset to start from.

func (*JudgeRubricQuery) Only

func (_q *JudgeRubricQuery) Only(ctx context.Context) (*JudgeRubric, error)

Only returns a single JudgeRubric entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one JudgeRubric entity is found. Returns a *NotFoundError when no JudgeRubric entities are found.

func (*JudgeRubricQuery) OnlyID

func (_q *JudgeRubricQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only JudgeRubric ID in the query. Returns a *NotSingularError when more than one JudgeRubric ID is found. Returns a *NotFoundError when no entities are found.

func (*JudgeRubricQuery) OnlyIDX

func (_q *JudgeRubricQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*JudgeRubricQuery) OnlyX

func (_q *JudgeRubricQuery) OnlyX(ctx context.Context) *JudgeRubric

OnlyX is like Only, but panics if an error occurs.

func (*JudgeRubricQuery) Order

Order specifies how the records should be ordered.

func (*JudgeRubricQuery) QueryResults

func (_q *JudgeRubricQuery) QueryResults() *JudgeResultQuery

QueryResults chains the current query on the "results" edge.

func (*JudgeRubricQuery) QueryWorkflow

func (_q *JudgeRubricQuery) QueryWorkflow() *SpecWorkflowQuery

QueryWorkflow chains the current query on the "workflow" edge.

func (*JudgeRubricQuery) Select

func (_q *JudgeRubricQuery) Select(fields ...string) *JudgeRubricSelect

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 {
	SpecType string `json:"spec_type,omitempty"`
}

client.JudgeRubric.Query().
	Select(judgerubric.FieldSpecType).
	Scan(ctx, &v)

func (*JudgeRubricQuery) Unique

func (_q *JudgeRubricQuery) Unique(unique bool) *JudgeRubricQuery

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 (*JudgeRubricQuery) Where

Where adds a new predicate for the JudgeRubricQuery builder.

func (*JudgeRubricQuery) WithResults

func (_q *JudgeRubricQuery) WithResults(opts ...func(*JudgeResultQuery)) *JudgeRubricQuery

WithResults tells the query-builder to eager-load the nodes that are connected to the "results" edge. The optional arguments are used to configure the query builder of the edge.

func (*JudgeRubricQuery) WithWorkflow

func (_q *JudgeRubricQuery) WithWorkflow(opts ...func(*SpecWorkflowQuery)) *JudgeRubricQuery

WithWorkflow tells the query-builder to eager-load the nodes that are connected to the "workflow" edge. The optional arguments are used to configure the query builder of the edge.

type JudgeRubricSelect

type JudgeRubricSelect struct {
	*JudgeRubricQuery
	// contains filtered or unexported fields
}

JudgeRubricSelect is the builder for selecting fields of JudgeRubric entities.

func (*JudgeRubricSelect) Aggregate

func (_s *JudgeRubricSelect) Aggregate(fns ...AggregateFunc) *JudgeRubricSelect

Aggregate adds the given aggregation functions to the selector query.

func (*JudgeRubricSelect) Bool

func (s *JudgeRubricSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*JudgeRubricSelect) BoolX

func (s *JudgeRubricSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*JudgeRubricSelect) Bools

func (s *JudgeRubricSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*JudgeRubricSelect) BoolsX

func (s *JudgeRubricSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*JudgeRubricSelect) Float64

func (s *JudgeRubricSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*JudgeRubricSelect) Float64X

func (s *JudgeRubricSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*JudgeRubricSelect) Float64s

func (s *JudgeRubricSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*JudgeRubricSelect) Float64sX

func (s *JudgeRubricSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*JudgeRubricSelect) Int

func (s *JudgeRubricSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*JudgeRubricSelect) IntX

func (s *JudgeRubricSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*JudgeRubricSelect) Ints

func (s *JudgeRubricSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*JudgeRubricSelect) IntsX

func (s *JudgeRubricSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*JudgeRubricSelect) Scan

func (_s *JudgeRubricSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*JudgeRubricSelect) ScanX

func (s *JudgeRubricSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*JudgeRubricSelect) String

func (s *JudgeRubricSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*JudgeRubricSelect) StringX

func (s *JudgeRubricSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*JudgeRubricSelect) Strings

func (s *JudgeRubricSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*JudgeRubricSelect) StringsX

func (s *JudgeRubricSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type JudgeRubricUpdate

type JudgeRubricUpdate struct {
	// contains filtered or unexported fields
}

JudgeRubricUpdate is the builder for updating JudgeRubric entities.

func (*JudgeRubricUpdate) AddResultIDs

func (_u *JudgeRubricUpdate) AddResultIDs(ids ...string) *JudgeRubricUpdate

AddResultIDs adds the "results" edge to the JudgeResult entity by IDs.

func (*JudgeRubricUpdate) AddResults

func (_u *JudgeRubricUpdate) AddResults(v ...*JudgeResult) *JudgeRubricUpdate

AddResults adds the "results" edges to the JudgeResult entity.

func (*JudgeRubricUpdate) ClearCriteria

func (_u *JudgeRubricUpdate) ClearCriteria() *JudgeRubricUpdate

ClearCriteria clears the value of the "criteria" field.

func (*JudgeRubricUpdate) ClearPromptTemplate

func (_u *JudgeRubricUpdate) ClearPromptTemplate() *JudgeRubricUpdate

ClearPromptTemplate clears the value of the "prompt_template" field.

func (*JudgeRubricUpdate) ClearResults

func (_u *JudgeRubricUpdate) ClearResults() *JudgeRubricUpdate

ClearResults clears all "results" edges to the JudgeResult entity.

func (*JudgeRubricUpdate) ClearWorkflow

func (_u *JudgeRubricUpdate) ClearWorkflow() *JudgeRubricUpdate

ClearWorkflow clears the "workflow" edge to the SpecWorkflow entity.

func (*JudgeRubricUpdate) Exec

func (_u *JudgeRubricUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*JudgeRubricUpdate) ExecX

func (_u *JudgeRubricUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*JudgeRubricUpdate) Mutation

func (_u *JudgeRubricUpdate) Mutation() *JudgeRubricMutation

Mutation returns the JudgeRubricMutation object of the builder.

func (*JudgeRubricUpdate) RemoveResultIDs

func (_u *JudgeRubricUpdate) RemoveResultIDs(ids ...string) *JudgeRubricUpdate

RemoveResultIDs removes the "results" edge to JudgeResult entities by IDs.

func (*JudgeRubricUpdate) RemoveResults

func (_u *JudgeRubricUpdate) RemoveResults(v ...*JudgeResult) *JudgeRubricUpdate

RemoveResults removes "results" edges to JudgeResult entities.

func (*JudgeRubricUpdate) Save

func (_u *JudgeRubricUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*JudgeRubricUpdate) SaveX

func (_u *JudgeRubricUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*JudgeRubricUpdate) SetCriteria

func (_u *JudgeRubricUpdate) SetCriteria(v map[string]interface{}) *JudgeRubricUpdate

SetCriteria sets the "criteria" field.

func (*JudgeRubricUpdate) SetNillablePromptTemplate

func (_u *JudgeRubricUpdate) SetNillablePromptTemplate(v *string) *JudgeRubricUpdate

SetNillablePromptTemplate sets the "prompt_template" field if the given value is not nil.

func (*JudgeRubricUpdate) SetNillableSpecType

func (_u *JudgeRubricUpdate) SetNillableSpecType(v *string) *JudgeRubricUpdate

SetNillableSpecType sets the "spec_type" field if the given value is not nil.

func (*JudgeRubricUpdate) SetNillableWorkflowID

func (_u *JudgeRubricUpdate) SetNillableWorkflowID(id *string) *JudgeRubricUpdate

SetNillableWorkflowID sets the "workflow" edge to the SpecWorkflow entity by ID if the given value is not nil.

func (*JudgeRubricUpdate) SetPromptTemplate

func (_u *JudgeRubricUpdate) SetPromptTemplate(v string) *JudgeRubricUpdate

SetPromptTemplate sets the "prompt_template" field.

func (*JudgeRubricUpdate) SetSpecType

func (_u *JudgeRubricUpdate) SetSpecType(v string) *JudgeRubricUpdate

SetSpecType sets the "spec_type" field.

func (*JudgeRubricUpdate) SetWorkflow

func (_u *JudgeRubricUpdate) SetWorkflow(v *SpecWorkflow) *JudgeRubricUpdate

SetWorkflow sets the "workflow" edge to the SpecWorkflow entity.

func (*JudgeRubricUpdate) SetWorkflowID

func (_u *JudgeRubricUpdate) SetWorkflowID(id string) *JudgeRubricUpdate

SetWorkflowID sets the "workflow" edge to the SpecWorkflow entity by ID.

func (*JudgeRubricUpdate) Where

Where appends a list predicates to the JudgeRubricUpdate builder.

type JudgeRubricUpdateOne

type JudgeRubricUpdateOne struct {
	// contains filtered or unexported fields
}

JudgeRubricUpdateOne is the builder for updating a single JudgeRubric entity.

func (*JudgeRubricUpdateOne) AddResultIDs

func (_u *JudgeRubricUpdateOne) AddResultIDs(ids ...string) *JudgeRubricUpdateOne

AddResultIDs adds the "results" edge to the JudgeResult entity by IDs.

func (*JudgeRubricUpdateOne) AddResults

func (_u *JudgeRubricUpdateOne) AddResults(v ...*JudgeResult) *JudgeRubricUpdateOne

AddResults adds the "results" edges to the JudgeResult entity.

func (*JudgeRubricUpdateOne) ClearCriteria

func (_u *JudgeRubricUpdateOne) ClearCriteria() *JudgeRubricUpdateOne

ClearCriteria clears the value of the "criteria" field.

func (*JudgeRubricUpdateOne) ClearPromptTemplate

func (_u *JudgeRubricUpdateOne) ClearPromptTemplate() *JudgeRubricUpdateOne

ClearPromptTemplate clears the value of the "prompt_template" field.

func (*JudgeRubricUpdateOne) ClearResults

func (_u *JudgeRubricUpdateOne) ClearResults() *JudgeRubricUpdateOne

ClearResults clears all "results" edges to the JudgeResult entity.

func (*JudgeRubricUpdateOne) ClearWorkflow

func (_u *JudgeRubricUpdateOne) ClearWorkflow() *JudgeRubricUpdateOne

ClearWorkflow clears the "workflow" edge to the SpecWorkflow entity.

func (*JudgeRubricUpdateOne) Exec

func (_u *JudgeRubricUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*JudgeRubricUpdateOne) ExecX

func (_u *JudgeRubricUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*JudgeRubricUpdateOne) Mutation

func (_u *JudgeRubricUpdateOne) Mutation() *JudgeRubricMutation

Mutation returns the JudgeRubricMutation object of the builder.

func (*JudgeRubricUpdateOne) RemoveResultIDs

func (_u *JudgeRubricUpdateOne) RemoveResultIDs(ids ...string) *JudgeRubricUpdateOne

RemoveResultIDs removes the "results" edge to JudgeResult entities by IDs.

func (*JudgeRubricUpdateOne) RemoveResults

func (_u *JudgeRubricUpdateOne) RemoveResults(v ...*JudgeResult) *JudgeRubricUpdateOne

RemoveResults removes "results" edges to JudgeResult entities.

func (*JudgeRubricUpdateOne) Save

Save executes the query and returns the updated JudgeRubric entity.

func (*JudgeRubricUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*JudgeRubricUpdateOne) Select

func (_u *JudgeRubricUpdateOne) Select(field string, fields ...string) *JudgeRubricUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*JudgeRubricUpdateOne) SetCriteria

func (_u *JudgeRubricUpdateOne) SetCriteria(v map[string]interface{}) *JudgeRubricUpdateOne

SetCriteria sets the "criteria" field.

func (*JudgeRubricUpdateOne) SetNillablePromptTemplate

func (_u *JudgeRubricUpdateOne) SetNillablePromptTemplate(v *string) *JudgeRubricUpdateOne

SetNillablePromptTemplate sets the "prompt_template" field if the given value is not nil.

func (*JudgeRubricUpdateOne) SetNillableSpecType

func (_u *JudgeRubricUpdateOne) SetNillableSpecType(v *string) *JudgeRubricUpdateOne

SetNillableSpecType sets the "spec_type" field if the given value is not nil.

func (*JudgeRubricUpdateOne) SetNillableWorkflowID

func (_u *JudgeRubricUpdateOne) SetNillableWorkflowID(id *string) *JudgeRubricUpdateOne

SetNillableWorkflowID sets the "workflow" edge to the SpecWorkflow entity by ID if the given value is not nil.

func (*JudgeRubricUpdateOne) SetPromptTemplate

func (_u *JudgeRubricUpdateOne) SetPromptTemplate(v string) *JudgeRubricUpdateOne

SetPromptTemplate sets the "prompt_template" field.

func (*JudgeRubricUpdateOne) SetSpecType

func (_u *JudgeRubricUpdateOne) SetSpecType(v string) *JudgeRubricUpdateOne

SetSpecType sets the "spec_type" field.

func (*JudgeRubricUpdateOne) SetWorkflow

SetWorkflow sets the "workflow" edge to the SpecWorkflow entity.

func (*JudgeRubricUpdateOne) SetWorkflowID

func (_u *JudgeRubricUpdateOne) SetWorkflowID(id string) *JudgeRubricUpdateOne

SetWorkflowID sets the "workflow" edge to the SpecWorkflow entity by ID.

func (*JudgeRubricUpdateOne) Where

Where appends a list predicates to the JudgeRubricUpdate builder.

type JudgeRubrics

type JudgeRubrics []*JudgeRubric

JudgeRubrics is a parsable slice of JudgeRubric.

type MaturityAssessment

type MaturityAssessment struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// InitiativeID holds the value of the "initiative_id" field.
	InitiativeID string `json:"initiative_id,omitempty"`
	// Organization holds the value of the "organization" field.
	Organization string `json:"organization,omitempty"`
	// Scores holds the value of the "scores" field.
	Scores map[string]schema.DimensionScore `json:"scores,omitempty"`
	// OverallScore holds the value of the "overall_score" field.
	OverallScore *float64 `json:"overall_score,omitempty"`
	// Summary holds the value of the "summary" field.
	Summary string `json:"summary,omitempty"`
	// AssessedBy holds the value of the "assessed_by" field.
	AssessedBy string `json:"assessed_by,omitempty"`
	// Model holds the value of the "model" field.
	Model string `json:"model,omitempty"`
	// AssessedAt holds the value of the "assessed_at" field.
	AssessedAt time.Time `json:"assessed_at,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the MaturityAssessmentQuery when eager-loading is set.
	Edges MaturityAssessmentEdges `json:"edges"`
	// contains filtered or unexported fields
}

MaturityAssessment is the model entity for the MaturityAssessment schema.

func (*MaturityAssessment) QueryCapabilityModel

func (_m *MaturityAssessment) QueryCapabilityModel() *CapabilityModelQuery

QueryCapabilityModel queries the "capability_model" edge of the MaturityAssessment entity.

func (*MaturityAssessment) String

func (_m *MaturityAssessment) String() string

String implements the fmt.Stringer.

func (*MaturityAssessment) Unwrap

func (_m *MaturityAssessment) Unwrap() *MaturityAssessment

Unwrap unwraps the MaturityAssessment 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 (*MaturityAssessment) Update

Update returns a builder for updating this MaturityAssessment. Note that you need to call MaturityAssessment.Unwrap() before calling this method if this MaturityAssessment was returned from a transaction, and the transaction was committed or rolled back.

func (*MaturityAssessment) Value

func (_m *MaturityAssessment) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the MaturityAssessment. This includes values selected through modifiers, order, etc.

type MaturityAssessmentClient

type MaturityAssessmentClient struct {
	// contains filtered or unexported fields
}

MaturityAssessmentClient is a client for the MaturityAssessment schema.

func NewMaturityAssessmentClient

func NewMaturityAssessmentClient(c config) *MaturityAssessmentClient

NewMaturityAssessmentClient returns a client for the MaturityAssessment from the given config.

func (*MaturityAssessmentClient) Create

Create returns a builder for creating a MaturityAssessment entity.

func (*MaturityAssessmentClient) CreateBulk

CreateBulk returns a builder for creating a bulk of MaturityAssessment entities.

func (*MaturityAssessmentClient) Delete

Delete returns a delete builder for MaturityAssessment.

func (*MaturityAssessmentClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*MaturityAssessmentClient) DeleteOneID

DeleteOneID returns a builder for deleting the given entity by its id.

func (*MaturityAssessmentClient) Get

Get returns a MaturityAssessment entity by its id.

func (*MaturityAssessmentClient) GetX

GetX is like Get, but panics if an error occurs.

func (*MaturityAssessmentClient) Hooks

func (c *MaturityAssessmentClient) Hooks() []Hook

Hooks returns the client hooks.

func (*MaturityAssessmentClient) Intercept

func (c *MaturityAssessmentClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `maturityassessment.Intercept(f(g(h())))`.

func (*MaturityAssessmentClient) Interceptors

func (c *MaturityAssessmentClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*MaturityAssessmentClient) MapCreateBulk

func (c *MaturityAssessmentClient) MapCreateBulk(slice any, setFunc func(*MaturityAssessmentCreate, int)) *MaturityAssessmentCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*MaturityAssessmentClient) Query

Query returns a query builder for MaturityAssessment.

func (*MaturityAssessmentClient) QueryCapabilityModel

QueryCapabilityModel queries the capability_model edge of a MaturityAssessment.

func (*MaturityAssessmentClient) Update

Update returns an update builder for MaturityAssessment.

func (*MaturityAssessmentClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*MaturityAssessmentClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*MaturityAssessmentClient) Use

func (c *MaturityAssessmentClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `maturityassessment.Hooks(f(g(h())))`.

type MaturityAssessmentCreate

type MaturityAssessmentCreate struct {
	// contains filtered or unexported fields
}

MaturityAssessmentCreate is the builder for creating a MaturityAssessment entity.

func (*MaturityAssessmentCreate) Exec

Exec executes the query.

func (*MaturityAssessmentCreate) ExecX

func (_c *MaturityAssessmentCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*MaturityAssessmentCreate) Mutation

Mutation returns the MaturityAssessmentMutation object of the builder.

func (*MaturityAssessmentCreate) Save

Save creates the MaturityAssessment in the database.

func (*MaturityAssessmentCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*MaturityAssessmentCreate) SetAssessedAt

SetAssessedAt sets the "assessed_at" field.

func (*MaturityAssessmentCreate) SetAssessedBy

SetAssessedBy sets the "assessed_by" field.

func (*MaturityAssessmentCreate) SetCapabilityModel

SetCapabilityModel sets the "capability_model" edge to the CapabilityModel entity.

func (*MaturityAssessmentCreate) SetCapabilityModelID

func (_c *MaturityAssessmentCreate) SetCapabilityModelID(id string) *MaturityAssessmentCreate

SetCapabilityModelID sets the "capability_model" edge to the CapabilityModel entity by ID.

func (*MaturityAssessmentCreate) SetID

SetID sets the "id" field.

func (*MaturityAssessmentCreate) SetInitiativeID

SetInitiativeID sets the "initiative_id" field.

func (*MaturityAssessmentCreate) SetModel

SetModel sets the "model" field.

func (*MaturityAssessmentCreate) SetNillableAssessedBy

func (_c *MaturityAssessmentCreate) SetNillableAssessedBy(v *string) *MaturityAssessmentCreate

SetNillableAssessedBy sets the "assessed_by" field if the given value is not nil.

func (*MaturityAssessmentCreate) SetNillableCapabilityModelID

func (_c *MaturityAssessmentCreate) SetNillableCapabilityModelID(id *string) *MaturityAssessmentCreate

SetNillableCapabilityModelID sets the "capability_model" edge to the CapabilityModel entity by ID if the given value is not nil.

func (*MaturityAssessmentCreate) SetNillableInitiativeID

func (_c *MaturityAssessmentCreate) SetNillableInitiativeID(v *string) *MaturityAssessmentCreate

SetNillableInitiativeID sets the "initiative_id" field if the given value is not nil.

func (*MaturityAssessmentCreate) SetNillableModel

func (_c *MaturityAssessmentCreate) SetNillableModel(v *string) *MaturityAssessmentCreate

SetNillableModel sets the "model" field if the given value is not nil.

func (*MaturityAssessmentCreate) SetNillableOrganization

func (_c *MaturityAssessmentCreate) SetNillableOrganization(v *string) *MaturityAssessmentCreate

SetNillableOrganization sets the "organization" field if the given value is not nil.

func (*MaturityAssessmentCreate) SetNillableOverallScore

func (_c *MaturityAssessmentCreate) SetNillableOverallScore(v *float64) *MaturityAssessmentCreate

SetNillableOverallScore sets the "overall_score" field if the given value is not nil.

func (*MaturityAssessmentCreate) SetNillableSummary

func (_c *MaturityAssessmentCreate) SetNillableSummary(v *string) *MaturityAssessmentCreate

SetNillableSummary sets the "summary" field if the given value is not nil.

func (*MaturityAssessmentCreate) SetOrganization

SetOrganization sets the "organization" field.

func (*MaturityAssessmentCreate) SetOverallScore

SetOverallScore sets the "overall_score" field.

func (*MaturityAssessmentCreate) SetScores

SetScores sets the "scores" field.

func (*MaturityAssessmentCreate) SetSummary

SetSummary sets the "summary" field.

type MaturityAssessmentCreateBulk

type MaturityAssessmentCreateBulk struct {
	// contains filtered or unexported fields
}

MaturityAssessmentCreateBulk is the builder for creating many MaturityAssessment entities in bulk.

func (*MaturityAssessmentCreateBulk) Exec

Exec executes the query.

func (*MaturityAssessmentCreateBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*MaturityAssessmentCreateBulk) Save

Save creates the MaturityAssessment entities in the database.

func (*MaturityAssessmentCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type MaturityAssessmentDelete

type MaturityAssessmentDelete struct {
	// contains filtered or unexported fields
}

MaturityAssessmentDelete is the builder for deleting a MaturityAssessment entity.

func (*MaturityAssessmentDelete) Exec

Exec executes the deletion query and returns how many vertices were deleted.

func (*MaturityAssessmentDelete) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*MaturityAssessmentDelete) Where

Where appends a list predicates to the MaturityAssessmentDelete builder.

type MaturityAssessmentDeleteOne

type MaturityAssessmentDeleteOne struct {
	// contains filtered or unexported fields
}

MaturityAssessmentDeleteOne is the builder for deleting a single MaturityAssessment entity.

func (*MaturityAssessmentDeleteOne) Exec

Exec executes the deletion query.

func (*MaturityAssessmentDeleteOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*MaturityAssessmentDeleteOne) Where

Where appends a list predicates to the MaturityAssessmentDelete builder.

type MaturityAssessmentEdges

type MaturityAssessmentEdges struct {
	// CapabilityModel holds the value of the capability_model edge.
	CapabilityModel *CapabilityModel `json:"capability_model,omitempty"`
	// contains filtered or unexported fields
}

MaturityAssessmentEdges holds the relations/edges for other nodes in the graph.

func (MaturityAssessmentEdges) CapabilityModelOrErr

func (e MaturityAssessmentEdges) CapabilityModelOrErr() (*CapabilityModel, error)

CapabilityModelOrErr returns the CapabilityModel value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

type MaturityAssessmentGroupBy

type MaturityAssessmentGroupBy struct {
	// contains filtered or unexported fields
}

MaturityAssessmentGroupBy is the group-by builder for MaturityAssessment entities.

func (*MaturityAssessmentGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*MaturityAssessmentGroupBy) Bool

func (s *MaturityAssessmentGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentGroupBy) BoolX

func (s *MaturityAssessmentGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*MaturityAssessmentGroupBy) Bools

func (s *MaturityAssessmentGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentGroupBy) BoolsX

func (s *MaturityAssessmentGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*MaturityAssessmentGroupBy) Float64

func (s *MaturityAssessmentGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentGroupBy) Float64X

func (s *MaturityAssessmentGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*MaturityAssessmentGroupBy) Float64s

func (s *MaturityAssessmentGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentGroupBy) Float64sX

func (s *MaturityAssessmentGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*MaturityAssessmentGroupBy) Int

func (s *MaturityAssessmentGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentGroupBy) IntX

func (s *MaturityAssessmentGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*MaturityAssessmentGroupBy) Ints

func (s *MaturityAssessmentGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentGroupBy) IntsX

func (s *MaturityAssessmentGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*MaturityAssessmentGroupBy) Scan

Scan applies the selector query and scans the result into the given value.

func (*MaturityAssessmentGroupBy) ScanX

func (s *MaturityAssessmentGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*MaturityAssessmentGroupBy) String

func (s *MaturityAssessmentGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentGroupBy) StringX

func (s *MaturityAssessmentGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*MaturityAssessmentGroupBy) Strings

func (s *MaturityAssessmentGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentGroupBy) StringsX

func (s *MaturityAssessmentGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type MaturityAssessmentMutation

type MaturityAssessmentMutation struct {
	// contains filtered or unexported fields
}

MaturityAssessmentMutation represents an operation that mutates the MaturityAssessment nodes in the graph.

func (*MaturityAssessmentMutation) AddField

func (m *MaturityAssessmentMutation) 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 (*MaturityAssessmentMutation) AddOverallScore

func (m *MaturityAssessmentMutation) AddOverallScore(f float64)

AddOverallScore adds f to the "overall_score" field.

func (*MaturityAssessmentMutation) AddedEdges

func (m *MaturityAssessmentMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*MaturityAssessmentMutation) AddedField

func (m *MaturityAssessmentMutation) 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 (*MaturityAssessmentMutation) AddedFields

func (m *MaturityAssessmentMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*MaturityAssessmentMutation) AddedIDs

func (m *MaturityAssessmentMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*MaturityAssessmentMutation) AddedOverallScore

func (m *MaturityAssessmentMutation) AddedOverallScore() (r float64, exists bool)

AddedOverallScore returns the value that was added to the "overall_score" field in this mutation.

func (*MaturityAssessmentMutation) AssessedAt

func (m *MaturityAssessmentMutation) AssessedAt() (r time.Time, exists bool)

AssessedAt returns the value of the "assessed_at" field in the mutation.

func (*MaturityAssessmentMutation) AssessedBy

func (m *MaturityAssessmentMutation) AssessedBy() (r string, exists bool)

AssessedBy returns the value of the "assessed_by" field in the mutation.

func (*MaturityAssessmentMutation) AssessedByCleared

func (m *MaturityAssessmentMutation) AssessedByCleared() bool

AssessedByCleared returns if the "assessed_by" field was cleared in this mutation.

func (*MaturityAssessmentMutation) CapabilityModelCleared

func (m *MaturityAssessmentMutation) CapabilityModelCleared() bool

CapabilityModelCleared reports if the "capability_model" edge to the CapabilityModel entity was cleared.

func (*MaturityAssessmentMutation) CapabilityModelID

func (m *MaturityAssessmentMutation) CapabilityModelID() (id string, exists bool)

CapabilityModelID returns the "capability_model" edge ID in the mutation.

func (*MaturityAssessmentMutation) CapabilityModelIDs

func (m *MaturityAssessmentMutation) CapabilityModelIDs() (ids []string)

CapabilityModelIDs returns the "capability_model" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use CapabilityModelID instead. It exists only for internal usage by the builders.

func (*MaturityAssessmentMutation) ClearAssessedBy

func (m *MaturityAssessmentMutation) ClearAssessedBy()

ClearAssessedBy clears the value of the "assessed_by" field.

func (*MaturityAssessmentMutation) ClearCapabilityModel

func (m *MaturityAssessmentMutation) ClearCapabilityModel()

ClearCapabilityModel clears the "capability_model" edge to the CapabilityModel entity.

func (*MaturityAssessmentMutation) ClearEdge

func (m *MaturityAssessmentMutation) 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 (*MaturityAssessmentMutation) ClearField

func (m *MaturityAssessmentMutation) 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 (*MaturityAssessmentMutation) ClearInitiativeID

func (m *MaturityAssessmentMutation) ClearInitiativeID()

ClearInitiativeID clears the value of the "initiative_id" field.

func (*MaturityAssessmentMutation) ClearModel

func (m *MaturityAssessmentMutation) ClearModel()

ClearModel clears the value of the "model" field.

func (*MaturityAssessmentMutation) ClearOrganization

func (m *MaturityAssessmentMutation) ClearOrganization()

ClearOrganization clears the value of the "organization" field.

func (*MaturityAssessmentMutation) ClearOverallScore

func (m *MaturityAssessmentMutation) ClearOverallScore()

ClearOverallScore clears the value of the "overall_score" field.

func (*MaturityAssessmentMutation) ClearScores

func (m *MaturityAssessmentMutation) ClearScores()

ClearScores clears the value of the "scores" field.

func (*MaturityAssessmentMutation) ClearSummary

func (m *MaturityAssessmentMutation) ClearSummary()

ClearSummary clears the value of the "summary" field.

func (*MaturityAssessmentMutation) ClearedEdges

func (m *MaturityAssessmentMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*MaturityAssessmentMutation) ClearedFields

func (m *MaturityAssessmentMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (MaturityAssessmentMutation) Client

func (m MaturityAssessmentMutation) 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 (*MaturityAssessmentMutation) EdgeCleared

func (m *MaturityAssessmentMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*MaturityAssessmentMutation) Field

func (m *MaturityAssessmentMutation) 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 (*MaturityAssessmentMutation) FieldCleared

func (m *MaturityAssessmentMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*MaturityAssessmentMutation) Fields

func (m *MaturityAssessmentMutation) 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 (*MaturityAssessmentMutation) ID

func (m *MaturityAssessmentMutation) ID() (id string, 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 (*MaturityAssessmentMutation) 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 (*MaturityAssessmentMutation) InitiativeID

func (m *MaturityAssessmentMutation) InitiativeID() (r string, exists bool)

InitiativeID returns the value of the "initiative_id" field in the mutation.

func (*MaturityAssessmentMutation) InitiativeIDCleared

func (m *MaturityAssessmentMutation) InitiativeIDCleared() bool

InitiativeIDCleared returns if the "initiative_id" field was cleared in this mutation.

func (*MaturityAssessmentMutation) Model

func (m *MaturityAssessmentMutation) Model() (r string, exists bool)

Model returns the value of the "model" field in the mutation.

func (*MaturityAssessmentMutation) ModelCleared

func (m *MaturityAssessmentMutation) ModelCleared() bool

ModelCleared returns if the "model" field was cleared in this mutation.

func (*MaturityAssessmentMutation) OldAssessedAt

func (m *MaturityAssessmentMutation) OldAssessedAt(ctx context.Context) (v time.Time, err error)

OldAssessedAt returns the old "assessed_at" field's value of the MaturityAssessment entity. If the MaturityAssessment 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 (*MaturityAssessmentMutation) OldAssessedBy

func (m *MaturityAssessmentMutation) OldAssessedBy(ctx context.Context) (v string, err error)

OldAssessedBy returns the old "assessed_by" field's value of the MaturityAssessment entity. If the MaturityAssessment 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 (*MaturityAssessmentMutation) OldField

func (m *MaturityAssessmentMutation) 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 (*MaturityAssessmentMutation) OldInitiativeID

func (m *MaturityAssessmentMutation) OldInitiativeID(ctx context.Context) (v string, err error)

OldInitiativeID returns the old "initiative_id" field's value of the MaturityAssessment entity. If the MaturityAssessment 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 (*MaturityAssessmentMutation) OldModel

func (m *MaturityAssessmentMutation) OldModel(ctx context.Context) (v string, err error)

OldModel returns the old "model" field's value of the MaturityAssessment entity. If the MaturityAssessment 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 (*MaturityAssessmentMutation) OldOrganization

func (m *MaturityAssessmentMutation) OldOrganization(ctx context.Context) (v string, err error)

OldOrganization returns the old "organization" field's value of the MaturityAssessment entity. If the MaturityAssessment 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 (*MaturityAssessmentMutation) OldOverallScore

func (m *MaturityAssessmentMutation) OldOverallScore(ctx context.Context) (v *float64, err error)

OldOverallScore returns the old "overall_score" field's value of the MaturityAssessment entity. If the MaturityAssessment 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 (*MaturityAssessmentMutation) OldScores

OldScores returns the old "scores" field's value of the MaturityAssessment entity. If the MaturityAssessment 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 (*MaturityAssessmentMutation) OldSummary

func (m *MaturityAssessmentMutation) OldSummary(ctx context.Context) (v string, err error)

OldSummary returns the old "summary" field's value of the MaturityAssessment entity. If the MaturityAssessment 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 (*MaturityAssessmentMutation) Op

Op returns the operation name.

func (*MaturityAssessmentMutation) Organization

func (m *MaturityAssessmentMutation) Organization() (r string, exists bool)

Organization returns the value of the "organization" field in the mutation.

func (*MaturityAssessmentMutation) OrganizationCleared

func (m *MaturityAssessmentMutation) OrganizationCleared() bool

OrganizationCleared returns if the "organization" field was cleared in this mutation.

func (*MaturityAssessmentMutation) OverallScore

func (m *MaturityAssessmentMutation) OverallScore() (r float64, exists bool)

OverallScore returns the value of the "overall_score" field in the mutation.

func (*MaturityAssessmentMutation) OverallScoreCleared

func (m *MaturityAssessmentMutation) OverallScoreCleared() bool

OverallScoreCleared returns if the "overall_score" field was cleared in this mutation.

func (*MaturityAssessmentMutation) RemovedEdges

func (m *MaturityAssessmentMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*MaturityAssessmentMutation) RemovedIDs

func (m *MaturityAssessmentMutation) 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 (*MaturityAssessmentMutation) ResetAssessedAt

func (m *MaturityAssessmentMutation) ResetAssessedAt()

ResetAssessedAt resets all changes to the "assessed_at" field.

func (*MaturityAssessmentMutation) ResetAssessedBy

func (m *MaturityAssessmentMutation) ResetAssessedBy()

ResetAssessedBy resets all changes to the "assessed_by" field.

func (*MaturityAssessmentMutation) ResetCapabilityModel

func (m *MaturityAssessmentMutation) ResetCapabilityModel()

ResetCapabilityModel resets all changes to the "capability_model" edge.

func (*MaturityAssessmentMutation) ResetEdge

func (m *MaturityAssessmentMutation) 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 (*MaturityAssessmentMutation) ResetField

func (m *MaturityAssessmentMutation) 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 (*MaturityAssessmentMutation) ResetInitiativeID

func (m *MaturityAssessmentMutation) ResetInitiativeID()

ResetInitiativeID resets all changes to the "initiative_id" field.

func (*MaturityAssessmentMutation) ResetModel

func (m *MaturityAssessmentMutation) ResetModel()

ResetModel resets all changes to the "model" field.

func (*MaturityAssessmentMutation) ResetOrganization

func (m *MaturityAssessmentMutation) ResetOrganization()

ResetOrganization resets all changes to the "organization" field.

func (*MaturityAssessmentMutation) ResetOverallScore

func (m *MaturityAssessmentMutation) ResetOverallScore()

ResetOverallScore resets all changes to the "overall_score" field.

func (*MaturityAssessmentMutation) ResetScores

func (m *MaturityAssessmentMutation) ResetScores()

ResetScores resets all changes to the "scores" field.

func (*MaturityAssessmentMutation) ResetSummary

func (m *MaturityAssessmentMutation) ResetSummary()

ResetSummary resets all changes to the "summary" field.

func (*MaturityAssessmentMutation) Scores

func (m *MaturityAssessmentMutation) Scores() (r map[string]schema.DimensionScore, exists bool)

Scores returns the value of the "scores" field in the mutation.

func (*MaturityAssessmentMutation) ScoresCleared

func (m *MaturityAssessmentMutation) ScoresCleared() bool

ScoresCleared returns if the "scores" field was cleared in this mutation.

func (*MaturityAssessmentMutation) SetAssessedAt

func (m *MaturityAssessmentMutation) SetAssessedAt(t time.Time)

SetAssessedAt sets the "assessed_at" field.

func (*MaturityAssessmentMutation) SetAssessedBy

func (m *MaturityAssessmentMutation) SetAssessedBy(s string)

SetAssessedBy sets the "assessed_by" field.

func (*MaturityAssessmentMutation) SetCapabilityModelID

func (m *MaturityAssessmentMutation) SetCapabilityModelID(id string)

SetCapabilityModelID sets the "capability_model" edge to the CapabilityModel entity by id.

func (*MaturityAssessmentMutation) SetField

func (m *MaturityAssessmentMutation) 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 (*MaturityAssessmentMutation) SetID

func (m *MaturityAssessmentMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of MaturityAssessment entities.

func (*MaturityAssessmentMutation) SetInitiativeID

func (m *MaturityAssessmentMutation) SetInitiativeID(s string)

SetInitiativeID sets the "initiative_id" field.

func (*MaturityAssessmentMutation) SetModel

func (m *MaturityAssessmentMutation) SetModel(s string)

SetModel sets the "model" field.

func (*MaturityAssessmentMutation) SetOp

func (m *MaturityAssessmentMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*MaturityAssessmentMutation) SetOrganization

func (m *MaturityAssessmentMutation) SetOrganization(s string)

SetOrganization sets the "organization" field.

func (*MaturityAssessmentMutation) SetOverallScore

func (m *MaturityAssessmentMutation) SetOverallScore(f float64)

SetOverallScore sets the "overall_score" field.

func (*MaturityAssessmentMutation) SetScores

SetScores sets the "scores" field.

func (*MaturityAssessmentMutation) SetSummary

func (m *MaturityAssessmentMutation) SetSummary(s string)

SetSummary sets the "summary" field.

func (*MaturityAssessmentMutation) Summary

func (m *MaturityAssessmentMutation) Summary() (r string, exists bool)

Summary returns the value of the "summary" field in the mutation.

func (*MaturityAssessmentMutation) SummaryCleared

func (m *MaturityAssessmentMutation) SummaryCleared() bool

SummaryCleared returns if the "summary" field was cleared in this mutation.

func (MaturityAssessmentMutation) Tx

func (m MaturityAssessmentMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*MaturityAssessmentMutation) Type

Type returns the node type of this mutation (MaturityAssessment).

func (*MaturityAssessmentMutation) Where

Where appends a list predicates to the MaturityAssessmentMutation builder.

func (*MaturityAssessmentMutation) WhereP

func (m *MaturityAssessmentMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the MaturityAssessmentMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type MaturityAssessmentQuery

type MaturityAssessmentQuery struct {
	// contains filtered or unexported fields
}

MaturityAssessmentQuery is the builder for querying MaturityAssessment entities.

func (*MaturityAssessmentQuery) Aggregate

Aggregate returns a MaturityAssessmentSelect configured with the given aggregations.

func (*MaturityAssessmentQuery) All

All executes the query and returns a list of MaturityAssessments.

func (*MaturityAssessmentQuery) AllX

AllX is like All, but panics if an error occurs.

func (*MaturityAssessmentQuery) Clone

Clone returns a duplicate of the MaturityAssessmentQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*MaturityAssessmentQuery) Count

func (_q *MaturityAssessmentQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*MaturityAssessmentQuery) CountX

func (_q *MaturityAssessmentQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*MaturityAssessmentQuery) Exist

func (_q *MaturityAssessmentQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*MaturityAssessmentQuery) ExistX

func (_q *MaturityAssessmentQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*MaturityAssessmentQuery) First

First returns the first MaturityAssessment entity from the query. Returns a *NotFoundError when no MaturityAssessment was found.

func (*MaturityAssessmentQuery) FirstID

func (_q *MaturityAssessmentQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first MaturityAssessment ID from the query. Returns a *NotFoundError when no MaturityAssessment ID was found.

func (*MaturityAssessmentQuery) FirstIDX

func (_q *MaturityAssessmentQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*MaturityAssessmentQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*MaturityAssessmentQuery) GroupBy

func (_q *MaturityAssessmentQuery) GroupBy(field string, fields ...string) *MaturityAssessmentGroupBy

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 {
	InitiativeID string `json:"initiative_id,omitempty"`
	Count int `json:"count,omitempty"`
}

client.MaturityAssessment.Query().
	GroupBy(maturityassessment.FieldInitiativeID).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*MaturityAssessmentQuery) IDs

func (_q *MaturityAssessmentQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of MaturityAssessment IDs.

func (*MaturityAssessmentQuery) IDsX

IDsX is like IDs, but panics if an error occurs.

func (*MaturityAssessmentQuery) Limit

Limit the number of records to be returned by this query.

func (*MaturityAssessmentQuery) Offset

Offset to start from.

func (*MaturityAssessmentQuery) Only

Only returns a single MaturityAssessment entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one MaturityAssessment entity is found. Returns a *NotFoundError when no MaturityAssessment entities are found.

func (*MaturityAssessmentQuery) OnlyID

func (_q *MaturityAssessmentQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only MaturityAssessment ID in the query. Returns a *NotSingularError when more than one MaturityAssessment ID is found. Returns a *NotFoundError when no entities are found.

func (*MaturityAssessmentQuery) OnlyIDX

func (_q *MaturityAssessmentQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*MaturityAssessmentQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*MaturityAssessmentQuery) Order

Order specifies how the records should be ordered.

func (*MaturityAssessmentQuery) QueryCapabilityModel

func (_q *MaturityAssessmentQuery) QueryCapabilityModel() *CapabilityModelQuery

QueryCapabilityModel chains the current query on the "capability_model" edge.

func (*MaturityAssessmentQuery) 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 {
	InitiativeID string `json:"initiative_id,omitempty"`
}

client.MaturityAssessment.Query().
	Select(maturityassessment.FieldInitiativeID).
	Scan(ctx, &v)

func (*MaturityAssessmentQuery) 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 (*MaturityAssessmentQuery) Where

Where adds a new predicate for the MaturityAssessmentQuery builder.

func (*MaturityAssessmentQuery) WithCapabilityModel

func (_q *MaturityAssessmentQuery) WithCapabilityModel(opts ...func(*CapabilityModelQuery)) *MaturityAssessmentQuery

WithCapabilityModel tells the query-builder to eager-load the nodes that are connected to the "capability_model" edge. The optional arguments are used to configure the query builder of the edge.

type MaturityAssessmentSelect

type MaturityAssessmentSelect struct {
	*MaturityAssessmentQuery
	// contains filtered or unexported fields
}

MaturityAssessmentSelect is the builder for selecting fields of MaturityAssessment entities.

func (*MaturityAssessmentSelect) Aggregate

Aggregate adds the given aggregation functions to the selector query.

func (*MaturityAssessmentSelect) Bool

func (s *MaturityAssessmentSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentSelect) BoolX

func (s *MaturityAssessmentSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*MaturityAssessmentSelect) Bools

func (s *MaturityAssessmentSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentSelect) BoolsX

func (s *MaturityAssessmentSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*MaturityAssessmentSelect) Float64

func (s *MaturityAssessmentSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentSelect) Float64X

func (s *MaturityAssessmentSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*MaturityAssessmentSelect) Float64s

func (s *MaturityAssessmentSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentSelect) Float64sX

func (s *MaturityAssessmentSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*MaturityAssessmentSelect) Int

func (s *MaturityAssessmentSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentSelect) IntX

func (s *MaturityAssessmentSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*MaturityAssessmentSelect) Ints

func (s *MaturityAssessmentSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentSelect) IntsX

func (s *MaturityAssessmentSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*MaturityAssessmentSelect) Scan

Scan applies the selector query and scans the result into the given value.

func (*MaturityAssessmentSelect) ScanX

func (s *MaturityAssessmentSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*MaturityAssessmentSelect) String

func (s *MaturityAssessmentSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentSelect) StringX

func (s *MaturityAssessmentSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*MaturityAssessmentSelect) Strings

func (s *MaturityAssessmentSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*MaturityAssessmentSelect) StringsX

func (s *MaturityAssessmentSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type MaturityAssessmentUpdate

type MaturityAssessmentUpdate struct {
	// contains filtered or unexported fields
}

MaturityAssessmentUpdate is the builder for updating MaturityAssessment entities.

func (*MaturityAssessmentUpdate) AddOverallScore

AddOverallScore adds value to the "overall_score" field.

func (*MaturityAssessmentUpdate) ClearAssessedBy

func (_u *MaturityAssessmentUpdate) ClearAssessedBy() *MaturityAssessmentUpdate

ClearAssessedBy clears the value of the "assessed_by" field.

func (*MaturityAssessmentUpdate) ClearCapabilityModel

func (_u *MaturityAssessmentUpdate) ClearCapabilityModel() *MaturityAssessmentUpdate

ClearCapabilityModel clears the "capability_model" edge to the CapabilityModel entity.

func (*MaturityAssessmentUpdate) ClearInitiativeID

func (_u *MaturityAssessmentUpdate) ClearInitiativeID() *MaturityAssessmentUpdate

ClearInitiativeID clears the value of the "initiative_id" field.

func (*MaturityAssessmentUpdate) ClearModel

ClearModel clears the value of the "model" field.

func (*MaturityAssessmentUpdate) ClearOrganization

func (_u *MaturityAssessmentUpdate) ClearOrganization() *MaturityAssessmentUpdate

ClearOrganization clears the value of the "organization" field.

func (*MaturityAssessmentUpdate) ClearOverallScore

func (_u *MaturityAssessmentUpdate) ClearOverallScore() *MaturityAssessmentUpdate

ClearOverallScore clears the value of the "overall_score" field.

func (*MaturityAssessmentUpdate) ClearScores

ClearScores clears the value of the "scores" field.

func (*MaturityAssessmentUpdate) ClearSummary

ClearSummary clears the value of the "summary" field.

func (*MaturityAssessmentUpdate) Exec

Exec executes the query.

func (*MaturityAssessmentUpdate) ExecX

func (_u *MaturityAssessmentUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*MaturityAssessmentUpdate) Mutation

Mutation returns the MaturityAssessmentMutation object of the builder.

func (*MaturityAssessmentUpdate) Save

Save executes the query and returns the number of nodes affected by the update operation.

func (*MaturityAssessmentUpdate) SaveX

SaveX is like Save, but panics if an error occurs.

func (*MaturityAssessmentUpdate) SetAssessedAt

SetAssessedAt sets the "assessed_at" field.

func (*MaturityAssessmentUpdate) SetAssessedBy

SetAssessedBy sets the "assessed_by" field.

func (*MaturityAssessmentUpdate) SetCapabilityModel

SetCapabilityModel sets the "capability_model" edge to the CapabilityModel entity.

func (*MaturityAssessmentUpdate) SetCapabilityModelID

func (_u *MaturityAssessmentUpdate) SetCapabilityModelID(id string) *MaturityAssessmentUpdate

SetCapabilityModelID sets the "capability_model" edge to the CapabilityModel entity by ID.

func (*MaturityAssessmentUpdate) SetInitiativeID

SetInitiativeID sets the "initiative_id" field.

func (*MaturityAssessmentUpdate) SetModel

SetModel sets the "model" field.

func (*MaturityAssessmentUpdate) SetNillableAssessedAt

func (_u *MaturityAssessmentUpdate) SetNillableAssessedAt(v *time.Time) *MaturityAssessmentUpdate

SetNillableAssessedAt sets the "assessed_at" field if the given value is not nil.

func (*MaturityAssessmentUpdate) SetNillableAssessedBy

func (_u *MaturityAssessmentUpdate) SetNillableAssessedBy(v *string) *MaturityAssessmentUpdate

SetNillableAssessedBy sets the "assessed_by" field if the given value is not nil.

func (*MaturityAssessmentUpdate) SetNillableCapabilityModelID

func (_u *MaturityAssessmentUpdate) SetNillableCapabilityModelID(id *string) *MaturityAssessmentUpdate

SetNillableCapabilityModelID sets the "capability_model" edge to the CapabilityModel entity by ID if the given value is not nil.

func (*MaturityAssessmentUpdate) SetNillableInitiativeID

func (_u *MaturityAssessmentUpdate) SetNillableInitiativeID(v *string) *MaturityAssessmentUpdate

SetNillableInitiativeID sets the "initiative_id" field if the given value is not nil.

func (*MaturityAssessmentUpdate) SetNillableModel

func (_u *MaturityAssessmentUpdate) SetNillableModel(v *string) *MaturityAssessmentUpdate

SetNillableModel sets the "model" field if the given value is not nil.

func (*MaturityAssessmentUpdate) SetNillableOrganization

func (_u *MaturityAssessmentUpdate) SetNillableOrganization(v *string) *MaturityAssessmentUpdate

SetNillableOrganization sets the "organization" field if the given value is not nil.

func (*MaturityAssessmentUpdate) SetNillableOverallScore

func (_u *MaturityAssessmentUpdate) SetNillableOverallScore(v *float64) *MaturityAssessmentUpdate

SetNillableOverallScore sets the "overall_score" field if the given value is not nil.

func (*MaturityAssessmentUpdate) SetNillableSummary

func (_u *MaturityAssessmentUpdate) SetNillableSummary(v *string) *MaturityAssessmentUpdate

SetNillableSummary sets the "summary" field if the given value is not nil.

func (*MaturityAssessmentUpdate) SetOrganization

SetOrganization sets the "organization" field.

func (*MaturityAssessmentUpdate) SetOverallScore

SetOverallScore sets the "overall_score" field.

func (*MaturityAssessmentUpdate) SetScores

SetScores sets the "scores" field.

func (*MaturityAssessmentUpdate) SetSummary

SetSummary sets the "summary" field.

func (*MaturityAssessmentUpdate) Where

Where appends a list predicates to the MaturityAssessmentUpdate builder.

type MaturityAssessmentUpdateOne

type MaturityAssessmentUpdateOne struct {
	// contains filtered or unexported fields
}

MaturityAssessmentUpdateOne is the builder for updating a single MaturityAssessment entity.

func (*MaturityAssessmentUpdateOne) AddOverallScore

AddOverallScore adds value to the "overall_score" field.

func (*MaturityAssessmentUpdateOne) ClearAssessedBy

ClearAssessedBy clears the value of the "assessed_by" field.

func (*MaturityAssessmentUpdateOne) ClearCapabilityModel

func (_u *MaturityAssessmentUpdateOne) ClearCapabilityModel() *MaturityAssessmentUpdateOne

ClearCapabilityModel clears the "capability_model" edge to the CapabilityModel entity.

func (*MaturityAssessmentUpdateOne) ClearInitiativeID

ClearInitiativeID clears the value of the "initiative_id" field.

func (*MaturityAssessmentUpdateOne) ClearModel

ClearModel clears the value of the "model" field.

func (*MaturityAssessmentUpdateOne) ClearOrganization

ClearOrganization clears the value of the "organization" field.

func (*MaturityAssessmentUpdateOne) ClearOverallScore

ClearOverallScore clears the value of the "overall_score" field.

func (*MaturityAssessmentUpdateOne) ClearScores

ClearScores clears the value of the "scores" field.

func (*MaturityAssessmentUpdateOne) ClearSummary

ClearSummary clears the value of the "summary" field.

func (*MaturityAssessmentUpdateOne) Exec

Exec executes the query on the entity.

func (*MaturityAssessmentUpdateOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*MaturityAssessmentUpdateOne) Mutation

Mutation returns the MaturityAssessmentMutation object of the builder.

func (*MaturityAssessmentUpdateOne) Save

Save executes the query and returns the updated MaturityAssessment entity.

func (*MaturityAssessmentUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*MaturityAssessmentUpdateOne) 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 (*MaturityAssessmentUpdateOne) SetAssessedAt

SetAssessedAt sets the "assessed_at" field.

func (*MaturityAssessmentUpdateOne) SetAssessedBy

SetAssessedBy sets the "assessed_by" field.

func (*MaturityAssessmentUpdateOne) SetCapabilityModel

SetCapabilityModel sets the "capability_model" edge to the CapabilityModel entity.

func (*MaturityAssessmentUpdateOne) SetCapabilityModelID

func (_u *MaturityAssessmentUpdateOne) SetCapabilityModelID(id string) *MaturityAssessmentUpdateOne

SetCapabilityModelID sets the "capability_model" edge to the CapabilityModel entity by ID.

func (*MaturityAssessmentUpdateOne) SetInitiativeID

SetInitiativeID sets the "initiative_id" field.

func (*MaturityAssessmentUpdateOne) SetModel

SetModel sets the "model" field.

func (*MaturityAssessmentUpdateOne) SetNillableAssessedAt

func (_u *MaturityAssessmentUpdateOne) SetNillableAssessedAt(v *time.Time) *MaturityAssessmentUpdateOne

SetNillableAssessedAt sets the "assessed_at" field if the given value is not nil.

func (*MaturityAssessmentUpdateOne) SetNillableAssessedBy

func (_u *MaturityAssessmentUpdateOne) SetNillableAssessedBy(v *string) *MaturityAssessmentUpdateOne

SetNillableAssessedBy sets the "assessed_by" field if the given value is not nil.

func (*MaturityAssessmentUpdateOne) SetNillableCapabilityModelID

func (_u *MaturityAssessmentUpdateOne) SetNillableCapabilityModelID(id *string) *MaturityAssessmentUpdateOne

SetNillableCapabilityModelID sets the "capability_model" edge to the CapabilityModel entity by ID if the given value is not nil.

func (*MaturityAssessmentUpdateOne) SetNillableInitiativeID

func (_u *MaturityAssessmentUpdateOne) SetNillableInitiativeID(v *string) *MaturityAssessmentUpdateOne

SetNillableInitiativeID sets the "initiative_id" field if the given value is not nil.

func (*MaturityAssessmentUpdateOne) SetNillableModel

SetNillableModel sets the "model" field if the given value is not nil.

func (*MaturityAssessmentUpdateOne) SetNillableOrganization

func (_u *MaturityAssessmentUpdateOne) SetNillableOrganization(v *string) *MaturityAssessmentUpdateOne

SetNillableOrganization sets the "organization" field if the given value is not nil.

func (*MaturityAssessmentUpdateOne) SetNillableOverallScore

func (_u *MaturityAssessmentUpdateOne) SetNillableOverallScore(v *float64) *MaturityAssessmentUpdateOne

SetNillableOverallScore sets the "overall_score" field if the given value is not nil.

func (*MaturityAssessmentUpdateOne) SetNillableSummary

SetNillableSummary sets the "summary" field if the given value is not nil.

func (*MaturityAssessmentUpdateOne) SetOrganization

SetOrganization sets the "organization" field.

func (*MaturityAssessmentUpdateOne) SetOverallScore

SetOverallScore sets the "overall_score" field.

func (*MaturityAssessmentUpdateOne) SetScores

SetScores sets the "scores" field.

func (*MaturityAssessmentUpdateOne) SetSummary

SetSummary sets the "summary" field.

func (*MaturityAssessmentUpdateOne) Where

Where appends a list predicates to the MaturityAssessmentUpdate builder.

type MaturityAssessments

type MaturityAssessments []*MaturityAssessment

MaturityAssessments is a parsable slice of MaturityAssessment.

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 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(...any)) Option

Log sets the logging function for debug mode.

type OrderFunc

type OrderFunc func(*sql.Selector)

OrderFunc applies an ordering on the sql selector. Deprecated: Use Asc/Desc functions or the package builders instead.

type Phase

type Phase struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// SequenceNumber holds the value of the "sequence_number" field.
	SequenceNumber int `json:"sequence_number,omitempty"`
	// Title holds the value of the "title" field.
	Title string `json:"title,omitempty"`
	// Theme holds the value of the "theme" field.
	Theme string `json:"theme,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the PhaseQuery when eager-loading is set.
	Edges PhaseEdges `json:"edges"`
	// contains filtered or unexported fields
}

Phase is the model entity for the Phase schema.

func (*Phase) QueryInitiative

func (_m *Phase) QueryInitiative() *InitiativeQuery

QueryInitiative queries the "initiative" edge of the Phase entity.

func (*Phase) QueryRoadmapItems

func (_m *Phase) QueryRoadmapItems() *RoadmapItemQuery

QueryRoadmapItems queries the "roadmap_items" edge of the Phase entity.

func (*Phase) String

func (_m *Phase) String() string

String implements the fmt.Stringer.

func (*Phase) Unwrap

func (_m *Phase) Unwrap() *Phase

Unwrap unwraps the Phase 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 (*Phase) Update

func (_m *Phase) Update() *PhaseUpdateOne

Update returns a builder for updating this Phase. Note that you need to call Phase.Unwrap() before calling this method if this Phase was returned from a transaction, and the transaction was committed or rolled back.

func (*Phase) Value

func (_m *Phase) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the Phase. This includes values selected through modifiers, order, etc.

type PhaseClient

type PhaseClient struct {
	// contains filtered or unexported fields
}

PhaseClient is a client for the Phase schema.

func NewPhaseClient

func NewPhaseClient(c config) *PhaseClient

NewPhaseClient returns a client for the Phase from the given config.

func (*PhaseClient) Create

func (c *PhaseClient) Create() *PhaseCreate

Create returns a builder for creating a Phase entity.

func (*PhaseClient) CreateBulk

func (c *PhaseClient) CreateBulk(builders ...*PhaseCreate) *PhaseCreateBulk

CreateBulk returns a builder for creating a bulk of Phase entities.

func (*PhaseClient) Delete

func (c *PhaseClient) Delete() *PhaseDelete

Delete returns a delete builder for Phase.

func (*PhaseClient) DeleteOne

func (c *PhaseClient) DeleteOne(_m *Phase) *PhaseDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*PhaseClient) DeleteOneID

func (c *PhaseClient) DeleteOneID(id string) *PhaseDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*PhaseClient) Get

func (c *PhaseClient) Get(ctx context.Context, id string) (*Phase, error)

Get returns a Phase entity by its id.

func (*PhaseClient) GetX

func (c *PhaseClient) GetX(ctx context.Context, id string) *Phase

GetX is like Get, but panics if an error occurs.

func (*PhaseClient) Hooks

func (c *PhaseClient) Hooks() []Hook

Hooks returns the client hooks.

func (*PhaseClient) Intercept

func (c *PhaseClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `phase.Intercept(f(g(h())))`.

func (*PhaseClient) Interceptors

func (c *PhaseClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*PhaseClient) MapCreateBulk

func (c *PhaseClient) MapCreateBulk(slice any, setFunc func(*PhaseCreate, int)) *PhaseCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*PhaseClient) Query

func (c *PhaseClient) Query() *PhaseQuery

Query returns a query builder for Phase.

func (*PhaseClient) QueryInitiative

func (c *PhaseClient) QueryInitiative(_m *Phase) *InitiativeQuery

QueryInitiative queries the initiative edge of a Phase.

func (*PhaseClient) QueryRoadmapItems

func (c *PhaseClient) QueryRoadmapItems(_m *Phase) *RoadmapItemQuery

QueryRoadmapItems queries the roadmap_items edge of a Phase.

func (*PhaseClient) Update

func (c *PhaseClient) Update() *PhaseUpdate

Update returns an update builder for Phase.

func (*PhaseClient) UpdateOne

func (c *PhaseClient) UpdateOne(_m *Phase) *PhaseUpdateOne

UpdateOne returns an update builder for the given entity.

func (*PhaseClient) UpdateOneID

func (c *PhaseClient) UpdateOneID(id string) *PhaseUpdateOne

UpdateOneID returns an update builder for the given id.

func (*PhaseClient) Use

func (c *PhaseClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `phase.Hooks(f(g(h())))`.

type PhaseCreate

type PhaseCreate struct {
	// contains filtered or unexported fields
}

PhaseCreate is the builder for creating a Phase entity.

func (*PhaseCreate) AddRoadmapItemIDs

func (_c *PhaseCreate) AddRoadmapItemIDs(ids ...string) *PhaseCreate

AddRoadmapItemIDs adds the "roadmap_items" edge to the RoadmapItem entity by IDs.

func (*PhaseCreate) AddRoadmapItems

func (_c *PhaseCreate) AddRoadmapItems(v ...*RoadmapItem) *PhaseCreate

AddRoadmapItems adds the "roadmap_items" edges to the RoadmapItem entity.

func (*PhaseCreate) Exec

func (_c *PhaseCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*PhaseCreate) ExecX

func (_c *PhaseCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*PhaseCreate) Mutation

func (_c *PhaseCreate) Mutation() *PhaseMutation

Mutation returns the PhaseMutation object of the builder.

func (*PhaseCreate) Save

func (_c *PhaseCreate) Save(ctx context.Context) (*Phase, error)

Save creates the Phase in the database.

func (*PhaseCreate) SaveX

func (_c *PhaseCreate) SaveX(ctx context.Context) *Phase

SaveX calls Save and panics if Save returns an error.

func (*PhaseCreate) SetID

func (_c *PhaseCreate) SetID(v string) *PhaseCreate

SetID sets the "id" field.

func (*PhaseCreate) SetInitiative

func (_c *PhaseCreate) SetInitiative(v *Initiative) *PhaseCreate

SetInitiative sets the "initiative" edge to the Initiative entity.

func (*PhaseCreate) SetInitiativeID

func (_c *PhaseCreate) SetInitiativeID(id string) *PhaseCreate

SetInitiativeID sets the "initiative" edge to the Initiative entity by ID.

func (*PhaseCreate) SetNillableTheme

func (_c *PhaseCreate) SetNillableTheme(v *string) *PhaseCreate

SetNillableTheme sets the "theme" field if the given value is not nil.

func (*PhaseCreate) SetSequenceNumber

func (_c *PhaseCreate) SetSequenceNumber(v int) *PhaseCreate

SetSequenceNumber sets the "sequence_number" field.

func (*PhaseCreate) SetTheme

func (_c *PhaseCreate) SetTheme(v string) *PhaseCreate

SetTheme sets the "theme" field.

func (*PhaseCreate) SetTitle

func (_c *PhaseCreate) SetTitle(v string) *PhaseCreate

SetTitle sets the "title" field.

type PhaseCreateBulk

type PhaseCreateBulk struct {
	// contains filtered or unexported fields
}

PhaseCreateBulk is the builder for creating many Phase entities in bulk.

func (*PhaseCreateBulk) Exec

func (_c *PhaseCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*PhaseCreateBulk) ExecX

func (_c *PhaseCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*PhaseCreateBulk) Save

func (_c *PhaseCreateBulk) Save(ctx context.Context) ([]*Phase, error)

Save creates the Phase entities in the database.

func (*PhaseCreateBulk) SaveX

func (_c *PhaseCreateBulk) SaveX(ctx context.Context) []*Phase

SaveX is like Save, but panics if an error occurs.

type PhaseDelete

type PhaseDelete struct {
	// contains filtered or unexported fields
}

PhaseDelete is the builder for deleting a Phase entity.

func (*PhaseDelete) Exec

func (_d *PhaseDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*PhaseDelete) ExecX

func (_d *PhaseDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*PhaseDelete) Where

func (_d *PhaseDelete) Where(ps ...predicate.Phase) *PhaseDelete

Where appends a list predicates to the PhaseDelete builder.

type PhaseDeleteOne

type PhaseDeleteOne struct {
	// contains filtered or unexported fields
}

PhaseDeleteOne is the builder for deleting a single Phase entity.

func (*PhaseDeleteOne) Exec

func (_d *PhaseDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*PhaseDeleteOne) ExecX

func (_d *PhaseDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*PhaseDeleteOne) Where

func (_d *PhaseDeleteOne) Where(ps ...predicate.Phase) *PhaseDeleteOne

Where appends a list predicates to the PhaseDelete builder.

type PhaseEdges

type PhaseEdges struct {
	// Initiative holds the value of the initiative edge.
	Initiative *Initiative `json:"initiative,omitempty"`
	// RoadmapItems holds the value of the roadmap_items edge.
	RoadmapItems []*RoadmapItem `json:"roadmap_items,omitempty"`
	// contains filtered or unexported fields
}

PhaseEdges holds the relations/edges for other nodes in the graph.

func (PhaseEdges) InitiativeOrErr

func (e PhaseEdges) InitiativeOrErr() (*Initiative, error)

InitiativeOrErr returns the Initiative value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (PhaseEdges) RoadmapItemsOrErr

func (e PhaseEdges) RoadmapItemsOrErr() ([]*RoadmapItem, error)

RoadmapItemsOrErr returns the RoadmapItems value or an error if the edge was not loaded in eager-loading.

type PhaseGroupBy

type PhaseGroupBy struct {
	// contains filtered or unexported fields
}

PhaseGroupBy is the group-by builder for Phase entities.

func (*PhaseGroupBy) Aggregate

func (_g *PhaseGroupBy) Aggregate(fns ...AggregateFunc) *PhaseGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*PhaseGroupBy) Bool

func (s *PhaseGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*PhaseGroupBy) BoolX

func (s *PhaseGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*PhaseGroupBy) Bools

func (s *PhaseGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*PhaseGroupBy) BoolsX

func (s *PhaseGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*PhaseGroupBy) Float64

func (s *PhaseGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*PhaseGroupBy) Float64X

func (s *PhaseGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*PhaseGroupBy) Float64s

func (s *PhaseGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*PhaseGroupBy) Float64sX

func (s *PhaseGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*PhaseGroupBy) Int

func (s *PhaseGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*PhaseGroupBy) IntX

func (s *PhaseGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*PhaseGroupBy) Ints

func (s *PhaseGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*PhaseGroupBy) IntsX

func (s *PhaseGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*PhaseGroupBy) Scan

func (_g *PhaseGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*PhaseGroupBy) ScanX

func (s *PhaseGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*PhaseGroupBy) String

func (s *PhaseGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*PhaseGroupBy) StringX

func (s *PhaseGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*PhaseGroupBy) Strings

func (s *PhaseGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*PhaseGroupBy) StringsX

func (s *PhaseGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type PhaseMutation

type PhaseMutation struct {
	// contains filtered or unexported fields
}

PhaseMutation represents an operation that mutates the Phase nodes in the graph.

func (*PhaseMutation) AddField

func (m *PhaseMutation) 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 (*PhaseMutation) AddRoadmapItemIDs

func (m *PhaseMutation) AddRoadmapItemIDs(ids ...string)

AddRoadmapItemIDs adds the "roadmap_items" edge to the RoadmapItem entity by ids.

func (*PhaseMutation) AddSequenceNumber

func (m *PhaseMutation) AddSequenceNumber(i int)

AddSequenceNumber adds i to the "sequence_number" field.

func (*PhaseMutation) AddedEdges

func (m *PhaseMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*PhaseMutation) AddedField

func (m *PhaseMutation) 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 (*PhaseMutation) AddedFields

func (m *PhaseMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*PhaseMutation) AddedIDs

func (m *PhaseMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*PhaseMutation) AddedSequenceNumber

func (m *PhaseMutation) AddedSequenceNumber() (r int, exists bool)

AddedSequenceNumber returns the value that was added to the "sequence_number" field in this mutation.

func (*PhaseMutation) ClearEdge

func (m *PhaseMutation) 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 (*PhaseMutation) ClearField

func (m *PhaseMutation) 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 (*PhaseMutation) ClearInitiative

func (m *PhaseMutation) ClearInitiative()

ClearInitiative clears the "initiative" edge to the Initiative entity.

func (*PhaseMutation) ClearRoadmapItems

func (m *PhaseMutation) ClearRoadmapItems()

ClearRoadmapItems clears the "roadmap_items" edge to the RoadmapItem entity.

func (*PhaseMutation) ClearTheme

func (m *PhaseMutation) ClearTheme()

ClearTheme clears the value of the "theme" field.

func (*PhaseMutation) ClearedEdges

func (m *PhaseMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*PhaseMutation) ClearedFields

func (m *PhaseMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (PhaseMutation) Client

func (m PhaseMutation) 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 (*PhaseMutation) EdgeCleared

func (m *PhaseMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*PhaseMutation) Field

func (m *PhaseMutation) 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 (*PhaseMutation) FieldCleared

func (m *PhaseMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*PhaseMutation) Fields

func (m *PhaseMutation) 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 (*PhaseMutation) ID

func (m *PhaseMutation) ID() (id string, 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 (*PhaseMutation) IDs

func (m *PhaseMutation) IDs(ctx context.Context) ([]string, 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 (*PhaseMutation) InitiativeCleared

func (m *PhaseMutation) InitiativeCleared() bool

InitiativeCleared reports if the "initiative" edge to the Initiative entity was cleared.

func (*PhaseMutation) InitiativeID

func (m *PhaseMutation) InitiativeID() (id string, exists bool)

InitiativeID returns the "initiative" edge ID in the mutation.

func (*PhaseMutation) InitiativeIDs

func (m *PhaseMutation) InitiativeIDs() (ids []string)

InitiativeIDs returns the "initiative" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use InitiativeID instead. It exists only for internal usage by the builders.

func (*PhaseMutation) OldField

func (m *PhaseMutation) 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 (*PhaseMutation) OldSequenceNumber

func (m *PhaseMutation) OldSequenceNumber(ctx context.Context) (v int, err error)

OldSequenceNumber returns the old "sequence_number" field's value of the Phase entity. If the Phase 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 (*PhaseMutation) OldTheme

func (m *PhaseMutation) OldTheme(ctx context.Context) (v string, err error)

OldTheme returns the old "theme" field's value of the Phase entity. If the Phase 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 (*PhaseMutation) OldTitle

func (m *PhaseMutation) OldTitle(ctx context.Context) (v string, err error)

OldTitle returns the old "title" field's value of the Phase entity. If the Phase 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 (*PhaseMutation) Op

func (m *PhaseMutation) Op() Op

Op returns the operation name.

func (*PhaseMutation) RemoveRoadmapItemIDs

func (m *PhaseMutation) RemoveRoadmapItemIDs(ids ...string)

RemoveRoadmapItemIDs removes the "roadmap_items" edge to the RoadmapItem entity by IDs.

func (*PhaseMutation) RemovedEdges

func (m *PhaseMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*PhaseMutation) RemovedIDs

func (m *PhaseMutation) 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 (*PhaseMutation) RemovedRoadmapItemsIDs

func (m *PhaseMutation) RemovedRoadmapItemsIDs() (ids []string)

RemovedRoadmapItems returns the removed IDs of the "roadmap_items" edge to the RoadmapItem entity.

func (*PhaseMutation) ResetEdge

func (m *PhaseMutation) 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 (*PhaseMutation) ResetField

func (m *PhaseMutation) 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 (*PhaseMutation) ResetInitiative

func (m *PhaseMutation) ResetInitiative()

ResetInitiative resets all changes to the "initiative" edge.

func (*PhaseMutation) ResetRoadmapItems

func (m *PhaseMutation) ResetRoadmapItems()

ResetRoadmapItems resets all changes to the "roadmap_items" edge.

func (*PhaseMutation) ResetSequenceNumber

func (m *PhaseMutation) ResetSequenceNumber()

ResetSequenceNumber resets all changes to the "sequence_number" field.

func (*PhaseMutation) ResetTheme

func (m *PhaseMutation) ResetTheme()

ResetTheme resets all changes to the "theme" field.

func (*PhaseMutation) ResetTitle

func (m *PhaseMutation) ResetTitle()

ResetTitle resets all changes to the "title" field.

func (*PhaseMutation) RoadmapItemsCleared

func (m *PhaseMutation) RoadmapItemsCleared() bool

RoadmapItemsCleared reports if the "roadmap_items" edge to the RoadmapItem entity was cleared.

func (*PhaseMutation) RoadmapItemsIDs

func (m *PhaseMutation) RoadmapItemsIDs() (ids []string)

RoadmapItemsIDs returns the "roadmap_items" edge IDs in the mutation.

func (*PhaseMutation) SequenceNumber

func (m *PhaseMutation) SequenceNumber() (r int, exists bool)

SequenceNumber returns the value of the "sequence_number" field in the mutation.

func (*PhaseMutation) SetField

func (m *PhaseMutation) 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 (*PhaseMutation) SetID

func (m *PhaseMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of Phase entities.

func (*PhaseMutation) SetInitiativeID

func (m *PhaseMutation) SetInitiativeID(id string)

SetInitiativeID sets the "initiative" edge to the Initiative entity by id.

func (*PhaseMutation) SetOp

func (m *PhaseMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*PhaseMutation) SetSequenceNumber

func (m *PhaseMutation) SetSequenceNumber(i int)

SetSequenceNumber sets the "sequence_number" field.

func (*PhaseMutation) SetTheme

func (m *PhaseMutation) SetTheme(s string)

SetTheme sets the "theme" field.

func (*PhaseMutation) SetTitle

func (m *PhaseMutation) SetTitle(s string)

SetTitle sets the "title" field.

func (*PhaseMutation) Theme

func (m *PhaseMutation) Theme() (r string, exists bool)

Theme returns the value of the "theme" field in the mutation.

func (*PhaseMutation) ThemeCleared

func (m *PhaseMutation) ThemeCleared() bool

ThemeCleared returns if the "theme" field was cleared in this mutation.

func (*PhaseMutation) Title

func (m *PhaseMutation) Title() (r string, exists bool)

Title returns the value of the "title" field in the mutation.

func (PhaseMutation) Tx

func (m PhaseMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*PhaseMutation) Type

func (m *PhaseMutation) Type() string

Type returns the node type of this mutation (Phase).

func (*PhaseMutation) Where

func (m *PhaseMutation) Where(ps ...predicate.Phase)

Where appends a list predicates to the PhaseMutation builder.

func (*PhaseMutation) WhereP

func (m *PhaseMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the PhaseMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type PhaseQuery

type PhaseQuery struct {
	// contains filtered or unexported fields
}

PhaseQuery is the builder for querying Phase entities.

func (*PhaseQuery) Aggregate

func (_q *PhaseQuery) Aggregate(fns ...AggregateFunc) *PhaseSelect

Aggregate returns a PhaseSelect configured with the given aggregations.

func (*PhaseQuery) All

func (_q *PhaseQuery) All(ctx context.Context) ([]*Phase, error)

All executes the query and returns a list of Phases.

func (*PhaseQuery) AllX

func (_q *PhaseQuery) AllX(ctx context.Context) []*Phase

AllX is like All, but panics if an error occurs.

func (*PhaseQuery) Clone

func (_q *PhaseQuery) Clone() *PhaseQuery

Clone returns a duplicate of the PhaseQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*PhaseQuery) Count

func (_q *PhaseQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*PhaseQuery) CountX

func (_q *PhaseQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*PhaseQuery) Exist

func (_q *PhaseQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*PhaseQuery) ExistX

func (_q *PhaseQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*PhaseQuery) First

func (_q *PhaseQuery) First(ctx context.Context) (*Phase, error)

First returns the first Phase entity from the query. Returns a *NotFoundError when no Phase was found.

func (*PhaseQuery) FirstID

func (_q *PhaseQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first Phase ID from the query. Returns a *NotFoundError when no Phase ID was found.

func (*PhaseQuery) FirstIDX

func (_q *PhaseQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*PhaseQuery) FirstX

func (_q *PhaseQuery) FirstX(ctx context.Context) *Phase

FirstX is like First, but panics if an error occurs.

func (*PhaseQuery) GroupBy

func (_q *PhaseQuery) GroupBy(field string, fields ...string) *PhaseGroupBy

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 {
	SequenceNumber int `json:"sequence_number,omitempty"`
	Count int `json:"count,omitempty"`
}

client.Phase.Query().
	GroupBy(phase.FieldSequenceNumber).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*PhaseQuery) IDs

func (_q *PhaseQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of Phase IDs.

func (*PhaseQuery) IDsX

func (_q *PhaseQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*PhaseQuery) Limit

func (_q *PhaseQuery) Limit(limit int) *PhaseQuery

Limit the number of records to be returned by this query.

func (*PhaseQuery) Offset

func (_q *PhaseQuery) Offset(offset int) *PhaseQuery

Offset to start from.

func (*PhaseQuery) Only

func (_q *PhaseQuery) Only(ctx context.Context) (*Phase, error)

Only returns a single Phase entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Phase entity is found. Returns a *NotFoundError when no Phase entities are found.

func (*PhaseQuery) OnlyID

func (_q *PhaseQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only Phase ID in the query. Returns a *NotSingularError when more than one Phase ID is found. Returns a *NotFoundError when no entities are found.

func (*PhaseQuery) OnlyIDX

func (_q *PhaseQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*PhaseQuery) OnlyX

func (_q *PhaseQuery) OnlyX(ctx context.Context) *Phase

OnlyX is like Only, but panics if an error occurs.

func (*PhaseQuery) Order

func (_q *PhaseQuery) Order(o ...phase.OrderOption) *PhaseQuery

Order specifies how the records should be ordered.

func (*PhaseQuery) QueryInitiative

func (_q *PhaseQuery) QueryInitiative() *InitiativeQuery

QueryInitiative chains the current query on the "initiative" edge.

func (*PhaseQuery) QueryRoadmapItems

func (_q *PhaseQuery) QueryRoadmapItems() *RoadmapItemQuery

QueryRoadmapItems chains the current query on the "roadmap_items" edge.

func (*PhaseQuery) Select

func (_q *PhaseQuery) Select(fields ...string) *PhaseSelect

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 {
	SequenceNumber int `json:"sequence_number,omitempty"`
}

client.Phase.Query().
	Select(phase.FieldSequenceNumber).
	Scan(ctx, &v)

func (*PhaseQuery) Unique

func (_q *PhaseQuery) Unique(unique bool) *PhaseQuery

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 (*PhaseQuery) Where

func (_q *PhaseQuery) Where(ps ...predicate.Phase) *PhaseQuery

Where adds a new predicate for the PhaseQuery builder.

func (*PhaseQuery) WithInitiative

func (_q *PhaseQuery) WithInitiative(opts ...func(*InitiativeQuery)) *PhaseQuery

WithInitiative tells the query-builder to eager-load the nodes that are connected to the "initiative" edge. The optional arguments are used to configure the query builder of the edge.

func (*PhaseQuery) WithRoadmapItems

func (_q *PhaseQuery) WithRoadmapItems(opts ...func(*RoadmapItemQuery)) *PhaseQuery

WithRoadmapItems tells the query-builder to eager-load the nodes that are connected to the "roadmap_items" edge. The optional arguments are used to configure the query builder of the edge.

type PhaseSelect

type PhaseSelect struct {
	*PhaseQuery
	// contains filtered or unexported fields
}

PhaseSelect is the builder for selecting fields of Phase entities.

func (*PhaseSelect) Aggregate

func (_s *PhaseSelect) Aggregate(fns ...AggregateFunc) *PhaseSelect

Aggregate adds the given aggregation functions to the selector query.

func (*PhaseSelect) Bool

func (s *PhaseSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*PhaseSelect) BoolX

func (s *PhaseSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*PhaseSelect) Bools

func (s *PhaseSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*PhaseSelect) BoolsX

func (s *PhaseSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*PhaseSelect) Float64

func (s *PhaseSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*PhaseSelect) Float64X

func (s *PhaseSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*PhaseSelect) Float64s

func (s *PhaseSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*PhaseSelect) Float64sX

func (s *PhaseSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*PhaseSelect) Int

func (s *PhaseSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*PhaseSelect) IntX

func (s *PhaseSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*PhaseSelect) Ints

func (s *PhaseSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*PhaseSelect) IntsX

func (s *PhaseSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*PhaseSelect) Scan

func (_s *PhaseSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*PhaseSelect) ScanX

func (s *PhaseSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*PhaseSelect) String

func (s *PhaseSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*PhaseSelect) StringX

func (s *PhaseSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*PhaseSelect) Strings

func (s *PhaseSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*PhaseSelect) StringsX

func (s *PhaseSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type PhaseUpdate

type PhaseUpdate struct {
	// contains filtered or unexported fields
}

PhaseUpdate is the builder for updating Phase entities.

func (*PhaseUpdate) AddRoadmapItemIDs

func (_u *PhaseUpdate) AddRoadmapItemIDs(ids ...string) *PhaseUpdate

AddRoadmapItemIDs adds the "roadmap_items" edge to the RoadmapItem entity by IDs.

func (*PhaseUpdate) AddRoadmapItems

func (_u *PhaseUpdate) AddRoadmapItems(v ...*RoadmapItem) *PhaseUpdate

AddRoadmapItems adds the "roadmap_items" edges to the RoadmapItem entity.

func (*PhaseUpdate) AddSequenceNumber

func (_u *PhaseUpdate) AddSequenceNumber(v int) *PhaseUpdate

AddSequenceNumber adds value to the "sequence_number" field.

func (*PhaseUpdate) ClearInitiative

func (_u *PhaseUpdate) ClearInitiative() *PhaseUpdate

ClearInitiative clears the "initiative" edge to the Initiative entity.

func (*PhaseUpdate) ClearRoadmapItems

func (_u *PhaseUpdate) ClearRoadmapItems() *PhaseUpdate

ClearRoadmapItems clears all "roadmap_items" edges to the RoadmapItem entity.

func (*PhaseUpdate) ClearTheme

func (_u *PhaseUpdate) ClearTheme() *PhaseUpdate

ClearTheme clears the value of the "theme" field.

func (*PhaseUpdate) Exec

func (_u *PhaseUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*PhaseUpdate) ExecX

func (_u *PhaseUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*PhaseUpdate) Mutation

func (_u *PhaseUpdate) Mutation() *PhaseMutation

Mutation returns the PhaseMutation object of the builder.

func (*PhaseUpdate) RemoveRoadmapItemIDs

func (_u *PhaseUpdate) RemoveRoadmapItemIDs(ids ...string) *PhaseUpdate

RemoveRoadmapItemIDs removes the "roadmap_items" edge to RoadmapItem entities by IDs.

func (*PhaseUpdate) RemoveRoadmapItems

func (_u *PhaseUpdate) RemoveRoadmapItems(v ...*RoadmapItem) *PhaseUpdate

RemoveRoadmapItems removes "roadmap_items" edges to RoadmapItem entities.

func (*PhaseUpdate) Save

func (_u *PhaseUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*PhaseUpdate) SaveX

func (_u *PhaseUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*PhaseUpdate) SetInitiative

func (_u *PhaseUpdate) SetInitiative(v *Initiative) *PhaseUpdate

SetInitiative sets the "initiative" edge to the Initiative entity.

func (*PhaseUpdate) SetInitiativeID

func (_u *PhaseUpdate) SetInitiativeID(id string) *PhaseUpdate

SetInitiativeID sets the "initiative" edge to the Initiative entity by ID.

func (*PhaseUpdate) SetNillableSequenceNumber

func (_u *PhaseUpdate) SetNillableSequenceNumber(v *int) *PhaseUpdate

SetNillableSequenceNumber sets the "sequence_number" field if the given value is not nil.

func (*PhaseUpdate) SetNillableTheme

func (_u *PhaseUpdate) SetNillableTheme(v *string) *PhaseUpdate

SetNillableTheme sets the "theme" field if the given value is not nil.

func (*PhaseUpdate) SetNillableTitle

func (_u *PhaseUpdate) SetNillableTitle(v *string) *PhaseUpdate

SetNillableTitle sets the "title" field if the given value is not nil.

func (*PhaseUpdate) SetSequenceNumber

func (_u *PhaseUpdate) SetSequenceNumber(v int) *PhaseUpdate

SetSequenceNumber sets the "sequence_number" field.

func (*PhaseUpdate) SetTheme

func (_u *PhaseUpdate) SetTheme(v string) *PhaseUpdate

SetTheme sets the "theme" field.

func (*PhaseUpdate) SetTitle

func (_u *PhaseUpdate) SetTitle(v string) *PhaseUpdate

SetTitle sets the "title" field.

func (*PhaseUpdate) Where

func (_u *PhaseUpdate) Where(ps ...predicate.Phase) *PhaseUpdate

Where appends a list predicates to the PhaseUpdate builder.

type PhaseUpdateOne

type PhaseUpdateOne struct {
	// contains filtered or unexported fields
}

PhaseUpdateOne is the builder for updating a single Phase entity.

func (*PhaseUpdateOne) AddRoadmapItemIDs

func (_u *PhaseUpdateOne) AddRoadmapItemIDs(ids ...string) *PhaseUpdateOne

AddRoadmapItemIDs adds the "roadmap_items" edge to the RoadmapItem entity by IDs.

func (*PhaseUpdateOne) AddRoadmapItems

func (_u *PhaseUpdateOne) AddRoadmapItems(v ...*RoadmapItem) *PhaseUpdateOne

AddRoadmapItems adds the "roadmap_items" edges to the RoadmapItem entity.

func (*PhaseUpdateOne) AddSequenceNumber

func (_u *PhaseUpdateOne) AddSequenceNumber(v int) *PhaseUpdateOne

AddSequenceNumber adds value to the "sequence_number" field.

func (*PhaseUpdateOne) ClearInitiative

func (_u *PhaseUpdateOne) ClearInitiative() *PhaseUpdateOne

ClearInitiative clears the "initiative" edge to the Initiative entity.

func (*PhaseUpdateOne) ClearRoadmapItems

func (_u *PhaseUpdateOne) ClearRoadmapItems() *PhaseUpdateOne

ClearRoadmapItems clears all "roadmap_items" edges to the RoadmapItem entity.

func (*PhaseUpdateOne) ClearTheme

func (_u *PhaseUpdateOne) ClearTheme() *PhaseUpdateOne

ClearTheme clears the value of the "theme" field.

func (*PhaseUpdateOne) Exec

func (_u *PhaseUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*PhaseUpdateOne) ExecX

func (_u *PhaseUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*PhaseUpdateOne) Mutation

func (_u *PhaseUpdateOne) Mutation() *PhaseMutation

Mutation returns the PhaseMutation object of the builder.

func (*PhaseUpdateOne) RemoveRoadmapItemIDs

func (_u *PhaseUpdateOne) RemoveRoadmapItemIDs(ids ...string) *PhaseUpdateOne

RemoveRoadmapItemIDs removes the "roadmap_items" edge to RoadmapItem entities by IDs.

func (*PhaseUpdateOne) RemoveRoadmapItems

func (_u *PhaseUpdateOne) RemoveRoadmapItems(v ...*RoadmapItem) *PhaseUpdateOne

RemoveRoadmapItems removes "roadmap_items" edges to RoadmapItem entities.

func (*PhaseUpdateOne) Save

func (_u *PhaseUpdateOne) Save(ctx context.Context) (*Phase, error)

Save executes the query and returns the updated Phase entity.

func (*PhaseUpdateOne) SaveX

func (_u *PhaseUpdateOne) SaveX(ctx context.Context) *Phase

SaveX is like Save, but panics if an error occurs.

func (*PhaseUpdateOne) Select

func (_u *PhaseUpdateOne) Select(field string, fields ...string) *PhaseUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*PhaseUpdateOne) SetInitiative

func (_u *PhaseUpdateOne) SetInitiative(v *Initiative) *PhaseUpdateOne

SetInitiative sets the "initiative" edge to the Initiative entity.

func (*PhaseUpdateOne) SetInitiativeID

func (_u *PhaseUpdateOne) SetInitiativeID(id string) *PhaseUpdateOne

SetInitiativeID sets the "initiative" edge to the Initiative entity by ID.

func (*PhaseUpdateOne) SetNillableSequenceNumber

func (_u *PhaseUpdateOne) SetNillableSequenceNumber(v *int) *PhaseUpdateOne

SetNillableSequenceNumber sets the "sequence_number" field if the given value is not nil.

func (*PhaseUpdateOne) SetNillableTheme

func (_u *PhaseUpdateOne) SetNillableTheme(v *string) *PhaseUpdateOne

SetNillableTheme sets the "theme" field if the given value is not nil.

func (*PhaseUpdateOne) SetNillableTitle

func (_u *PhaseUpdateOne) SetNillableTitle(v *string) *PhaseUpdateOne

SetNillableTitle sets the "title" field if the given value is not nil.

func (*PhaseUpdateOne) SetSequenceNumber

func (_u *PhaseUpdateOne) SetSequenceNumber(v int) *PhaseUpdateOne

SetSequenceNumber sets the "sequence_number" field.

func (*PhaseUpdateOne) SetTheme

func (_u *PhaseUpdateOne) SetTheme(v string) *PhaseUpdateOne

SetTheme sets the "theme" field.

func (*PhaseUpdateOne) SetTitle

func (_u *PhaseUpdateOne) SetTitle(v string) *PhaseUpdateOne

SetTitle sets the "title" field.

func (*PhaseUpdateOne) Where

func (_u *PhaseUpdateOne) Where(ps ...predicate.Phase) *PhaseUpdateOne

Where appends a list predicates to the PhaseUpdate builder.

type Phases

type Phases []*Phase

Phases is a parsable slice of Phase.

type Policy

type Policy = ent.Policy

ent aliases to avoid import conflicts in user's code.

type Program

type Program struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// Name holds the value of the "name" field.
	Name string `json:"name,omitempty"`
	// Organization holds the value of the "organization" field.
	Organization string `json:"organization,omitempty"`
	// Description holds the value of the "description" field.
	Description string `json:"description,omitempty"`
	// Hidden holds the value of the "hidden" field.
	Hidden bool `json:"hidden,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the ProgramQuery when eager-loading is set.
	Edges ProgramEdges `json:"edges"`
	// contains filtered or unexported fields
}

Program is the model entity for the Program schema.

func (*Program) QueryInitiatives

func (_m *Program) QueryInitiatives() *InitiativeQuery

QueryInitiatives queries the "initiatives" edge of the Program entity.

func (*Program) String

func (_m *Program) String() string

String implements the fmt.Stringer.

func (*Program) Unwrap

func (_m *Program) Unwrap() *Program

Unwrap unwraps the Program 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 (*Program) Update

func (_m *Program) Update() *ProgramUpdateOne

Update returns a builder for updating this Program. Note that you need to call Program.Unwrap() before calling this method if this Program was returned from a transaction, and the transaction was committed or rolled back.

func (*Program) Value

func (_m *Program) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the Program. This includes values selected through modifiers, order, etc.

type ProgramClient

type ProgramClient struct {
	// contains filtered or unexported fields
}

ProgramClient is a client for the Program schema.

func NewProgramClient

func NewProgramClient(c config) *ProgramClient

NewProgramClient returns a client for the Program from the given config.

func (*ProgramClient) Create

func (c *ProgramClient) Create() *ProgramCreate

Create returns a builder for creating a Program entity.

func (*ProgramClient) CreateBulk

func (c *ProgramClient) CreateBulk(builders ...*ProgramCreate) *ProgramCreateBulk

CreateBulk returns a builder for creating a bulk of Program entities.

func (*ProgramClient) Delete

func (c *ProgramClient) Delete() *ProgramDelete

Delete returns a delete builder for Program.

func (*ProgramClient) DeleteOne

func (c *ProgramClient) DeleteOne(_m *Program) *ProgramDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*ProgramClient) DeleteOneID

func (c *ProgramClient) DeleteOneID(id string) *ProgramDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*ProgramClient) Get

func (c *ProgramClient) Get(ctx context.Context, id string) (*Program, error)

Get returns a Program entity by its id.

func (*ProgramClient) GetX

func (c *ProgramClient) GetX(ctx context.Context, id string) *Program

GetX is like Get, but panics if an error occurs.

func (*ProgramClient) Hooks

func (c *ProgramClient) Hooks() []Hook

Hooks returns the client hooks.

func (*ProgramClient) Intercept

func (c *ProgramClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `program.Intercept(f(g(h())))`.

func (*ProgramClient) Interceptors

func (c *ProgramClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*ProgramClient) MapCreateBulk

func (c *ProgramClient) MapCreateBulk(slice any, setFunc func(*ProgramCreate, int)) *ProgramCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*ProgramClient) Query

func (c *ProgramClient) Query() *ProgramQuery

Query returns a query builder for Program.

func (*ProgramClient) QueryInitiatives

func (c *ProgramClient) QueryInitiatives(_m *Program) *InitiativeQuery

QueryInitiatives queries the initiatives edge of a Program.

func (*ProgramClient) Update

func (c *ProgramClient) Update() *ProgramUpdate

Update returns an update builder for Program.

func (*ProgramClient) UpdateOne

func (c *ProgramClient) UpdateOne(_m *Program) *ProgramUpdateOne

UpdateOne returns an update builder for the given entity.

func (*ProgramClient) UpdateOneID

func (c *ProgramClient) UpdateOneID(id string) *ProgramUpdateOne

UpdateOneID returns an update builder for the given id.

func (*ProgramClient) Use

func (c *ProgramClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `program.Hooks(f(g(h())))`.

type ProgramCreate

type ProgramCreate struct {
	// contains filtered or unexported fields
}

ProgramCreate is the builder for creating a Program entity.

func (*ProgramCreate) AddInitiativeIDs

func (_c *ProgramCreate) AddInitiativeIDs(ids ...string) *ProgramCreate

AddInitiativeIDs adds the "initiatives" edge to the Initiative entity by IDs.

func (*ProgramCreate) AddInitiatives

func (_c *ProgramCreate) AddInitiatives(v ...*Initiative) *ProgramCreate

AddInitiatives adds the "initiatives" edges to the Initiative entity.

func (*ProgramCreate) Exec

func (_c *ProgramCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*ProgramCreate) ExecX

func (_c *ProgramCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProgramCreate) Mutation

func (_c *ProgramCreate) Mutation() *ProgramMutation

Mutation returns the ProgramMutation object of the builder.

func (*ProgramCreate) Save

func (_c *ProgramCreate) Save(ctx context.Context) (*Program, error)

Save creates the Program in the database.

func (*ProgramCreate) SaveX

func (_c *ProgramCreate) SaveX(ctx context.Context) *Program

SaveX calls Save and panics if Save returns an error.

func (*ProgramCreate) SetCreatedAt

func (_c *ProgramCreate) SetCreatedAt(v time.Time) *ProgramCreate

SetCreatedAt sets the "created_at" field.

func (*ProgramCreate) SetDescription

func (_c *ProgramCreate) SetDescription(v string) *ProgramCreate

SetDescription sets the "description" field.

func (*ProgramCreate) SetHidden

func (_c *ProgramCreate) SetHidden(v bool) *ProgramCreate

SetHidden sets the "hidden" field.

func (*ProgramCreate) SetID

func (_c *ProgramCreate) SetID(v string) *ProgramCreate

SetID sets the "id" field.

func (*ProgramCreate) SetName

func (_c *ProgramCreate) SetName(v string) *ProgramCreate

SetName sets the "name" field.

func (*ProgramCreate) SetNillableDescription

func (_c *ProgramCreate) SetNillableDescription(v *string) *ProgramCreate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*ProgramCreate) SetNillableHidden

func (_c *ProgramCreate) SetNillableHidden(v *bool) *ProgramCreate

SetNillableHidden sets the "hidden" field if the given value is not nil.

func (*ProgramCreate) SetOrganization

func (_c *ProgramCreate) SetOrganization(v string) *ProgramCreate

SetOrganization sets the "organization" field.

func (*ProgramCreate) SetUpdatedAt

func (_c *ProgramCreate) SetUpdatedAt(v time.Time) *ProgramCreate

SetUpdatedAt sets the "updated_at" field.

type ProgramCreateBulk

type ProgramCreateBulk struct {
	// contains filtered or unexported fields
}

ProgramCreateBulk is the builder for creating many Program entities in bulk.

func (*ProgramCreateBulk) Exec

func (_c *ProgramCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*ProgramCreateBulk) ExecX

func (_c *ProgramCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProgramCreateBulk) Save

func (_c *ProgramCreateBulk) Save(ctx context.Context) ([]*Program, error)

Save creates the Program entities in the database.

func (*ProgramCreateBulk) SaveX

func (_c *ProgramCreateBulk) SaveX(ctx context.Context) []*Program

SaveX is like Save, but panics if an error occurs.

type ProgramDelete

type ProgramDelete struct {
	// contains filtered or unexported fields
}

ProgramDelete is the builder for deleting a Program entity.

func (*ProgramDelete) Exec

func (_d *ProgramDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*ProgramDelete) ExecX

func (_d *ProgramDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*ProgramDelete) Where

func (_d *ProgramDelete) Where(ps ...predicate.Program) *ProgramDelete

Where appends a list predicates to the ProgramDelete builder.

type ProgramDeleteOne

type ProgramDeleteOne struct {
	// contains filtered or unexported fields
}

ProgramDeleteOne is the builder for deleting a single Program entity.

func (*ProgramDeleteOne) Exec

func (_d *ProgramDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*ProgramDeleteOne) ExecX

func (_d *ProgramDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProgramDeleteOne) Where

Where appends a list predicates to the ProgramDelete builder.

type ProgramEdges

type ProgramEdges struct {
	// Initiatives holds the value of the initiatives edge.
	Initiatives []*Initiative `json:"initiatives,omitempty"`
	// contains filtered or unexported fields
}

ProgramEdges holds the relations/edges for other nodes in the graph.

func (ProgramEdges) InitiativesOrErr

func (e ProgramEdges) InitiativesOrErr() ([]*Initiative, error)

InitiativesOrErr returns the Initiatives value or an error if the edge was not loaded in eager-loading.

type ProgramGroupBy

type ProgramGroupBy struct {
	// contains filtered or unexported fields
}

ProgramGroupBy is the group-by builder for Program entities.

func (*ProgramGroupBy) Aggregate

func (_g *ProgramGroupBy) Aggregate(fns ...AggregateFunc) *ProgramGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*ProgramGroupBy) Bool

func (s *ProgramGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ProgramGroupBy) BoolX

func (s *ProgramGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ProgramGroupBy) Bools

func (s *ProgramGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ProgramGroupBy) BoolsX

func (s *ProgramGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ProgramGroupBy) Float64

func (s *ProgramGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ProgramGroupBy) Float64X

func (s *ProgramGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ProgramGroupBy) Float64s

func (s *ProgramGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ProgramGroupBy) Float64sX

func (s *ProgramGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ProgramGroupBy) Int

func (s *ProgramGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ProgramGroupBy) IntX

func (s *ProgramGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ProgramGroupBy) Ints

func (s *ProgramGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ProgramGroupBy) IntsX

func (s *ProgramGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ProgramGroupBy) Scan

func (_g *ProgramGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*ProgramGroupBy) ScanX

func (s *ProgramGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ProgramGroupBy) String

func (s *ProgramGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ProgramGroupBy) StringX

func (s *ProgramGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ProgramGroupBy) Strings

func (s *ProgramGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ProgramGroupBy) StringsX

func (s *ProgramGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ProgramMutation

type ProgramMutation struct {
	// contains filtered or unexported fields
}

ProgramMutation represents an operation that mutates the Program nodes in the graph.

func (*ProgramMutation) AddField

func (m *ProgramMutation) 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 (*ProgramMutation) AddInitiativeIDs

func (m *ProgramMutation) AddInitiativeIDs(ids ...string)

AddInitiativeIDs adds the "initiatives" edge to the Initiative entity by ids.

func (*ProgramMutation) AddedEdges

func (m *ProgramMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*ProgramMutation) AddedField

func (m *ProgramMutation) 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 (*ProgramMutation) AddedFields

func (m *ProgramMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*ProgramMutation) AddedIDs

func (m *ProgramMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*ProgramMutation) ClearDescription

func (m *ProgramMutation) ClearDescription()

ClearDescription clears the value of the "description" field.

func (*ProgramMutation) ClearEdge

func (m *ProgramMutation) 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 (*ProgramMutation) ClearField

func (m *ProgramMutation) 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 (*ProgramMutation) ClearInitiatives

func (m *ProgramMutation) ClearInitiatives()

ClearInitiatives clears the "initiatives" edge to the Initiative entity.

func (*ProgramMutation) ClearedEdges

func (m *ProgramMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*ProgramMutation) ClearedFields

func (m *ProgramMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (ProgramMutation) Client

func (m ProgramMutation) 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 (*ProgramMutation) CreatedAt

func (m *ProgramMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*ProgramMutation) Description

func (m *ProgramMutation) Description() (r string, exists bool)

Description returns the value of the "description" field in the mutation.

func (*ProgramMutation) DescriptionCleared

func (m *ProgramMutation) DescriptionCleared() bool

DescriptionCleared returns if the "description" field was cleared in this mutation.

func (*ProgramMutation) EdgeCleared

func (m *ProgramMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*ProgramMutation) Field

func (m *ProgramMutation) 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 (*ProgramMutation) FieldCleared

func (m *ProgramMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*ProgramMutation) Fields

func (m *ProgramMutation) 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 (*ProgramMutation) Hidden

func (m *ProgramMutation) Hidden() (r bool, exists bool)

Hidden returns the value of the "hidden" field in the mutation.

func (*ProgramMutation) ID

func (m *ProgramMutation) ID() (id string, 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 (*ProgramMutation) IDs

func (m *ProgramMutation) IDs(ctx context.Context) ([]string, 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 (*ProgramMutation) InitiativesCleared

func (m *ProgramMutation) InitiativesCleared() bool

InitiativesCleared reports if the "initiatives" edge to the Initiative entity was cleared.

func (*ProgramMutation) InitiativesIDs

func (m *ProgramMutation) InitiativesIDs() (ids []string)

InitiativesIDs returns the "initiatives" edge IDs in the mutation.

func (*ProgramMutation) Name

func (m *ProgramMutation) Name() (r string, exists bool)

Name returns the value of the "name" field in the mutation.

func (*ProgramMutation) OldCreatedAt

func (m *ProgramMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the Program entity. If the Program 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 (*ProgramMutation) OldDescription

func (m *ProgramMutation) OldDescription(ctx context.Context) (v string, err error)

OldDescription returns the old "description" field's value of the Program entity. If the Program 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 (*ProgramMutation) OldField

func (m *ProgramMutation) 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 (*ProgramMutation) OldHidden

func (m *ProgramMutation) OldHidden(ctx context.Context) (v bool, err error)

OldHidden returns the old "hidden" field's value of the Program entity. If the Program 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 (*ProgramMutation) OldName

func (m *ProgramMutation) OldName(ctx context.Context) (v string, err error)

OldName returns the old "name" field's value of the Program entity. If the Program 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 (*ProgramMutation) OldOrganization

func (m *ProgramMutation) OldOrganization(ctx context.Context) (v string, err error)

OldOrganization returns the old "organization" field's value of the Program entity. If the Program 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 (*ProgramMutation) OldUpdatedAt

func (m *ProgramMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the Program entity. If the Program 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 (*ProgramMutation) Op

func (m *ProgramMutation) Op() Op

Op returns the operation name.

func (*ProgramMutation) Organization

func (m *ProgramMutation) Organization() (r string, exists bool)

Organization returns the value of the "organization" field in the mutation.

func (*ProgramMutation) RemoveInitiativeIDs

func (m *ProgramMutation) RemoveInitiativeIDs(ids ...string)

RemoveInitiativeIDs removes the "initiatives" edge to the Initiative entity by IDs.

func (*ProgramMutation) RemovedEdges

func (m *ProgramMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*ProgramMutation) RemovedIDs

func (m *ProgramMutation) 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 (*ProgramMutation) RemovedInitiativesIDs

func (m *ProgramMutation) RemovedInitiativesIDs() (ids []string)

RemovedInitiatives returns the removed IDs of the "initiatives" edge to the Initiative entity.

func (*ProgramMutation) ResetCreatedAt

func (m *ProgramMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*ProgramMutation) ResetDescription

func (m *ProgramMutation) ResetDescription()

ResetDescription resets all changes to the "description" field.

func (*ProgramMutation) ResetEdge

func (m *ProgramMutation) 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 (*ProgramMutation) ResetField

func (m *ProgramMutation) 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 (*ProgramMutation) ResetHidden

func (m *ProgramMutation) ResetHidden()

ResetHidden resets all changes to the "hidden" field.

func (*ProgramMutation) ResetInitiatives

func (m *ProgramMutation) ResetInitiatives()

ResetInitiatives resets all changes to the "initiatives" edge.

func (*ProgramMutation) ResetName

func (m *ProgramMutation) ResetName()

ResetName resets all changes to the "name" field.

func (*ProgramMutation) ResetOrganization

func (m *ProgramMutation) ResetOrganization()

ResetOrganization resets all changes to the "organization" field.

func (*ProgramMutation) ResetUpdatedAt

func (m *ProgramMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*ProgramMutation) SetCreatedAt

func (m *ProgramMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*ProgramMutation) SetDescription

func (m *ProgramMutation) SetDescription(s string)

SetDescription sets the "description" field.

func (*ProgramMutation) SetField

func (m *ProgramMutation) 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 (*ProgramMutation) SetHidden

func (m *ProgramMutation) SetHidden(b bool)

SetHidden sets the "hidden" field.

func (*ProgramMutation) SetID

func (m *ProgramMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of Program entities.

func (*ProgramMutation) SetName

func (m *ProgramMutation) SetName(s string)

SetName sets the "name" field.

func (*ProgramMutation) SetOp

func (m *ProgramMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*ProgramMutation) SetOrganization

func (m *ProgramMutation) SetOrganization(s string)

SetOrganization sets the "organization" field.

func (*ProgramMutation) SetUpdatedAt

func (m *ProgramMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (ProgramMutation) Tx

func (m ProgramMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*ProgramMutation) Type

func (m *ProgramMutation) Type() string

Type returns the node type of this mutation (Program).

func (*ProgramMutation) UpdatedAt

func (m *ProgramMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*ProgramMutation) Where

func (m *ProgramMutation) Where(ps ...predicate.Program)

Where appends a list predicates to the ProgramMutation builder.

func (*ProgramMutation) WhereP

func (m *ProgramMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the ProgramMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type ProgramQuery

type ProgramQuery struct {
	// contains filtered or unexported fields
}

ProgramQuery is the builder for querying Program entities.

func (*ProgramQuery) Aggregate

func (_q *ProgramQuery) Aggregate(fns ...AggregateFunc) *ProgramSelect

Aggregate returns a ProgramSelect configured with the given aggregations.

func (*ProgramQuery) All

func (_q *ProgramQuery) All(ctx context.Context) ([]*Program, error)

All executes the query and returns a list of Programs.

func (*ProgramQuery) AllX

func (_q *ProgramQuery) AllX(ctx context.Context) []*Program

AllX is like All, but panics if an error occurs.

func (*ProgramQuery) Clone

func (_q *ProgramQuery) Clone() *ProgramQuery

Clone returns a duplicate of the ProgramQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*ProgramQuery) Count

func (_q *ProgramQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*ProgramQuery) CountX

func (_q *ProgramQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*ProgramQuery) Exist

func (_q *ProgramQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*ProgramQuery) ExistX

func (_q *ProgramQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*ProgramQuery) First

func (_q *ProgramQuery) First(ctx context.Context) (*Program, error)

First returns the first Program entity from the query. Returns a *NotFoundError when no Program was found.

func (*ProgramQuery) FirstID

func (_q *ProgramQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first Program ID from the query. Returns a *NotFoundError when no Program ID was found.

func (*ProgramQuery) FirstIDX

func (_q *ProgramQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*ProgramQuery) FirstX

func (_q *ProgramQuery) FirstX(ctx context.Context) *Program

FirstX is like First, but panics if an error occurs.

func (*ProgramQuery) GroupBy

func (_q *ProgramQuery) GroupBy(field string, fields ...string) *ProgramGroupBy

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.Program.Query().
	GroupBy(program.FieldName).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*ProgramQuery) IDs

func (_q *ProgramQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of Program IDs.

func (*ProgramQuery) IDsX

func (_q *ProgramQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*ProgramQuery) Limit

func (_q *ProgramQuery) Limit(limit int) *ProgramQuery

Limit the number of records to be returned by this query.

func (*ProgramQuery) Offset

func (_q *ProgramQuery) Offset(offset int) *ProgramQuery

Offset to start from.

func (*ProgramQuery) Only

func (_q *ProgramQuery) Only(ctx context.Context) (*Program, error)

Only returns a single Program entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Program entity is found. Returns a *NotFoundError when no Program entities are found.

func (*ProgramQuery) OnlyID

func (_q *ProgramQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only Program ID in the query. Returns a *NotSingularError when more than one Program ID is found. Returns a *NotFoundError when no entities are found.

func (*ProgramQuery) OnlyIDX

func (_q *ProgramQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*ProgramQuery) OnlyX

func (_q *ProgramQuery) OnlyX(ctx context.Context) *Program

OnlyX is like Only, but panics if an error occurs.

func (*ProgramQuery) Order

func (_q *ProgramQuery) Order(o ...program.OrderOption) *ProgramQuery

Order specifies how the records should be ordered.

func (*ProgramQuery) QueryInitiatives

func (_q *ProgramQuery) QueryInitiatives() *InitiativeQuery

QueryInitiatives chains the current query on the "initiatives" edge.

func (*ProgramQuery) Select

func (_q *ProgramQuery) Select(fields ...string) *ProgramSelect

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.Program.Query().
	Select(program.FieldName).
	Scan(ctx, &v)

func (*ProgramQuery) Unique

func (_q *ProgramQuery) Unique(unique bool) *ProgramQuery

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 (*ProgramQuery) Where

func (_q *ProgramQuery) Where(ps ...predicate.Program) *ProgramQuery

Where adds a new predicate for the ProgramQuery builder.

func (*ProgramQuery) WithInitiatives

func (_q *ProgramQuery) WithInitiatives(opts ...func(*InitiativeQuery)) *ProgramQuery

WithInitiatives tells the query-builder to eager-load the nodes that are connected to the "initiatives" edge. The optional arguments are used to configure the query builder of the edge.

type ProgramSelect

type ProgramSelect struct {
	*ProgramQuery
	// contains filtered or unexported fields
}

ProgramSelect is the builder for selecting fields of Program entities.

func (*ProgramSelect) Aggregate

func (_s *ProgramSelect) Aggregate(fns ...AggregateFunc) *ProgramSelect

Aggregate adds the given aggregation functions to the selector query.

func (*ProgramSelect) Bool

func (s *ProgramSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ProgramSelect) BoolX

func (s *ProgramSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ProgramSelect) Bools

func (s *ProgramSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ProgramSelect) BoolsX

func (s *ProgramSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ProgramSelect) Float64

func (s *ProgramSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ProgramSelect) Float64X

func (s *ProgramSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ProgramSelect) Float64s

func (s *ProgramSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ProgramSelect) Float64sX

func (s *ProgramSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ProgramSelect) Int

func (s *ProgramSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ProgramSelect) IntX

func (s *ProgramSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ProgramSelect) Ints

func (s *ProgramSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ProgramSelect) IntsX

func (s *ProgramSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ProgramSelect) Scan

func (_s *ProgramSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*ProgramSelect) ScanX

func (s *ProgramSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ProgramSelect) String

func (s *ProgramSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ProgramSelect) StringX

func (s *ProgramSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ProgramSelect) Strings

func (s *ProgramSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ProgramSelect) StringsX

func (s *ProgramSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ProgramUpdate

type ProgramUpdate struct {
	// contains filtered or unexported fields
}

ProgramUpdate is the builder for updating Program entities.

func (*ProgramUpdate) AddInitiativeIDs

func (_u *ProgramUpdate) AddInitiativeIDs(ids ...string) *ProgramUpdate

AddInitiativeIDs adds the "initiatives" edge to the Initiative entity by IDs.

func (*ProgramUpdate) AddInitiatives

func (_u *ProgramUpdate) AddInitiatives(v ...*Initiative) *ProgramUpdate

AddInitiatives adds the "initiatives" edges to the Initiative entity.

func (*ProgramUpdate) ClearDescription

func (_u *ProgramUpdate) ClearDescription() *ProgramUpdate

ClearDescription clears the value of the "description" field.

func (*ProgramUpdate) ClearInitiatives

func (_u *ProgramUpdate) ClearInitiatives() *ProgramUpdate

ClearInitiatives clears all "initiatives" edges to the Initiative entity.

func (*ProgramUpdate) Exec

func (_u *ProgramUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*ProgramUpdate) ExecX

func (_u *ProgramUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProgramUpdate) Mutation

func (_u *ProgramUpdate) Mutation() *ProgramMutation

Mutation returns the ProgramMutation object of the builder.

func (*ProgramUpdate) RemoveInitiativeIDs

func (_u *ProgramUpdate) RemoveInitiativeIDs(ids ...string) *ProgramUpdate

RemoveInitiativeIDs removes the "initiatives" edge to Initiative entities by IDs.

func (*ProgramUpdate) RemoveInitiatives

func (_u *ProgramUpdate) RemoveInitiatives(v ...*Initiative) *ProgramUpdate

RemoveInitiatives removes "initiatives" edges to Initiative entities.

func (*ProgramUpdate) Save

func (_u *ProgramUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*ProgramUpdate) SaveX

func (_u *ProgramUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*ProgramUpdate) SetCreatedAt

func (_u *ProgramUpdate) SetCreatedAt(v time.Time) *ProgramUpdate

SetCreatedAt sets the "created_at" field.

func (*ProgramUpdate) SetDescription

func (_u *ProgramUpdate) SetDescription(v string) *ProgramUpdate

SetDescription sets the "description" field.

func (*ProgramUpdate) SetHidden

func (_u *ProgramUpdate) SetHidden(v bool) *ProgramUpdate

SetHidden sets the "hidden" field.

func (*ProgramUpdate) SetName

func (_u *ProgramUpdate) SetName(v string) *ProgramUpdate

SetName sets the "name" field.

func (*ProgramUpdate) SetNillableCreatedAt

func (_u *ProgramUpdate) SetNillableCreatedAt(v *time.Time) *ProgramUpdate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*ProgramUpdate) SetNillableDescription

func (_u *ProgramUpdate) SetNillableDescription(v *string) *ProgramUpdate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*ProgramUpdate) SetNillableHidden

func (_u *ProgramUpdate) SetNillableHidden(v *bool) *ProgramUpdate

SetNillableHidden sets the "hidden" field if the given value is not nil.

func (*ProgramUpdate) SetNillableName

func (_u *ProgramUpdate) SetNillableName(v *string) *ProgramUpdate

SetNillableName sets the "name" field if the given value is not nil.

func (*ProgramUpdate) SetNillableOrganization

func (_u *ProgramUpdate) SetNillableOrganization(v *string) *ProgramUpdate

SetNillableOrganization sets the "organization" field if the given value is not nil.

func (*ProgramUpdate) SetNillableUpdatedAt

func (_u *ProgramUpdate) SetNillableUpdatedAt(v *time.Time) *ProgramUpdate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*ProgramUpdate) SetOrganization

func (_u *ProgramUpdate) SetOrganization(v string) *ProgramUpdate

SetOrganization sets the "organization" field.

func (*ProgramUpdate) SetUpdatedAt

func (_u *ProgramUpdate) SetUpdatedAt(v time.Time) *ProgramUpdate

SetUpdatedAt sets the "updated_at" field.

func (*ProgramUpdate) Where

func (_u *ProgramUpdate) Where(ps ...predicate.Program) *ProgramUpdate

Where appends a list predicates to the ProgramUpdate builder.

type ProgramUpdateOne

type ProgramUpdateOne struct {
	// contains filtered or unexported fields
}

ProgramUpdateOne is the builder for updating a single Program entity.

func (*ProgramUpdateOne) AddInitiativeIDs

func (_u *ProgramUpdateOne) AddInitiativeIDs(ids ...string) *ProgramUpdateOne

AddInitiativeIDs adds the "initiatives" edge to the Initiative entity by IDs.

func (*ProgramUpdateOne) AddInitiatives

func (_u *ProgramUpdateOne) AddInitiatives(v ...*Initiative) *ProgramUpdateOne

AddInitiatives adds the "initiatives" edges to the Initiative entity.

func (*ProgramUpdateOne) ClearDescription

func (_u *ProgramUpdateOne) ClearDescription() *ProgramUpdateOne

ClearDescription clears the value of the "description" field.

func (*ProgramUpdateOne) ClearInitiatives

func (_u *ProgramUpdateOne) ClearInitiatives() *ProgramUpdateOne

ClearInitiatives clears all "initiatives" edges to the Initiative entity.

func (*ProgramUpdateOne) Exec

func (_u *ProgramUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*ProgramUpdateOne) ExecX

func (_u *ProgramUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProgramUpdateOne) Mutation

func (_u *ProgramUpdateOne) Mutation() *ProgramMutation

Mutation returns the ProgramMutation object of the builder.

func (*ProgramUpdateOne) RemoveInitiativeIDs

func (_u *ProgramUpdateOne) RemoveInitiativeIDs(ids ...string) *ProgramUpdateOne

RemoveInitiativeIDs removes the "initiatives" edge to Initiative entities by IDs.

func (*ProgramUpdateOne) RemoveInitiatives

func (_u *ProgramUpdateOne) RemoveInitiatives(v ...*Initiative) *ProgramUpdateOne

RemoveInitiatives removes "initiatives" edges to Initiative entities.

func (*ProgramUpdateOne) Save

func (_u *ProgramUpdateOne) Save(ctx context.Context) (*Program, error)

Save executes the query and returns the updated Program entity.

func (*ProgramUpdateOne) SaveX

func (_u *ProgramUpdateOne) SaveX(ctx context.Context) *Program

SaveX is like Save, but panics if an error occurs.

func (*ProgramUpdateOne) Select

func (_u *ProgramUpdateOne) Select(field string, fields ...string) *ProgramUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*ProgramUpdateOne) SetCreatedAt

func (_u *ProgramUpdateOne) SetCreatedAt(v time.Time) *ProgramUpdateOne

SetCreatedAt sets the "created_at" field.

func (*ProgramUpdateOne) SetDescription

func (_u *ProgramUpdateOne) SetDescription(v string) *ProgramUpdateOne

SetDescription sets the "description" field.

func (*ProgramUpdateOne) SetHidden

func (_u *ProgramUpdateOne) SetHidden(v bool) *ProgramUpdateOne

SetHidden sets the "hidden" field.

func (*ProgramUpdateOne) SetName

func (_u *ProgramUpdateOne) SetName(v string) *ProgramUpdateOne

SetName sets the "name" field.

func (*ProgramUpdateOne) SetNillableCreatedAt

func (_u *ProgramUpdateOne) SetNillableCreatedAt(v *time.Time) *ProgramUpdateOne

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*ProgramUpdateOne) SetNillableDescription

func (_u *ProgramUpdateOne) SetNillableDescription(v *string) *ProgramUpdateOne

SetNillableDescription sets the "description" field if the given value is not nil.

func (*ProgramUpdateOne) SetNillableHidden

func (_u *ProgramUpdateOne) SetNillableHidden(v *bool) *ProgramUpdateOne

SetNillableHidden sets the "hidden" field if the given value is not nil.

func (*ProgramUpdateOne) SetNillableName

func (_u *ProgramUpdateOne) SetNillableName(v *string) *ProgramUpdateOne

SetNillableName sets the "name" field if the given value is not nil.

func (*ProgramUpdateOne) SetNillableOrganization

func (_u *ProgramUpdateOne) SetNillableOrganization(v *string) *ProgramUpdateOne

SetNillableOrganization sets the "organization" field if the given value is not nil.

func (*ProgramUpdateOne) SetNillableUpdatedAt

func (_u *ProgramUpdateOne) SetNillableUpdatedAt(v *time.Time) *ProgramUpdateOne

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*ProgramUpdateOne) SetOrganization

func (_u *ProgramUpdateOne) SetOrganization(v string) *ProgramUpdateOne

SetOrganization sets the "organization" field.

func (*ProgramUpdateOne) SetUpdatedAt

func (_u *ProgramUpdateOne) SetUpdatedAt(v time.Time) *ProgramUpdateOne

SetUpdatedAt sets the "updated_at" field.

func (*ProgramUpdateOne) Where

Where appends a list predicates to the ProgramUpdate builder.

type Programs

type Programs []*Program

Programs is a parsable slice of Program.

type Querier

type Querier = ent.Querier

ent aliases to avoid import conflicts in user's code.

type QuerierFunc

type QuerierFunc = ent.QuerierFunc

ent aliases to avoid import conflicts in user's code.

type Query

type Query = ent.Query

ent aliases to avoid import conflicts in user's code.

type QueryContext

type QueryContext = ent.QueryContext

ent aliases to avoid import conflicts in user's code.

type RMIDependencies

type RMIDependencies []*RMIDependency

RMIDependencies is a parsable slice of RMIDependency.

type RMIDependency

type RMIDependency struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// SourceRmiID holds the value of the "source_rmi_id" field.
	SourceRmiID string `json:"source_rmi_id,omitempty"`
	// TargetRmiID holds the value of the "target_rmi_id" field.
	TargetRmiID string `json:"target_rmi_id,omitempty"`
	// Relationship holds the value of the "relationship" field.
	Relationship string `json:"relationship,omitempty"`
	// contains filtered or unexported fields
}

RMIDependency is the model entity for the RMIDependency schema.

func (*RMIDependency) String

func (_m *RMIDependency) String() string

String implements the fmt.Stringer.

func (*RMIDependency) Unwrap

func (_m *RMIDependency) Unwrap() *RMIDependency

Unwrap unwraps the RMIDependency 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 (*RMIDependency) Update

func (_m *RMIDependency) Update() *RMIDependencyUpdateOne

Update returns a builder for updating this RMIDependency. Note that you need to call RMIDependency.Unwrap() before calling this method if this RMIDependency was returned from a transaction, and the transaction was committed or rolled back.

func (*RMIDependency) Value

func (_m *RMIDependency) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the RMIDependency. This includes values selected through modifiers, order, etc.

type RMIDependencyClient

type RMIDependencyClient struct {
	// contains filtered or unexported fields
}

RMIDependencyClient is a client for the RMIDependency schema.

func NewRMIDependencyClient

func NewRMIDependencyClient(c config) *RMIDependencyClient

NewRMIDependencyClient returns a client for the RMIDependency from the given config.

func (*RMIDependencyClient) Create

Create returns a builder for creating a RMIDependency entity.

func (*RMIDependencyClient) CreateBulk

CreateBulk returns a builder for creating a bulk of RMIDependency entities.

func (*RMIDependencyClient) Delete

Delete returns a delete builder for RMIDependency.

func (*RMIDependencyClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*RMIDependencyClient) DeleteOneID

func (c *RMIDependencyClient) DeleteOneID(id int) *RMIDependencyDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*RMIDependencyClient) Get

Get returns a RMIDependency entity by its id.

func (*RMIDependencyClient) GetX

GetX is like Get, but panics if an error occurs.

func (*RMIDependencyClient) Hooks

func (c *RMIDependencyClient) Hooks() []Hook

Hooks returns the client hooks.

func (*RMIDependencyClient) Intercept

func (c *RMIDependencyClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `rmidependency.Intercept(f(g(h())))`.

func (*RMIDependencyClient) Interceptors

func (c *RMIDependencyClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*RMIDependencyClient) MapCreateBulk

func (c *RMIDependencyClient) MapCreateBulk(slice any, setFunc func(*RMIDependencyCreate, int)) *RMIDependencyCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*RMIDependencyClient) Query

Query returns a query builder for RMIDependency.

func (*RMIDependencyClient) Update

Update returns an update builder for RMIDependency.

func (*RMIDependencyClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*RMIDependencyClient) UpdateOneID

func (c *RMIDependencyClient) UpdateOneID(id int) *RMIDependencyUpdateOne

UpdateOneID returns an update builder for the given id.

func (*RMIDependencyClient) Use

func (c *RMIDependencyClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `rmidependency.Hooks(f(g(h())))`.

type RMIDependencyCreate

type RMIDependencyCreate struct {
	// contains filtered or unexported fields
}

RMIDependencyCreate is the builder for creating a RMIDependency entity.

func (*RMIDependencyCreate) Exec

func (_c *RMIDependencyCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*RMIDependencyCreate) ExecX

func (_c *RMIDependencyCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RMIDependencyCreate) Mutation

Mutation returns the RMIDependencyMutation object of the builder.

func (*RMIDependencyCreate) Save

Save creates the RMIDependency in the database.

func (*RMIDependencyCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*RMIDependencyCreate) SetRelationship

func (_c *RMIDependencyCreate) SetRelationship(v string) *RMIDependencyCreate

SetRelationship sets the "relationship" field.

func (*RMIDependencyCreate) SetSourceRmiID

func (_c *RMIDependencyCreate) SetSourceRmiID(v string) *RMIDependencyCreate

SetSourceRmiID sets the "source_rmi_id" field.

func (*RMIDependencyCreate) SetTargetRmiID

func (_c *RMIDependencyCreate) SetTargetRmiID(v string) *RMIDependencyCreate

SetTargetRmiID sets the "target_rmi_id" field.

type RMIDependencyCreateBulk

type RMIDependencyCreateBulk struct {
	// contains filtered or unexported fields
}

RMIDependencyCreateBulk is the builder for creating many RMIDependency entities in bulk.

func (*RMIDependencyCreateBulk) Exec

Exec executes the query.

func (*RMIDependencyCreateBulk) ExecX

func (_c *RMIDependencyCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RMIDependencyCreateBulk) Save

Save creates the RMIDependency entities in the database.

func (*RMIDependencyCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type RMIDependencyDelete

type RMIDependencyDelete struct {
	// contains filtered or unexported fields
}

RMIDependencyDelete is the builder for deleting a RMIDependency entity.

func (*RMIDependencyDelete) Exec

func (_d *RMIDependencyDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*RMIDependencyDelete) ExecX

func (_d *RMIDependencyDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*RMIDependencyDelete) Where

Where appends a list predicates to the RMIDependencyDelete builder.

type RMIDependencyDeleteOne

type RMIDependencyDeleteOne struct {
	// contains filtered or unexported fields
}

RMIDependencyDeleteOne is the builder for deleting a single RMIDependency entity.

func (*RMIDependencyDeleteOne) Exec

Exec executes the deletion query.

func (*RMIDependencyDeleteOne) ExecX

func (_d *RMIDependencyDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RMIDependencyDeleteOne) Where

Where appends a list predicates to the RMIDependencyDelete builder.

type RMIDependencyGroupBy

type RMIDependencyGroupBy struct {
	// contains filtered or unexported fields
}

RMIDependencyGroupBy is the group-by builder for RMIDependency entities.

func (*RMIDependencyGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*RMIDependencyGroupBy) Bool

func (s *RMIDependencyGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*RMIDependencyGroupBy) BoolX

func (s *RMIDependencyGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*RMIDependencyGroupBy) Bools

func (s *RMIDependencyGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*RMIDependencyGroupBy) BoolsX

func (s *RMIDependencyGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*RMIDependencyGroupBy) Float64

func (s *RMIDependencyGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*RMIDependencyGroupBy) Float64X

func (s *RMIDependencyGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*RMIDependencyGroupBy) Float64s

func (s *RMIDependencyGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*RMIDependencyGroupBy) Float64sX

func (s *RMIDependencyGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*RMIDependencyGroupBy) Int

func (s *RMIDependencyGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*RMIDependencyGroupBy) IntX

func (s *RMIDependencyGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*RMIDependencyGroupBy) Ints

func (s *RMIDependencyGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*RMIDependencyGroupBy) IntsX

func (s *RMIDependencyGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*RMIDependencyGroupBy) Scan

func (_g *RMIDependencyGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*RMIDependencyGroupBy) ScanX

func (s *RMIDependencyGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*RMIDependencyGroupBy) String

func (s *RMIDependencyGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*RMIDependencyGroupBy) StringX

func (s *RMIDependencyGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*RMIDependencyGroupBy) Strings

func (s *RMIDependencyGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*RMIDependencyGroupBy) StringsX

func (s *RMIDependencyGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type RMIDependencyMutation

type RMIDependencyMutation struct {
	// contains filtered or unexported fields
}

RMIDependencyMutation represents an operation that mutates the RMIDependency nodes in the graph.

func (*RMIDependencyMutation) AddField

func (m *RMIDependencyMutation) 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 (*RMIDependencyMutation) AddedEdges

func (m *RMIDependencyMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*RMIDependencyMutation) AddedField

func (m *RMIDependencyMutation) 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 (*RMIDependencyMutation) AddedFields

func (m *RMIDependencyMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*RMIDependencyMutation) AddedIDs

func (m *RMIDependencyMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*RMIDependencyMutation) ClearEdge

func (m *RMIDependencyMutation) 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 (*RMIDependencyMutation) ClearField

func (m *RMIDependencyMutation) 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 (*RMIDependencyMutation) ClearedEdges

func (m *RMIDependencyMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*RMIDependencyMutation) ClearedFields

func (m *RMIDependencyMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (RMIDependencyMutation) Client

func (m RMIDependencyMutation) 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 (*RMIDependencyMutation) EdgeCleared

func (m *RMIDependencyMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*RMIDependencyMutation) Field

func (m *RMIDependencyMutation) 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 (*RMIDependencyMutation) FieldCleared

func (m *RMIDependencyMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*RMIDependencyMutation) Fields

func (m *RMIDependencyMutation) 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 (*RMIDependencyMutation) ID

func (m *RMIDependencyMutation) 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 (*RMIDependencyMutation) IDs

func (m *RMIDependencyMutation) 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 (*RMIDependencyMutation) OldField

func (m *RMIDependencyMutation) 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 (*RMIDependencyMutation) OldRelationship

func (m *RMIDependencyMutation) OldRelationship(ctx context.Context) (v string, err error)

OldRelationship returns the old "relationship" field's value of the RMIDependency entity. If the RMIDependency 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 (*RMIDependencyMutation) OldSourceRmiID

func (m *RMIDependencyMutation) OldSourceRmiID(ctx context.Context) (v string, err error)

OldSourceRmiID returns the old "source_rmi_id" field's value of the RMIDependency entity. If the RMIDependency 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 (*RMIDependencyMutation) OldTargetRmiID

func (m *RMIDependencyMutation) OldTargetRmiID(ctx context.Context) (v string, err error)

OldTargetRmiID returns the old "target_rmi_id" field's value of the RMIDependency entity. If the RMIDependency 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 (*RMIDependencyMutation) Op

func (m *RMIDependencyMutation) Op() Op

Op returns the operation name.

func (*RMIDependencyMutation) Relationship

func (m *RMIDependencyMutation) Relationship() (r string, exists bool)

Relationship returns the value of the "relationship" field in the mutation.

func (*RMIDependencyMutation) RemovedEdges

func (m *RMIDependencyMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*RMIDependencyMutation) RemovedIDs

func (m *RMIDependencyMutation) 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 (*RMIDependencyMutation) ResetEdge

func (m *RMIDependencyMutation) 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 (*RMIDependencyMutation) ResetField

func (m *RMIDependencyMutation) 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 (*RMIDependencyMutation) ResetRelationship

func (m *RMIDependencyMutation) ResetRelationship()

ResetRelationship resets all changes to the "relationship" field.

func (*RMIDependencyMutation) ResetSourceRmiID

func (m *RMIDependencyMutation) ResetSourceRmiID()

ResetSourceRmiID resets all changes to the "source_rmi_id" field.

func (*RMIDependencyMutation) ResetTargetRmiID

func (m *RMIDependencyMutation) ResetTargetRmiID()

ResetTargetRmiID resets all changes to the "target_rmi_id" field.

func (*RMIDependencyMutation) SetField

func (m *RMIDependencyMutation) 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 (*RMIDependencyMutation) SetOp

func (m *RMIDependencyMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*RMIDependencyMutation) SetRelationship

func (m *RMIDependencyMutation) SetRelationship(s string)

SetRelationship sets the "relationship" field.

func (*RMIDependencyMutation) SetSourceRmiID

func (m *RMIDependencyMutation) SetSourceRmiID(s string)

SetSourceRmiID sets the "source_rmi_id" field.

func (*RMIDependencyMutation) SetTargetRmiID

func (m *RMIDependencyMutation) SetTargetRmiID(s string)

SetTargetRmiID sets the "target_rmi_id" field.

func (*RMIDependencyMutation) SourceRmiID

func (m *RMIDependencyMutation) SourceRmiID() (r string, exists bool)

SourceRmiID returns the value of the "source_rmi_id" field in the mutation.

func (*RMIDependencyMutation) TargetRmiID

func (m *RMIDependencyMutation) TargetRmiID() (r string, exists bool)

TargetRmiID returns the value of the "target_rmi_id" field in the mutation.

func (RMIDependencyMutation) Tx

func (m RMIDependencyMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*RMIDependencyMutation) Type

func (m *RMIDependencyMutation) Type() string

Type returns the node type of this mutation (RMIDependency).

func (*RMIDependencyMutation) Where

Where appends a list predicates to the RMIDependencyMutation builder.

func (*RMIDependencyMutation) WhereP

func (m *RMIDependencyMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the RMIDependencyMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type RMIDependencyQuery

type RMIDependencyQuery struct {
	// contains filtered or unexported fields
}

RMIDependencyQuery is the builder for querying RMIDependency entities.

func (*RMIDependencyQuery) Aggregate

func (_q *RMIDependencyQuery) Aggregate(fns ...AggregateFunc) *RMIDependencySelect

Aggregate returns a RMIDependencySelect configured with the given aggregations.

func (*RMIDependencyQuery) All

All executes the query and returns a list of RMIDependencies.

func (*RMIDependencyQuery) AllX

AllX is like All, but panics if an error occurs.

func (*RMIDependencyQuery) Clone

Clone returns a duplicate of the RMIDependencyQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*RMIDependencyQuery) Count

func (_q *RMIDependencyQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*RMIDependencyQuery) CountX

func (_q *RMIDependencyQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*RMIDependencyQuery) Exist

func (_q *RMIDependencyQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*RMIDependencyQuery) ExistX

func (_q *RMIDependencyQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*RMIDependencyQuery) First

First returns the first RMIDependency entity from the query. Returns a *NotFoundError when no RMIDependency was found.

func (*RMIDependencyQuery) FirstID

func (_q *RMIDependencyQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first RMIDependency ID from the query. Returns a *NotFoundError when no RMIDependency ID was found.

func (*RMIDependencyQuery) FirstIDX

func (_q *RMIDependencyQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*RMIDependencyQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*RMIDependencyQuery) GroupBy

func (_q *RMIDependencyQuery) GroupBy(field string, fields ...string) *RMIDependencyGroupBy

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 {
	SourceRmiID string `json:"source_rmi_id,omitempty"`
	Count int `json:"count,omitempty"`
}

client.RMIDependency.Query().
	GroupBy(rmidependency.FieldSourceRmiID).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*RMIDependencyQuery) IDs

func (_q *RMIDependencyQuery) IDs(ctx context.Context) (ids []int, err error)

IDs executes the query and returns a list of RMIDependency IDs.

func (*RMIDependencyQuery) IDsX

func (_q *RMIDependencyQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*RMIDependencyQuery) Limit

func (_q *RMIDependencyQuery) Limit(limit int) *RMIDependencyQuery

Limit the number of records to be returned by this query.

func (*RMIDependencyQuery) Offset

func (_q *RMIDependencyQuery) Offset(offset int) *RMIDependencyQuery

Offset to start from.

func (*RMIDependencyQuery) Only

Only returns a single RMIDependency entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one RMIDependency entity is found. Returns a *NotFoundError when no RMIDependency entities are found.

func (*RMIDependencyQuery) OnlyID

func (_q *RMIDependencyQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only RMIDependency ID in the query. Returns a *NotSingularError when more than one RMIDependency ID is found. Returns a *NotFoundError when no entities are found.

func (*RMIDependencyQuery) OnlyIDX

func (_q *RMIDependencyQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*RMIDependencyQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*RMIDependencyQuery) Order

Order specifies how the records should be ordered.

func (*RMIDependencyQuery) Select

func (_q *RMIDependencyQuery) Select(fields ...string) *RMIDependencySelect

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 {
	SourceRmiID string `json:"source_rmi_id,omitempty"`
}

client.RMIDependency.Query().
	Select(rmidependency.FieldSourceRmiID).
	Scan(ctx, &v)

func (*RMIDependencyQuery) Unique

func (_q *RMIDependencyQuery) Unique(unique bool) *RMIDependencyQuery

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 (*RMIDependencyQuery) Where

Where adds a new predicate for the RMIDependencyQuery builder.

type RMIDependencySelect

type RMIDependencySelect struct {
	*RMIDependencyQuery
	// contains filtered or unexported fields
}

RMIDependencySelect is the builder for selecting fields of RMIDependency entities.

func (*RMIDependencySelect) Aggregate

func (_s *RMIDependencySelect) Aggregate(fns ...AggregateFunc) *RMIDependencySelect

Aggregate adds the given aggregation functions to the selector query.

func (*RMIDependencySelect) Bool

func (s *RMIDependencySelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*RMIDependencySelect) BoolX

func (s *RMIDependencySelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*RMIDependencySelect) Bools

func (s *RMIDependencySelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*RMIDependencySelect) BoolsX

func (s *RMIDependencySelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*RMIDependencySelect) Float64

func (s *RMIDependencySelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*RMIDependencySelect) Float64X

func (s *RMIDependencySelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*RMIDependencySelect) Float64s

func (s *RMIDependencySelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*RMIDependencySelect) Float64sX

func (s *RMIDependencySelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*RMIDependencySelect) Int

func (s *RMIDependencySelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*RMIDependencySelect) IntX

func (s *RMIDependencySelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*RMIDependencySelect) Ints

func (s *RMIDependencySelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*RMIDependencySelect) IntsX

func (s *RMIDependencySelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*RMIDependencySelect) Scan

func (_s *RMIDependencySelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*RMIDependencySelect) ScanX

func (s *RMIDependencySelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*RMIDependencySelect) String

func (s *RMIDependencySelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*RMIDependencySelect) StringX

func (s *RMIDependencySelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*RMIDependencySelect) Strings

func (s *RMIDependencySelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*RMIDependencySelect) StringsX

func (s *RMIDependencySelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type RMIDependencyUpdate

type RMIDependencyUpdate struct {
	// contains filtered or unexported fields
}

RMIDependencyUpdate is the builder for updating RMIDependency entities.

func (*RMIDependencyUpdate) Exec

func (_u *RMIDependencyUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*RMIDependencyUpdate) ExecX

func (_u *RMIDependencyUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RMIDependencyUpdate) Mutation

Mutation returns the RMIDependencyMutation object of the builder.

func (*RMIDependencyUpdate) Save

func (_u *RMIDependencyUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*RMIDependencyUpdate) SaveX

func (_u *RMIDependencyUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*RMIDependencyUpdate) SetNillableRelationship

func (_u *RMIDependencyUpdate) SetNillableRelationship(v *string) *RMIDependencyUpdate

SetNillableRelationship sets the "relationship" field if the given value is not nil.

func (*RMIDependencyUpdate) SetNillableSourceRmiID

func (_u *RMIDependencyUpdate) SetNillableSourceRmiID(v *string) *RMIDependencyUpdate

SetNillableSourceRmiID sets the "source_rmi_id" field if the given value is not nil.

func (*RMIDependencyUpdate) SetNillableTargetRmiID

func (_u *RMIDependencyUpdate) SetNillableTargetRmiID(v *string) *RMIDependencyUpdate

SetNillableTargetRmiID sets the "target_rmi_id" field if the given value is not nil.

func (*RMIDependencyUpdate) SetRelationship

func (_u *RMIDependencyUpdate) SetRelationship(v string) *RMIDependencyUpdate

SetRelationship sets the "relationship" field.

func (*RMIDependencyUpdate) SetSourceRmiID

func (_u *RMIDependencyUpdate) SetSourceRmiID(v string) *RMIDependencyUpdate

SetSourceRmiID sets the "source_rmi_id" field.

func (*RMIDependencyUpdate) SetTargetRmiID

func (_u *RMIDependencyUpdate) SetTargetRmiID(v string) *RMIDependencyUpdate

SetTargetRmiID sets the "target_rmi_id" field.

func (*RMIDependencyUpdate) Where

Where appends a list predicates to the RMIDependencyUpdate builder.

type RMIDependencyUpdateOne

type RMIDependencyUpdateOne struct {
	// contains filtered or unexported fields
}

RMIDependencyUpdateOne is the builder for updating a single RMIDependency entity.

func (*RMIDependencyUpdateOne) Exec

Exec executes the query on the entity.

func (*RMIDependencyUpdateOne) ExecX

func (_u *RMIDependencyUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RMIDependencyUpdateOne) Mutation

Mutation returns the RMIDependencyMutation object of the builder.

func (*RMIDependencyUpdateOne) Save

Save executes the query and returns the updated RMIDependency entity.

func (*RMIDependencyUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*RMIDependencyUpdateOne) Select

func (_u *RMIDependencyUpdateOne) Select(field string, fields ...string) *RMIDependencyUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*RMIDependencyUpdateOne) SetNillableRelationship

func (_u *RMIDependencyUpdateOne) SetNillableRelationship(v *string) *RMIDependencyUpdateOne

SetNillableRelationship sets the "relationship" field if the given value is not nil.

func (*RMIDependencyUpdateOne) SetNillableSourceRmiID

func (_u *RMIDependencyUpdateOne) SetNillableSourceRmiID(v *string) *RMIDependencyUpdateOne

SetNillableSourceRmiID sets the "source_rmi_id" field if the given value is not nil.

func (*RMIDependencyUpdateOne) SetNillableTargetRmiID

func (_u *RMIDependencyUpdateOne) SetNillableTargetRmiID(v *string) *RMIDependencyUpdateOne

SetNillableTargetRmiID sets the "target_rmi_id" field if the given value is not nil.

func (*RMIDependencyUpdateOne) SetRelationship

func (_u *RMIDependencyUpdateOne) SetRelationship(v string) *RMIDependencyUpdateOne

SetRelationship sets the "relationship" field.

func (*RMIDependencyUpdateOne) SetSourceRmiID

func (_u *RMIDependencyUpdateOne) SetSourceRmiID(v string) *RMIDependencyUpdateOne

SetSourceRmiID sets the "source_rmi_id" field.

func (*RMIDependencyUpdateOne) SetTargetRmiID

func (_u *RMIDependencyUpdateOne) SetTargetRmiID(v string) *RMIDependencyUpdateOne

SetTargetRmiID sets the "target_rmi_id" field.

func (*RMIDependencyUpdateOne) Where

Where appends a list predicates to the RMIDependencyUpdate builder.

type Repositories

type Repositories []*Repository

Repositories is a parsable slice of Repository.

type Repository

type Repository struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// Organization holds the value of the "organization" field.
	Organization string `json:"organization,omitempty"`
	// RepositoryName holds the value of the "repository_name" field.
	RepositoryName string `json:"repository_name,omitempty"`
	// DefaultBranch holds the value of the "default_branch" field.
	DefaultBranch string `json:"default_branch,omitempty"`
	// LocalPath holds the value of the "local_path" field.
	LocalPath string `json:"local_path,omitempty"`
	// GoModule holds the value of the "go_module" field.
	GoModule string `json:"go_module,omitempty"`
	// Domain holds the value of the "domain" field.
	Domain string `json:"domain,omitempty"`
	// Status holds the value of the "status" field.
	Status string `json:"status,omitempty"`
	// IngestHighWater holds the value of the "ingest_high_water" field.
	IngestHighWater string `json:"ingest_high_water,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) QueryRoadmapItems

func (_m *Repository) QueryRoadmapItems() *RoadmapItemQuery

QueryRoadmapItems queries the "roadmap_items" edge of the Repository entity.

func (*Repository) String

func (_m *Repository) String() string

String implements the fmt.Stringer.

func (*Repository) Unwrap

func (_m *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 (_m *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.

func (*Repository) Value

func (_m *Repository) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the Repository. This includes values selected through modifiers, order, etc.

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

func (c *RepositoryClient) DeleteOne(_m *Repository) *RepositoryDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*RepositoryClient) DeleteOneID

func (c *RepositoryClient) DeleteOneID(id string) *RepositoryDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*RepositoryClient) Get

func (c *RepositoryClient) Get(ctx context.Context, id string) (*Repository, error)

Get returns a Repository entity by its id.

func (*RepositoryClient) GetX

func (c *RepositoryClient) GetX(ctx context.Context, id string) *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) Intercept

func (c *RepositoryClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `repository.Intercept(f(g(h())))`.

func (*RepositoryClient) Interceptors

func (c *RepositoryClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*RepositoryClient) MapCreateBulk

func (c *RepositoryClient) MapCreateBulk(slice any, setFunc func(*RepositoryCreate, int)) *RepositoryCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*RepositoryClient) Query

func (c *RepositoryClient) Query() *RepositoryQuery

Query returns a query builder for Repository.

func (*RepositoryClient) QueryRoadmapItems

func (c *RepositoryClient) QueryRoadmapItems(_m *Repository) *RoadmapItemQuery

QueryRoadmapItems queries the roadmap_items edge of a Repository.

func (*RepositoryClient) Update

func (c *RepositoryClient) Update() *RepositoryUpdate

Update returns an update builder for Repository.

func (*RepositoryClient) UpdateOne

func (c *RepositoryClient) UpdateOne(_m *Repository) *RepositoryUpdateOne

UpdateOne returns an update builder for the given entity.

func (*RepositoryClient) UpdateOneID

func (c *RepositoryClient) UpdateOneID(id string) *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 RepositoryCreate

type RepositoryCreate struct {
	// contains filtered or unexported fields
}

RepositoryCreate is the builder for creating a Repository entity.

func (*RepositoryCreate) AddRoadmapItemIDs

func (_c *RepositoryCreate) AddRoadmapItemIDs(ids ...string) *RepositoryCreate

AddRoadmapItemIDs adds the "roadmap_items" edge to the RoadmapItem entity by IDs.

func (*RepositoryCreate) AddRoadmapItems

func (_c *RepositoryCreate) AddRoadmapItems(v ...*RoadmapItem) *RepositoryCreate

AddRoadmapItems adds the "roadmap_items" edges to the RoadmapItem entity.

func (*RepositoryCreate) Exec

func (_c *RepositoryCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*RepositoryCreate) ExecX

func (_c *RepositoryCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryCreate) Mutation

func (_c *RepositoryCreate) Mutation() *RepositoryMutation

Mutation returns the RepositoryMutation object of the builder.

func (*RepositoryCreate) Save

func (_c *RepositoryCreate) Save(ctx context.Context) (*Repository, error)

Save creates the Repository in the database.

func (*RepositoryCreate) SaveX

func (_c *RepositoryCreate) SaveX(ctx context.Context) *Repository

SaveX calls Save and panics if Save returns an error.

func (*RepositoryCreate) SetDefaultBranch

func (_c *RepositoryCreate) SetDefaultBranch(v string) *RepositoryCreate

SetDefaultBranch sets the "default_branch" field.

func (*RepositoryCreate) SetDomain

func (_c *RepositoryCreate) SetDomain(v string) *RepositoryCreate

SetDomain sets the "domain" field.

func (*RepositoryCreate) SetGoModule

func (_c *RepositoryCreate) SetGoModule(v string) *RepositoryCreate

SetGoModule sets the "go_module" field.

func (*RepositoryCreate) SetID

SetID sets the "id" field.

func (*RepositoryCreate) SetIngestHighWater

func (_c *RepositoryCreate) SetIngestHighWater(v string) *RepositoryCreate

SetIngestHighWater sets the "ingest_high_water" field.

func (*RepositoryCreate) SetLocalPath

func (_c *RepositoryCreate) SetLocalPath(v string) *RepositoryCreate

SetLocalPath sets the "local_path" field.

func (*RepositoryCreate) SetNillableDefaultBranch

func (_c *RepositoryCreate) SetNillableDefaultBranch(v *string) *RepositoryCreate

SetNillableDefaultBranch sets the "default_branch" field if the given value is not nil.

func (*RepositoryCreate) SetNillableDomain

func (_c *RepositoryCreate) SetNillableDomain(v *string) *RepositoryCreate

SetNillableDomain sets the "domain" field if the given value is not nil.

func (*RepositoryCreate) SetNillableGoModule

func (_c *RepositoryCreate) SetNillableGoModule(v *string) *RepositoryCreate

SetNillableGoModule sets the "go_module" field if the given value is not nil.

func (*RepositoryCreate) SetNillableIngestHighWater

func (_c *RepositoryCreate) SetNillableIngestHighWater(v *string) *RepositoryCreate

SetNillableIngestHighWater sets the "ingest_high_water" field if the given value is not nil.

func (*RepositoryCreate) SetNillableLocalPath

func (_c *RepositoryCreate) SetNillableLocalPath(v *string) *RepositoryCreate

SetNillableLocalPath sets the "local_path" field if the given value is not nil.

func (*RepositoryCreate) SetOrganization

func (_c *RepositoryCreate) SetOrganization(v string) *RepositoryCreate

SetOrganization sets the "organization" field.

func (*RepositoryCreate) SetRepositoryName

func (_c *RepositoryCreate) SetRepositoryName(v string) *RepositoryCreate

SetRepositoryName sets the "repository_name" field.

func (*RepositoryCreate) SetStatus

func (_c *RepositoryCreate) SetStatus(v string) *RepositoryCreate

SetStatus sets the "status" field.

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 (_c *RepositoryCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*RepositoryCreateBulk) ExecX

func (_c *RepositoryCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryCreateBulk) Save

func (_c *RepositoryCreateBulk) Save(ctx context.Context) ([]*Repository, error)

Save creates the Repository entities in the database.

func (*RepositoryCreateBulk) SaveX

func (_c *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 (_d *RepositoryDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*RepositoryDelete) ExecX

func (_d *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 (_d *RepositoryDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*RepositoryDeleteOne) ExecX

func (_d *RepositoryDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryDeleteOne) Where

Where appends a list predicates to the RepositoryDelete builder.

type RepositoryDependencies

type RepositoryDependencies []*RepositoryDependency

RepositoryDependencies is a parsable slice of RepositoryDependency.

type RepositoryDependency

type RepositoryDependency struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// SourceRepositoryID holds the value of the "source_repository_id" field.
	SourceRepositoryID string `json:"source_repository_id,omitempty"`
	// TargetRepositoryID holds the value of the "target_repository_id" field.
	TargetRepositoryID string `json:"target_repository_id,omitempty"`
	// DependencyType holds the value of the "dependency_type" field.
	DependencyType string `json:"dependency_type,omitempty"`
	// contains filtered or unexported fields
}

RepositoryDependency is the model entity for the RepositoryDependency schema.

func (*RepositoryDependency) String

func (_m *RepositoryDependency) String() string

String implements the fmt.Stringer.

func (*RepositoryDependency) Unwrap

Unwrap unwraps the RepositoryDependency 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 (*RepositoryDependency) Update

Update returns a builder for updating this RepositoryDependency. Note that you need to call RepositoryDependency.Unwrap() before calling this method if this RepositoryDependency was returned from a transaction, and the transaction was committed or rolled back.

func (*RepositoryDependency) Value

func (_m *RepositoryDependency) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the RepositoryDependency. This includes values selected through modifiers, order, etc.

type RepositoryDependencyClient

type RepositoryDependencyClient struct {
	// contains filtered or unexported fields
}

RepositoryDependencyClient is a client for the RepositoryDependency schema.

func NewRepositoryDependencyClient

func NewRepositoryDependencyClient(c config) *RepositoryDependencyClient

NewRepositoryDependencyClient returns a client for the RepositoryDependency from the given config.

func (*RepositoryDependencyClient) Create

Create returns a builder for creating a RepositoryDependency entity.

func (*RepositoryDependencyClient) CreateBulk

CreateBulk returns a builder for creating a bulk of RepositoryDependency entities.

func (*RepositoryDependencyClient) Delete

Delete returns a delete builder for RepositoryDependency.

func (*RepositoryDependencyClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*RepositoryDependencyClient) DeleteOneID

DeleteOneID returns a builder for deleting the given entity by its id.

func (*RepositoryDependencyClient) Get

Get returns a RepositoryDependency entity by its id.

func (*RepositoryDependencyClient) GetX

GetX is like Get, but panics if an error occurs.

func (*RepositoryDependencyClient) Hooks

func (c *RepositoryDependencyClient) Hooks() []Hook

Hooks returns the client hooks.

func (*RepositoryDependencyClient) Intercept

func (c *RepositoryDependencyClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `repositorydependency.Intercept(f(g(h())))`.

func (*RepositoryDependencyClient) Interceptors

func (c *RepositoryDependencyClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*RepositoryDependencyClient) MapCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*RepositoryDependencyClient) Query

Query returns a query builder for RepositoryDependency.

func (*RepositoryDependencyClient) Update

Update returns an update builder for RepositoryDependency.

func (*RepositoryDependencyClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*RepositoryDependencyClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*RepositoryDependencyClient) Use

func (c *RepositoryDependencyClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `repositorydependency.Hooks(f(g(h())))`.

type RepositoryDependencyCreate

type RepositoryDependencyCreate struct {
	// contains filtered or unexported fields
}

RepositoryDependencyCreate is the builder for creating a RepositoryDependency entity.

func (*RepositoryDependencyCreate) Exec

Exec executes the query.

func (*RepositoryDependencyCreate) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryDependencyCreate) Mutation

Mutation returns the RepositoryDependencyMutation object of the builder.

func (*RepositoryDependencyCreate) Save

Save creates the RepositoryDependency in the database.

func (*RepositoryDependencyCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*RepositoryDependencyCreate) SetDependencyType

SetDependencyType sets the "dependency_type" field.

func (*RepositoryDependencyCreate) SetSourceRepositoryID

func (_c *RepositoryDependencyCreate) SetSourceRepositoryID(v string) *RepositoryDependencyCreate

SetSourceRepositoryID sets the "source_repository_id" field.

func (*RepositoryDependencyCreate) SetTargetRepositoryID

func (_c *RepositoryDependencyCreate) SetTargetRepositoryID(v string) *RepositoryDependencyCreate

SetTargetRepositoryID sets the "target_repository_id" field.

type RepositoryDependencyCreateBulk

type RepositoryDependencyCreateBulk struct {
	// contains filtered or unexported fields
}

RepositoryDependencyCreateBulk is the builder for creating many RepositoryDependency entities in bulk.

func (*RepositoryDependencyCreateBulk) Exec

Exec executes the query.

func (*RepositoryDependencyCreateBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryDependencyCreateBulk) Save

Save creates the RepositoryDependency entities in the database.

func (*RepositoryDependencyCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type RepositoryDependencyDelete

type RepositoryDependencyDelete struct {
	// contains filtered or unexported fields
}

RepositoryDependencyDelete is the builder for deleting a RepositoryDependency entity.

func (*RepositoryDependencyDelete) Exec

Exec executes the deletion query and returns how many vertices were deleted.

func (*RepositoryDependencyDelete) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryDependencyDelete) Where

Where appends a list predicates to the RepositoryDependencyDelete builder.

type RepositoryDependencyDeleteOne

type RepositoryDependencyDeleteOne struct {
	// contains filtered or unexported fields
}

RepositoryDependencyDeleteOne is the builder for deleting a single RepositoryDependency entity.

func (*RepositoryDependencyDeleteOne) Exec

Exec executes the deletion query.

func (*RepositoryDependencyDeleteOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryDependencyDeleteOne) Where

Where appends a list predicates to the RepositoryDependencyDelete builder.

type RepositoryDependencyGroupBy

type RepositoryDependencyGroupBy struct {
	// contains filtered or unexported fields
}

RepositoryDependencyGroupBy is the group-by builder for RepositoryDependency entities.

func (*RepositoryDependencyGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*RepositoryDependencyGroupBy) Bool

func (s *RepositoryDependencyGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencyGroupBy) BoolX

func (s *RepositoryDependencyGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*RepositoryDependencyGroupBy) Bools

func (s *RepositoryDependencyGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencyGroupBy) BoolsX

func (s *RepositoryDependencyGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*RepositoryDependencyGroupBy) Float64

func (s *RepositoryDependencyGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencyGroupBy) Float64X

func (s *RepositoryDependencyGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*RepositoryDependencyGroupBy) Float64s

func (s *RepositoryDependencyGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencyGroupBy) Float64sX

func (s *RepositoryDependencyGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*RepositoryDependencyGroupBy) Int

func (s *RepositoryDependencyGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencyGroupBy) IntX

func (s *RepositoryDependencyGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*RepositoryDependencyGroupBy) Ints

func (s *RepositoryDependencyGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencyGroupBy) IntsX

func (s *RepositoryDependencyGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*RepositoryDependencyGroupBy) Scan

Scan applies the selector query and scans the result into the given value.

func (*RepositoryDependencyGroupBy) ScanX

func (s *RepositoryDependencyGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*RepositoryDependencyGroupBy) String

func (s *RepositoryDependencyGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencyGroupBy) StringX

func (s *RepositoryDependencyGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*RepositoryDependencyGroupBy) Strings

func (s *RepositoryDependencyGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencyGroupBy) StringsX

func (s *RepositoryDependencyGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type RepositoryDependencyMutation

type RepositoryDependencyMutation struct {
	// contains filtered or unexported fields
}

RepositoryDependencyMutation represents an operation that mutates the RepositoryDependency nodes in the graph.

func (*RepositoryDependencyMutation) AddField

func (m *RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) AddedEdges

func (m *RepositoryDependencyMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*RepositoryDependencyMutation) AddedField

func (m *RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) AddedFields

func (m *RepositoryDependencyMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*RepositoryDependencyMutation) AddedIDs

func (m *RepositoryDependencyMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*RepositoryDependencyMutation) ClearEdge

func (m *RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) ClearField

func (m *RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) ClearedEdges

func (m *RepositoryDependencyMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*RepositoryDependencyMutation) ClearedFields

func (m *RepositoryDependencyMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) DependencyType

func (m *RepositoryDependencyMutation) DependencyType() (r string, exists bool)

DependencyType returns the value of the "dependency_type" field in the mutation.

func (*RepositoryDependencyMutation) EdgeCleared

func (m *RepositoryDependencyMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*RepositoryDependencyMutation) Field

func (m *RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) FieldCleared

func (m *RepositoryDependencyMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*RepositoryDependencyMutation) Fields

func (m *RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) ID

func (m *RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) OldDependencyType

func (m *RepositoryDependencyMutation) OldDependencyType(ctx context.Context) (v string, err error)

OldDependencyType returns the old "dependency_type" field's value of the RepositoryDependency entity. If the RepositoryDependency 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 (*RepositoryDependencyMutation) OldField

func (m *RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) OldSourceRepositoryID

func (m *RepositoryDependencyMutation) OldSourceRepositoryID(ctx context.Context) (v string, err error)

OldSourceRepositoryID returns the old "source_repository_id" field's value of the RepositoryDependency entity. If the RepositoryDependency 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 (*RepositoryDependencyMutation) OldTargetRepositoryID

func (m *RepositoryDependencyMutation) OldTargetRepositoryID(ctx context.Context) (v string, err error)

OldTargetRepositoryID returns the old "target_repository_id" field's value of the RepositoryDependency entity. If the RepositoryDependency 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 (*RepositoryDependencyMutation) Op

Op returns the operation name.

func (*RepositoryDependencyMutation) RemovedEdges

func (m *RepositoryDependencyMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*RepositoryDependencyMutation) RemovedIDs

func (m *RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) ResetDependencyType

func (m *RepositoryDependencyMutation) ResetDependencyType()

ResetDependencyType resets all changes to the "dependency_type" field.

func (*RepositoryDependencyMutation) ResetEdge

func (m *RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) ResetField

func (m *RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) ResetSourceRepositoryID

func (m *RepositoryDependencyMutation) ResetSourceRepositoryID()

ResetSourceRepositoryID resets all changes to the "source_repository_id" field.

func (*RepositoryDependencyMutation) ResetTargetRepositoryID

func (m *RepositoryDependencyMutation) ResetTargetRepositoryID()

ResetTargetRepositoryID resets all changes to the "target_repository_id" field.

func (*RepositoryDependencyMutation) SetDependencyType

func (m *RepositoryDependencyMutation) SetDependencyType(s string)

SetDependencyType sets the "dependency_type" field.

func (*RepositoryDependencyMutation) SetField

func (m *RepositoryDependencyMutation) 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 (*RepositoryDependencyMutation) SetOp

func (m *RepositoryDependencyMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*RepositoryDependencyMutation) SetSourceRepositoryID

func (m *RepositoryDependencyMutation) SetSourceRepositoryID(s string)

SetSourceRepositoryID sets the "source_repository_id" field.

func (*RepositoryDependencyMutation) SetTargetRepositoryID

func (m *RepositoryDependencyMutation) SetTargetRepositoryID(s string)

SetTargetRepositoryID sets the "target_repository_id" field.

func (*RepositoryDependencyMutation) SourceRepositoryID

func (m *RepositoryDependencyMutation) SourceRepositoryID() (r string, exists bool)

SourceRepositoryID returns the value of the "source_repository_id" field in the mutation.

func (*RepositoryDependencyMutation) TargetRepositoryID

func (m *RepositoryDependencyMutation) TargetRepositoryID() (r string, exists bool)

TargetRepositoryID returns the value of the "target_repository_id" field in the mutation.

func (RepositoryDependencyMutation) Tx

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*RepositoryDependencyMutation) Type

Type returns the node type of this mutation (RepositoryDependency).

func (*RepositoryDependencyMutation) Where

Where appends a list predicates to the RepositoryDependencyMutation builder.

func (*RepositoryDependencyMutation) WhereP

func (m *RepositoryDependencyMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the RepositoryDependencyMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type RepositoryDependencyQuery

type RepositoryDependencyQuery struct {
	// contains filtered or unexported fields
}

RepositoryDependencyQuery is the builder for querying RepositoryDependency entities.

func (*RepositoryDependencyQuery) Aggregate

Aggregate returns a RepositoryDependencySelect configured with the given aggregations.

func (*RepositoryDependencyQuery) All

All executes the query and returns a list of RepositoryDependencies.

func (*RepositoryDependencyQuery) AllX

AllX is like All, but panics if an error occurs.

func (*RepositoryDependencyQuery) Clone

Clone returns a duplicate of the RepositoryDependencyQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*RepositoryDependencyQuery) Count

Count returns the count of the given query.

func (*RepositoryDependencyQuery) CountX

func (_q *RepositoryDependencyQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*RepositoryDependencyQuery) Exist

Exist returns true if the query has elements in the graph.

func (*RepositoryDependencyQuery) ExistX

ExistX is like Exist, but panics if an error occurs.

func (*RepositoryDependencyQuery) First

First returns the first RepositoryDependency entity from the query. Returns a *NotFoundError when no RepositoryDependency was found.

func (*RepositoryDependencyQuery) FirstID

func (_q *RepositoryDependencyQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first RepositoryDependency ID from the query. Returns a *NotFoundError when no RepositoryDependency ID was found.

func (*RepositoryDependencyQuery) FirstIDX

func (_q *RepositoryDependencyQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*RepositoryDependencyQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*RepositoryDependencyQuery) GroupBy

func (_q *RepositoryDependencyQuery) GroupBy(field string, fields ...string) *RepositoryDependencyGroupBy

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 {
	SourceRepositoryID string `json:"source_repository_id,omitempty"`
	Count int `json:"count,omitempty"`
}

client.RepositoryDependency.Query().
	GroupBy(repositorydependency.FieldSourceRepositoryID).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*RepositoryDependencyQuery) IDs

func (_q *RepositoryDependencyQuery) IDs(ctx context.Context) (ids []int, err error)

IDs executes the query and returns a list of RepositoryDependency IDs.

func (*RepositoryDependencyQuery) IDsX

func (_q *RepositoryDependencyQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*RepositoryDependencyQuery) Limit

Limit the number of records to be returned by this query.

func (*RepositoryDependencyQuery) Offset

Offset to start from.

func (*RepositoryDependencyQuery) Only

Only returns a single RepositoryDependency entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one RepositoryDependency entity is found. Returns a *NotFoundError when no RepositoryDependency entities are found.

func (*RepositoryDependencyQuery) OnlyID

func (_q *RepositoryDependencyQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only RepositoryDependency ID in the query. Returns a *NotSingularError when more than one RepositoryDependency ID is found. Returns a *NotFoundError when no entities are found.

func (*RepositoryDependencyQuery) OnlyIDX

func (_q *RepositoryDependencyQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*RepositoryDependencyQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*RepositoryDependencyQuery) Order

Order specifies how the records should be ordered.

func (*RepositoryDependencyQuery) 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 {
	SourceRepositoryID string `json:"source_repository_id,omitempty"`
}

client.RepositoryDependency.Query().
	Select(repositorydependency.FieldSourceRepositoryID).
	Scan(ctx, &v)

func (*RepositoryDependencyQuery) 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 (*RepositoryDependencyQuery) Where

Where adds a new predicate for the RepositoryDependencyQuery builder.

type RepositoryDependencySelect

type RepositoryDependencySelect struct {
	*RepositoryDependencyQuery
	// contains filtered or unexported fields
}

RepositoryDependencySelect is the builder for selecting fields of RepositoryDependency entities.

func (*RepositoryDependencySelect) Aggregate

Aggregate adds the given aggregation functions to the selector query.

func (*RepositoryDependencySelect) Bool

func (s *RepositoryDependencySelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencySelect) BoolX

func (s *RepositoryDependencySelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*RepositoryDependencySelect) Bools

func (s *RepositoryDependencySelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencySelect) BoolsX

func (s *RepositoryDependencySelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*RepositoryDependencySelect) Float64

func (s *RepositoryDependencySelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencySelect) Float64X

func (s *RepositoryDependencySelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*RepositoryDependencySelect) Float64s

func (s *RepositoryDependencySelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencySelect) Float64sX

func (s *RepositoryDependencySelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*RepositoryDependencySelect) Int

func (s *RepositoryDependencySelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencySelect) IntX

func (s *RepositoryDependencySelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*RepositoryDependencySelect) Ints

func (s *RepositoryDependencySelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencySelect) IntsX

func (s *RepositoryDependencySelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*RepositoryDependencySelect) Scan

Scan applies the selector query and scans the result into the given value.

func (*RepositoryDependencySelect) ScanX

func (s *RepositoryDependencySelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*RepositoryDependencySelect) String

func (s *RepositoryDependencySelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencySelect) StringX

func (s *RepositoryDependencySelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*RepositoryDependencySelect) Strings

func (s *RepositoryDependencySelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*RepositoryDependencySelect) StringsX

func (s *RepositoryDependencySelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type RepositoryDependencyUpdate

type RepositoryDependencyUpdate struct {
	// contains filtered or unexported fields
}

RepositoryDependencyUpdate is the builder for updating RepositoryDependency entities.

func (*RepositoryDependencyUpdate) Exec

Exec executes the query.

func (*RepositoryDependencyUpdate) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryDependencyUpdate) Mutation

Mutation returns the RepositoryDependencyMutation object of the builder.

func (*RepositoryDependencyUpdate) Save

Save executes the query and returns the number of nodes affected by the update operation.

func (*RepositoryDependencyUpdate) SaveX

SaveX is like Save, but panics if an error occurs.

func (*RepositoryDependencyUpdate) SetDependencyType

SetDependencyType sets the "dependency_type" field.

func (*RepositoryDependencyUpdate) SetNillableDependencyType

func (_u *RepositoryDependencyUpdate) SetNillableDependencyType(v *string) *RepositoryDependencyUpdate

SetNillableDependencyType sets the "dependency_type" field if the given value is not nil.

func (*RepositoryDependencyUpdate) SetNillableSourceRepositoryID

func (_u *RepositoryDependencyUpdate) SetNillableSourceRepositoryID(v *string) *RepositoryDependencyUpdate

SetNillableSourceRepositoryID sets the "source_repository_id" field if the given value is not nil.

func (*RepositoryDependencyUpdate) SetNillableTargetRepositoryID

func (_u *RepositoryDependencyUpdate) SetNillableTargetRepositoryID(v *string) *RepositoryDependencyUpdate

SetNillableTargetRepositoryID sets the "target_repository_id" field if the given value is not nil.

func (*RepositoryDependencyUpdate) SetSourceRepositoryID

func (_u *RepositoryDependencyUpdate) SetSourceRepositoryID(v string) *RepositoryDependencyUpdate

SetSourceRepositoryID sets the "source_repository_id" field.

func (*RepositoryDependencyUpdate) SetTargetRepositoryID

func (_u *RepositoryDependencyUpdate) SetTargetRepositoryID(v string) *RepositoryDependencyUpdate

SetTargetRepositoryID sets the "target_repository_id" field.

func (*RepositoryDependencyUpdate) Where

Where appends a list predicates to the RepositoryDependencyUpdate builder.

type RepositoryDependencyUpdateOne

type RepositoryDependencyUpdateOne struct {
	// contains filtered or unexported fields
}

RepositoryDependencyUpdateOne is the builder for updating a single RepositoryDependency entity.

func (*RepositoryDependencyUpdateOne) Exec

Exec executes the query on the entity.

func (*RepositoryDependencyUpdateOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryDependencyUpdateOne) Mutation

Mutation returns the RepositoryDependencyMutation object of the builder.

func (*RepositoryDependencyUpdateOne) Save

Save executes the query and returns the updated RepositoryDependency entity.

func (*RepositoryDependencyUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*RepositoryDependencyUpdateOne) 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 (*RepositoryDependencyUpdateOne) SetDependencyType

SetDependencyType sets the "dependency_type" field.

func (*RepositoryDependencyUpdateOne) SetNillableDependencyType

func (_u *RepositoryDependencyUpdateOne) SetNillableDependencyType(v *string) *RepositoryDependencyUpdateOne

SetNillableDependencyType sets the "dependency_type" field if the given value is not nil.

func (*RepositoryDependencyUpdateOne) SetNillableSourceRepositoryID

func (_u *RepositoryDependencyUpdateOne) SetNillableSourceRepositoryID(v *string) *RepositoryDependencyUpdateOne

SetNillableSourceRepositoryID sets the "source_repository_id" field if the given value is not nil.

func (*RepositoryDependencyUpdateOne) SetNillableTargetRepositoryID

func (_u *RepositoryDependencyUpdateOne) SetNillableTargetRepositoryID(v *string) *RepositoryDependencyUpdateOne

SetNillableTargetRepositoryID sets the "target_repository_id" field if the given value is not nil.

func (*RepositoryDependencyUpdateOne) SetSourceRepositoryID

SetSourceRepositoryID sets the "source_repository_id" field.

func (*RepositoryDependencyUpdateOne) SetTargetRepositoryID

SetTargetRepositoryID sets the "target_repository_id" field.

func (*RepositoryDependencyUpdateOne) Where

Where appends a list predicates to the RepositoryDependencyUpdate builder.

type RepositoryEdges

type RepositoryEdges struct {
	// RoadmapItems holds the value of the roadmap_items edge.
	RoadmapItems []*RoadmapItem `json:"roadmap_items,omitempty"`
	// contains filtered or unexported fields
}

RepositoryEdges holds the relations/edges for other nodes in the graph.

func (RepositoryEdges) RoadmapItemsOrErr

func (e RepositoryEdges) RoadmapItemsOrErr() ([]*RoadmapItem, error)

RoadmapItemsOrErr returns the RoadmapItems 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 (_g *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 (_g *RepositoryGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*RepositoryGroupBy) ScanX

func (s *RepositoryGroupBy) ScanX(ctx context.Context, v any)

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) 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) AddRoadmapItemIDs

func (m *RepositoryMutation) AddRoadmapItemIDs(ids ...string)

AddRoadmapItemIDs adds the "roadmap_items" edge to the RoadmapItem 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) ClearDomain

func (m *RepositoryMutation) ClearDomain()

ClearDomain clears the value of the "domain" field.

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) ClearGoModule

func (m *RepositoryMutation) ClearGoModule()

ClearGoModule clears the value of the "go_module" field.

func (*RepositoryMutation) ClearIngestHighWater

func (m *RepositoryMutation) ClearIngestHighWater()

ClearIngestHighWater clears the value of the "ingest_high_water" field.

func (*RepositoryMutation) ClearLocalPath

func (m *RepositoryMutation) ClearLocalPath()

ClearLocalPath clears the value of the "local_path" field.

func (*RepositoryMutation) ClearRoadmapItems

func (m *RepositoryMutation) ClearRoadmapItems()

ClearRoadmapItems clears the "roadmap_items" edge to the RoadmapItem 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) DefaultBranch

func (m *RepositoryMutation) DefaultBranch() (r string, exists bool)

DefaultBranch returns the value of the "default_branch" field in the mutation.

func (*RepositoryMutation) Domain

func (m *RepositoryMutation) Domain() (r string, exists bool)

Domain returns the value of the "domain" field in the mutation.

func (*RepositoryMutation) DomainCleared

func (m *RepositoryMutation) DomainCleared() bool

DomainCleared returns if the "domain" field was cleared in this 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) GoModule

func (m *RepositoryMutation) GoModule() (r string, exists bool)

GoModule returns the value of the "go_module" field in the mutation.

func (*RepositoryMutation) GoModuleCleared

func (m *RepositoryMutation) GoModuleCleared() bool

GoModuleCleared returns if the "go_module" field was cleared in this mutation.

func (*RepositoryMutation) ID

func (m *RepositoryMutation) ID() (id string, 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) ([]string, 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) IngestHighWater

func (m *RepositoryMutation) IngestHighWater() (r string, exists bool)

IngestHighWater returns the value of the "ingest_high_water" field in the mutation.

func (*RepositoryMutation) IngestHighWaterCleared

func (m *RepositoryMutation) IngestHighWaterCleared() bool

IngestHighWaterCleared returns if the "ingest_high_water" field was cleared in this mutation.

func (*RepositoryMutation) LocalPath

func (m *RepositoryMutation) LocalPath() (r string, exists bool)

LocalPath returns the value of the "local_path" field in the mutation.

func (*RepositoryMutation) LocalPathCleared

func (m *RepositoryMutation) LocalPathCleared() bool

LocalPathCleared returns if the "local_path" field was cleared in this mutation.

func (*RepositoryMutation) OldDefaultBranch

func (m *RepositoryMutation) OldDefaultBranch(ctx context.Context) (v string, err error)

OldDefaultBranch returns the old "default_branch" 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) OldDomain

func (m *RepositoryMutation) OldDomain(ctx context.Context) (v string, err error)

OldDomain returns the old "domain" 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) OldGoModule

func (m *RepositoryMutation) OldGoModule(ctx context.Context) (v string, err error)

OldGoModule returns the old "go_module" 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) OldIngestHighWater

func (m *RepositoryMutation) OldIngestHighWater(ctx context.Context) (v string, err error)

OldIngestHighWater returns the old "ingest_high_water" 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) OldLocalPath

func (m *RepositoryMutation) OldLocalPath(ctx context.Context) (v string, err error)

OldLocalPath returns the old "local_path" 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) OldOrganization

func (m *RepositoryMutation) OldOrganization(ctx context.Context) (v string, err error)

OldOrganization returns the old "organization" 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) OldRepositoryName

func (m *RepositoryMutation) OldRepositoryName(ctx context.Context) (v string, err error)

OldRepositoryName returns the old "repository_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) OldStatus

func (m *RepositoryMutation) OldStatus(ctx context.Context) (v string, err error)

OldStatus returns the old "status" 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) Organization

func (m *RepositoryMutation) Organization() (r string, exists bool)

Organization returns the value of the "organization" field in the mutation.

func (*RepositoryMutation) RemoveRoadmapItemIDs

func (m *RepositoryMutation) RemoveRoadmapItemIDs(ids ...string)

RemoveRoadmapItemIDs removes the "roadmap_items" edge to the RoadmapItem entity by IDs.

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) RemovedRoadmapItemsIDs

func (m *RepositoryMutation) RemovedRoadmapItemsIDs() (ids []string)

RemovedRoadmapItems returns the removed IDs of the "roadmap_items" edge to the RoadmapItem entity.

func (*RepositoryMutation) RepositoryName

func (m *RepositoryMutation) RepositoryName() (r string, exists bool)

RepositoryName returns the value of the "repository_name" field in the mutation.

func (*RepositoryMutation) ResetDefaultBranch

func (m *RepositoryMutation) ResetDefaultBranch()

ResetDefaultBranch resets all changes to the "default_branch" field.

func (*RepositoryMutation) ResetDomain

func (m *RepositoryMutation) ResetDomain()

ResetDomain resets all changes to the "domain" field.

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) ResetGoModule

func (m *RepositoryMutation) ResetGoModule()

ResetGoModule resets all changes to the "go_module" field.

func (*RepositoryMutation) ResetIngestHighWater

func (m *RepositoryMutation) ResetIngestHighWater()

ResetIngestHighWater resets all changes to the "ingest_high_water" field.

func (*RepositoryMutation) ResetLocalPath

func (m *RepositoryMutation) ResetLocalPath()

ResetLocalPath resets all changes to the "local_path" field.

func (*RepositoryMutation) ResetOrganization

func (m *RepositoryMutation) ResetOrganization()

ResetOrganization resets all changes to the "organization" field.

func (*RepositoryMutation) ResetRepositoryName

func (m *RepositoryMutation) ResetRepositoryName()

ResetRepositoryName resets all changes to the "repository_name" field.

func (*RepositoryMutation) ResetRoadmapItems

func (m *RepositoryMutation) ResetRoadmapItems()

ResetRoadmapItems resets all changes to the "roadmap_items" edge.

func (*RepositoryMutation) ResetStatus

func (m *RepositoryMutation) ResetStatus()

ResetStatus resets all changes to the "status" field.

func (*RepositoryMutation) RoadmapItemsCleared

func (m *RepositoryMutation) RoadmapItemsCleared() bool

RoadmapItemsCleared reports if the "roadmap_items" edge to the RoadmapItem entity was cleared.

func (*RepositoryMutation) RoadmapItemsIDs

func (m *RepositoryMutation) RoadmapItemsIDs() (ids []string)

RoadmapItemsIDs returns the "roadmap_items" edge IDs in the mutation.

func (*RepositoryMutation) SetDefaultBranch

func (m *RepositoryMutation) SetDefaultBranch(s string)

SetDefaultBranch sets the "default_branch" field.

func (*RepositoryMutation) SetDomain

func (m *RepositoryMutation) SetDomain(s string)

SetDomain sets the "domain" 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) SetGoModule

func (m *RepositoryMutation) SetGoModule(s string)

SetGoModule sets the "go_module" field.

func (*RepositoryMutation) SetID

func (m *RepositoryMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of Repository entities.

func (*RepositoryMutation) SetIngestHighWater

func (m *RepositoryMutation) SetIngestHighWater(s string)

SetIngestHighWater sets the "ingest_high_water" field.

func (*RepositoryMutation) SetLocalPath

func (m *RepositoryMutation) SetLocalPath(s string)

SetLocalPath sets the "local_path" field.

func (*RepositoryMutation) SetOp

func (m *RepositoryMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*RepositoryMutation) SetOrganization

func (m *RepositoryMutation) SetOrganization(s string)

SetOrganization sets the "organization" field.

func (*RepositoryMutation) SetRepositoryName

func (m *RepositoryMutation) SetRepositoryName(s string)

SetRepositoryName sets the "repository_name" field.

func (*RepositoryMutation) SetStatus

func (m *RepositoryMutation) SetStatus(s string)

SetStatus sets the "status" field.

func (*RepositoryMutation) Status

func (m *RepositoryMutation) Status() (r string, exists bool)

Status returns the value of the "status" field 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.

func (*RepositoryMutation) WhereP

func (m *RepositoryMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the RepositoryMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type RepositoryQuery

type RepositoryQuery struct {
	// contains filtered or unexported fields
}

RepositoryQuery is the builder for querying Repository entities.

func (*RepositoryQuery) Aggregate

func (_q *RepositoryQuery) Aggregate(fns ...AggregateFunc) *RepositorySelect

Aggregate returns a RepositorySelect configured with the given aggregations.

func (*RepositoryQuery) All

func (_q *RepositoryQuery) All(ctx context.Context) ([]*Repository, error)

All executes the query and returns a list of Repositories.

func (*RepositoryQuery) AllX

func (_q *RepositoryQuery) AllX(ctx context.Context) []*Repository

AllX is like All, but panics if an error occurs.

func (*RepositoryQuery) Clone

func (_q *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) Count

func (_q *RepositoryQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*RepositoryQuery) CountX

func (_q *RepositoryQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*RepositoryQuery) Exist

func (_q *RepositoryQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*RepositoryQuery) ExistX

func (_q *RepositoryQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*RepositoryQuery) First

func (_q *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 (_q *RepositoryQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first Repository ID from the query. Returns a *NotFoundError when no Repository ID was found.

func (*RepositoryQuery) FirstIDX

func (_q *RepositoryQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*RepositoryQuery) FirstX

func (_q *RepositoryQuery) FirstX(ctx context.Context) *Repository

FirstX is like First, but panics if an error occurs.

func (*RepositoryQuery) GroupBy

func (_q *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 {
	Organization string `json:"organization,omitempty"`
	Count int `json:"count,omitempty"`
}

client.Repository.Query().
	GroupBy(repository.FieldOrganization).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*RepositoryQuery) IDs

func (_q *RepositoryQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of Repository IDs.

func (*RepositoryQuery) IDsX

func (_q *RepositoryQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*RepositoryQuery) Limit

func (_q *RepositoryQuery) Limit(limit int) *RepositoryQuery

Limit the number of records to be returned by this query.

func (*RepositoryQuery) Offset

func (_q *RepositoryQuery) Offset(offset int) *RepositoryQuery

Offset to start from.

func (*RepositoryQuery) Only

func (_q *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 (_q *RepositoryQuery) OnlyID(ctx context.Context) (id string, 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 (_q *RepositoryQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*RepositoryQuery) OnlyX

func (_q *RepositoryQuery) OnlyX(ctx context.Context) *Repository

OnlyX is like Only, but panics if an error occurs.

func (*RepositoryQuery) Order

Order specifies how the records should be ordered.

func (*RepositoryQuery) QueryRoadmapItems

func (_q *RepositoryQuery) QueryRoadmapItems() *RoadmapItemQuery

QueryRoadmapItems chains the current query on the "roadmap_items" edge.

func (*RepositoryQuery) Select

func (_q *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 {
	Organization string `json:"organization,omitempty"`
}

client.Repository.Query().
	Select(repository.FieldOrganization).
	Scan(ctx, &v)

func (*RepositoryQuery) Unique

func (_q *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) WithRoadmapItems

func (_q *RepositoryQuery) WithRoadmapItems(opts ...func(*RoadmapItemQuery)) *RepositoryQuery

WithRoadmapItems tells the query-builder to eager-load the nodes that are connected to the "roadmap_items" 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) Aggregate

func (_s *RepositorySelect) Aggregate(fns ...AggregateFunc) *RepositorySelect

Aggregate adds the given aggregation functions to the selector query.

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 (_s *RepositorySelect) Scan(ctx context.Context, v any) 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 any)

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 RepositoryUpdate

type RepositoryUpdate struct {
	// contains filtered or unexported fields
}

RepositoryUpdate is the builder for updating Repository entities.

func (*RepositoryUpdate) AddRoadmapItemIDs

func (_u *RepositoryUpdate) AddRoadmapItemIDs(ids ...string) *RepositoryUpdate

AddRoadmapItemIDs adds the "roadmap_items" edge to the RoadmapItem entity by IDs.

func (*RepositoryUpdate) AddRoadmapItems

func (_u *RepositoryUpdate) AddRoadmapItems(v ...*RoadmapItem) *RepositoryUpdate

AddRoadmapItems adds the "roadmap_items" edges to the RoadmapItem entity.

func (*RepositoryUpdate) ClearDomain

func (_u *RepositoryUpdate) ClearDomain() *RepositoryUpdate

ClearDomain clears the value of the "domain" field.

func (*RepositoryUpdate) ClearGoModule

func (_u *RepositoryUpdate) ClearGoModule() *RepositoryUpdate

ClearGoModule clears the value of the "go_module" field.

func (*RepositoryUpdate) ClearIngestHighWater

func (_u *RepositoryUpdate) ClearIngestHighWater() *RepositoryUpdate

ClearIngestHighWater clears the value of the "ingest_high_water" field.

func (*RepositoryUpdate) ClearLocalPath

func (_u *RepositoryUpdate) ClearLocalPath() *RepositoryUpdate

ClearLocalPath clears the value of the "local_path" field.

func (*RepositoryUpdate) ClearRoadmapItems

func (_u *RepositoryUpdate) ClearRoadmapItems() *RepositoryUpdate

ClearRoadmapItems clears all "roadmap_items" edges to the RoadmapItem entity.

func (*RepositoryUpdate) Exec

func (_u *RepositoryUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*RepositoryUpdate) ExecX

func (_u *RepositoryUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryUpdate) Mutation

func (_u *RepositoryUpdate) Mutation() *RepositoryMutation

Mutation returns the RepositoryMutation object of the builder.

func (*RepositoryUpdate) RemoveRoadmapItemIDs

func (_u *RepositoryUpdate) RemoveRoadmapItemIDs(ids ...string) *RepositoryUpdate

RemoveRoadmapItemIDs removes the "roadmap_items" edge to RoadmapItem entities by IDs.

func (*RepositoryUpdate) RemoveRoadmapItems

func (_u *RepositoryUpdate) RemoveRoadmapItems(v ...*RoadmapItem) *RepositoryUpdate

RemoveRoadmapItems removes "roadmap_items" edges to RoadmapItem entities.

func (*RepositoryUpdate) Save

func (_u *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 (_u *RepositoryUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*RepositoryUpdate) SetDefaultBranch

func (_u *RepositoryUpdate) SetDefaultBranch(v string) *RepositoryUpdate

SetDefaultBranch sets the "default_branch" field.

func (*RepositoryUpdate) SetDomain

func (_u *RepositoryUpdate) SetDomain(v string) *RepositoryUpdate

SetDomain sets the "domain" field.

func (*RepositoryUpdate) SetGoModule

func (_u *RepositoryUpdate) SetGoModule(v string) *RepositoryUpdate

SetGoModule sets the "go_module" field.

func (*RepositoryUpdate) SetIngestHighWater

func (_u *RepositoryUpdate) SetIngestHighWater(v string) *RepositoryUpdate

SetIngestHighWater sets the "ingest_high_water" field.

func (*RepositoryUpdate) SetLocalPath

func (_u *RepositoryUpdate) SetLocalPath(v string) *RepositoryUpdate

SetLocalPath sets the "local_path" field.

func (*RepositoryUpdate) SetNillableDefaultBranch

func (_u *RepositoryUpdate) SetNillableDefaultBranch(v *string) *RepositoryUpdate

SetNillableDefaultBranch sets the "default_branch" field if the given value is not nil.

func (*RepositoryUpdate) SetNillableDomain

func (_u *RepositoryUpdate) SetNillableDomain(v *string) *RepositoryUpdate

SetNillableDomain sets the "domain" field if the given value is not nil.

func (*RepositoryUpdate) SetNillableGoModule

func (_u *RepositoryUpdate) SetNillableGoModule(v *string) *RepositoryUpdate

SetNillableGoModule sets the "go_module" field if the given value is not nil.

func (*RepositoryUpdate) SetNillableIngestHighWater

func (_u *RepositoryUpdate) SetNillableIngestHighWater(v *string) *RepositoryUpdate

SetNillableIngestHighWater sets the "ingest_high_water" field if the given value is not nil.

func (*RepositoryUpdate) SetNillableLocalPath

func (_u *RepositoryUpdate) SetNillableLocalPath(v *string) *RepositoryUpdate

SetNillableLocalPath sets the "local_path" field if the given value is not nil.

func (*RepositoryUpdate) SetNillableOrganization

func (_u *RepositoryUpdate) SetNillableOrganization(v *string) *RepositoryUpdate

SetNillableOrganization sets the "organization" field if the given value is not nil.

func (*RepositoryUpdate) SetNillableRepositoryName

func (_u *RepositoryUpdate) SetNillableRepositoryName(v *string) *RepositoryUpdate

SetNillableRepositoryName sets the "repository_name" field if the given value is not nil.

func (*RepositoryUpdate) SetNillableStatus

func (_u *RepositoryUpdate) SetNillableStatus(v *string) *RepositoryUpdate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*RepositoryUpdate) SetOrganization

func (_u *RepositoryUpdate) SetOrganization(v string) *RepositoryUpdate

SetOrganization sets the "organization" field.

func (*RepositoryUpdate) SetRepositoryName

func (_u *RepositoryUpdate) SetRepositoryName(v string) *RepositoryUpdate

SetRepositoryName sets the "repository_name" field.

func (*RepositoryUpdate) SetStatus

func (_u *RepositoryUpdate) SetStatus(v string) *RepositoryUpdate

SetStatus sets the "status" field.

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) AddRoadmapItemIDs

func (_u *RepositoryUpdateOne) AddRoadmapItemIDs(ids ...string) *RepositoryUpdateOne

AddRoadmapItemIDs adds the "roadmap_items" edge to the RoadmapItem entity by IDs.

func (*RepositoryUpdateOne) AddRoadmapItems

func (_u *RepositoryUpdateOne) AddRoadmapItems(v ...*RoadmapItem) *RepositoryUpdateOne

AddRoadmapItems adds the "roadmap_items" edges to the RoadmapItem entity.

func (*RepositoryUpdateOne) ClearDomain

func (_u *RepositoryUpdateOne) ClearDomain() *RepositoryUpdateOne

ClearDomain clears the value of the "domain" field.

func (*RepositoryUpdateOne) ClearGoModule

func (_u *RepositoryUpdateOne) ClearGoModule() *RepositoryUpdateOne

ClearGoModule clears the value of the "go_module" field.

func (*RepositoryUpdateOne) ClearIngestHighWater

func (_u *RepositoryUpdateOne) ClearIngestHighWater() *RepositoryUpdateOne

ClearIngestHighWater clears the value of the "ingest_high_water" field.

func (*RepositoryUpdateOne) ClearLocalPath

func (_u *RepositoryUpdateOne) ClearLocalPath() *RepositoryUpdateOne

ClearLocalPath clears the value of the "local_path" field.

func (*RepositoryUpdateOne) ClearRoadmapItems

func (_u *RepositoryUpdateOne) ClearRoadmapItems() *RepositoryUpdateOne

ClearRoadmapItems clears all "roadmap_items" edges to the RoadmapItem entity.

func (*RepositoryUpdateOne) Exec

func (_u *RepositoryUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*RepositoryUpdateOne) ExecX

func (_u *RepositoryUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RepositoryUpdateOne) Mutation

func (_u *RepositoryUpdateOne) Mutation() *RepositoryMutation

Mutation returns the RepositoryMutation object of the builder.

func (*RepositoryUpdateOne) RemoveRoadmapItemIDs

func (_u *RepositoryUpdateOne) RemoveRoadmapItemIDs(ids ...string) *RepositoryUpdateOne

RemoveRoadmapItemIDs removes the "roadmap_items" edge to RoadmapItem entities by IDs.

func (*RepositoryUpdateOne) RemoveRoadmapItems

func (_u *RepositoryUpdateOne) RemoveRoadmapItems(v ...*RoadmapItem) *RepositoryUpdateOne

RemoveRoadmapItems removes "roadmap_items" edges to RoadmapItem entities.

func (*RepositoryUpdateOne) Save

Save executes the query and returns the updated Repository entity.

func (*RepositoryUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*RepositoryUpdateOne) Select

func (_u *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) SetDefaultBranch

func (_u *RepositoryUpdateOne) SetDefaultBranch(v string) *RepositoryUpdateOne

SetDefaultBranch sets the "default_branch" field.

func (*RepositoryUpdateOne) SetDomain

SetDomain sets the "domain" field.

func (*RepositoryUpdateOne) SetGoModule

func (_u *RepositoryUpdateOne) SetGoModule(v string) *RepositoryUpdateOne

SetGoModule sets the "go_module" field.

func (*RepositoryUpdateOne) SetIngestHighWater

func (_u *RepositoryUpdateOne) SetIngestHighWater(v string) *RepositoryUpdateOne

SetIngestHighWater sets the "ingest_high_water" field.

func (*RepositoryUpdateOne) SetLocalPath

func (_u *RepositoryUpdateOne) SetLocalPath(v string) *RepositoryUpdateOne

SetLocalPath sets the "local_path" field.

func (*RepositoryUpdateOne) SetNillableDefaultBranch

func (_u *RepositoryUpdateOne) SetNillableDefaultBranch(v *string) *RepositoryUpdateOne

SetNillableDefaultBranch sets the "default_branch" field if the given value is not nil.

func (*RepositoryUpdateOne) SetNillableDomain

func (_u *RepositoryUpdateOne) SetNillableDomain(v *string) *RepositoryUpdateOne

SetNillableDomain sets the "domain" field if the given value is not nil.

func (*RepositoryUpdateOne) SetNillableGoModule

func (_u *RepositoryUpdateOne) SetNillableGoModule(v *string) *RepositoryUpdateOne

SetNillableGoModule sets the "go_module" field if the given value is not nil.

func (*RepositoryUpdateOne) SetNillableIngestHighWater

func (_u *RepositoryUpdateOne) SetNillableIngestHighWater(v *string) *RepositoryUpdateOne

SetNillableIngestHighWater sets the "ingest_high_water" field if the given value is not nil.

func (*RepositoryUpdateOne) SetNillableLocalPath

func (_u *RepositoryUpdateOne) SetNillableLocalPath(v *string) *RepositoryUpdateOne

SetNillableLocalPath sets the "local_path" field if the given value is not nil.

func (*RepositoryUpdateOne) SetNillableOrganization

func (_u *RepositoryUpdateOne) SetNillableOrganization(v *string) *RepositoryUpdateOne

SetNillableOrganization sets the "organization" field if the given value is not nil.

func (*RepositoryUpdateOne) SetNillableRepositoryName

func (_u *RepositoryUpdateOne) SetNillableRepositoryName(v *string) *RepositoryUpdateOne

SetNillableRepositoryName sets the "repository_name" field if the given value is not nil.

func (*RepositoryUpdateOne) SetNillableStatus

func (_u *RepositoryUpdateOne) SetNillableStatus(v *string) *RepositoryUpdateOne

SetNillableStatus sets the "status" field if the given value is not nil.

func (*RepositoryUpdateOne) SetOrganization

func (_u *RepositoryUpdateOne) SetOrganization(v string) *RepositoryUpdateOne

SetOrganization sets the "organization" field.

func (*RepositoryUpdateOne) SetRepositoryName

func (_u *RepositoryUpdateOne) SetRepositoryName(v string) *RepositoryUpdateOne

SetRepositoryName sets the "repository_name" field.

func (*RepositoryUpdateOne) SetStatus

SetStatus sets the "status" field.

func (*RepositoryUpdateOne) Where

Where appends a list predicates to the RepositoryUpdate builder.

type RoadmapItem

type RoadmapItem struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// Title holds the value of the "title" field.
	Title string `json:"title,omitempty"`
	// Description holds the value of the "description" field.
	Description string `json:"description,omitempty"`
	// ItemType holds the value of the "item_type" field.
	ItemType string `json:"item_type,omitempty"`
	// Status holds the value of the "status" field.
	Status string `json:"status,omitempty"`
	// Priority holds the value of the "priority" field.
	Priority string `json:"priority,omitempty"`
	// Required holds the value of the "required" field.
	Required bool `json:"required,omitempty"`
	// SequenceNumber holds the value of the "sequence_number" field.
	SequenceNumber int `json:"sequence_number,omitempty"`
	// AcceptanceCriteria holds the value of the "acceptance_criteria" field.
	AcceptanceCriteria []string `json:"acceptance_criteria,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// CompletedAt holds the value of the "completed_at" field.
	CompletedAt *time.Time `json:"completed_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the RoadmapItemQuery when eager-loading is set.
	Edges RoadmapItemEdges `json:"edges"`
	// contains filtered or unexported fields
}

RoadmapItem is the model entity for the RoadmapItem schema.

func (*RoadmapItem) QueryAssignments

func (_m *RoadmapItem) QueryAssignments() *AssignmentQuery

QueryAssignments queries the "assignments" edge of the RoadmapItem entity.

func (*RoadmapItem) QueryEvidence

func (_m *RoadmapItem) QueryEvidence() *DeliveryEvidenceQuery

QueryEvidence queries the "evidence" edge of the RoadmapItem entity.

func (*RoadmapItem) QueryInitiative

func (_m *RoadmapItem) QueryInitiative() *InitiativeQuery

QueryInitiative queries the "initiative" edge of the RoadmapItem entity.

func (*RoadmapItem) QueryPhase

func (_m *RoadmapItem) QueryPhase() *PhaseQuery

QueryPhase queries the "phase" edge of the RoadmapItem entity.

func (*RoadmapItem) QueryRepository

func (_m *RoadmapItem) QueryRepository() *RepositoryQuery

QueryRepository queries the "repository" edge of the RoadmapItem entity.

func (*RoadmapItem) String

func (_m *RoadmapItem) String() string

String implements the fmt.Stringer.

func (*RoadmapItem) Unwrap

func (_m *RoadmapItem) Unwrap() *RoadmapItem

Unwrap unwraps the RoadmapItem 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 (*RoadmapItem) Update

func (_m *RoadmapItem) Update() *RoadmapItemUpdateOne

Update returns a builder for updating this RoadmapItem. Note that you need to call RoadmapItem.Unwrap() before calling this method if this RoadmapItem was returned from a transaction, and the transaction was committed or rolled back.

func (*RoadmapItem) Value

func (_m *RoadmapItem) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the RoadmapItem. This includes values selected through modifiers, order, etc.

type RoadmapItemClient

type RoadmapItemClient struct {
	// contains filtered or unexported fields
}

RoadmapItemClient is a client for the RoadmapItem schema.

func NewRoadmapItemClient

func NewRoadmapItemClient(c config) *RoadmapItemClient

NewRoadmapItemClient returns a client for the RoadmapItem from the given config.

func (*RoadmapItemClient) Create

func (c *RoadmapItemClient) Create() *RoadmapItemCreate

Create returns a builder for creating a RoadmapItem entity.

func (*RoadmapItemClient) CreateBulk

func (c *RoadmapItemClient) CreateBulk(builders ...*RoadmapItemCreate) *RoadmapItemCreateBulk

CreateBulk returns a builder for creating a bulk of RoadmapItem entities.

func (*RoadmapItemClient) Delete

func (c *RoadmapItemClient) Delete() *RoadmapItemDelete

Delete returns a delete builder for RoadmapItem.

func (*RoadmapItemClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*RoadmapItemClient) DeleteOneID

func (c *RoadmapItemClient) DeleteOneID(id string) *RoadmapItemDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*RoadmapItemClient) Get

Get returns a RoadmapItem entity by its id.

func (*RoadmapItemClient) GetX

GetX is like Get, but panics if an error occurs.

func (*RoadmapItemClient) Hooks

func (c *RoadmapItemClient) Hooks() []Hook

Hooks returns the client hooks.

func (*RoadmapItemClient) Intercept

func (c *RoadmapItemClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `roadmapitem.Intercept(f(g(h())))`.

func (*RoadmapItemClient) Interceptors

func (c *RoadmapItemClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*RoadmapItemClient) MapCreateBulk

func (c *RoadmapItemClient) MapCreateBulk(slice any, setFunc func(*RoadmapItemCreate, int)) *RoadmapItemCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*RoadmapItemClient) Query

func (c *RoadmapItemClient) Query() *RoadmapItemQuery

Query returns a query builder for RoadmapItem.

func (*RoadmapItemClient) QueryAssignments

func (c *RoadmapItemClient) QueryAssignments(_m *RoadmapItem) *AssignmentQuery

QueryAssignments queries the assignments edge of a RoadmapItem.

func (*RoadmapItemClient) QueryEvidence

func (c *RoadmapItemClient) QueryEvidence(_m *RoadmapItem) *DeliveryEvidenceQuery

QueryEvidence queries the evidence edge of a RoadmapItem.

func (*RoadmapItemClient) QueryInitiative

func (c *RoadmapItemClient) QueryInitiative(_m *RoadmapItem) *InitiativeQuery

QueryInitiative queries the initiative edge of a RoadmapItem.

func (*RoadmapItemClient) QueryPhase

func (c *RoadmapItemClient) QueryPhase(_m *RoadmapItem) *PhaseQuery

QueryPhase queries the phase edge of a RoadmapItem.

func (*RoadmapItemClient) QueryRepository

func (c *RoadmapItemClient) QueryRepository(_m *RoadmapItem) *RepositoryQuery

QueryRepository queries the repository edge of a RoadmapItem.

func (*RoadmapItemClient) Update

func (c *RoadmapItemClient) Update() *RoadmapItemUpdate

Update returns an update builder for RoadmapItem.

func (*RoadmapItemClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*RoadmapItemClient) UpdateOneID

func (c *RoadmapItemClient) UpdateOneID(id string) *RoadmapItemUpdateOne

UpdateOneID returns an update builder for the given id.

func (*RoadmapItemClient) Use

func (c *RoadmapItemClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `roadmapitem.Hooks(f(g(h())))`.

type RoadmapItemCreate

type RoadmapItemCreate struct {
	// contains filtered or unexported fields
}

RoadmapItemCreate is the builder for creating a RoadmapItem entity.

func (*RoadmapItemCreate) AddAssignmentIDs

func (_c *RoadmapItemCreate) AddAssignmentIDs(ids ...string) *RoadmapItemCreate

AddAssignmentIDs adds the "assignments" edge to the Assignment entity by IDs.

func (*RoadmapItemCreate) AddAssignments

func (_c *RoadmapItemCreate) AddAssignments(v ...*Assignment) *RoadmapItemCreate

AddAssignments adds the "assignments" edges to the Assignment entity.

func (*RoadmapItemCreate) AddEvidence

func (_c *RoadmapItemCreate) AddEvidence(v ...*DeliveryEvidence) *RoadmapItemCreate

AddEvidence adds the "evidence" edges to the DeliveryEvidence entity.

func (*RoadmapItemCreate) AddEvidenceIDs

func (_c *RoadmapItemCreate) AddEvidenceIDs(ids ...string) *RoadmapItemCreate

AddEvidenceIDs adds the "evidence" edge to the DeliveryEvidence entity by IDs.

func (*RoadmapItemCreate) Exec

func (_c *RoadmapItemCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*RoadmapItemCreate) ExecX

func (_c *RoadmapItemCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RoadmapItemCreate) Mutation

func (_c *RoadmapItemCreate) Mutation() *RoadmapItemMutation

Mutation returns the RoadmapItemMutation object of the builder.

func (*RoadmapItemCreate) Save

Save creates the RoadmapItem in the database.

func (*RoadmapItemCreate) SaveX

func (_c *RoadmapItemCreate) SaveX(ctx context.Context) *RoadmapItem

SaveX calls Save and panics if Save returns an error.

func (*RoadmapItemCreate) SetAcceptanceCriteria

func (_c *RoadmapItemCreate) SetAcceptanceCriteria(v []string) *RoadmapItemCreate

SetAcceptanceCriteria sets the "acceptance_criteria" field.

func (*RoadmapItemCreate) SetCompletedAt

func (_c *RoadmapItemCreate) SetCompletedAt(v time.Time) *RoadmapItemCreate

SetCompletedAt sets the "completed_at" field.

func (*RoadmapItemCreate) SetCreatedAt

func (_c *RoadmapItemCreate) SetCreatedAt(v time.Time) *RoadmapItemCreate

SetCreatedAt sets the "created_at" field.

func (*RoadmapItemCreate) SetDescription

func (_c *RoadmapItemCreate) SetDescription(v string) *RoadmapItemCreate

SetDescription sets the "description" field.

func (*RoadmapItemCreate) SetID

SetID sets the "id" field.

func (*RoadmapItemCreate) SetInitiative

func (_c *RoadmapItemCreate) SetInitiative(v *Initiative) *RoadmapItemCreate

SetInitiative sets the "initiative" edge to the Initiative entity.

func (*RoadmapItemCreate) SetInitiativeID

func (_c *RoadmapItemCreate) SetInitiativeID(id string) *RoadmapItemCreate

SetInitiativeID sets the "initiative" edge to the Initiative entity by ID.

func (*RoadmapItemCreate) SetItemType

func (_c *RoadmapItemCreate) SetItemType(v string) *RoadmapItemCreate

SetItemType sets the "item_type" field.

func (*RoadmapItemCreate) SetNillableCompletedAt

func (_c *RoadmapItemCreate) SetNillableCompletedAt(v *time.Time) *RoadmapItemCreate

SetNillableCompletedAt sets the "completed_at" field if the given value is not nil.

func (*RoadmapItemCreate) SetNillableDescription

func (_c *RoadmapItemCreate) SetNillableDescription(v *string) *RoadmapItemCreate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*RoadmapItemCreate) SetNillableInitiativeID

func (_c *RoadmapItemCreate) SetNillableInitiativeID(id *string) *RoadmapItemCreate

SetNillableInitiativeID sets the "initiative" edge to the Initiative entity by ID if the given value is not nil.

func (*RoadmapItemCreate) SetNillablePhaseID

func (_c *RoadmapItemCreate) SetNillablePhaseID(id *string) *RoadmapItemCreate

SetNillablePhaseID sets the "phase" edge to the Phase entity by ID if the given value is not nil.

func (*RoadmapItemCreate) SetNillablePriority

func (_c *RoadmapItemCreate) SetNillablePriority(v *string) *RoadmapItemCreate

SetNillablePriority sets the "priority" field if the given value is not nil.

func (*RoadmapItemCreate) SetNillableRequired

func (_c *RoadmapItemCreate) SetNillableRequired(v *bool) *RoadmapItemCreate

SetNillableRequired sets the "required" field if the given value is not nil.

func (*RoadmapItemCreate) SetNillableSequenceNumber

func (_c *RoadmapItemCreate) SetNillableSequenceNumber(v *int) *RoadmapItemCreate

SetNillableSequenceNumber sets the "sequence_number" field if the given value is not nil.

func (*RoadmapItemCreate) SetPhase

func (_c *RoadmapItemCreate) SetPhase(v *Phase) *RoadmapItemCreate

SetPhase sets the "phase" edge to the Phase entity.

func (*RoadmapItemCreate) SetPhaseID

func (_c *RoadmapItemCreate) SetPhaseID(id string) *RoadmapItemCreate

SetPhaseID sets the "phase" edge to the Phase entity by ID.

func (*RoadmapItemCreate) SetPriority

func (_c *RoadmapItemCreate) SetPriority(v string) *RoadmapItemCreate

SetPriority sets the "priority" field.

func (*RoadmapItemCreate) SetRepository

func (_c *RoadmapItemCreate) SetRepository(v *Repository) *RoadmapItemCreate

SetRepository sets the "repository" edge to the Repository entity.

func (*RoadmapItemCreate) SetRepositoryID

func (_c *RoadmapItemCreate) SetRepositoryID(id string) *RoadmapItemCreate

SetRepositoryID sets the "repository" edge to the Repository entity by ID.

func (*RoadmapItemCreate) SetRequired

func (_c *RoadmapItemCreate) SetRequired(v bool) *RoadmapItemCreate

SetRequired sets the "required" field.

func (*RoadmapItemCreate) SetSequenceNumber

func (_c *RoadmapItemCreate) SetSequenceNumber(v int) *RoadmapItemCreate

SetSequenceNumber sets the "sequence_number" field.

func (*RoadmapItemCreate) SetStatus

func (_c *RoadmapItemCreate) SetStatus(v string) *RoadmapItemCreate

SetStatus sets the "status" field.

func (*RoadmapItemCreate) SetTitle

func (_c *RoadmapItemCreate) SetTitle(v string) *RoadmapItemCreate

SetTitle sets the "title" field.

func (*RoadmapItemCreate) SetUpdatedAt

func (_c *RoadmapItemCreate) SetUpdatedAt(v time.Time) *RoadmapItemCreate

SetUpdatedAt sets the "updated_at" field.

type RoadmapItemCreateBulk

type RoadmapItemCreateBulk struct {
	// contains filtered or unexported fields
}

RoadmapItemCreateBulk is the builder for creating many RoadmapItem entities in bulk.

func (*RoadmapItemCreateBulk) Exec

Exec executes the query.

func (*RoadmapItemCreateBulk) ExecX

func (_c *RoadmapItemCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RoadmapItemCreateBulk) Save

Save creates the RoadmapItem entities in the database.

func (*RoadmapItemCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type RoadmapItemDelete

type RoadmapItemDelete struct {
	// contains filtered or unexported fields
}

RoadmapItemDelete is the builder for deleting a RoadmapItem entity.

func (*RoadmapItemDelete) Exec

func (_d *RoadmapItemDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*RoadmapItemDelete) ExecX

func (_d *RoadmapItemDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*RoadmapItemDelete) Where

Where appends a list predicates to the RoadmapItemDelete builder.

type RoadmapItemDeleteOne

type RoadmapItemDeleteOne struct {
	// contains filtered or unexported fields
}

RoadmapItemDeleteOne is the builder for deleting a single RoadmapItem entity.

func (*RoadmapItemDeleteOne) Exec

func (_d *RoadmapItemDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*RoadmapItemDeleteOne) ExecX

func (_d *RoadmapItemDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RoadmapItemDeleteOne) Where

Where appends a list predicates to the RoadmapItemDelete builder.

type RoadmapItemEdges

type RoadmapItemEdges struct {
	// Initiative holds the value of the initiative edge.
	Initiative *Initiative `json:"initiative,omitempty"`
	// Phase holds the value of the phase edge.
	Phase *Phase `json:"phase,omitempty"`
	// Repository holds the value of the repository edge.
	Repository *Repository `json:"repository,omitempty"`
	// Assignments holds the value of the assignments edge.
	Assignments []*Assignment `json:"assignments,omitempty"`
	// Evidence holds the value of the evidence edge.
	Evidence []*DeliveryEvidence `json:"evidence,omitempty"`
	// contains filtered or unexported fields
}

RoadmapItemEdges holds the relations/edges for other nodes in the graph.

func (RoadmapItemEdges) AssignmentsOrErr

func (e RoadmapItemEdges) AssignmentsOrErr() ([]*Assignment, error)

AssignmentsOrErr returns the Assignments value or an error if the edge was not loaded in eager-loading.

func (RoadmapItemEdges) EvidenceOrErr

func (e RoadmapItemEdges) EvidenceOrErr() ([]*DeliveryEvidence, error)

EvidenceOrErr returns the Evidence value or an error if the edge was not loaded in eager-loading.

func (RoadmapItemEdges) InitiativeOrErr

func (e RoadmapItemEdges) InitiativeOrErr() (*Initiative, error)

InitiativeOrErr returns the Initiative value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (RoadmapItemEdges) PhaseOrErr

func (e RoadmapItemEdges) PhaseOrErr() (*Phase, error)

PhaseOrErr returns the Phase value or an error if the edge was not loaded in eager-loading, or loaded but was not found.

func (RoadmapItemEdges) RepositoryOrErr

func (e RoadmapItemEdges) 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 RoadmapItemGroupBy

type RoadmapItemGroupBy struct {
	// contains filtered or unexported fields
}

RoadmapItemGroupBy is the group-by builder for RoadmapItem entities.

func (*RoadmapItemGroupBy) Aggregate

func (_g *RoadmapItemGroupBy) Aggregate(fns ...AggregateFunc) *RoadmapItemGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*RoadmapItemGroupBy) Bool

func (s *RoadmapItemGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*RoadmapItemGroupBy) BoolX

func (s *RoadmapItemGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*RoadmapItemGroupBy) Bools

func (s *RoadmapItemGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*RoadmapItemGroupBy) BoolsX

func (s *RoadmapItemGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*RoadmapItemGroupBy) Float64

func (s *RoadmapItemGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*RoadmapItemGroupBy) Float64X

func (s *RoadmapItemGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*RoadmapItemGroupBy) Float64s

func (s *RoadmapItemGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*RoadmapItemGroupBy) Float64sX

func (s *RoadmapItemGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*RoadmapItemGroupBy) Int

func (s *RoadmapItemGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*RoadmapItemGroupBy) IntX

func (s *RoadmapItemGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*RoadmapItemGroupBy) Ints

func (s *RoadmapItemGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*RoadmapItemGroupBy) IntsX

func (s *RoadmapItemGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*RoadmapItemGroupBy) Scan

func (_g *RoadmapItemGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*RoadmapItemGroupBy) ScanX

func (s *RoadmapItemGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*RoadmapItemGroupBy) String

func (s *RoadmapItemGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*RoadmapItemGroupBy) StringX

func (s *RoadmapItemGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*RoadmapItemGroupBy) Strings

func (s *RoadmapItemGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*RoadmapItemGroupBy) StringsX

func (s *RoadmapItemGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type RoadmapItemMutation

type RoadmapItemMutation struct {
	// contains filtered or unexported fields
}

RoadmapItemMutation represents an operation that mutates the RoadmapItem nodes in the graph.

func (*RoadmapItemMutation) AcceptanceCriteria

func (m *RoadmapItemMutation) AcceptanceCriteria() (r []string, exists bool)

AcceptanceCriteria returns the value of the "acceptance_criteria" field in the mutation.

func (*RoadmapItemMutation) AcceptanceCriteriaCleared

func (m *RoadmapItemMutation) AcceptanceCriteriaCleared() bool

AcceptanceCriteriaCleared returns if the "acceptance_criteria" field was cleared in this mutation.

func (*RoadmapItemMutation) AddAssignmentIDs

func (m *RoadmapItemMutation) AddAssignmentIDs(ids ...string)

AddAssignmentIDs adds the "assignments" edge to the Assignment entity by ids.

func (*RoadmapItemMutation) AddEvidenceIDs

func (m *RoadmapItemMutation) AddEvidenceIDs(ids ...string)

AddEvidenceIDs adds the "evidence" edge to the DeliveryEvidence entity by ids.

func (*RoadmapItemMutation) AddField

func (m *RoadmapItemMutation) 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 (*RoadmapItemMutation) AddSequenceNumber

func (m *RoadmapItemMutation) AddSequenceNumber(i int)

AddSequenceNumber adds i to the "sequence_number" field.

func (*RoadmapItemMutation) AddedEdges

func (m *RoadmapItemMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*RoadmapItemMutation) AddedField

func (m *RoadmapItemMutation) 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 (*RoadmapItemMutation) AddedFields

func (m *RoadmapItemMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*RoadmapItemMutation) AddedIDs

func (m *RoadmapItemMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*RoadmapItemMutation) AddedSequenceNumber

func (m *RoadmapItemMutation) AddedSequenceNumber() (r int, exists bool)

AddedSequenceNumber returns the value that was added to the "sequence_number" field in this mutation.

func (*RoadmapItemMutation) AppendAcceptanceCriteria

func (m *RoadmapItemMutation) AppendAcceptanceCriteria(s []string)

AppendAcceptanceCriteria adds s to the "acceptance_criteria" field.

func (*RoadmapItemMutation) AppendedAcceptanceCriteria

func (m *RoadmapItemMutation) AppendedAcceptanceCriteria() ([]string, bool)

AppendedAcceptanceCriteria returns the list of values that were appended to the "acceptance_criteria" field in this mutation.

func (*RoadmapItemMutation) AssignmentsCleared

func (m *RoadmapItemMutation) AssignmentsCleared() bool

AssignmentsCleared reports if the "assignments" edge to the Assignment entity was cleared.

func (*RoadmapItemMutation) AssignmentsIDs

func (m *RoadmapItemMutation) AssignmentsIDs() (ids []string)

AssignmentsIDs returns the "assignments" edge IDs in the mutation.

func (*RoadmapItemMutation) ClearAcceptanceCriteria

func (m *RoadmapItemMutation) ClearAcceptanceCriteria()

ClearAcceptanceCriteria clears the value of the "acceptance_criteria" field.

func (*RoadmapItemMutation) ClearAssignments

func (m *RoadmapItemMutation) ClearAssignments()

ClearAssignments clears the "assignments" edge to the Assignment entity.

func (*RoadmapItemMutation) ClearCompletedAt

func (m *RoadmapItemMutation) ClearCompletedAt()

ClearCompletedAt clears the value of the "completed_at" field.

func (*RoadmapItemMutation) ClearDescription

func (m *RoadmapItemMutation) ClearDescription()

ClearDescription clears the value of the "description" field.

func (*RoadmapItemMutation) ClearEdge

func (m *RoadmapItemMutation) 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 (*RoadmapItemMutation) ClearEvidence

func (m *RoadmapItemMutation) ClearEvidence()

ClearEvidence clears the "evidence" edge to the DeliveryEvidence entity.

func (*RoadmapItemMutation) ClearField

func (m *RoadmapItemMutation) 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 (*RoadmapItemMutation) ClearInitiative

func (m *RoadmapItemMutation) ClearInitiative()

ClearInitiative clears the "initiative" edge to the Initiative entity.

func (*RoadmapItemMutation) ClearPhase

func (m *RoadmapItemMutation) ClearPhase()

ClearPhase clears the "phase" edge to the Phase entity.

func (*RoadmapItemMutation) ClearPriority

func (m *RoadmapItemMutation) ClearPriority()

ClearPriority clears the value of the "priority" field.

func (*RoadmapItemMutation) ClearRepository

func (m *RoadmapItemMutation) ClearRepository()

ClearRepository clears the "repository" edge to the Repository entity.

func (*RoadmapItemMutation) ClearSequenceNumber

func (m *RoadmapItemMutation) ClearSequenceNumber()

ClearSequenceNumber clears the value of the "sequence_number" field.

func (*RoadmapItemMutation) ClearedEdges

func (m *RoadmapItemMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*RoadmapItemMutation) ClearedFields

func (m *RoadmapItemMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (RoadmapItemMutation) Client

func (m RoadmapItemMutation) 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 (*RoadmapItemMutation) CompletedAt

func (m *RoadmapItemMutation) CompletedAt() (r time.Time, exists bool)

CompletedAt returns the value of the "completed_at" field in the mutation.

func (*RoadmapItemMutation) CompletedAtCleared

func (m *RoadmapItemMutation) CompletedAtCleared() bool

CompletedAtCleared returns if the "completed_at" field was cleared in this mutation.

func (*RoadmapItemMutation) CreatedAt

func (m *RoadmapItemMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*RoadmapItemMutation) Description

func (m *RoadmapItemMutation) Description() (r string, exists bool)

Description returns the value of the "description" field in the mutation.

func (*RoadmapItemMutation) DescriptionCleared

func (m *RoadmapItemMutation) DescriptionCleared() bool

DescriptionCleared returns if the "description" field was cleared in this mutation.

func (*RoadmapItemMutation) EdgeCleared

func (m *RoadmapItemMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*RoadmapItemMutation) EvidenceCleared

func (m *RoadmapItemMutation) EvidenceCleared() bool

EvidenceCleared reports if the "evidence" edge to the DeliveryEvidence entity was cleared.

func (*RoadmapItemMutation) EvidenceIDs

func (m *RoadmapItemMutation) EvidenceIDs() (ids []string)

EvidenceIDs returns the "evidence" edge IDs in the mutation.

func (*RoadmapItemMutation) Field

func (m *RoadmapItemMutation) 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 (*RoadmapItemMutation) FieldCleared

func (m *RoadmapItemMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*RoadmapItemMutation) Fields

func (m *RoadmapItemMutation) 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 (*RoadmapItemMutation) ID

func (m *RoadmapItemMutation) ID() (id string, 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 (*RoadmapItemMutation) IDs

func (m *RoadmapItemMutation) IDs(ctx context.Context) ([]string, 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 (*RoadmapItemMutation) InitiativeCleared

func (m *RoadmapItemMutation) InitiativeCleared() bool

InitiativeCleared reports if the "initiative" edge to the Initiative entity was cleared.

func (*RoadmapItemMutation) InitiativeID

func (m *RoadmapItemMutation) InitiativeID() (id string, exists bool)

InitiativeID returns the "initiative" edge ID in the mutation.

func (*RoadmapItemMutation) InitiativeIDs

func (m *RoadmapItemMutation) InitiativeIDs() (ids []string)

InitiativeIDs returns the "initiative" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use InitiativeID instead. It exists only for internal usage by the builders.

func (*RoadmapItemMutation) ItemType

func (m *RoadmapItemMutation) ItemType() (r string, exists bool)

ItemType returns the value of the "item_type" field in the mutation.

func (*RoadmapItemMutation) OldAcceptanceCriteria

func (m *RoadmapItemMutation) OldAcceptanceCriteria(ctx context.Context) (v []string, err error)

OldAcceptanceCriteria returns the old "acceptance_criteria" field's value of the RoadmapItem entity. If the RoadmapItem 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 (*RoadmapItemMutation) OldCompletedAt

func (m *RoadmapItemMutation) OldCompletedAt(ctx context.Context) (v *time.Time, err error)

OldCompletedAt returns the old "completed_at" field's value of the RoadmapItem entity. If the RoadmapItem 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 (*RoadmapItemMutation) OldCreatedAt

func (m *RoadmapItemMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the RoadmapItem entity. If the RoadmapItem 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 (*RoadmapItemMutation) OldDescription

func (m *RoadmapItemMutation) OldDescription(ctx context.Context) (v string, err error)

OldDescription returns the old "description" field's value of the RoadmapItem entity. If the RoadmapItem 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 (*RoadmapItemMutation) OldField

func (m *RoadmapItemMutation) 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 (*RoadmapItemMutation) OldItemType

func (m *RoadmapItemMutation) OldItemType(ctx context.Context) (v string, err error)

OldItemType returns the old "item_type" field's value of the RoadmapItem entity. If the RoadmapItem 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 (*RoadmapItemMutation) OldPriority

func (m *RoadmapItemMutation) OldPriority(ctx context.Context) (v string, err error)

OldPriority returns the old "priority" field's value of the RoadmapItem entity. If the RoadmapItem 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 (*RoadmapItemMutation) OldRequired

func (m *RoadmapItemMutation) OldRequired(ctx context.Context) (v bool, err error)

OldRequired returns the old "required" field's value of the RoadmapItem entity. If the RoadmapItem 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 (*RoadmapItemMutation) OldSequenceNumber

func (m *RoadmapItemMutation) OldSequenceNumber(ctx context.Context) (v int, err error)

OldSequenceNumber returns the old "sequence_number" field's value of the RoadmapItem entity. If the RoadmapItem 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 (*RoadmapItemMutation) OldStatus

func (m *RoadmapItemMutation) OldStatus(ctx context.Context) (v string, err error)

OldStatus returns the old "status" field's value of the RoadmapItem entity. If the RoadmapItem 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 (*RoadmapItemMutation) OldTitle

func (m *RoadmapItemMutation) OldTitle(ctx context.Context) (v string, err error)

OldTitle returns the old "title" field's value of the RoadmapItem entity. If the RoadmapItem 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 (*RoadmapItemMutation) OldUpdatedAt

func (m *RoadmapItemMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the RoadmapItem entity. If the RoadmapItem 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 (*RoadmapItemMutation) Op

func (m *RoadmapItemMutation) Op() Op

Op returns the operation name.

func (*RoadmapItemMutation) PhaseCleared

func (m *RoadmapItemMutation) PhaseCleared() bool

PhaseCleared reports if the "phase" edge to the Phase entity was cleared.

func (*RoadmapItemMutation) PhaseID

func (m *RoadmapItemMutation) PhaseID() (id string, exists bool)

PhaseID returns the "phase" edge ID in the mutation.

func (*RoadmapItemMutation) PhaseIDs

func (m *RoadmapItemMutation) PhaseIDs() (ids []string)

PhaseIDs returns the "phase" edge IDs in the mutation. Note that IDs always returns len(IDs) <= 1 for unique edges, and you should use PhaseID instead. It exists only for internal usage by the builders.

func (*RoadmapItemMutation) Priority

func (m *RoadmapItemMutation) Priority() (r string, exists bool)

Priority returns the value of the "priority" field in the mutation.

func (*RoadmapItemMutation) PriorityCleared

func (m *RoadmapItemMutation) PriorityCleared() bool

PriorityCleared returns if the "priority" field was cleared in this mutation.

func (*RoadmapItemMutation) RemoveAssignmentIDs

func (m *RoadmapItemMutation) RemoveAssignmentIDs(ids ...string)

RemoveAssignmentIDs removes the "assignments" edge to the Assignment entity by IDs.

func (*RoadmapItemMutation) RemoveEvidenceIDs

func (m *RoadmapItemMutation) RemoveEvidenceIDs(ids ...string)

RemoveEvidenceIDs removes the "evidence" edge to the DeliveryEvidence entity by IDs.

func (*RoadmapItemMutation) RemovedAssignmentsIDs

func (m *RoadmapItemMutation) RemovedAssignmentsIDs() (ids []string)

RemovedAssignments returns the removed IDs of the "assignments" edge to the Assignment entity.

func (*RoadmapItemMutation) RemovedEdges

func (m *RoadmapItemMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*RoadmapItemMutation) RemovedEvidenceIDs

func (m *RoadmapItemMutation) RemovedEvidenceIDs() (ids []string)

RemovedEvidence returns the removed IDs of the "evidence" edge to the DeliveryEvidence entity.

func (*RoadmapItemMutation) RemovedIDs

func (m *RoadmapItemMutation) 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 (*RoadmapItemMutation) RepositoryCleared

func (m *RoadmapItemMutation) RepositoryCleared() bool

RepositoryCleared reports if the "repository" edge to the Repository entity was cleared.

func (*RoadmapItemMutation) RepositoryID

func (m *RoadmapItemMutation) RepositoryID() (id string, exists bool)

RepositoryID returns the "repository" edge ID in the mutation.

func (*RoadmapItemMutation) RepositoryIDs

func (m *RoadmapItemMutation) RepositoryIDs() (ids []string)

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 (*RoadmapItemMutation) Required

func (m *RoadmapItemMutation) Required() (r bool, exists bool)

Required returns the value of the "required" field in the mutation.

func (*RoadmapItemMutation) ResetAcceptanceCriteria

func (m *RoadmapItemMutation) ResetAcceptanceCriteria()

ResetAcceptanceCriteria resets all changes to the "acceptance_criteria" field.

func (*RoadmapItemMutation) ResetAssignments

func (m *RoadmapItemMutation) ResetAssignments()

ResetAssignments resets all changes to the "assignments" edge.

func (*RoadmapItemMutation) ResetCompletedAt

func (m *RoadmapItemMutation) ResetCompletedAt()

ResetCompletedAt resets all changes to the "completed_at" field.

func (*RoadmapItemMutation) ResetCreatedAt

func (m *RoadmapItemMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*RoadmapItemMutation) ResetDescription

func (m *RoadmapItemMutation) ResetDescription()

ResetDescription resets all changes to the "description" field.

func (*RoadmapItemMutation) ResetEdge

func (m *RoadmapItemMutation) 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 (*RoadmapItemMutation) ResetEvidence

func (m *RoadmapItemMutation) ResetEvidence()

ResetEvidence resets all changes to the "evidence" edge.

func (*RoadmapItemMutation) ResetField

func (m *RoadmapItemMutation) 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 (*RoadmapItemMutation) ResetInitiative

func (m *RoadmapItemMutation) ResetInitiative()

ResetInitiative resets all changes to the "initiative" edge.

func (*RoadmapItemMutation) ResetItemType

func (m *RoadmapItemMutation) ResetItemType()

ResetItemType resets all changes to the "item_type" field.

func (*RoadmapItemMutation) ResetPhase

func (m *RoadmapItemMutation) ResetPhase()

ResetPhase resets all changes to the "phase" edge.

func (*RoadmapItemMutation) ResetPriority

func (m *RoadmapItemMutation) ResetPriority()

ResetPriority resets all changes to the "priority" field.

func (*RoadmapItemMutation) ResetRepository

func (m *RoadmapItemMutation) ResetRepository()

ResetRepository resets all changes to the "repository" edge.

func (*RoadmapItemMutation) ResetRequired

func (m *RoadmapItemMutation) ResetRequired()

ResetRequired resets all changes to the "required" field.

func (*RoadmapItemMutation) ResetSequenceNumber

func (m *RoadmapItemMutation) ResetSequenceNumber()

ResetSequenceNumber resets all changes to the "sequence_number" field.

func (*RoadmapItemMutation) ResetStatus

func (m *RoadmapItemMutation) ResetStatus()

ResetStatus resets all changes to the "status" field.

func (*RoadmapItemMutation) ResetTitle

func (m *RoadmapItemMutation) ResetTitle()

ResetTitle resets all changes to the "title" field.

func (*RoadmapItemMutation) ResetUpdatedAt

func (m *RoadmapItemMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*RoadmapItemMutation) SequenceNumber

func (m *RoadmapItemMutation) SequenceNumber() (r int, exists bool)

SequenceNumber returns the value of the "sequence_number" field in the mutation.

func (*RoadmapItemMutation) SequenceNumberCleared

func (m *RoadmapItemMutation) SequenceNumberCleared() bool

SequenceNumberCleared returns if the "sequence_number" field was cleared in this mutation.

func (*RoadmapItemMutation) SetAcceptanceCriteria

func (m *RoadmapItemMutation) SetAcceptanceCriteria(s []string)

SetAcceptanceCriteria sets the "acceptance_criteria" field.

func (*RoadmapItemMutation) SetCompletedAt

func (m *RoadmapItemMutation) SetCompletedAt(t time.Time)

SetCompletedAt sets the "completed_at" field.

func (*RoadmapItemMutation) SetCreatedAt

func (m *RoadmapItemMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*RoadmapItemMutation) SetDescription

func (m *RoadmapItemMutation) SetDescription(s string)

SetDescription sets the "description" field.

func (*RoadmapItemMutation) SetField

func (m *RoadmapItemMutation) 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 (*RoadmapItemMutation) SetID

func (m *RoadmapItemMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of RoadmapItem entities.

func (*RoadmapItemMutation) SetInitiativeID

func (m *RoadmapItemMutation) SetInitiativeID(id string)

SetInitiativeID sets the "initiative" edge to the Initiative entity by id.

func (*RoadmapItemMutation) SetItemType

func (m *RoadmapItemMutation) SetItemType(s string)

SetItemType sets the "item_type" field.

func (*RoadmapItemMutation) SetOp

func (m *RoadmapItemMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*RoadmapItemMutation) SetPhaseID

func (m *RoadmapItemMutation) SetPhaseID(id string)

SetPhaseID sets the "phase" edge to the Phase entity by id.

func (*RoadmapItemMutation) SetPriority

func (m *RoadmapItemMutation) SetPriority(s string)

SetPriority sets the "priority" field.

func (*RoadmapItemMutation) SetRepositoryID

func (m *RoadmapItemMutation) SetRepositoryID(id string)

SetRepositoryID sets the "repository" edge to the Repository entity by id.

func (*RoadmapItemMutation) SetRequired

func (m *RoadmapItemMutation) SetRequired(b bool)

SetRequired sets the "required" field.

func (*RoadmapItemMutation) SetSequenceNumber

func (m *RoadmapItemMutation) SetSequenceNumber(i int)

SetSequenceNumber sets the "sequence_number" field.

func (*RoadmapItemMutation) SetStatus

func (m *RoadmapItemMutation) SetStatus(s string)

SetStatus sets the "status" field.

func (*RoadmapItemMutation) SetTitle

func (m *RoadmapItemMutation) SetTitle(s string)

SetTitle sets the "title" field.

func (*RoadmapItemMutation) SetUpdatedAt

func (m *RoadmapItemMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (*RoadmapItemMutation) Status

func (m *RoadmapItemMutation) Status() (r string, exists bool)

Status returns the value of the "status" field in the mutation.

func (*RoadmapItemMutation) Title

func (m *RoadmapItemMutation) Title() (r string, exists bool)

Title returns the value of the "title" field in the mutation.

func (RoadmapItemMutation) Tx

func (m RoadmapItemMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*RoadmapItemMutation) Type

func (m *RoadmapItemMutation) Type() string

Type returns the node type of this mutation (RoadmapItem).

func (*RoadmapItemMutation) UpdatedAt

func (m *RoadmapItemMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*RoadmapItemMutation) Where

func (m *RoadmapItemMutation) Where(ps ...predicate.RoadmapItem)

Where appends a list predicates to the RoadmapItemMutation builder.

func (*RoadmapItemMutation) WhereP

func (m *RoadmapItemMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the RoadmapItemMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type RoadmapItemQuery

type RoadmapItemQuery struct {
	// contains filtered or unexported fields
}

RoadmapItemQuery is the builder for querying RoadmapItem entities.

func (*RoadmapItemQuery) Aggregate

func (_q *RoadmapItemQuery) Aggregate(fns ...AggregateFunc) *RoadmapItemSelect

Aggregate returns a RoadmapItemSelect configured with the given aggregations.

func (*RoadmapItemQuery) All

func (_q *RoadmapItemQuery) All(ctx context.Context) ([]*RoadmapItem, error)

All executes the query and returns a list of RoadmapItems.

func (*RoadmapItemQuery) AllX

func (_q *RoadmapItemQuery) AllX(ctx context.Context) []*RoadmapItem

AllX is like All, but panics if an error occurs.

func (*RoadmapItemQuery) Clone

func (_q *RoadmapItemQuery) Clone() *RoadmapItemQuery

Clone returns a duplicate of the RoadmapItemQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*RoadmapItemQuery) Count

func (_q *RoadmapItemQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*RoadmapItemQuery) CountX

func (_q *RoadmapItemQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*RoadmapItemQuery) Exist

func (_q *RoadmapItemQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*RoadmapItemQuery) ExistX

func (_q *RoadmapItemQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*RoadmapItemQuery) First

func (_q *RoadmapItemQuery) First(ctx context.Context) (*RoadmapItem, error)

First returns the first RoadmapItem entity from the query. Returns a *NotFoundError when no RoadmapItem was found.

func (*RoadmapItemQuery) FirstID

func (_q *RoadmapItemQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first RoadmapItem ID from the query. Returns a *NotFoundError when no RoadmapItem ID was found.

func (*RoadmapItemQuery) FirstIDX

func (_q *RoadmapItemQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*RoadmapItemQuery) FirstX

func (_q *RoadmapItemQuery) FirstX(ctx context.Context) *RoadmapItem

FirstX is like First, but panics if an error occurs.

func (*RoadmapItemQuery) GroupBy

func (_q *RoadmapItemQuery) GroupBy(field string, fields ...string) *RoadmapItemGroupBy

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 {
	Title string `json:"title,omitempty"`
	Count int `json:"count,omitempty"`
}

client.RoadmapItem.Query().
	GroupBy(roadmapitem.FieldTitle).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*RoadmapItemQuery) IDs

func (_q *RoadmapItemQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of RoadmapItem IDs.

func (*RoadmapItemQuery) IDsX

func (_q *RoadmapItemQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*RoadmapItemQuery) Limit

func (_q *RoadmapItemQuery) Limit(limit int) *RoadmapItemQuery

Limit the number of records to be returned by this query.

func (*RoadmapItemQuery) Offset

func (_q *RoadmapItemQuery) Offset(offset int) *RoadmapItemQuery

Offset to start from.

func (*RoadmapItemQuery) Only

func (_q *RoadmapItemQuery) Only(ctx context.Context) (*RoadmapItem, error)

Only returns a single RoadmapItem entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one RoadmapItem entity is found. Returns a *NotFoundError when no RoadmapItem entities are found.

func (*RoadmapItemQuery) OnlyID

func (_q *RoadmapItemQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only RoadmapItem ID in the query. Returns a *NotSingularError when more than one RoadmapItem ID is found. Returns a *NotFoundError when no entities are found.

func (*RoadmapItemQuery) OnlyIDX

func (_q *RoadmapItemQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*RoadmapItemQuery) OnlyX

func (_q *RoadmapItemQuery) OnlyX(ctx context.Context) *RoadmapItem

OnlyX is like Only, but panics if an error occurs.

func (*RoadmapItemQuery) Order

Order specifies how the records should be ordered.

func (*RoadmapItemQuery) QueryAssignments

func (_q *RoadmapItemQuery) QueryAssignments() *AssignmentQuery

QueryAssignments chains the current query on the "assignments" edge.

func (*RoadmapItemQuery) QueryEvidence

func (_q *RoadmapItemQuery) QueryEvidence() *DeliveryEvidenceQuery

QueryEvidence chains the current query on the "evidence" edge.

func (*RoadmapItemQuery) QueryInitiative

func (_q *RoadmapItemQuery) QueryInitiative() *InitiativeQuery

QueryInitiative chains the current query on the "initiative" edge.

func (*RoadmapItemQuery) QueryPhase

func (_q *RoadmapItemQuery) QueryPhase() *PhaseQuery

QueryPhase chains the current query on the "phase" edge.

func (*RoadmapItemQuery) QueryRepository

func (_q *RoadmapItemQuery) QueryRepository() *RepositoryQuery

QueryRepository chains the current query on the "repository" edge.

func (*RoadmapItemQuery) Select

func (_q *RoadmapItemQuery) Select(fields ...string) *RoadmapItemSelect

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 {
	Title string `json:"title,omitempty"`
}

client.RoadmapItem.Query().
	Select(roadmapitem.FieldTitle).
	Scan(ctx, &v)

func (*RoadmapItemQuery) Unique

func (_q *RoadmapItemQuery) Unique(unique bool) *RoadmapItemQuery

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 (*RoadmapItemQuery) Where

Where adds a new predicate for the RoadmapItemQuery builder.

func (*RoadmapItemQuery) WithAssignments

func (_q *RoadmapItemQuery) WithAssignments(opts ...func(*AssignmentQuery)) *RoadmapItemQuery

WithAssignments tells the query-builder to eager-load the nodes that are connected to the "assignments" edge. The optional arguments are used to configure the query builder of the edge.

func (*RoadmapItemQuery) WithEvidence

func (_q *RoadmapItemQuery) WithEvidence(opts ...func(*DeliveryEvidenceQuery)) *RoadmapItemQuery

WithEvidence tells the query-builder to eager-load the nodes that are connected to the "evidence" edge. The optional arguments are used to configure the query builder of the edge.

func (*RoadmapItemQuery) WithInitiative

func (_q *RoadmapItemQuery) WithInitiative(opts ...func(*InitiativeQuery)) *RoadmapItemQuery

WithInitiative tells the query-builder to eager-load the nodes that are connected to the "initiative" edge. The optional arguments are used to configure the query builder of the edge.

func (*RoadmapItemQuery) WithPhase

func (_q *RoadmapItemQuery) WithPhase(opts ...func(*PhaseQuery)) *RoadmapItemQuery

WithPhase tells the query-builder to eager-load the nodes that are connected to the "phase" edge. The optional arguments are used to configure the query builder of the edge.

func (*RoadmapItemQuery) WithRepository

func (_q *RoadmapItemQuery) WithRepository(opts ...func(*RepositoryQuery)) *RoadmapItemQuery

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 RoadmapItemSelect

type RoadmapItemSelect struct {
	*RoadmapItemQuery
	// contains filtered or unexported fields
}

RoadmapItemSelect is the builder for selecting fields of RoadmapItem entities.

func (*RoadmapItemSelect) Aggregate

func (_s *RoadmapItemSelect) Aggregate(fns ...AggregateFunc) *RoadmapItemSelect

Aggregate adds the given aggregation functions to the selector query.

func (*RoadmapItemSelect) Bool

func (s *RoadmapItemSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*RoadmapItemSelect) BoolX

func (s *RoadmapItemSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*RoadmapItemSelect) Bools

func (s *RoadmapItemSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*RoadmapItemSelect) BoolsX

func (s *RoadmapItemSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*RoadmapItemSelect) Float64

func (s *RoadmapItemSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*RoadmapItemSelect) Float64X

func (s *RoadmapItemSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*RoadmapItemSelect) Float64s

func (s *RoadmapItemSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*RoadmapItemSelect) Float64sX

func (s *RoadmapItemSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*RoadmapItemSelect) Int

func (s *RoadmapItemSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*RoadmapItemSelect) IntX

func (s *RoadmapItemSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*RoadmapItemSelect) Ints

func (s *RoadmapItemSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*RoadmapItemSelect) IntsX

func (s *RoadmapItemSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*RoadmapItemSelect) Scan

func (_s *RoadmapItemSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*RoadmapItemSelect) ScanX

func (s *RoadmapItemSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*RoadmapItemSelect) String

func (s *RoadmapItemSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*RoadmapItemSelect) StringX

func (s *RoadmapItemSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*RoadmapItemSelect) Strings

func (s *RoadmapItemSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*RoadmapItemSelect) StringsX

func (s *RoadmapItemSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type RoadmapItemUpdate

type RoadmapItemUpdate struct {
	// contains filtered or unexported fields
}

RoadmapItemUpdate is the builder for updating RoadmapItem entities.

func (*RoadmapItemUpdate) AddAssignmentIDs

func (_u *RoadmapItemUpdate) AddAssignmentIDs(ids ...string) *RoadmapItemUpdate

AddAssignmentIDs adds the "assignments" edge to the Assignment entity by IDs.

func (*RoadmapItemUpdate) AddAssignments

func (_u *RoadmapItemUpdate) AddAssignments(v ...*Assignment) *RoadmapItemUpdate

AddAssignments adds the "assignments" edges to the Assignment entity.

func (*RoadmapItemUpdate) AddEvidence

func (_u *RoadmapItemUpdate) AddEvidence(v ...*DeliveryEvidence) *RoadmapItemUpdate

AddEvidence adds the "evidence" edges to the DeliveryEvidence entity.

func (*RoadmapItemUpdate) AddEvidenceIDs

func (_u *RoadmapItemUpdate) AddEvidenceIDs(ids ...string) *RoadmapItemUpdate

AddEvidenceIDs adds the "evidence" edge to the DeliveryEvidence entity by IDs.

func (*RoadmapItemUpdate) AddSequenceNumber

func (_u *RoadmapItemUpdate) AddSequenceNumber(v int) *RoadmapItemUpdate

AddSequenceNumber adds value to the "sequence_number" field.

func (*RoadmapItemUpdate) AppendAcceptanceCriteria

func (_u *RoadmapItemUpdate) AppendAcceptanceCriteria(v []string) *RoadmapItemUpdate

AppendAcceptanceCriteria appends value to the "acceptance_criteria" field.

func (*RoadmapItemUpdate) ClearAcceptanceCriteria

func (_u *RoadmapItemUpdate) ClearAcceptanceCriteria() *RoadmapItemUpdate

ClearAcceptanceCriteria clears the value of the "acceptance_criteria" field.

func (*RoadmapItemUpdate) ClearAssignments

func (_u *RoadmapItemUpdate) ClearAssignments() *RoadmapItemUpdate

ClearAssignments clears all "assignments" edges to the Assignment entity.

func (*RoadmapItemUpdate) ClearCompletedAt

func (_u *RoadmapItemUpdate) ClearCompletedAt() *RoadmapItemUpdate

ClearCompletedAt clears the value of the "completed_at" field.

func (*RoadmapItemUpdate) ClearDescription

func (_u *RoadmapItemUpdate) ClearDescription() *RoadmapItemUpdate

ClearDescription clears the value of the "description" field.

func (*RoadmapItemUpdate) ClearEvidence

func (_u *RoadmapItemUpdate) ClearEvidence() *RoadmapItemUpdate

ClearEvidence clears all "evidence" edges to the DeliveryEvidence entity.

func (*RoadmapItemUpdate) ClearInitiative

func (_u *RoadmapItemUpdate) ClearInitiative() *RoadmapItemUpdate

ClearInitiative clears the "initiative" edge to the Initiative entity.

func (*RoadmapItemUpdate) ClearPhase

func (_u *RoadmapItemUpdate) ClearPhase() *RoadmapItemUpdate

ClearPhase clears the "phase" edge to the Phase entity.

func (*RoadmapItemUpdate) ClearPriority

func (_u *RoadmapItemUpdate) ClearPriority() *RoadmapItemUpdate

ClearPriority clears the value of the "priority" field.

func (*RoadmapItemUpdate) ClearRepository

func (_u *RoadmapItemUpdate) ClearRepository() *RoadmapItemUpdate

ClearRepository clears the "repository" edge to the Repository entity.

func (*RoadmapItemUpdate) ClearSequenceNumber

func (_u *RoadmapItemUpdate) ClearSequenceNumber() *RoadmapItemUpdate

ClearSequenceNumber clears the value of the "sequence_number" field.

func (*RoadmapItemUpdate) Exec

func (_u *RoadmapItemUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*RoadmapItemUpdate) ExecX

func (_u *RoadmapItemUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RoadmapItemUpdate) Mutation

func (_u *RoadmapItemUpdate) Mutation() *RoadmapItemMutation

Mutation returns the RoadmapItemMutation object of the builder.

func (*RoadmapItemUpdate) RemoveAssignmentIDs

func (_u *RoadmapItemUpdate) RemoveAssignmentIDs(ids ...string) *RoadmapItemUpdate

RemoveAssignmentIDs removes the "assignments" edge to Assignment entities by IDs.

func (*RoadmapItemUpdate) RemoveAssignments

func (_u *RoadmapItemUpdate) RemoveAssignments(v ...*Assignment) *RoadmapItemUpdate

RemoveAssignments removes "assignments" edges to Assignment entities.

func (*RoadmapItemUpdate) RemoveEvidence

func (_u *RoadmapItemUpdate) RemoveEvidence(v ...*DeliveryEvidence) *RoadmapItemUpdate

RemoveEvidence removes "evidence" edges to DeliveryEvidence entities.

func (*RoadmapItemUpdate) RemoveEvidenceIDs

func (_u *RoadmapItemUpdate) RemoveEvidenceIDs(ids ...string) *RoadmapItemUpdate

RemoveEvidenceIDs removes the "evidence" edge to DeliveryEvidence entities by IDs.

func (*RoadmapItemUpdate) Save

func (_u *RoadmapItemUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*RoadmapItemUpdate) SaveX

func (_u *RoadmapItemUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*RoadmapItemUpdate) SetAcceptanceCriteria

func (_u *RoadmapItemUpdate) SetAcceptanceCriteria(v []string) *RoadmapItemUpdate

SetAcceptanceCriteria sets the "acceptance_criteria" field.

func (*RoadmapItemUpdate) SetCompletedAt

func (_u *RoadmapItemUpdate) SetCompletedAt(v time.Time) *RoadmapItemUpdate

SetCompletedAt sets the "completed_at" field.

func (*RoadmapItemUpdate) SetCreatedAt

func (_u *RoadmapItemUpdate) SetCreatedAt(v time.Time) *RoadmapItemUpdate

SetCreatedAt sets the "created_at" field.

func (*RoadmapItemUpdate) SetDescription

func (_u *RoadmapItemUpdate) SetDescription(v string) *RoadmapItemUpdate

SetDescription sets the "description" field.

func (*RoadmapItemUpdate) SetInitiative

func (_u *RoadmapItemUpdate) SetInitiative(v *Initiative) *RoadmapItemUpdate

SetInitiative sets the "initiative" edge to the Initiative entity.

func (*RoadmapItemUpdate) SetInitiativeID

func (_u *RoadmapItemUpdate) SetInitiativeID(id string) *RoadmapItemUpdate

SetInitiativeID sets the "initiative" edge to the Initiative entity by ID.

func (*RoadmapItemUpdate) SetItemType

func (_u *RoadmapItemUpdate) SetItemType(v string) *RoadmapItemUpdate

SetItemType sets the "item_type" field.

func (*RoadmapItemUpdate) SetNillableCompletedAt

func (_u *RoadmapItemUpdate) SetNillableCompletedAt(v *time.Time) *RoadmapItemUpdate

SetNillableCompletedAt sets the "completed_at" field if the given value is not nil.

func (*RoadmapItemUpdate) SetNillableCreatedAt

func (_u *RoadmapItemUpdate) SetNillableCreatedAt(v *time.Time) *RoadmapItemUpdate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*RoadmapItemUpdate) SetNillableDescription

func (_u *RoadmapItemUpdate) SetNillableDescription(v *string) *RoadmapItemUpdate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*RoadmapItemUpdate) SetNillableInitiativeID

func (_u *RoadmapItemUpdate) SetNillableInitiativeID(id *string) *RoadmapItemUpdate

SetNillableInitiativeID sets the "initiative" edge to the Initiative entity by ID if the given value is not nil.

func (*RoadmapItemUpdate) SetNillableItemType

func (_u *RoadmapItemUpdate) SetNillableItemType(v *string) *RoadmapItemUpdate

SetNillableItemType sets the "item_type" field if the given value is not nil.

func (*RoadmapItemUpdate) SetNillablePhaseID

func (_u *RoadmapItemUpdate) SetNillablePhaseID(id *string) *RoadmapItemUpdate

SetNillablePhaseID sets the "phase" edge to the Phase entity by ID if the given value is not nil.

func (*RoadmapItemUpdate) SetNillablePriority

func (_u *RoadmapItemUpdate) SetNillablePriority(v *string) *RoadmapItemUpdate

SetNillablePriority sets the "priority" field if the given value is not nil.

func (*RoadmapItemUpdate) SetNillableRequired

func (_u *RoadmapItemUpdate) SetNillableRequired(v *bool) *RoadmapItemUpdate

SetNillableRequired sets the "required" field if the given value is not nil.

func (*RoadmapItemUpdate) SetNillableSequenceNumber

func (_u *RoadmapItemUpdate) SetNillableSequenceNumber(v *int) *RoadmapItemUpdate

SetNillableSequenceNumber sets the "sequence_number" field if the given value is not nil.

func (*RoadmapItemUpdate) SetNillableStatus

func (_u *RoadmapItemUpdate) SetNillableStatus(v *string) *RoadmapItemUpdate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*RoadmapItemUpdate) SetNillableTitle

func (_u *RoadmapItemUpdate) SetNillableTitle(v *string) *RoadmapItemUpdate

SetNillableTitle sets the "title" field if the given value is not nil.

func (*RoadmapItemUpdate) SetNillableUpdatedAt

func (_u *RoadmapItemUpdate) SetNillableUpdatedAt(v *time.Time) *RoadmapItemUpdate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*RoadmapItemUpdate) SetPhase

func (_u *RoadmapItemUpdate) SetPhase(v *Phase) *RoadmapItemUpdate

SetPhase sets the "phase" edge to the Phase entity.

func (*RoadmapItemUpdate) SetPhaseID

func (_u *RoadmapItemUpdate) SetPhaseID(id string) *RoadmapItemUpdate

SetPhaseID sets the "phase" edge to the Phase entity by ID.

func (*RoadmapItemUpdate) SetPriority

func (_u *RoadmapItemUpdate) SetPriority(v string) *RoadmapItemUpdate

SetPriority sets the "priority" field.

func (*RoadmapItemUpdate) SetRepository

func (_u *RoadmapItemUpdate) SetRepository(v *Repository) *RoadmapItemUpdate

SetRepository sets the "repository" edge to the Repository entity.

func (*RoadmapItemUpdate) SetRepositoryID

func (_u *RoadmapItemUpdate) SetRepositoryID(id string) *RoadmapItemUpdate

SetRepositoryID sets the "repository" edge to the Repository entity by ID.

func (*RoadmapItemUpdate) SetRequired

func (_u *RoadmapItemUpdate) SetRequired(v bool) *RoadmapItemUpdate

SetRequired sets the "required" field.

func (*RoadmapItemUpdate) SetSequenceNumber

func (_u *RoadmapItemUpdate) SetSequenceNumber(v int) *RoadmapItemUpdate

SetSequenceNumber sets the "sequence_number" field.

func (*RoadmapItemUpdate) SetStatus

func (_u *RoadmapItemUpdate) SetStatus(v string) *RoadmapItemUpdate

SetStatus sets the "status" field.

func (*RoadmapItemUpdate) SetTitle

func (_u *RoadmapItemUpdate) SetTitle(v string) *RoadmapItemUpdate

SetTitle sets the "title" field.

func (*RoadmapItemUpdate) SetUpdatedAt

func (_u *RoadmapItemUpdate) SetUpdatedAt(v time.Time) *RoadmapItemUpdate

SetUpdatedAt sets the "updated_at" field.

func (*RoadmapItemUpdate) Where

Where appends a list predicates to the RoadmapItemUpdate builder.

type RoadmapItemUpdateOne

type RoadmapItemUpdateOne struct {
	// contains filtered or unexported fields
}

RoadmapItemUpdateOne is the builder for updating a single RoadmapItem entity.

func (*RoadmapItemUpdateOne) AddAssignmentIDs

func (_u *RoadmapItemUpdateOne) AddAssignmentIDs(ids ...string) *RoadmapItemUpdateOne

AddAssignmentIDs adds the "assignments" edge to the Assignment entity by IDs.

func (*RoadmapItemUpdateOne) AddAssignments

func (_u *RoadmapItemUpdateOne) AddAssignments(v ...*Assignment) *RoadmapItemUpdateOne

AddAssignments adds the "assignments" edges to the Assignment entity.

func (*RoadmapItemUpdateOne) AddEvidence

AddEvidence adds the "evidence" edges to the DeliveryEvidence entity.

func (*RoadmapItemUpdateOne) AddEvidenceIDs

func (_u *RoadmapItemUpdateOne) AddEvidenceIDs(ids ...string) *RoadmapItemUpdateOne

AddEvidenceIDs adds the "evidence" edge to the DeliveryEvidence entity by IDs.

func (*RoadmapItemUpdateOne) AddSequenceNumber

func (_u *RoadmapItemUpdateOne) AddSequenceNumber(v int) *RoadmapItemUpdateOne

AddSequenceNumber adds value to the "sequence_number" field.

func (*RoadmapItemUpdateOne) AppendAcceptanceCriteria

func (_u *RoadmapItemUpdateOne) AppendAcceptanceCriteria(v []string) *RoadmapItemUpdateOne

AppendAcceptanceCriteria appends value to the "acceptance_criteria" field.

func (*RoadmapItemUpdateOne) ClearAcceptanceCriteria

func (_u *RoadmapItemUpdateOne) ClearAcceptanceCriteria() *RoadmapItemUpdateOne

ClearAcceptanceCriteria clears the value of the "acceptance_criteria" field.

func (*RoadmapItemUpdateOne) ClearAssignments

func (_u *RoadmapItemUpdateOne) ClearAssignments() *RoadmapItemUpdateOne

ClearAssignments clears all "assignments" edges to the Assignment entity.

func (*RoadmapItemUpdateOne) ClearCompletedAt

func (_u *RoadmapItemUpdateOne) ClearCompletedAt() *RoadmapItemUpdateOne

ClearCompletedAt clears the value of the "completed_at" field.

func (*RoadmapItemUpdateOne) ClearDescription

func (_u *RoadmapItemUpdateOne) ClearDescription() *RoadmapItemUpdateOne

ClearDescription clears the value of the "description" field.

func (*RoadmapItemUpdateOne) ClearEvidence

func (_u *RoadmapItemUpdateOne) ClearEvidence() *RoadmapItemUpdateOne

ClearEvidence clears all "evidence" edges to the DeliveryEvidence entity.

func (*RoadmapItemUpdateOne) ClearInitiative

func (_u *RoadmapItemUpdateOne) ClearInitiative() *RoadmapItemUpdateOne

ClearInitiative clears the "initiative" edge to the Initiative entity.

func (*RoadmapItemUpdateOne) ClearPhase

func (_u *RoadmapItemUpdateOne) ClearPhase() *RoadmapItemUpdateOne

ClearPhase clears the "phase" edge to the Phase entity.

func (*RoadmapItemUpdateOne) ClearPriority

func (_u *RoadmapItemUpdateOne) ClearPriority() *RoadmapItemUpdateOne

ClearPriority clears the value of the "priority" field.

func (*RoadmapItemUpdateOne) ClearRepository

func (_u *RoadmapItemUpdateOne) ClearRepository() *RoadmapItemUpdateOne

ClearRepository clears the "repository" edge to the Repository entity.

func (*RoadmapItemUpdateOne) ClearSequenceNumber

func (_u *RoadmapItemUpdateOne) ClearSequenceNumber() *RoadmapItemUpdateOne

ClearSequenceNumber clears the value of the "sequence_number" field.

func (*RoadmapItemUpdateOne) Exec

func (_u *RoadmapItemUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*RoadmapItemUpdateOne) ExecX

func (_u *RoadmapItemUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RoadmapItemUpdateOne) Mutation

func (_u *RoadmapItemUpdateOne) Mutation() *RoadmapItemMutation

Mutation returns the RoadmapItemMutation object of the builder.

func (*RoadmapItemUpdateOne) RemoveAssignmentIDs

func (_u *RoadmapItemUpdateOne) RemoveAssignmentIDs(ids ...string) *RoadmapItemUpdateOne

RemoveAssignmentIDs removes the "assignments" edge to Assignment entities by IDs.

func (*RoadmapItemUpdateOne) RemoveAssignments

func (_u *RoadmapItemUpdateOne) RemoveAssignments(v ...*Assignment) *RoadmapItemUpdateOne

RemoveAssignments removes "assignments" edges to Assignment entities.

func (*RoadmapItemUpdateOne) RemoveEvidence

func (_u *RoadmapItemUpdateOne) RemoveEvidence(v ...*DeliveryEvidence) *RoadmapItemUpdateOne

RemoveEvidence removes "evidence" edges to DeliveryEvidence entities.

func (*RoadmapItemUpdateOne) RemoveEvidenceIDs

func (_u *RoadmapItemUpdateOne) RemoveEvidenceIDs(ids ...string) *RoadmapItemUpdateOne

RemoveEvidenceIDs removes the "evidence" edge to DeliveryEvidence entities by IDs.

func (*RoadmapItemUpdateOne) Save

Save executes the query and returns the updated RoadmapItem entity.

func (*RoadmapItemUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*RoadmapItemUpdateOne) Select

func (_u *RoadmapItemUpdateOne) Select(field string, fields ...string) *RoadmapItemUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*RoadmapItemUpdateOne) SetAcceptanceCriteria

func (_u *RoadmapItemUpdateOne) SetAcceptanceCriteria(v []string) *RoadmapItemUpdateOne

SetAcceptanceCriteria sets the "acceptance_criteria" field.

func (*RoadmapItemUpdateOne) SetCompletedAt

func (_u *RoadmapItemUpdateOne) SetCompletedAt(v time.Time) *RoadmapItemUpdateOne

SetCompletedAt sets the "completed_at" field.

func (*RoadmapItemUpdateOne) SetCreatedAt

func (_u *RoadmapItemUpdateOne) SetCreatedAt(v time.Time) *RoadmapItemUpdateOne

SetCreatedAt sets the "created_at" field.

func (*RoadmapItemUpdateOne) SetDescription

func (_u *RoadmapItemUpdateOne) SetDescription(v string) *RoadmapItemUpdateOne

SetDescription sets the "description" field.

func (*RoadmapItemUpdateOne) SetInitiative

func (_u *RoadmapItemUpdateOne) SetInitiative(v *Initiative) *RoadmapItemUpdateOne

SetInitiative sets the "initiative" edge to the Initiative entity.

func (*RoadmapItemUpdateOne) SetInitiativeID

func (_u *RoadmapItemUpdateOne) SetInitiativeID(id string) *RoadmapItemUpdateOne

SetInitiativeID sets the "initiative" edge to the Initiative entity by ID.

func (*RoadmapItemUpdateOne) SetItemType

func (_u *RoadmapItemUpdateOne) SetItemType(v string) *RoadmapItemUpdateOne

SetItemType sets the "item_type" field.

func (*RoadmapItemUpdateOne) SetNillableCompletedAt

func (_u *RoadmapItemUpdateOne) SetNillableCompletedAt(v *time.Time) *RoadmapItemUpdateOne

SetNillableCompletedAt sets the "completed_at" field if the given value is not nil.

func (*RoadmapItemUpdateOne) SetNillableCreatedAt

func (_u *RoadmapItemUpdateOne) SetNillableCreatedAt(v *time.Time) *RoadmapItemUpdateOne

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*RoadmapItemUpdateOne) SetNillableDescription

func (_u *RoadmapItemUpdateOne) SetNillableDescription(v *string) *RoadmapItemUpdateOne

SetNillableDescription sets the "description" field if the given value is not nil.

func (*RoadmapItemUpdateOne) SetNillableInitiativeID

func (_u *RoadmapItemUpdateOne) SetNillableInitiativeID(id *string) *RoadmapItemUpdateOne

SetNillableInitiativeID sets the "initiative" edge to the Initiative entity by ID if the given value is not nil.

func (*RoadmapItemUpdateOne) SetNillableItemType

func (_u *RoadmapItemUpdateOne) SetNillableItemType(v *string) *RoadmapItemUpdateOne

SetNillableItemType sets the "item_type" field if the given value is not nil.

func (*RoadmapItemUpdateOne) SetNillablePhaseID

func (_u *RoadmapItemUpdateOne) SetNillablePhaseID(id *string) *RoadmapItemUpdateOne

SetNillablePhaseID sets the "phase" edge to the Phase entity by ID if the given value is not nil.

func (*RoadmapItemUpdateOne) SetNillablePriority

func (_u *RoadmapItemUpdateOne) SetNillablePriority(v *string) *RoadmapItemUpdateOne

SetNillablePriority sets the "priority" field if the given value is not nil.

func (*RoadmapItemUpdateOne) SetNillableRequired

func (_u *RoadmapItemUpdateOne) SetNillableRequired(v *bool) *RoadmapItemUpdateOne

SetNillableRequired sets the "required" field if the given value is not nil.

func (*RoadmapItemUpdateOne) SetNillableSequenceNumber

func (_u *RoadmapItemUpdateOne) SetNillableSequenceNumber(v *int) *RoadmapItemUpdateOne

SetNillableSequenceNumber sets the "sequence_number" field if the given value is not nil.

func (*RoadmapItemUpdateOne) SetNillableStatus

func (_u *RoadmapItemUpdateOne) SetNillableStatus(v *string) *RoadmapItemUpdateOne

SetNillableStatus sets the "status" field if the given value is not nil.

func (*RoadmapItemUpdateOne) SetNillableTitle

func (_u *RoadmapItemUpdateOne) SetNillableTitle(v *string) *RoadmapItemUpdateOne

SetNillableTitle sets the "title" field if the given value is not nil.

func (*RoadmapItemUpdateOne) SetNillableUpdatedAt

func (_u *RoadmapItemUpdateOne) SetNillableUpdatedAt(v *time.Time) *RoadmapItemUpdateOne

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*RoadmapItemUpdateOne) SetPhase

SetPhase sets the "phase" edge to the Phase entity.

func (*RoadmapItemUpdateOne) SetPhaseID

func (_u *RoadmapItemUpdateOne) SetPhaseID(id string) *RoadmapItemUpdateOne

SetPhaseID sets the "phase" edge to the Phase entity by ID.

func (*RoadmapItemUpdateOne) SetPriority

func (_u *RoadmapItemUpdateOne) SetPriority(v string) *RoadmapItemUpdateOne

SetPriority sets the "priority" field.

func (*RoadmapItemUpdateOne) SetRepository

func (_u *RoadmapItemUpdateOne) SetRepository(v *Repository) *RoadmapItemUpdateOne

SetRepository sets the "repository" edge to the Repository entity.

func (*RoadmapItemUpdateOne) SetRepositoryID

func (_u *RoadmapItemUpdateOne) SetRepositoryID(id string) *RoadmapItemUpdateOne

SetRepositoryID sets the "repository" edge to the Repository entity by ID.

func (*RoadmapItemUpdateOne) SetRequired

func (_u *RoadmapItemUpdateOne) SetRequired(v bool) *RoadmapItemUpdateOne

SetRequired sets the "required" field.

func (*RoadmapItemUpdateOne) SetSequenceNumber

func (_u *RoadmapItemUpdateOne) SetSequenceNumber(v int) *RoadmapItemUpdateOne

SetSequenceNumber sets the "sequence_number" field.

func (*RoadmapItemUpdateOne) SetStatus

SetStatus sets the "status" field.

func (*RoadmapItemUpdateOne) SetTitle

SetTitle sets the "title" field.

func (*RoadmapItemUpdateOne) SetUpdatedAt

func (_u *RoadmapItemUpdateOne) SetUpdatedAt(v time.Time) *RoadmapItemUpdateOne

SetUpdatedAt sets the "updated_at" field.

func (*RoadmapItemUpdateOne) Where

Where appends a list predicates to the RoadmapItemUpdate builder.

type RoadmapItems

type RoadmapItems []*RoadmapItem

RoadmapItems is a parsable slice of RoadmapItem.

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 SpecWorkflow

type SpecWorkflow struct {

	// ID of the ent.
	ID string `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"`
	// SpecsRequired holds the value of the "specs_required" field.
	SpecsRequired []string `json:"specs_required,omitempty"`
	// SpecsOptional holds the value of the "specs_optional" field.
	SpecsOptional []string `json:"specs_optional,omitempty"`
	// InitTypes holds the value of the "init_types" field.
	InitTypes []string `json:"init_types,omitempty"`
	// Edges holds the relations/edges for other nodes in the graph.
	// The values are being populated by the SpecWorkflowQuery when eager-loading is set.
	Edges SpecWorkflowEdges `json:"edges"`
	// contains filtered or unexported fields
}

SpecWorkflow is the model entity for the SpecWorkflow schema.

func (*SpecWorkflow) QueryInitiatives

func (_m *SpecWorkflow) QueryInitiatives() *InitiativeQuery

QueryInitiatives queries the "initiatives" edge of the SpecWorkflow entity.

func (*SpecWorkflow) QueryRubrics

func (_m *SpecWorkflow) QueryRubrics() *JudgeRubricQuery

QueryRubrics queries the "rubrics" edge of the SpecWorkflow entity.

func (*SpecWorkflow) String

func (_m *SpecWorkflow) String() string

String implements the fmt.Stringer.

func (*SpecWorkflow) Unwrap

func (_m *SpecWorkflow) Unwrap() *SpecWorkflow

Unwrap unwraps the SpecWorkflow 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 (*SpecWorkflow) Update

func (_m *SpecWorkflow) Update() *SpecWorkflowUpdateOne

Update returns a builder for updating this SpecWorkflow. Note that you need to call SpecWorkflow.Unwrap() before calling this method if this SpecWorkflow was returned from a transaction, and the transaction was committed or rolled back.

func (*SpecWorkflow) Value

func (_m *SpecWorkflow) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the SpecWorkflow. This includes values selected through modifiers, order, etc.

type SpecWorkflowClient

type SpecWorkflowClient struct {
	// contains filtered or unexported fields
}

SpecWorkflowClient is a client for the SpecWorkflow schema.

func NewSpecWorkflowClient

func NewSpecWorkflowClient(c config) *SpecWorkflowClient

NewSpecWorkflowClient returns a client for the SpecWorkflow from the given config.

func (*SpecWorkflowClient) Create

Create returns a builder for creating a SpecWorkflow entity.

func (*SpecWorkflowClient) CreateBulk

func (c *SpecWorkflowClient) CreateBulk(builders ...*SpecWorkflowCreate) *SpecWorkflowCreateBulk

CreateBulk returns a builder for creating a bulk of SpecWorkflow entities.

func (*SpecWorkflowClient) Delete

Delete returns a delete builder for SpecWorkflow.

func (*SpecWorkflowClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*SpecWorkflowClient) DeleteOneID

func (c *SpecWorkflowClient) DeleteOneID(id string) *SpecWorkflowDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*SpecWorkflowClient) Get

Get returns a SpecWorkflow entity by its id.

func (*SpecWorkflowClient) GetX

GetX is like Get, but panics if an error occurs.

func (*SpecWorkflowClient) Hooks

func (c *SpecWorkflowClient) Hooks() []Hook

Hooks returns the client hooks.

func (*SpecWorkflowClient) Intercept

func (c *SpecWorkflowClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `specworkflow.Intercept(f(g(h())))`.

func (*SpecWorkflowClient) Interceptors

func (c *SpecWorkflowClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*SpecWorkflowClient) MapCreateBulk

func (c *SpecWorkflowClient) MapCreateBulk(slice any, setFunc func(*SpecWorkflowCreate, int)) *SpecWorkflowCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*SpecWorkflowClient) Query

Query returns a query builder for SpecWorkflow.

func (*SpecWorkflowClient) QueryInitiatives

func (c *SpecWorkflowClient) QueryInitiatives(_m *SpecWorkflow) *InitiativeQuery

QueryInitiatives queries the initiatives edge of a SpecWorkflow.

func (*SpecWorkflowClient) QueryRubrics

func (c *SpecWorkflowClient) QueryRubrics(_m *SpecWorkflow) *JudgeRubricQuery

QueryRubrics queries the rubrics edge of a SpecWorkflow.

func (*SpecWorkflowClient) Update

Update returns an update builder for SpecWorkflow.

func (*SpecWorkflowClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*SpecWorkflowClient) UpdateOneID

func (c *SpecWorkflowClient) UpdateOneID(id string) *SpecWorkflowUpdateOne

UpdateOneID returns an update builder for the given id.

func (*SpecWorkflowClient) Use

func (c *SpecWorkflowClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `specworkflow.Hooks(f(g(h())))`.

type SpecWorkflowCreate

type SpecWorkflowCreate struct {
	// contains filtered or unexported fields
}

SpecWorkflowCreate is the builder for creating a SpecWorkflow entity.

func (*SpecWorkflowCreate) AddInitiativeIDs

func (_c *SpecWorkflowCreate) AddInitiativeIDs(ids ...string) *SpecWorkflowCreate

AddInitiativeIDs adds the "initiatives" edge to the Initiative entity by IDs.

func (*SpecWorkflowCreate) AddInitiatives

func (_c *SpecWorkflowCreate) AddInitiatives(v ...*Initiative) *SpecWorkflowCreate

AddInitiatives adds the "initiatives" edges to the Initiative entity.

func (*SpecWorkflowCreate) AddRubricIDs

func (_c *SpecWorkflowCreate) AddRubricIDs(ids ...string) *SpecWorkflowCreate

AddRubricIDs adds the "rubrics" edge to the JudgeRubric entity by IDs.

func (*SpecWorkflowCreate) AddRubrics

func (_c *SpecWorkflowCreate) AddRubrics(v ...*JudgeRubric) *SpecWorkflowCreate

AddRubrics adds the "rubrics" edges to the JudgeRubric entity.

func (*SpecWorkflowCreate) Exec

func (_c *SpecWorkflowCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*SpecWorkflowCreate) ExecX

func (_c *SpecWorkflowCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SpecWorkflowCreate) Mutation

func (_c *SpecWorkflowCreate) Mutation() *SpecWorkflowMutation

Mutation returns the SpecWorkflowMutation object of the builder.

func (*SpecWorkflowCreate) Save

Save creates the SpecWorkflow in the database.

func (*SpecWorkflowCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*SpecWorkflowCreate) SetDescription

func (_c *SpecWorkflowCreate) SetDescription(v string) *SpecWorkflowCreate

SetDescription sets the "description" field.

func (*SpecWorkflowCreate) SetID

SetID sets the "id" field.

func (*SpecWorkflowCreate) SetInitTypes

func (_c *SpecWorkflowCreate) SetInitTypes(v []string) *SpecWorkflowCreate

SetInitTypes sets the "init_types" field.

func (*SpecWorkflowCreate) SetName

SetName sets the "name" field.

func (*SpecWorkflowCreate) SetNillableDescription

func (_c *SpecWorkflowCreate) SetNillableDescription(v *string) *SpecWorkflowCreate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*SpecWorkflowCreate) SetSpecsOptional

func (_c *SpecWorkflowCreate) SetSpecsOptional(v []string) *SpecWorkflowCreate

SetSpecsOptional sets the "specs_optional" field.

func (*SpecWorkflowCreate) SetSpecsRequired

func (_c *SpecWorkflowCreate) SetSpecsRequired(v []string) *SpecWorkflowCreate

SetSpecsRequired sets the "specs_required" field.

type SpecWorkflowCreateBulk

type SpecWorkflowCreateBulk struct {
	// contains filtered or unexported fields
}

SpecWorkflowCreateBulk is the builder for creating many SpecWorkflow entities in bulk.

func (*SpecWorkflowCreateBulk) Exec

Exec executes the query.

func (*SpecWorkflowCreateBulk) ExecX

func (_c *SpecWorkflowCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SpecWorkflowCreateBulk) Save

Save creates the SpecWorkflow entities in the database.

func (*SpecWorkflowCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type SpecWorkflowDelete

type SpecWorkflowDelete struct {
	// contains filtered or unexported fields
}

SpecWorkflowDelete is the builder for deleting a SpecWorkflow entity.

func (*SpecWorkflowDelete) Exec

func (_d *SpecWorkflowDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*SpecWorkflowDelete) ExecX

func (_d *SpecWorkflowDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*SpecWorkflowDelete) Where

Where appends a list predicates to the SpecWorkflowDelete builder.

type SpecWorkflowDeleteOne

type SpecWorkflowDeleteOne struct {
	// contains filtered or unexported fields
}

SpecWorkflowDeleteOne is the builder for deleting a single SpecWorkflow entity.

func (*SpecWorkflowDeleteOne) Exec

Exec executes the deletion query.

func (*SpecWorkflowDeleteOne) ExecX

func (_d *SpecWorkflowDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SpecWorkflowDeleteOne) Where

Where appends a list predicates to the SpecWorkflowDelete builder.

type SpecWorkflowEdges

type SpecWorkflowEdges struct {
	// Initiatives holds the value of the initiatives edge.
	Initiatives []*Initiative `json:"initiatives,omitempty"`
	// Rubrics holds the value of the rubrics edge.
	Rubrics []*JudgeRubric `json:"rubrics,omitempty"`
	// contains filtered or unexported fields
}

SpecWorkflowEdges holds the relations/edges for other nodes in the graph.

func (SpecWorkflowEdges) InitiativesOrErr

func (e SpecWorkflowEdges) InitiativesOrErr() ([]*Initiative, error)

InitiativesOrErr returns the Initiatives value or an error if the edge was not loaded in eager-loading.

func (SpecWorkflowEdges) RubricsOrErr

func (e SpecWorkflowEdges) RubricsOrErr() ([]*JudgeRubric, error)

RubricsOrErr returns the Rubrics value or an error if the edge was not loaded in eager-loading.

type SpecWorkflowGroupBy

type SpecWorkflowGroupBy struct {
	// contains filtered or unexported fields
}

SpecWorkflowGroupBy is the group-by builder for SpecWorkflow entities.

func (*SpecWorkflowGroupBy) Aggregate

func (_g *SpecWorkflowGroupBy) Aggregate(fns ...AggregateFunc) *SpecWorkflowGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*SpecWorkflowGroupBy) Bool

func (s *SpecWorkflowGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowGroupBy) BoolX

func (s *SpecWorkflowGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*SpecWorkflowGroupBy) Bools

func (s *SpecWorkflowGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowGroupBy) BoolsX

func (s *SpecWorkflowGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*SpecWorkflowGroupBy) Float64

func (s *SpecWorkflowGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowGroupBy) Float64X

func (s *SpecWorkflowGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*SpecWorkflowGroupBy) Float64s

func (s *SpecWorkflowGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowGroupBy) Float64sX

func (s *SpecWorkflowGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*SpecWorkflowGroupBy) Int

func (s *SpecWorkflowGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowGroupBy) IntX

func (s *SpecWorkflowGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*SpecWorkflowGroupBy) Ints

func (s *SpecWorkflowGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowGroupBy) IntsX

func (s *SpecWorkflowGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*SpecWorkflowGroupBy) Scan

func (_g *SpecWorkflowGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*SpecWorkflowGroupBy) ScanX

func (s *SpecWorkflowGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*SpecWorkflowGroupBy) String

func (s *SpecWorkflowGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowGroupBy) StringX

func (s *SpecWorkflowGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*SpecWorkflowGroupBy) Strings

func (s *SpecWorkflowGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowGroupBy) StringsX

func (s *SpecWorkflowGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type SpecWorkflowMutation

type SpecWorkflowMutation struct {
	// contains filtered or unexported fields
}

SpecWorkflowMutation represents an operation that mutates the SpecWorkflow nodes in the graph.

func (*SpecWorkflowMutation) AddField

func (m *SpecWorkflowMutation) 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 (*SpecWorkflowMutation) AddInitiativeIDs

func (m *SpecWorkflowMutation) AddInitiativeIDs(ids ...string)

AddInitiativeIDs adds the "initiatives" edge to the Initiative entity by ids.

func (*SpecWorkflowMutation) AddRubricIDs

func (m *SpecWorkflowMutation) AddRubricIDs(ids ...string)

AddRubricIDs adds the "rubrics" edge to the JudgeRubric entity by ids.

func (*SpecWorkflowMutation) AddedEdges

func (m *SpecWorkflowMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*SpecWorkflowMutation) AddedField

func (m *SpecWorkflowMutation) 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 (*SpecWorkflowMutation) AddedFields

func (m *SpecWorkflowMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*SpecWorkflowMutation) AddedIDs

func (m *SpecWorkflowMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*SpecWorkflowMutation) AppendInitTypes

func (m *SpecWorkflowMutation) AppendInitTypes(s []string)

AppendInitTypes adds s to the "init_types" field.

func (*SpecWorkflowMutation) AppendSpecsOptional

func (m *SpecWorkflowMutation) AppendSpecsOptional(s []string)

AppendSpecsOptional adds s to the "specs_optional" field.

func (*SpecWorkflowMutation) AppendSpecsRequired

func (m *SpecWorkflowMutation) AppendSpecsRequired(s []string)

AppendSpecsRequired adds s to the "specs_required" field.

func (*SpecWorkflowMutation) AppendedInitTypes

func (m *SpecWorkflowMutation) AppendedInitTypes() ([]string, bool)

AppendedInitTypes returns the list of values that were appended to the "init_types" field in this mutation.

func (*SpecWorkflowMutation) AppendedSpecsOptional

func (m *SpecWorkflowMutation) AppendedSpecsOptional() ([]string, bool)

AppendedSpecsOptional returns the list of values that were appended to the "specs_optional" field in this mutation.

func (*SpecWorkflowMutation) AppendedSpecsRequired

func (m *SpecWorkflowMutation) AppendedSpecsRequired() ([]string, bool)

AppendedSpecsRequired returns the list of values that were appended to the "specs_required" field in this mutation.

func (*SpecWorkflowMutation) ClearDescription

func (m *SpecWorkflowMutation) ClearDescription()

ClearDescription clears the value of the "description" field.

func (*SpecWorkflowMutation) ClearEdge

func (m *SpecWorkflowMutation) 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 (*SpecWorkflowMutation) ClearField

func (m *SpecWorkflowMutation) 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 (*SpecWorkflowMutation) ClearInitTypes

func (m *SpecWorkflowMutation) ClearInitTypes()

ClearInitTypes clears the value of the "init_types" field.

func (*SpecWorkflowMutation) ClearInitiatives

func (m *SpecWorkflowMutation) ClearInitiatives()

ClearInitiatives clears the "initiatives" edge to the Initiative entity.

func (*SpecWorkflowMutation) ClearRubrics

func (m *SpecWorkflowMutation) ClearRubrics()

ClearRubrics clears the "rubrics" edge to the JudgeRubric entity.

func (*SpecWorkflowMutation) ClearSpecsOptional

func (m *SpecWorkflowMutation) ClearSpecsOptional()

ClearSpecsOptional clears the value of the "specs_optional" field.

func (*SpecWorkflowMutation) ClearSpecsRequired

func (m *SpecWorkflowMutation) ClearSpecsRequired()

ClearSpecsRequired clears the value of the "specs_required" field.

func (*SpecWorkflowMutation) ClearedEdges

func (m *SpecWorkflowMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*SpecWorkflowMutation) ClearedFields

func (m *SpecWorkflowMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (SpecWorkflowMutation) Client

func (m SpecWorkflowMutation) 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 (*SpecWorkflowMutation) Description

func (m *SpecWorkflowMutation) Description() (r string, exists bool)

Description returns the value of the "description" field in the mutation.

func (*SpecWorkflowMutation) DescriptionCleared

func (m *SpecWorkflowMutation) DescriptionCleared() bool

DescriptionCleared returns if the "description" field was cleared in this mutation.

func (*SpecWorkflowMutation) EdgeCleared

func (m *SpecWorkflowMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*SpecWorkflowMutation) Field

func (m *SpecWorkflowMutation) 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 (*SpecWorkflowMutation) FieldCleared

func (m *SpecWorkflowMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*SpecWorkflowMutation) Fields

func (m *SpecWorkflowMutation) 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 (*SpecWorkflowMutation) ID

func (m *SpecWorkflowMutation) ID() (id string, 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 (*SpecWorkflowMutation) IDs

func (m *SpecWorkflowMutation) IDs(ctx context.Context) ([]string, 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 (*SpecWorkflowMutation) InitTypes

func (m *SpecWorkflowMutation) InitTypes() (r []string, exists bool)

InitTypes returns the value of the "init_types" field in the mutation.

func (*SpecWorkflowMutation) InitTypesCleared

func (m *SpecWorkflowMutation) InitTypesCleared() bool

InitTypesCleared returns if the "init_types" field was cleared in this mutation.

func (*SpecWorkflowMutation) InitiativesCleared

func (m *SpecWorkflowMutation) InitiativesCleared() bool

InitiativesCleared reports if the "initiatives" edge to the Initiative entity was cleared.

func (*SpecWorkflowMutation) InitiativesIDs

func (m *SpecWorkflowMutation) InitiativesIDs() (ids []string)

InitiativesIDs returns the "initiatives" edge IDs in the mutation.

func (*SpecWorkflowMutation) Name

func (m *SpecWorkflowMutation) Name() (r string, exists bool)

Name returns the value of the "name" field in the mutation.

func (*SpecWorkflowMutation) OldDescription

func (m *SpecWorkflowMutation) OldDescription(ctx context.Context) (v string, err error)

OldDescription returns the old "description" field's value of the SpecWorkflow entity. If the SpecWorkflow 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 (*SpecWorkflowMutation) OldField

func (m *SpecWorkflowMutation) 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 (*SpecWorkflowMutation) OldInitTypes

func (m *SpecWorkflowMutation) OldInitTypes(ctx context.Context) (v []string, err error)

OldInitTypes returns the old "init_types" field's value of the SpecWorkflow entity. If the SpecWorkflow 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 (*SpecWorkflowMutation) OldName

func (m *SpecWorkflowMutation) OldName(ctx context.Context) (v string, err error)

OldName returns the old "name" field's value of the SpecWorkflow entity. If the SpecWorkflow 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 (*SpecWorkflowMutation) OldSpecsOptional

func (m *SpecWorkflowMutation) OldSpecsOptional(ctx context.Context) (v []string, err error)

OldSpecsOptional returns the old "specs_optional" field's value of the SpecWorkflow entity. If the SpecWorkflow 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 (*SpecWorkflowMutation) OldSpecsRequired

func (m *SpecWorkflowMutation) OldSpecsRequired(ctx context.Context) (v []string, err error)

OldSpecsRequired returns the old "specs_required" field's value of the SpecWorkflow entity. If the SpecWorkflow 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 (*SpecWorkflowMutation) Op

func (m *SpecWorkflowMutation) Op() Op

Op returns the operation name.

func (*SpecWorkflowMutation) RemoveInitiativeIDs

func (m *SpecWorkflowMutation) RemoveInitiativeIDs(ids ...string)

RemoveInitiativeIDs removes the "initiatives" edge to the Initiative entity by IDs.

func (*SpecWorkflowMutation) RemoveRubricIDs

func (m *SpecWorkflowMutation) RemoveRubricIDs(ids ...string)

RemoveRubricIDs removes the "rubrics" edge to the JudgeRubric entity by IDs.

func (*SpecWorkflowMutation) RemovedEdges

func (m *SpecWorkflowMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*SpecWorkflowMutation) RemovedIDs

func (m *SpecWorkflowMutation) 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 (*SpecWorkflowMutation) RemovedInitiativesIDs

func (m *SpecWorkflowMutation) RemovedInitiativesIDs() (ids []string)

RemovedInitiatives returns the removed IDs of the "initiatives" edge to the Initiative entity.

func (*SpecWorkflowMutation) RemovedRubricsIDs

func (m *SpecWorkflowMutation) RemovedRubricsIDs() (ids []string)

RemovedRubrics returns the removed IDs of the "rubrics" edge to the JudgeRubric entity.

func (*SpecWorkflowMutation) ResetDescription

func (m *SpecWorkflowMutation) ResetDescription()

ResetDescription resets all changes to the "description" field.

func (*SpecWorkflowMutation) ResetEdge

func (m *SpecWorkflowMutation) 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 (*SpecWorkflowMutation) ResetField

func (m *SpecWorkflowMutation) 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 (*SpecWorkflowMutation) ResetInitTypes

func (m *SpecWorkflowMutation) ResetInitTypes()

ResetInitTypes resets all changes to the "init_types" field.

func (*SpecWorkflowMutation) ResetInitiatives

func (m *SpecWorkflowMutation) ResetInitiatives()

ResetInitiatives resets all changes to the "initiatives" edge.

func (*SpecWorkflowMutation) ResetName

func (m *SpecWorkflowMutation) ResetName()

ResetName resets all changes to the "name" field.

func (*SpecWorkflowMutation) ResetRubrics

func (m *SpecWorkflowMutation) ResetRubrics()

ResetRubrics resets all changes to the "rubrics" edge.

func (*SpecWorkflowMutation) ResetSpecsOptional

func (m *SpecWorkflowMutation) ResetSpecsOptional()

ResetSpecsOptional resets all changes to the "specs_optional" field.

func (*SpecWorkflowMutation) ResetSpecsRequired

func (m *SpecWorkflowMutation) ResetSpecsRequired()

ResetSpecsRequired resets all changes to the "specs_required" field.

func (*SpecWorkflowMutation) RubricsCleared

func (m *SpecWorkflowMutation) RubricsCleared() bool

RubricsCleared reports if the "rubrics" edge to the JudgeRubric entity was cleared.

func (*SpecWorkflowMutation) RubricsIDs

func (m *SpecWorkflowMutation) RubricsIDs() (ids []string)

RubricsIDs returns the "rubrics" edge IDs in the mutation.

func (*SpecWorkflowMutation) SetDescription

func (m *SpecWorkflowMutation) SetDescription(s string)

SetDescription sets the "description" field.

func (*SpecWorkflowMutation) SetField

func (m *SpecWorkflowMutation) 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 (*SpecWorkflowMutation) SetID

func (m *SpecWorkflowMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of SpecWorkflow entities.

func (*SpecWorkflowMutation) SetInitTypes

func (m *SpecWorkflowMutation) SetInitTypes(s []string)

SetInitTypes sets the "init_types" field.

func (*SpecWorkflowMutation) SetName

func (m *SpecWorkflowMutation) SetName(s string)

SetName sets the "name" field.

func (*SpecWorkflowMutation) SetOp

func (m *SpecWorkflowMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*SpecWorkflowMutation) SetSpecsOptional

func (m *SpecWorkflowMutation) SetSpecsOptional(s []string)

SetSpecsOptional sets the "specs_optional" field.

func (*SpecWorkflowMutation) SetSpecsRequired

func (m *SpecWorkflowMutation) SetSpecsRequired(s []string)

SetSpecsRequired sets the "specs_required" field.

func (*SpecWorkflowMutation) SpecsOptional

func (m *SpecWorkflowMutation) SpecsOptional() (r []string, exists bool)

SpecsOptional returns the value of the "specs_optional" field in the mutation.

func (*SpecWorkflowMutation) SpecsOptionalCleared

func (m *SpecWorkflowMutation) SpecsOptionalCleared() bool

SpecsOptionalCleared returns if the "specs_optional" field was cleared in this mutation.

func (*SpecWorkflowMutation) SpecsRequired

func (m *SpecWorkflowMutation) SpecsRequired() (r []string, exists bool)

SpecsRequired returns the value of the "specs_required" field in the mutation.

func (*SpecWorkflowMutation) SpecsRequiredCleared

func (m *SpecWorkflowMutation) SpecsRequiredCleared() bool

SpecsRequiredCleared returns if the "specs_required" field was cleared in this mutation.

func (SpecWorkflowMutation) Tx

func (m SpecWorkflowMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*SpecWorkflowMutation) Type

func (m *SpecWorkflowMutation) Type() string

Type returns the node type of this mutation (SpecWorkflow).

func (*SpecWorkflowMutation) Where

Where appends a list predicates to the SpecWorkflowMutation builder.

func (*SpecWorkflowMutation) WhereP

func (m *SpecWorkflowMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the SpecWorkflowMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type SpecWorkflowQuery

type SpecWorkflowQuery struct {
	// contains filtered or unexported fields
}

SpecWorkflowQuery is the builder for querying SpecWorkflow entities.

func (*SpecWorkflowQuery) Aggregate

func (_q *SpecWorkflowQuery) Aggregate(fns ...AggregateFunc) *SpecWorkflowSelect

Aggregate returns a SpecWorkflowSelect configured with the given aggregations.

func (*SpecWorkflowQuery) All

func (_q *SpecWorkflowQuery) All(ctx context.Context) ([]*SpecWorkflow, error)

All executes the query and returns a list of SpecWorkflows.

func (*SpecWorkflowQuery) AllX

func (_q *SpecWorkflowQuery) AllX(ctx context.Context) []*SpecWorkflow

AllX is like All, but panics if an error occurs.

func (*SpecWorkflowQuery) Clone

func (_q *SpecWorkflowQuery) Clone() *SpecWorkflowQuery

Clone returns a duplicate of the SpecWorkflowQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*SpecWorkflowQuery) Count

func (_q *SpecWorkflowQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*SpecWorkflowQuery) CountX

func (_q *SpecWorkflowQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*SpecWorkflowQuery) Exist

func (_q *SpecWorkflowQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*SpecWorkflowQuery) ExistX

func (_q *SpecWorkflowQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*SpecWorkflowQuery) First

func (_q *SpecWorkflowQuery) First(ctx context.Context) (*SpecWorkflow, error)

First returns the first SpecWorkflow entity from the query. Returns a *NotFoundError when no SpecWorkflow was found.

func (*SpecWorkflowQuery) FirstID

func (_q *SpecWorkflowQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first SpecWorkflow ID from the query. Returns a *NotFoundError when no SpecWorkflow ID was found.

func (*SpecWorkflowQuery) FirstIDX

func (_q *SpecWorkflowQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*SpecWorkflowQuery) FirstX

func (_q *SpecWorkflowQuery) FirstX(ctx context.Context) *SpecWorkflow

FirstX is like First, but panics if an error occurs.

func (*SpecWorkflowQuery) GroupBy

func (_q *SpecWorkflowQuery) GroupBy(field string, fields ...string) *SpecWorkflowGroupBy

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.SpecWorkflow.Query().
	GroupBy(specworkflow.FieldName).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*SpecWorkflowQuery) IDs

func (_q *SpecWorkflowQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of SpecWorkflow IDs.

func (*SpecWorkflowQuery) IDsX

func (_q *SpecWorkflowQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*SpecWorkflowQuery) Limit

func (_q *SpecWorkflowQuery) Limit(limit int) *SpecWorkflowQuery

Limit the number of records to be returned by this query.

func (*SpecWorkflowQuery) Offset

func (_q *SpecWorkflowQuery) Offset(offset int) *SpecWorkflowQuery

Offset to start from.

func (*SpecWorkflowQuery) Only

Only returns a single SpecWorkflow entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one SpecWorkflow entity is found. Returns a *NotFoundError when no SpecWorkflow entities are found.

func (*SpecWorkflowQuery) OnlyID

func (_q *SpecWorkflowQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only SpecWorkflow ID in the query. Returns a *NotSingularError when more than one SpecWorkflow ID is found. Returns a *NotFoundError when no entities are found.

func (*SpecWorkflowQuery) OnlyIDX

func (_q *SpecWorkflowQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*SpecWorkflowQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*SpecWorkflowQuery) Order

Order specifies how the records should be ordered.

func (*SpecWorkflowQuery) QueryInitiatives

func (_q *SpecWorkflowQuery) QueryInitiatives() *InitiativeQuery

QueryInitiatives chains the current query on the "initiatives" edge.

func (*SpecWorkflowQuery) QueryRubrics

func (_q *SpecWorkflowQuery) QueryRubrics() *JudgeRubricQuery

QueryRubrics chains the current query on the "rubrics" edge.

func (*SpecWorkflowQuery) Select

func (_q *SpecWorkflowQuery) Select(fields ...string) *SpecWorkflowSelect

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.SpecWorkflow.Query().
	Select(specworkflow.FieldName).
	Scan(ctx, &v)

func (*SpecWorkflowQuery) Unique

func (_q *SpecWorkflowQuery) Unique(unique bool) *SpecWorkflowQuery

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 (*SpecWorkflowQuery) Where

Where adds a new predicate for the SpecWorkflowQuery builder.

func (*SpecWorkflowQuery) WithInitiatives

func (_q *SpecWorkflowQuery) WithInitiatives(opts ...func(*InitiativeQuery)) *SpecWorkflowQuery

WithInitiatives tells the query-builder to eager-load the nodes that are connected to the "initiatives" edge. The optional arguments are used to configure the query builder of the edge.

func (*SpecWorkflowQuery) WithRubrics

func (_q *SpecWorkflowQuery) WithRubrics(opts ...func(*JudgeRubricQuery)) *SpecWorkflowQuery

WithRubrics tells the query-builder to eager-load the nodes that are connected to the "rubrics" edge. The optional arguments are used to configure the query builder of the edge.

type SpecWorkflowSelect

type SpecWorkflowSelect struct {
	*SpecWorkflowQuery
	// contains filtered or unexported fields
}

SpecWorkflowSelect is the builder for selecting fields of SpecWorkflow entities.

func (*SpecWorkflowSelect) Aggregate

func (_s *SpecWorkflowSelect) Aggregate(fns ...AggregateFunc) *SpecWorkflowSelect

Aggregate adds the given aggregation functions to the selector query.

func (*SpecWorkflowSelect) Bool

func (s *SpecWorkflowSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowSelect) BoolX

func (s *SpecWorkflowSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*SpecWorkflowSelect) Bools

func (s *SpecWorkflowSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowSelect) BoolsX

func (s *SpecWorkflowSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*SpecWorkflowSelect) Float64

func (s *SpecWorkflowSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowSelect) Float64X

func (s *SpecWorkflowSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*SpecWorkflowSelect) Float64s

func (s *SpecWorkflowSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowSelect) Float64sX

func (s *SpecWorkflowSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*SpecWorkflowSelect) Int

func (s *SpecWorkflowSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowSelect) IntX

func (s *SpecWorkflowSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*SpecWorkflowSelect) Ints

func (s *SpecWorkflowSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowSelect) IntsX

func (s *SpecWorkflowSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*SpecWorkflowSelect) Scan

func (_s *SpecWorkflowSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*SpecWorkflowSelect) ScanX

func (s *SpecWorkflowSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*SpecWorkflowSelect) String

func (s *SpecWorkflowSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowSelect) StringX

func (s *SpecWorkflowSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*SpecWorkflowSelect) Strings

func (s *SpecWorkflowSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*SpecWorkflowSelect) StringsX

func (s *SpecWorkflowSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type SpecWorkflowUpdate

type SpecWorkflowUpdate struct {
	// contains filtered or unexported fields
}

SpecWorkflowUpdate is the builder for updating SpecWorkflow entities.

func (*SpecWorkflowUpdate) AddInitiativeIDs

func (_u *SpecWorkflowUpdate) AddInitiativeIDs(ids ...string) *SpecWorkflowUpdate

AddInitiativeIDs adds the "initiatives" edge to the Initiative entity by IDs.

func (*SpecWorkflowUpdate) AddInitiatives

func (_u *SpecWorkflowUpdate) AddInitiatives(v ...*Initiative) *SpecWorkflowUpdate

AddInitiatives adds the "initiatives" edges to the Initiative entity.

func (*SpecWorkflowUpdate) AddRubricIDs

func (_u *SpecWorkflowUpdate) AddRubricIDs(ids ...string) *SpecWorkflowUpdate

AddRubricIDs adds the "rubrics" edge to the JudgeRubric entity by IDs.

func (*SpecWorkflowUpdate) AddRubrics

func (_u *SpecWorkflowUpdate) AddRubrics(v ...*JudgeRubric) *SpecWorkflowUpdate

AddRubrics adds the "rubrics" edges to the JudgeRubric entity.

func (*SpecWorkflowUpdate) AppendInitTypes

func (_u *SpecWorkflowUpdate) AppendInitTypes(v []string) *SpecWorkflowUpdate

AppendInitTypes appends value to the "init_types" field.

func (*SpecWorkflowUpdate) AppendSpecsOptional

func (_u *SpecWorkflowUpdate) AppendSpecsOptional(v []string) *SpecWorkflowUpdate

AppendSpecsOptional appends value to the "specs_optional" field.

func (*SpecWorkflowUpdate) AppendSpecsRequired

func (_u *SpecWorkflowUpdate) AppendSpecsRequired(v []string) *SpecWorkflowUpdate

AppendSpecsRequired appends value to the "specs_required" field.

func (*SpecWorkflowUpdate) ClearDescription

func (_u *SpecWorkflowUpdate) ClearDescription() *SpecWorkflowUpdate

ClearDescription clears the value of the "description" field.

func (*SpecWorkflowUpdate) ClearInitTypes

func (_u *SpecWorkflowUpdate) ClearInitTypes() *SpecWorkflowUpdate

ClearInitTypes clears the value of the "init_types" field.

func (*SpecWorkflowUpdate) ClearInitiatives

func (_u *SpecWorkflowUpdate) ClearInitiatives() *SpecWorkflowUpdate

ClearInitiatives clears all "initiatives" edges to the Initiative entity.

func (*SpecWorkflowUpdate) ClearRubrics

func (_u *SpecWorkflowUpdate) ClearRubrics() *SpecWorkflowUpdate

ClearRubrics clears all "rubrics" edges to the JudgeRubric entity.

func (*SpecWorkflowUpdate) ClearSpecsOptional

func (_u *SpecWorkflowUpdate) ClearSpecsOptional() *SpecWorkflowUpdate

ClearSpecsOptional clears the value of the "specs_optional" field.

func (*SpecWorkflowUpdate) ClearSpecsRequired

func (_u *SpecWorkflowUpdate) ClearSpecsRequired() *SpecWorkflowUpdate

ClearSpecsRequired clears the value of the "specs_required" field.

func (*SpecWorkflowUpdate) Exec

func (_u *SpecWorkflowUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*SpecWorkflowUpdate) ExecX

func (_u *SpecWorkflowUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SpecWorkflowUpdate) Mutation

func (_u *SpecWorkflowUpdate) Mutation() *SpecWorkflowMutation

Mutation returns the SpecWorkflowMutation object of the builder.

func (*SpecWorkflowUpdate) RemoveInitiativeIDs

func (_u *SpecWorkflowUpdate) RemoveInitiativeIDs(ids ...string) *SpecWorkflowUpdate

RemoveInitiativeIDs removes the "initiatives" edge to Initiative entities by IDs.

func (*SpecWorkflowUpdate) RemoveInitiatives

func (_u *SpecWorkflowUpdate) RemoveInitiatives(v ...*Initiative) *SpecWorkflowUpdate

RemoveInitiatives removes "initiatives" edges to Initiative entities.

func (*SpecWorkflowUpdate) RemoveRubricIDs

func (_u *SpecWorkflowUpdate) RemoveRubricIDs(ids ...string) *SpecWorkflowUpdate

RemoveRubricIDs removes the "rubrics" edge to JudgeRubric entities by IDs.

func (*SpecWorkflowUpdate) RemoveRubrics

func (_u *SpecWorkflowUpdate) RemoveRubrics(v ...*JudgeRubric) *SpecWorkflowUpdate

RemoveRubrics removes "rubrics" edges to JudgeRubric entities.

func (*SpecWorkflowUpdate) Save

func (_u *SpecWorkflowUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*SpecWorkflowUpdate) SaveX

func (_u *SpecWorkflowUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*SpecWorkflowUpdate) SetDescription

func (_u *SpecWorkflowUpdate) SetDescription(v string) *SpecWorkflowUpdate

SetDescription sets the "description" field.

func (*SpecWorkflowUpdate) SetInitTypes

func (_u *SpecWorkflowUpdate) SetInitTypes(v []string) *SpecWorkflowUpdate

SetInitTypes sets the "init_types" field.

func (*SpecWorkflowUpdate) SetName

SetName sets the "name" field.

func (*SpecWorkflowUpdate) SetNillableDescription

func (_u *SpecWorkflowUpdate) SetNillableDescription(v *string) *SpecWorkflowUpdate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*SpecWorkflowUpdate) SetNillableName

func (_u *SpecWorkflowUpdate) SetNillableName(v *string) *SpecWorkflowUpdate

SetNillableName sets the "name" field if the given value is not nil.

func (*SpecWorkflowUpdate) SetSpecsOptional

func (_u *SpecWorkflowUpdate) SetSpecsOptional(v []string) *SpecWorkflowUpdate

SetSpecsOptional sets the "specs_optional" field.

func (*SpecWorkflowUpdate) SetSpecsRequired

func (_u *SpecWorkflowUpdate) SetSpecsRequired(v []string) *SpecWorkflowUpdate

SetSpecsRequired sets the "specs_required" field.

func (*SpecWorkflowUpdate) Where

Where appends a list predicates to the SpecWorkflowUpdate builder.

type SpecWorkflowUpdateOne

type SpecWorkflowUpdateOne struct {
	// contains filtered or unexported fields
}

SpecWorkflowUpdateOne is the builder for updating a single SpecWorkflow entity.

func (*SpecWorkflowUpdateOne) AddInitiativeIDs

func (_u *SpecWorkflowUpdateOne) AddInitiativeIDs(ids ...string) *SpecWorkflowUpdateOne

AddInitiativeIDs adds the "initiatives" edge to the Initiative entity by IDs.

func (*SpecWorkflowUpdateOne) AddInitiatives

func (_u *SpecWorkflowUpdateOne) AddInitiatives(v ...*Initiative) *SpecWorkflowUpdateOne

AddInitiatives adds the "initiatives" edges to the Initiative entity.

func (*SpecWorkflowUpdateOne) AddRubricIDs

func (_u *SpecWorkflowUpdateOne) AddRubricIDs(ids ...string) *SpecWorkflowUpdateOne

AddRubricIDs adds the "rubrics" edge to the JudgeRubric entity by IDs.

func (*SpecWorkflowUpdateOne) AddRubrics

AddRubrics adds the "rubrics" edges to the JudgeRubric entity.

func (*SpecWorkflowUpdateOne) AppendInitTypes

func (_u *SpecWorkflowUpdateOne) AppendInitTypes(v []string) *SpecWorkflowUpdateOne

AppendInitTypes appends value to the "init_types" field.

func (*SpecWorkflowUpdateOne) AppendSpecsOptional

func (_u *SpecWorkflowUpdateOne) AppendSpecsOptional(v []string) *SpecWorkflowUpdateOne

AppendSpecsOptional appends value to the "specs_optional" field.

func (*SpecWorkflowUpdateOne) AppendSpecsRequired

func (_u *SpecWorkflowUpdateOne) AppendSpecsRequired(v []string) *SpecWorkflowUpdateOne

AppendSpecsRequired appends value to the "specs_required" field.

func (*SpecWorkflowUpdateOne) ClearDescription

func (_u *SpecWorkflowUpdateOne) ClearDescription() *SpecWorkflowUpdateOne

ClearDescription clears the value of the "description" field.

func (*SpecWorkflowUpdateOne) ClearInitTypes

func (_u *SpecWorkflowUpdateOne) ClearInitTypes() *SpecWorkflowUpdateOne

ClearInitTypes clears the value of the "init_types" field.

func (*SpecWorkflowUpdateOne) ClearInitiatives

func (_u *SpecWorkflowUpdateOne) ClearInitiatives() *SpecWorkflowUpdateOne

ClearInitiatives clears all "initiatives" edges to the Initiative entity.

func (*SpecWorkflowUpdateOne) ClearRubrics

func (_u *SpecWorkflowUpdateOne) ClearRubrics() *SpecWorkflowUpdateOne

ClearRubrics clears all "rubrics" edges to the JudgeRubric entity.

func (*SpecWorkflowUpdateOne) ClearSpecsOptional

func (_u *SpecWorkflowUpdateOne) ClearSpecsOptional() *SpecWorkflowUpdateOne

ClearSpecsOptional clears the value of the "specs_optional" field.

func (*SpecWorkflowUpdateOne) ClearSpecsRequired

func (_u *SpecWorkflowUpdateOne) ClearSpecsRequired() *SpecWorkflowUpdateOne

ClearSpecsRequired clears the value of the "specs_required" field.

func (*SpecWorkflowUpdateOne) Exec

Exec executes the query on the entity.

func (*SpecWorkflowUpdateOne) ExecX

func (_u *SpecWorkflowUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SpecWorkflowUpdateOne) Mutation

Mutation returns the SpecWorkflowMutation object of the builder.

func (*SpecWorkflowUpdateOne) RemoveInitiativeIDs

func (_u *SpecWorkflowUpdateOne) RemoveInitiativeIDs(ids ...string) *SpecWorkflowUpdateOne

RemoveInitiativeIDs removes the "initiatives" edge to Initiative entities by IDs.

func (*SpecWorkflowUpdateOne) RemoveInitiatives

func (_u *SpecWorkflowUpdateOne) RemoveInitiatives(v ...*Initiative) *SpecWorkflowUpdateOne

RemoveInitiatives removes "initiatives" edges to Initiative entities.

func (*SpecWorkflowUpdateOne) RemoveRubricIDs

func (_u *SpecWorkflowUpdateOne) RemoveRubricIDs(ids ...string) *SpecWorkflowUpdateOne

RemoveRubricIDs removes the "rubrics" edge to JudgeRubric entities by IDs.

func (*SpecWorkflowUpdateOne) RemoveRubrics

func (_u *SpecWorkflowUpdateOne) RemoveRubrics(v ...*JudgeRubric) *SpecWorkflowUpdateOne

RemoveRubrics removes "rubrics" edges to JudgeRubric entities.

func (*SpecWorkflowUpdateOne) Save

Save executes the query and returns the updated SpecWorkflow entity.

func (*SpecWorkflowUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*SpecWorkflowUpdateOne) Select

func (_u *SpecWorkflowUpdateOne) Select(field string, fields ...string) *SpecWorkflowUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*SpecWorkflowUpdateOne) SetDescription

func (_u *SpecWorkflowUpdateOne) SetDescription(v string) *SpecWorkflowUpdateOne

SetDescription sets the "description" field.

func (*SpecWorkflowUpdateOne) SetInitTypes

func (_u *SpecWorkflowUpdateOne) SetInitTypes(v []string) *SpecWorkflowUpdateOne

SetInitTypes sets the "init_types" field.

func (*SpecWorkflowUpdateOne) SetName

SetName sets the "name" field.

func (*SpecWorkflowUpdateOne) SetNillableDescription

func (_u *SpecWorkflowUpdateOne) SetNillableDescription(v *string) *SpecWorkflowUpdateOne

SetNillableDescription sets the "description" field if the given value is not nil.

func (*SpecWorkflowUpdateOne) SetNillableName

func (_u *SpecWorkflowUpdateOne) SetNillableName(v *string) *SpecWorkflowUpdateOne

SetNillableName sets the "name" field if the given value is not nil.

func (*SpecWorkflowUpdateOne) SetSpecsOptional

func (_u *SpecWorkflowUpdateOne) SetSpecsOptional(v []string) *SpecWorkflowUpdateOne

SetSpecsOptional sets the "specs_optional" field.

func (*SpecWorkflowUpdateOne) SetSpecsRequired

func (_u *SpecWorkflowUpdateOne) SetSpecsRequired(v []string) *SpecWorkflowUpdateOne

SetSpecsRequired sets the "specs_required" field.

func (*SpecWorkflowUpdateOne) Where

Where appends a list predicates to the SpecWorkflowUpdate builder.

type SpecWorkflows

type SpecWorkflows []*SpecWorkflow

SpecWorkflows is a parsable slice of SpecWorkflow.

type TraverseFunc

type TraverseFunc = ent.TraverseFunc

ent aliases to avoid import conflicts in user's code.

type Traverser

type Traverser = ent.Traverser

ent aliases to avoid import conflicts in user's code.

type Tx

type Tx struct {

	// Assignment is the client for interacting with the Assignment builders.
	Assignment *AssignmentClient
	// CapabilityModel is the client for interacting with the CapabilityModel builders.
	CapabilityModel *CapabilityModelClient
	// DeliveryEvidence is the client for interacting with the DeliveryEvidence builders.
	DeliveryEvidence *DeliveryEvidenceClient
	// Initiative is the client for interacting with the Initiative builders.
	Initiative *InitiativeClient
	// InitiativeDependency is the client for interacting with the InitiativeDependency builders.
	InitiativeDependency *InitiativeDependencyClient
	// JudgeResult is the client for interacting with the JudgeResult builders.
	JudgeResult *JudgeResultClient
	// JudgeRubric is the client for interacting with the JudgeRubric builders.
	JudgeRubric *JudgeRubricClient
	// MaturityAssessment is the client for interacting with the MaturityAssessment builders.
	MaturityAssessment *MaturityAssessmentClient
	// Phase is the client for interacting with the Phase builders.
	Phase *PhaseClient
	// Program is the client for interacting with the Program builders.
	Program *ProgramClient
	// RMIDependency is the client for interacting with the RMIDependency builders.
	RMIDependency *RMIDependencyClient
	// Repository is the client for interacting with the Repository builders.
	Repository *RepositoryClient
	// RepositoryDependency is the client for interacting with the RepositoryDependency builders.
	RepositoryDependency *RepositoryDependencyClient
	// RoadmapItem is the client for interacting with the RoadmapItem builders.
	RoadmapItem *RoadmapItemClient
	// SpecWorkflow is the client for interacting with the SpecWorkflow builders.
	SpecWorkflow *SpecWorkflowClient
	// 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 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