document

package
v0.0.0-...-aa737f3 Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the document type in the database.
	Label = "document"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "id"
	// FieldUUID holds the string denoting the uuid field in the database.
	FieldUUID = "uuid"
	// FieldCreatedAt holds the string denoting the created_at field in the database.
	FieldCreatedAt = "created_at"
	// FieldUpdatedAt holds the string denoting the updated_at field in the database.
	FieldUpdatedAt = "updated_at"
	// FieldTitle holds the string denoting the title field in the database.
	FieldTitle = "title"
	// FieldDescription holds the string denoting the description field in the database.
	FieldDescription = "description"
	// FieldFilename holds the string denoting the filename field in the database.
	FieldFilename = "filename"
	// FieldFiletype holds the string denoting the filetype field in the database.
	FieldFiletype = "filetype"
	// FieldContent holds the string denoting the content field in the database.
	FieldContent = "content"
	// FieldContentHash holds the string denoting the content_hash field in the database.
	FieldContentHash = "content_hash"
	// EdgeUser holds the string denoting the user edge name in mutations.
	EdgeUser = "user"
	// EdgeSearch holds the string denoting the search edge name in mutations.
	EdgeSearch = "search"
	// Table holds the table name of the document in the database.
	Table = "documents"
	// UserTable is the table that holds the user relation/edge.
	UserTable = "documents"
	// 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_documents"
	// SearchTable is the table that holds the search relation/edge.
	SearchTable = "document_searches"
	// SearchInverseTable is the table name for the DocumentSearch entity.
	// It exists in this package in order to avoid circular dependency with the "documentsearch" package.
	SearchInverseTable = "document_searches"
	// SearchColumn is the table column denoting the search relation/edge.
	SearchColumn = "document_id"
)

Variables

View Source
var (
	Hooks [1]ent.Hook
	// DefaultUUID holds the default value on creation for the "uuid" field.
	DefaultUUID func() uuid.UUID
	// DefaultCreatedAt holds the default value on creation for the "created_at" field.
	DefaultCreatedAt func() time.Time
	// DefaultUpdatedAt holds the default value on creation for the "updated_at" field.
	DefaultUpdatedAt func() time.Time
	// UpdateDefaultUpdatedAt holds the default value on update for the "updated_at" field.
	UpdateDefaultUpdatedAt func() time.Time
)

Note that the variables below are initialized by the runtime package on the initialization of the application. Therefore, it should be imported in the main as follows:

import _ "github.com/frisbm/graduateplace/pkg/store/ent/runtime"

Columns holds all SQL columns for document fields.

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

ForeignKeys holds the SQL foreign-keys that are owned by the "documents" table and are not defined as standalone fields in the schema.

Functions

func And

func And(predicates ...predicate.Document) predicate.Document

And groups predicates with the AND operator between them.

func Content

func Content(v string) predicate.Document

Content applies equality check predicate on the "content" field. It's identical to ContentEQ.

func ContentContains

func ContentContains(v string) predicate.Document

ContentContains applies the Contains predicate on the "content" field.

func ContentContainsFold

func ContentContainsFold(v string) predicate.Document

ContentContainsFold applies the ContainsFold predicate on the "content" field.

func ContentEQ

func ContentEQ(v string) predicate.Document

ContentEQ applies the EQ predicate on the "content" field.

func ContentEqualFold

func ContentEqualFold(v string) predicate.Document

ContentEqualFold applies the EqualFold predicate on the "content" field.

func ContentGT

func ContentGT(v string) predicate.Document

ContentGT applies the GT predicate on the "content" field.

func ContentGTE

func ContentGTE(v string) predicate.Document

ContentGTE applies the GTE predicate on the "content" field.

func ContentHasPrefix

func ContentHasPrefix(v string) predicate.Document

ContentHasPrefix applies the HasPrefix predicate on the "content" field.

func ContentHasSuffix

func ContentHasSuffix(v string) predicate.Document

ContentHasSuffix applies the HasSuffix predicate on the "content" field.

func ContentHash

func ContentHash(v string) predicate.Document

ContentHash applies equality check predicate on the "content_hash" field. It's identical to ContentHashEQ.

func ContentHashContains

func ContentHashContains(v string) predicate.Document

ContentHashContains applies the Contains predicate on the "content_hash" field.

func ContentHashContainsFold

func ContentHashContainsFold(v string) predicate.Document

ContentHashContainsFold applies the ContainsFold predicate on the "content_hash" field.

func ContentHashEQ

func ContentHashEQ(v string) predicate.Document

ContentHashEQ applies the EQ predicate on the "content_hash" field.

func ContentHashEqualFold

func ContentHashEqualFold(v string) predicate.Document

ContentHashEqualFold applies the EqualFold predicate on the "content_hash" field.

