tree

package
v1.63.0 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the tree type in the database.
	Label = "tree"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "id"
	// FieldSetID holds the string denoting the set_id field in the database.
	FieldSetID = "set_id"
	// FieldPath holds the string denoting the path field in the database.
	FieldPath = "path"
	// FieldDir holds the string denoting the dir field in the database.
	FieldDir = "dir"
	// FieldValidFrom holds the string denoting the valid_from field in the database.
	FieldValidFrom = "valid_from"
	// FieldValidUntil holds the string denoting the valid_until field in the database.
	FieldValidUntil = "valid_until"
	// FieldRef holds the string denoting the ref field in the database.
	FieldRef = "ref"
	// EdgeSet holds the string denoting the set edge name in mutations.
	EdgeSet = "set"
	// Table holds the table name of the tree in the database.
	Table = "trees"
	// SetTable is the table that holds the set relation/edge.
	SetTable = "trees"
	// SetInverseTable is the table name for the Set entity.
	// It exists in this package in order to avoid circular dependency with the "set" package.
	SetInverseTable = "sets"
	// SetColumn is the table column denoting the set relation/edge.
	SetColumn = "set_id"
)

Variables

Columns holds all SQL columns for tree fields.

Functions

func And

func And(predicates ...predicate.Tree) predicate.Tree

And groups predicates with the AND operator between them.

func Dir

func Dir(v string) predicate.Tree

Dir applies equality check predicate on the "dir" field. It's identical to DirEQ.

func DirContains

func DirContains(v string) predicate.Tree

DirContains applies the Contains predicate on the "dir" field.

func DirContainsFold

func DirContainsFold(v string) predicate.Tree

DirContainsFold applies the ContainsFold predicate on the "dir" field.

func DirEQ

func DirEQ(v string) predicate.Tree

DirEQ applies the EQ predicate on the "dir" field.

func DirEqualFold

func DirEqualFold(v string) predicate.Tree

DirEqualFold applies the EqualFold predicate on the "dir" field.

func DirGT

func DirGT(v string) predicate.Tree

DirGT applies the GT predicate on the "dir" field.

func DirGTE

func DirGTE(v string) predicate.Tree

DirGTE applies the GTE predicate on the "dir" field.

func DirHasPrefix

func DirHasPrefix(v string) predicate.Tree

DirHasPrefix applies the HasPrefix predicate on the "dir" field.

func DirHasSuffix

func DirHasSuffix(v string) predicate.Tree

DirHasSuffix applies the HasSuffix predicate on the "dir" field.

func DirIn

func DirIn(vs ...string) predicate.Tree

DirIn applies the In predicate on the "dir" field.

func DirLT

func DirLT(v string) predicate.Tree

DirLT applies the LT predicate on the "dir" field.

func DirLTE

func DirLTE(v string) predicate.Tree

DirLTE applies the LTE predicate on the "dir" field.

func DirNEQ

func DirNEQ(v string) predicate.Tree

DirNEQ applies the NEQ predicate on the "dir" field.

func DirNotIn

func DirNotIn(vs ...string) predicate.Tree

DirNotIn applies the NotIn predicate on the "dir" field.

func HasSet

func HasSet() predicate.Tree

HasSet applies the HasEdge predicate on the "set" edge.

func HasSetWith

func HasSetWith(preds ...predicate.Set) predicate.Tree

HasSetWith applies the HasEdge predicate on the "set" edge with a given conditions (other predicates).

func ID

func ID(id int) predicate.Tree

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id int) predicate.Tree

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id int) predicate.Tree

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id int) predicate.Tree

IDGTE applies the GTE predicate on the ID field.

func IDIn

func IDIn(ids ...int) predicate.Tree

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id int) predicate.Tree

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id int) predicate.Tree

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id int) predicate.Tree

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

func IDNotIn(ids ...int) predicate.Tree

IDNotIn applies the NotIn predicate on the ID field.

func Not

Not applies the not operator on the given predicate.

func Or

func Or(predicates ...predicate.Tree) predicate.Tree

