sense

package
v0.0.0-...-192b5dc Latest Latest
Warning

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

Go to latest
Published: Dec 2, 2024 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the sense type in the database.
	Label = "sense"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "id"
	// EdgeSynset holds the string denoting the synset edge name in mutations.
	EdgeSynset = "synset"
	// EdgeLemma holds the string denoting the lemma edge name in mutations.
	EdgeLemma = "lemma"
	// EdgeRelFrom holds the string denoting the relfrom edge name in mutations.
	EdgeRelFrom = "relFrom"
	// EdgeRelTo holds the string denoting the relto edge name in mutations.
	EdgeRelTo = "relTo"
	// Table holds the table name of the sense in the database.
	Table = "senses"
	// SynsetTable is the table that holds the synset relation/edge.
	SynsetTable = "senses"
	// SynsetInverseTable is the table name for the Synset entity.
	// It exists in this package in order to avoid circular dependency with the "synset" package.
	SynsetInverseTable = "synsets"
	// SynsetColumn is the table column denoting the synset relation/edge.
	SynsetColumn = "sense_synset"
	// LemmaTable is the table that holds the lemma relation/edge.
	LemmaTable = "senses"
	// LemmaInverseTable is the table name for the Lemma entity.
	// It exists in this package in order to avoid circular dependency with the "lemma" package.
	LemmaInverseTable = "lemmas"
	// LemmaColumn is the table column denoting the lemma relation/edge.
	LemmaColumn = "sense_lemma"
	// RelFromTable is the table that holds the relFrom relation/edge.
	RelFromTable = "sense_relations"
	// RelFromInverseTable is the table name for the SenseRelation entity.
	// It exists in this package in order to avoid circular dependency with the "senserelation" package.
	RelFromInverseTable = "sense_relations"
	// RelFromColumn is the table column denoting the relFrom relation/edge.
	RelFromColumn = "sense_relation_to"
	// RelToTable is the table that holds the relTo relation/edge.
	RelToTable = "sense_relations"
	// RelToInverseTable is the table name for the SenseRelation entity.
	// It exists in this package in order to avoid circular dependency with the "senserelation" package.
	RelToInverseTable = "sense_relations"
	// RelToColumn is the table column denoting the relTo relation/edge.
	RelToColumn = "sense_relation_from"
)

Variables

View Source
var Columns = []string{
	FieldID,
}

Columns holds all SQL columns for sense fields.

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

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

View Source
var (
	// IDValidator is a validator for the "id" field. It is called by the builders before save.
	IDValidator func(string) error
)

Functions

func And

func And(predicates ...predicate.Sense) predicate.Sense

And groups predicates with the AND operator between them.

func HasLemma

func HasLemma() predicate.Sense

HasLemma applies the HasEdge predicate on the "lemma" edge.

func HasLemmaWith

func HasLemmaWith(preds ...predicate.Lemma) predicate.Sense

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

func HasRelFrom

func HasRelFrom() predicate.Sense

HasRelFrom applies the HasEdge predicate on the "relFrom" edge.

func HasRelFromWith

func HasRelFromWith(preds ...predicate.SenseRelation) predicate.Sense

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

func HasRelTo

func HasRelTo() predicate.Sense

HasRelTo applies the HasEdge predicate on the "relTo" edge.

func HasRelToWith

func HasRelToWith(preds ...predicate.SenseRelation) predicate.Sense

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

func HasSynset

func HasSynset() predicate.Sense

HasSynset applies the HasEdge predicate on the "synset" edge.

func HasSynsetWith

func HasSynsetWith(preds ...predicate.Synset) predicate.Sense

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

func ID

func ID(id string) predicate.Sense

ID filters vertices based on their ID field.

func IDContainsFold

func IDContainsFold(id string) predicate.Sense

IDContainsFold applies the ContainsFold predicate on the ID field.

func IDEQ

func IDEQ(id string) predicate.Sense

IDEQ applies the EQ predicate on the ID field.

func IDEqualFold

func IDEqualFold(id string) predicate.Sense

IDEqualFold applies the EqualFold predicate on the ID field.

func IDGT

func IDGT(id string) predicate.Sense

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id string) predicate.Sense

IDGTE applies the GTE predicate on the ID field.

func IDIn

func IDIn(ids ...string) predicate.Sense

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id string) predicate.Sense

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id string) predicate.Sense

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id string) predicate.Sense

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

func IDNotIn(ids ...string) predicate.Sense

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

Or groups predicates with the OR operator between them.

func ValidColumn

func ValidColumn(column string) bool

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

Types

type OrderOption

type OrderOption func(*sql.Selector)

OrderOption defines the ordering options for the Sense queries.

func ByID

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

ByID orders the results by the id field.

func ByLemmaField

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

ByLemmaField orders the results by lemma field.

func ByRelFrom

func ByRelFrom(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption

ByRelFrom orders the results by relFrom terms.

func ByRelFromCount

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

ByRelFromCount orders the results by relFrom count.

func ByRelTo

func ByRelTo(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption

ByRelTo orders the results by relTo terms.

func ByRelToCount

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

ByRelToCount orders the results by relTo count.

func BySynsetField

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

BySynsetField orders the results by synset field.

Jump to

Keyboard shortcuts

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