func ContentHashGT

func ContentHashGT(v string) predicate.Document

ContentHashGT applies the GT predicate on the "content_hash" field.

func ContentHashGTE

func ContentHashGTE(v string) predicate.Document

ContentHashGTE applies the GTE predicate on the "content_hash" field.

func ContentHashHasPrefix

func ContentHashHasPrefix(v string) predicate.Document

ContentHashHasPrefix applies the HasPrefix predicate on the "content_hash" field.

func ContentHashHasSuffix

func ContentHashHasSuffix(v string) predicate.Document

ContentHashHasSuffix applies the HasSuffix predicate on the "content_hash" field.

func ContentHashIn

func ContentHashIn(vs ...string) predicate.Document

ContentHashIn applies the In predicate on the "content_hash" field.

func ContentHashIsNil

func ContentHashIsNil() predicate.Document

ContentHashIsNil applies the IsNil predicate on the "content_hash" field.

func ContentHashLT

func ContentHashLT(v string) predicate.Document

ContentHashLT applies the LT predicate on the "content_hash" field.

func ContentHashLTE

func ContentHashLTE(v string) predicate.Document

ContentHashLTE applies the LTE predicate on the "content_hash" field.

func ContentHashNEQ

func ContentHashNEQ(v string) predicate.Document

ContentHashNEQ applies the NEQ predicate on the "content_hash" field.

func ContentHashNotIn

func ContentHashNotIn(vs ...string) predicate.Document

ContentHashNotIn applies the NotIn predicate on the "content_hash" field.

func ContentHashNotNil

func ContentHashNotNil() predicate.Document

ContentHashNotNil applies the NotNil predicate on the "content_hash" field.

func ContentIn

func ContentIn(vs ...string) predicate.Document

ContentIn applies the In predicate on the "content" field.

func ContentIsNil

func ContentIsNil() predicate.Document

ContentIsNil applies the IsNil predicate on the "content" field.

func ContentLT

func ContentLT(v string) predicate.Document

ContentLT applies the LT predicate on the "content" field.

func ContentLTE

func ContentLTE(v string) predicate.Document

ContentLTE applies the LTE predicate on the "content" field.

func ContentNEQ

func ContentNEQ(v string) predicate.Document

ContentNEQ applies the NEQ predicate on the "content" field.

func ContentNotIn

func ContentNotIn(vs ...string) predicate.Document

ContentNotIn applies the NotIn predicate on the "content" field.

func ContentNotNil

func ContentNotNil() predicate.Document

ContentNotNil applies the NotNil predicate on the "content" field.

func CreatedAt

func CreatedAt(v time.Time) predicate.Document

CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.

func CreatedAtEQ

func CreatedAtEQ(v time.Time) predicate.Document

CreatedAtEQ applies the EQ predicate on the "created_at" field.

func CreatedAtGT

func CreatedAtGT(v time.Time) predicate.Document

CreatedAtGT applies the GT predicate on the "created_at" field.

func CreatedAtGTE

func CreatedAtGTE(v time.Time) predicate.Document

CreatedAtGTE applies the GTE predicate on the "created_at" field.

func CreatedAtIn

func CreatedAtIn(vs ...time.Time) predicate.Document

CreatedAtIn applies the In predicate on the "created_at" field.

func CreatedAtLT

func CreatedAtLT(v time.Time) predicate.Document

CreatedAtLT applies the LT predicate on the "created_at" field.

func CreatedAtLTE

func CreatedAtLTE(v time.Time) predicate.Document

CreatedAtLTE applies the LTE predicate on the "created_at" field.

func CreatedAtNEQ

func CreatedAtNEQ(v time.Time) predicate.Document

CreatedAtNEQ applies the NEQ predicate on the "created_at" field.

func CreatedAtNotIn

func CreatedAtNotIn(vs ...time.Time) predicate.Document

CreatedAtNotIn applies the NotIn predicate on the "created_at" field.

func Description

func Description(v string) predicate.Document

Description applies equality check predicate on the "description" field. It's identical to DescriptionEQ.

func DescriptionContains

func DescriptionContains(v string) predicate.Document

DescriptionContains applies the Contains predicate on the "description" field.

func DescriptionContainsFold

func DescriptionContainsFold(v string) predicate.Document

DescriptionContainsFold applies the ContainsFold predicate on the "description" field.

func DescriptionEQ

func DescriptionEQ(v string) predicate.Document

DescriptionEQ applies the EQ predicate on the "description" field.

func DescriptionEqualFold

func DescriptionEqualFold(v string) predicate.Document

DescriptionEqualFold applies the EqualFold predicate on the "description" field.

func DescriptionGT

func DescriptionGT(v string) predicate.Document

DescriptionGT applies the GT predicate on the "description" field.