Or groups predicates with the OR operator between them.

func Path

func Path(v string) predicate.Tree

Path applies equality check predicate on the "path" field. It's identical to PathEQ.

func PathContains

func PathContains(v string) predicate.Tree

PathContains applies the Contains predicate on the "path" field.

func PathContainsFold

func PathContainsFold(v string) predicate.Tree

PathContainsFold applies the ContainsFold predicate on the "path" field.

func PathEQ

func PathEQ(v string) predicate.Tree

PathEQ applies the EQ predicate on the "path" field.

func PathEqualFold

func PathEqualFold(v string) predicate.Tree

PathEqualFold applies the EqualFold predicate on the "path" field.

func PathGT

func PathGT(v string) predicate.Tree

PathGT applies the GT predicate on the "path" field.

func PathGTE

func PathGTE(v string) predicate.Tree

PathGTE applies the GTE predicate on the "path" field.

func PathHasPrefix

func PathHasPrefix(v string) predicate.Tree

PathHasPrefix applies the HasPrefix predicate on the "path" field.

func PathHasSuffix

func PathHasSuffix(v string) predicate.Tree

PathHasSuffix applies the HasSuffix predicate on the "path" field.

func PathIn

func PathIn(vs ...string) predicate.Tree

PathIn applies the In predicate on the "path" field.

func PathLT

func PathLT(v string) predicate.Tree

PathLT applies the LT predicate on the "path" field.

func PathLTE

func PathLTE(v string) predicate.Tree

PathLTE applies the LTE predicate on the "path" field.

func PathNEQ

func PathNEQ(v string) predicate.Tree

PathNEQ applies the NEQ predicate on the "path" field.

func PathNotIn

func PathNotIn(vs ...string) predicate.Tree

PathNotIn applies the NotIn predicate on the "path" field.

func Ref

func Ref(v []byte) predicate.Tree

Ref applies equality check predicate on the "ref" field. It's identical to RefEQ.

func RefEQ

func RefEQ(v []byte) predicate.Tree

RefEQ applies the EQ predicate on the "ref" field.

func RefGT

func RefGT(v []byte) predicate.Tree

RefGT applies the GT predicate on the "ref" field.

func RefGTE

func RefGTE(v []byte) predicate.Tree

RefGTE applies the GTE predicate on the "ref" field.

func RefIn

func RefIn(vs ...[]byte) predicate.Tree

RefIn applies the In predicate on the "ref" field.

func RefLT

func RefLT(v []byte) predicate.Tree

RefLT applies the LT predicate on the "ref" field.

func RefLTE

func RefLTE(v []byte) predicate.Tree

RefLTE applies the LTE predicate on the "ref" field.

func RefNEQ

func RefNEQ(v []byte) predicate.Tree

RefNEQ applies the NEQ predicate on the "ref" field.

func RefNotIn

func RefNotIn(vs ...[]byte) predicate.Tree

RefNotIn applies the NotIn predicate on the "ref" field.

func SetID

func SetID(v int64) predicate.Tree

SetID applies equality check predicate on the "set_id" field. It's identical to SetIDEQ.

func SetIDEQ

func SetIDEQ(v int64) predicate.Tree

SetIDEQ applies the EQ predicate on the "set_id" field.

func SetIDIn

func SetIDIn(vs ...int64) predicate.Tree

SetIDIn applies the In predicate on the "set_id" field.

func SetIDNEQ

func SetIDNEQ(v int64) predicate.Tree

SetIDNEQ applies the NEQ predicate on the "set_id" field.

func SetIDNotIn

func SetIDNotIn(vs ...int64) predicate.Tree

SetIDNotIn applies the NotIn predicate on the "set_id" field.

func ValidColumn

func ValidColumn(column string) bool

ValidColumn reports if the column name is valid (part of the table columns).

func ValidFrom

func ValidFrom(v time.Time) predicate.Tree

ValidFrom applies equality check predicate on the "valid_from" field. It's identical to ValidFromEQ.

func ValidFromEQ

