distributelock

package
v0.5.0-rc2 Latest Latest
Warning

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

Go to latest
Published: Jan 22, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the distributelock type in the database.
	Label = "distribute_lock"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "id"
	// FieldExpireAt holds the string denoting the expireat field in the database.
	FieldExpireAt = "expire_at"
	// FieldHolder holds the string denoting the holder field in the database.
	FieldHolder = "holder"
	// Table holds the table name of the distributelock in the database.
	Table = "distribute_locks"
)

Variables

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

Columns holds all SQL columns for distributelock fields.

Functions

func And

And groups predicates with the AND operator between them.

func ExpireAt

func ExpireAt(v int64) predicate.DistributeLock

ExpireAt applies equality check predicate on the "expireAt" field. It's identical to ExpireAtEQ.

func ExpireAtEQ

func ExpireAtEQ(v int64) predicate.DistributeLock

ExpireAtEQ applies the EQ predicate on the "expireAt" field.

func ExpireAtGT

func ExpireAtGT(v int64) predicate.DistributeLock

ExpireAtGT applies the GT predicate on the "expireAt" field.

func ExpireAtGTE

func ExpireAtGTE(v int64) predicate.DistributeLock

ExpireAtGTE applies the GTE predicate on the "expireAt" field.

func ExpireAtIn

func ExpireAtIn(vs ...int64) predicate.DistributeLock

ExpireAtIn applies the In predicate on the "expireAt" field.

func ExpireAtLT

func ExpireAtLT(v int64) predicate.DistributeLock

ExpireAtLT applies the LT predicate on the "expireAt" field.

func ExpireAtLTE

func ExpireAtLTE(v int64) predicate.DistributeLock

ExpireAtLTE applies the LTE predicate on the "expireAt" field.

func ExpireAtNEQ

func ExpireAtNEQ(v int64) predicate.DistributeLock

ExpireAtNEQ applies the NEQ predicate on the "expireAt" field.

func ExpireAtNotIn

func ExpireAtNotIn(vs ...int64) predicate.DistributeLock

ExpireAtNotIn applies the NotIn predicate on the "expireAt" field.

func Holder

Holder applies equality check predicate on the "holder" field. It's identical to HolderEQ.

func HolderContains

func HolderContains(v string) predicate.DistributeLock

HolderContains applies the Contains predicate on the "holder" field.

func HolderContainsFold

func HolderContainsFold(v string) predicate.DistributeLock

HolderContainsFold applies the ContainsFold predicate on the "holder" field.

func HolderEQ

func HolderEQ(v string) predicate.DistributeLock

HolderEQ applies the EQ predicate on the "holder" field.

func HolderEqualFold

func HolderEqualFold(v string) predicate.DistributeLock

HolderEqualFold applies the EqualFold predicate on the "holder" field.

func HolderGT

func HolderGT(v string) predicate.DistributeLock

HolderGT applies the GT predicate on the "holder" field.

func HolderGTE

func HolderGTE(v string) predicate.DistributeLock

HolderGTE applies the GTE predicate on the "holder" field.

func HolderHasPrefix

func HolderHasPrefix(v string) predicate.DistributeLock

HolderHasPrefix applies the HasPrefix predicate on the "holder" field.

func HolderHasSuffix

func HolderHasSuffix(v string) predicate.DistributeLock

HolderHasSuffix applies the HasSuffix predicate on the "holder" field.

func HolderIn

func HolderIn(vs ...string) predicate.DistributeLock

HolderIn applies the In predicate on the "holder" field.

func HolderLT

func HolderLT(v string) predicate.DistributeLock

HolderLT applies the LT predicate on the "holder" field.

func HolderLTE

func HolderLTE(v string) predicate.DistributeLock

HolderLTE applies the LTE predicate on the "holder" field.

func HolderNEQ

func HolderNEQ(v string) predicate.DistributeLock

HolderNEQ applies the NEQ predicate on the "holder" field.

func HolderNotIn

func HolderNotIn(vs ...string) predicate.DistributeLock

HolderNotIn applies the NotIn predicate on the "holder" field.

func ID

ID filters vertices based on their ID field.

func IDContainsFold

func IDContainsFold(id string) predicate.DistributeLock

IDContainsFold applies the ContainsFold predicate on the ID field.

func IDEQ

IDEQ applies the EQ predicate on the ID field.

func IDEqualFold

func IDEqualFold(id string) predicate.DistributeLock

IDEqualFold applies the EqualFold predicate on the ID field.

func IDGT

IDGT applies the GT predicate on the ID field.

func IDGTE

IDGTE applies the GTE predicate on the ID field.

func IDIn

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

IDIn applies the In predicate on the ID field.

func IDLT

IDLT applies the LT predicate on the ID field.

func IDLTE

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

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

IDNotIn applies the NotIn predicate on the ID field.

func Not

Not applies the not operator on the given predicate.

func Or

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

func WithoutFields

func WithoutFields(ignores ...string) []string

WithoutFields returns the fields ignored the given list.

Types

type OrderOption

type OrderOption func(*sql.Selector)

OrderOption defines the ordering options for the DistributeLock queries.

func ByExpireAt

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

ByExpireAt orders the results by the expireAt field.

func ByHolder

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

ByHolder orders the results by the holder field.

func ByID

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

ByID orders the results by the id field.

Jump to

Keyboard shortcuts

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