func DescriptionGTE

func DescriptionGTE(v string) predicate.Document

DescriptionGTE applies the GTE predicate on the "description" field.

func DescriptionHasPrefix

func DescriptionHasPrefix(v string) predicate.Document

DescriptionHasPrefix applies the HasPrefix predicate on the "description" field.

func DescriptionHasSuffix

func DescriptionHasSuffix(v string) predicate.Document

DescriptionHasSuffix applies the HasSuffix predicate on the "description" field.

func DescriptionIn

func DescriptionIn(vs ...string) predicate.Document

DescriptionIn applies the In predicate on the "description" field.

func DescriptionLT

func DescriptionLT(v string) predicate.Document

DescriptionLT applies the LT predicate on the "description" field.

func DescriptionLTE

func DescriptionLTE(v string) predicate.Document

DescriptionLTE applies the LTE predicate on the "description" field.

func DescriptionNEQ

func DescriptionNEQ(v string) predicate.Document

DescriptionNEQ applies the NEQ predicate on the "description" field.

func DescriptionNotIn

func DescriptionNotIn(vs ...string) predicate.Document

DescriptionNotIn applies the NotIn predicate on the "description" field.

func Filename

func Filename(v string) predicate.Document

Filename applies equality check predicate on the "filename" field. It's identical to FilenameEQ.

func FilenameContains

func FilenameContains(v string) predicate.Document

FilenameContains applies the Contains predicate on the "filename" field.

func FilenameContainsFold

func FilenameContainsFold(v string) predicate.Document

FilenameContainsFold applies the ContainsFold predicate on the "filename" field.

func FilenameEQ

func FilenameEQ(v string) predicate.Document

FilenameEQ applies the EQ predicate on the "filename" field.

func FilenameEqualFold

func FilenameEqualFold(v string) predicate.Document

FilenameEqualFold applies the EqualFold predicate on the "filename" field.

func FilenameGT

func FilenameGT(v string) predicate.Document

FilenameGT applies the GT predicate on the "filename" field.

func FilenameGTE

func FilenameGTE(v string) predicate.Document

FilenameGTE applies the GTE predicate on the "filename" field.

func FilenameHasPrefix

func FilenameHasPrefix(v string) predicate.Document

FilenameHasPrefix applies the HasPrefix predicate on the "filename" field.

func FilenameHasSuffix

func FilenameHasSuffix(v string) predicate.Document

FilenameHasSuffix applies the HasSuffix predicate on the "filename" field.

func FilenameIn

func FilenameIn(vs ...string) predicate.Document

FilenameIn applies the In predicate on the "filename" field.

func FilenameLT

func FilenameLT(v string) predicate.Document

FilenameLT applies the LT predicate on the "filename" field.

func FilenameLTE

func FilenameLTE(v string) predicate.Document

FilenameLTE applies the LTE predicate on the "filename" field.

func FilenameNEQ

func FilenameNEQ(v string) predicate.Document

FilenameNEQ applies the NEQ predicate on the "filename" field.

func FilenameNotIn

func FilenameNotIn(vs ...string) predicate.Document

FilenameNotIn applies the NotIn predicate on the "filename" field.

func FiletypeEQ

func FiletypeEQ(v types.Filetype) predicate.Document

FiletypeEQ applies the EQ predicate on the "filetype" field.

func FiletypeIn

func FiletypeIn(vs ...types.Filetype) predicate.Document

FiletypeIn applies the In predicate on the "filetype" field.

func FiletypeNEQ

func FiletypeNEQ(v types.Filetype) predicate.Document

FiletypeNEQ applies the NEQ predicate on the "filetype" field.

func FiletypeNotIn

func FiletypeNotIn(vs ...types.Filetype) predicate.Document

FiletypeNotIn applies the NotIn predicate on the "filetype" field.

func FiletypeValidator

func FiletypeValidator(f types.Filetype) error

FiletypeValidator is a validator for the "filetype" field enum values. It is called by the builders before save.

func HasSearch

func HasSearch() predicate.Document

HasSearch applies the HasEdge predicate on the "search" edge.

func HasSearchWith

func HasSearchWith(preds ...predicate.DocumentSearch) predicate.Document

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

func HasUser

func HasUser() predicate.Document

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

func HasUserWith

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

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

func ID

func ID(id int) predicate.Document

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id int) predicate.Document

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id int) predicate.Document

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id int) predicate.Document

IDGTE applies the GTE predicate on the ID field.

func IDIn

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

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id int) predicate.Document

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id int) predicate.Document

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id int) predicate.Document

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

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

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.Document) predicate.Document

Or groups predicates with the OR operator between them.

func Title

func Title(v string) predicate.Document

Title applies equality check predicate on the "title" field. It's identical to TitleEQ.