func ValidFromEQ(v time.Time) predicate.Tree

ValidFromEQ applies the EQ predicate on the "valid_from" field.

func ValidFromGT

func ValidFromGT(v time.Time) predicate.Tree

ValidFromGT applies the GT predicate on the "valid_from" field.

func ValidFromGTE

func ValidFromGTE(v time.Time) predicate.Tree

ValidFromGTE applies the GTE predicate on the "valid_from" field.

func ValidFromIn

func ValidFromIn(vs ...time.Time) predicate.Tree

ValidFromIn applies the In predicate on the "valid_from" field.

func ValidFromLT

func ValidFromLT(v time.Time) predicate.Tree

ValidFromLT applies the LT predicate on the "valid_from" field.

func ValidFromLTE

func ValidFromLTE(v time.Time) predicate.Tree

ValidFromLTE applies the LTE predicate on the "valid_from" field.

func ValidFromNEQ

func ValidFromNEQ(v time.Time) predicate.Tree

ValidFromNEQ applies the NEQ predicate on the "valid_from" field.

func ValidFromNotIn

func ValidFromNotIn(vs ...time.Time) predicate.Tree

ValidFromNotIn applies the NotIn predicate on the "valid_from" field.

func ValidUntil

func ValidUntil(v time.Time) predicate.Tree

ValidUntil applies equality check predicate on the "valid_until" field. It's identical to ValidUntilEQ.

func ValidUntilEQ

func ValidUntilEQ(v time.Time) predicate.Tree

ValidUntilEQ applies the EQ predicate on the "valid_until" field.

func ValidUntilGT

func ValidUntilGT(v time.Time) predicate.Tree

ValidUntilGT applies the GT predicate on the "valid_until" field.

func ValidUntilGTE

func ValidUntilGTE(v time.Time) predicate.Tree

ValidUntilGTE applies the GTE predicate on the "valid_until" field.

func ValidUntilIn

func ValidUntilIn(vs ...time.Time) predicate.Tree

ValidUntilIn applies the In predicate on the "valid_until" field.

func ValidUntilIsNil

func ValidUntilIsNil() predicate.Tree

ValidUntilIsNil applies the IsNil predicate on the "valid_until" field.

func ValidUntilLT

func ValidUntilLT(v time.Time) predicate.Tree

ValidUntilLT applies the LT predicate on the "valid_until" field.

func ValidUntilLTE

func ValidUntilLTE(v time.Time) predicate.Tree

ValidUntilLTE applies the LTE predicate on the "valid_until" field.

func ValidUntilNEQ

func ValidUntilNEQ(v time.Time) predicate.Tree

ValidUntilNEQ applies the NEQ predicate on the "valid_until" field.

func ValidUntilNotIn

func ValidUntilNotIn(vs ...time.Time) predicate.Tree

ValidUntilNotIn applies the NotIn predicate on the "valid_until" field.

func ValidUntilNotNil

func ValidUntilNotNil() predicate.Tree

ValidUntilNotNil applies the NotNil predicate on the "valid_until" field.

Types

type OrderOption

type OrderOption func(*sql.Selector)

OrderOption defines the ordering options for the Tree queries.

func ByDir

func ByDir(opts ...sql.OrderTermOption) OrderOption

ByDir orders the results by the dir field.

func ByID

func ByID(opts ...sql.OrderTermOption) OrderOption

ByID orders the results by the id field.

func ByPath

func ByPath(opts ...sql.OrderTermOption) OrderOption

ByPath orders the results by the path field.

func BySetField

func BySetField(field string, opts ...sql.OrderTermOption) OrderOption

BySetField orders the results by set field.

func BySetID

func BySetID(opts ...sql.OrderTermOption) OrderOption

BySetID orders the results by the set_id field.

func ByValidFrom

func ByValidFrom(opts ...sql.OrderTermOption) OrderOption

ByValidFrom orders the results by the valid_from field.

func ByValidUntil

func ByValidUntil(opts ...sql.OrderTermOption) OrderOption

ByValidUntil orders the results by the valid_until field.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL