file

package
v0.0.0-...-83be90a Latest Latest
Warning

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

Go to latest
Published: May 9, 2020 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the file type in the database.
	Label = "file"
	// FieldID holds the string denoting the id field in the database.
	FieldID         = "id"          // FieldHash holds the string denoting the hash vertex property in the database.
	FieldHash       = "hash"        // FieldSize holds the string denoting the size vertex property in the database.
	FieldSize       = "size"        // FieldPinnedAt holds the string denoting the pinned_at vertex property in the database.
	FieldPinnedAt   = "pinned_at"   // FieldUnpinnedAt holds the string denoting the unpinned_at vertex property in the database.
	FieldUnpinnedAt = "unpinned_at" // FieldMetadata holds the string denoting the metadata vertex property in the database.
	FieldMetadata   = "metadata"

	// EdgeUser holds the string denoting the user edge name in mutations.
	EdgeUser = "user"

	// Table holds the table name of the file in the database.
	Table = "files"
	// UserTable is the table the holds the user relation/edge.
	UserTable = "files"
	// UserInverseTable is the table name for the User entity.
	// It exists in this package in order to avoid circular dependency with the "user" package.
	UserInverseTable = "users"
	// UserColumn is the table column denoting the user relation/edge.
	UserColumn = "user_files"
)

Variables

View Source
var (
	// HashValidator is a validator for the "hash" field. It is called by the builders before save.
	HashValidator func(string) error
	// SizeValidator is a validator for the "size" field. It is called by the builders before save.
	SizeValidator func(int64) error
	// DefaultPinnedAt holds the default value on creation for the pinned_at field.
	DefaultPinnedAt func() time.Time
)

Columns holds all SQL columns for file fields.

View Source
var ForeignKeys = []string{
	"user_files",
}

ForeignKeys holds the SQL foreign-keys that are owned by the File type.

Functions

func And

func And(predicates ...predicate.File) predicate.File

And groups list of predicates with the AND operator between them.

func HasUser

func HasUser() predicate.File

HasUser applies the HasEdge predicate on the "user" edge.

func HasUserWith

func HasUserWith(preds ...predicate.User) predicate.File

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

func Hash

func Hash(v string) predicate.File

Hash applies equality check predicate on the "hash" field. It's identical to HashEQ.

func HashContains

func HashContains(v string) predicate.File

HashContains applies the Contains predicate on the "hash" field.

func HashContainsFold

func HashContainsFold(v string) predicate.File

HashContainsFold applies the ContainsFold predicate on the "hash" field.

func HashEQ

func HashEQ(v string) predicate.File

HashEQ applies the EQ predicate on the "hash" field.

func HashEqualFold

func HashEqualFold(v string) predicate.File

HashEqualFold applies the EqualFold predicate on the "hash" field.

func HashGT

func HashGT(v string) predicate.File

HashGT applies the GT predicate on the "hash" field.

func HashGTE

func HashGTE(v string) predicate.File

HashGTE applies the GTE predicate on the "hash" field.

func HashHasPrefix

func HashHasPrefix(v string) predicate.File

HashHasPrefix applies the HasPrefix predicate on the "hash" field.

func HashHasSuffix

func HashHasSuffix(v string) predicate.File

HashHasSuffix applies the HasSuffix predicate on the "hash" field.

func HashIn

func HashIn(vs ...string) predicate.File

HashIn applies the In predicate on the "hash" field.

func HashLT

func HashLT(v string) predicate.File

HashLT applies the LT predicate on the "hash" field.

func HashLTE

func HashLTE(v string) predicate.File

HashLTE applies the LTE predicate on the "hash" field.

func HashNEQ

func HashNEQ(v string) predicate.File

HashNEQ applies the NEQ predicate on the "hash" field.

func HashNotIn

func HashNotIn(vs ...string) predicate.File

HashNotIn applies the NotIn predicate on the "hash" field.

func ID

func ID(id uuid.UUID) predicate.File

ID filters vertices based on their identifier.

func IDEQ

func IDEQ(id uuid.UUID) predicate.File

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id uuid.UUID) predicate.File

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id uuid.UUID) predicate.File

IDGTE applies the GTE predicate on the ID field.

func IDIn

func IDIn(ids ...uuid.UUID) predicate.File

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id uuid.UUID) predicate.File

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id uuid.UUID) predicate.File

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id uuid.UUID) predicate.File

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

func IDNotIn(ids ...uuid.UUID) predicate.File

IDNotIn applies the NotIn predicate on the ID field.

func MetadataIsNil

func MetadataIsNil() predicate.File