func TitleContains

func TitleContains(v string) predicate.Document

TitleContains applies the Contains predicate on the "title" field.

func TitleContainsFold

func TitleContainsFold(v string) predicate.Document

TitleContainsFold applies the ContainsFold predicate on the "title" field.

func TitleEQ

func TitleEQ(v string) predicate.Document

TitleEQ applies the EQ predicate on the "title" field.

func TitleEqualFold

func TitleEqualFold(v string) predicate.Document

TitleEqualFold applies the EqualFold predicate on the "title" field.

func TitleGT

func TitleGT(v string) predicate.Document

TitleGT applies the GT predicate on the "title" field.

func TitleGTE

func TitleGTE(v string) predicate.Document

TitleGTE applies the GTE predicate on the "title" field.

func TitleHasPrefix

func TitleHasPrefix(v string) predicate.Document

TitleHasPrefix applies the HasPrefix predicate on the "title" field.

func TitleHasSuffix

func TitleHasSuffix(v string) predicate.Document

TitleHasSuffix applies the HasSuffix predicate on the "title" field.

func TitleIn

func TitleIn(vs ...string) predicate.Document

TitleIn applies the In predicate on the "title" field.

func TitleLT

func TitleLT(v string) predicate.Document

TitleLT applies the LT predicate on the "title" field.

func TitleLTE

func TitleLTE(v string) predicate.Document

TitleLTE applies the LTE predicate on the "title" field.

func TitleNEQ

func TitleNEQ(v string) predicate.Document

TitleNEQ applies the NEQ predicate on the "title" field.

func TitleNotIn

func TitleNotIn(vs ...string) predicate.Document

TitleNotIn applies the NotIn predicate on the "title" field.

func UUID

func UUID(v uuid.UUID) predicate.Document

UUID applies equality check predicate on the "uuid" field. It's identical to UUIDEQ.

func UUIDEQ

func UUIDEQ(v uuid.UUID) predicate.Document

UUIDEQ applies the EQ predicate on the "uuid" field.

func UUIDGT

func UUIDGT(v uuid.UUID) predicate.Document

UUIDGT applies the GT predicate on the "uuid" field.

func UUIDGTE

func UUIDGTE(v uuid.UUID) predicate.Document

UUIDGTE applies the GTE predicate on the "uuid" field.

func UUIDIn

func UUIDIn(vs ...uuid.UUID) predicate.Document

UUIDIn applies the In predicate on the "uuid" field.

func UUIDLT

func UUIDLT(v uuid.UUID) predicate.Document

UUIDLT applies the LT predicate on the "uuid" field.

func UUIDLTE

func UUIDLTE(v uuid.UUID) predicate.Document

UUIDLTE applies the LTE predicate on the "uuid" field.

func UUIDNEQ

func UUIDNEQ(v uuid.UUID) predicate.Document

UUIDNEQ applies the NEQ predicate on the "uuid" field.

func UUIDNotIn

func UUIDNotIn(vs ...uuid.UUID) predicate.Document

UUIDNotIn applies the NotIn predicate on the "uuid" field.

func UpdatedAt

func UpdatedAt(v time.Time) predicate.Document

UpdatedAt applies equality check predicate on the "updated_at" field. It's identical to UpdatedAtEQ.

func UpdatedAtEQ

func UpdatedAtEQ(v time.Time) predicate.Document

UpdatedAtEQ applies the EQ predicate on the "updated_at" field.

func UpdatedAtGT

func UpdatedAtGT(v time.Time) predicate.Document

UpdatedAtGT applies the GT predicate on the "updated_at" field.

func UpdatedAtGTE

func UpdatedAtGTE(v time.Time) predicate.Document

UpdatedAtGTE applies the GTE predicate on the "updated_at" field.

func UpdatedAtIn

func UpdatedAtIn(vs ...time.Time) predicate.Document

UpdatedAtIn applies the In predicate on the "updated_at" field.

func UpdatedAtLT

func UpdatedAtLT(v time.Time) predicate.Document

UpdatedAtLT applies the LT predicate on the "updated_at" field.

func UpdatedAtLTE

func UpdatedAtLTE(v time.Time) predicate.Document

UpdatedAtLTE applies the LTE predicate on the "updated_at" field.

func UpdatedAtNEQ

func UpdatedAtNEQ(v time.Time) predicate.Document

UpdatedAtNEQ applies the NEQ predicate on the "updated_at" field.

func UpdatedAtNotIn

func UpdatedAtNotIn(vs ...time.Time) predicate.Document

UpdatedAtNotIn applies the NotIn predicate on the "updated_at" field.

func ValidColumn

func ValidColumn(column string) bool

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

Types

This section is empty.

Jump to

Keyboard shortcuts

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