MetadataIsNil applies the IsNil predicate on the "metadata" field.

func MetadataNotNil

func MetadataNotNil() predicate.File

MetadataNotNil applies the NotNil predicate on the "metadata" field.

func Not

Not applies the not operator on the given predicate.

func Or

func Or(predicates ...predicate.File) predicate.File

Or groups list of predicates with the OR operator between them.

func PinnedAt

func PinnedAt(v time.Time) predicate.File

PinnedAt applies equality check predicate on the "pinned_at" field. It's identical to PinnedAtEQ.

func PinnedAtEQ

func PinnedAtEQ(v time.Time) predicate.File

PinnedAtEQ applies the EQ predicate on the "pinned_at" field.

func PinnedAtGT

func PinnedAtGT(v time.Time) predicate.File

PinnedAtGT applies the GT predicate on the "pinned_at" field.

func PinnedAtGTE

func PinnedAtGTE(v time.Time) predicate.File

PinnedAtGTE applies the GTE predicate on the "pinned_at" field.

func PinnedAtIn

func PinnedAtIn(vs ...time.Time) predicate.File

PinnedAtIn applies the In predicate on the "pinned_at" field.

func PinnedAtLT

func PinnedAtLT(v time.Time) predicate.File

PinnedAtLT applies the LT predicate on the "pinned_at" field.

func PinnedAtLTE

func PinnedAtLTE(v time.Time) predicate.File

PinnedAtLTE applies the LTE predicate on the "pinned_at" field.

func PinnedAtNEQ

func PinnedAtNEQ(v time.Time) predicate.File

PinnedAtNEQ applies the NEQ predicate on the "pinned_at" field.

func PinnedAtNotIn

func PinnedAtNotIn(vs ...time.Time) predicate.File

PinnedAtNotIn applies the NotIn predicate on the "pinned_at" field.

func Size

func Size(v int64) predicate.File

Size applies equality check predicate on the "size" field. It's identical to SizeEQ.

func SizeEQ

func SizeEQ(v int64) predicate.File

SizeEQ applies the EQ predicate on the "size" field.

func SizeGT

func SizeGT(v int64) predicate.File

SizeGT applies the GT predicate on the "size" field.

func SizeGTE

func SizeGTE(v int64) predicate.File

SizeGTE applies the GTE predicate on the "size" field.

func SizeIn

func SizeIn(vs ...int64) predicate.File

SizeIn applies the In predicate on the "size" field.

func SizeLT

func SizeLT(v int64) predicate.File

SizeLT applies the LT predicate on the "size" field.

func SizeLTE

func SizeLTE(v int64) predicate.File

SizeLTE applies the LTE predicate on the "size" field.

func SizeNEQ

func SizeNEQ(v int64) predicate.File

SizeNEQ applies the NEQ predicate on the "size" field.

func SizeNotIn

func SizeNotIn(vs ...int64) predicate.File

SizeNotIn applies the NotIn predicate on the "size" field.

func UnpinnedAt

func UnpinnedAt(v time.Time) predicate.File

UnpinnedAt applies equality check predicate on the "unpinned_at" field. It's identical to UnpinnedAtEQ.

func UnpinnedAtEQ

func UnpinnedAtEQ(v time.Time) predicate.File

UnpinnedAtEQ applies the EQ predicate on the "unpinned_at" field.

func UnpinnedAtGT

func UnpinnedAtGT(v time.Time) predicate.File

UnpinnedAtGT applies the GT predicate on the "unpinned_at" field.

func UnpinnedAtGTE

func UnpinnedAtGTE(v time.Time) predicate.File

UnpinnedAtGTE applies the GTE predicate on the "unpinned_at" field.

func UnpinnedAtIn

func UnpinnedAtIn(vs ...time.Time) predicate.File

UnpinnedAtIn applies the In predicate on the "unpinned_at" field.

func UnpinnedAtLT

func UnpinnedAtLT(v time.Time) predicate.File

UnpinnedAtLT applies the LT predicate on the "unpinned_at" field.

func UnpinnedAtLTE

func UnpinnedAtLTE(v time.Time) predicate.File

UnpinnedAtLTE applies the LTE predicate on the "unpinned_at" field.

func UnpinnedAtNEQ

func UnpinnedAtNEQ(v time.Time) predicate.File

UnpinnedAtNEQ applies the NEQ predicate on the "unpinned_at" field.

func UnpinnedAtNotIn

func UnpinnedAtNotIn(vs ...time.Time) predicate.File

UnpinnedAtNotIn applies the NotIn predicate on the "unpinned_at" field.

Types

This section is empty.

Jump to

Keyboard shortcuts

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