machinechanneltoken

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the machinechanneltoken type in the database.
	Label = "machine_channel_token"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "id"
	// FieldMachineID holds the string denoting the machine_id field in the database.
	FieldMachineID = "machine_id"
	// FieldTokenHash holds the string denoting the token_hash field in the database.
	FieldTokenHash = "token_hash"
	// FieldStatus holds the string denoting the status field in the database.
	FieldStatus = "status"
	// FieldExpiresAt holds the string denoting the expires_at field in the database.
	FieldExpiresAt = "expires_at"
	// FieldCreatedAt holds the string denoting the created_at field in the database.
	FieldCreatedAt = "created_at"
	// FieldLastUsedAt holds the string denoting the last_used_at field in the database.
	FieldLastUsedAt = "last_used_at"
	// FieldRevokedAt holds the string denoting the revoked_at field in the database.
	FieldRevokedAt = "revoked_at"
	// EdgeMachine holds the string denoting the machine edge name in mutations.
	EdgeMachine = "machine"
	// Table holds the table name of the machinechanneltoken in the database.
	Table = "machine_channel_tokens"
	// MachineTable is the table that holds the machine relation/edge.
	MachineTable = "machine_channel_tokens"
	// MachineInverseTable is the table name for the Machine entity.
	// It exists in this package in order to avoid circular dependency with the "machine" package.
	MachineInverseTable = "machines"
	// MachineColumn is the table column denoting the machine relation/edge.
	MachineColumn = "machine_id"
)
View Source
const DefaultStatus = StatusActive

StatusActive is the default value of the Status enum.

Variables

View Source
var (
	// TokenHashValidator is a validator for the "token_hash" field. It is called by the builders before save.
	TokenHashValidator func(string) error
	// DefaultCreatedAt holds the default value on creation for the "created_at" field.
	DefaultCreatedAt func() time.Time
	// DefaultID holds the default value on creation for the "id" field.
	DefaultID func() uuid.UUID
)

Columns holds all SQL columns for machinechanneltoken fields.

Functions

func And

And groups predicates with the AND operator between them.

func CreatedAt

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

func CreatedAtEQ

func CreatedAtEQ(v time.Time) predicate.MachineChannelToken

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

func CreatedAtGT

func CreatedAtGT(v time.Time) predicate.MachineChannelToken

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

func CreatedAtGTE

func CreatedAtGTE(v time.Time) predicate.MachineChannelToken

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

func CreatedAtIn

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

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

func CreatedAtLT

func CreatedAtLT(v time.Time) predicate.MachineChannelToken

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

func CreatedAtLTE

func CreatedAtLTE(v time.Time) predicate.MachineChannelToken

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

func CreatedAtNEQ

func CreatedAtNEQ(v time.Time) predicate.MachineChannelToken

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

func CreatedAtNotIn

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

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

func ExpiresAt

ExpiresAt applies equality check predicate on the "expires_at" field. It's identical to ExpiresAtEQ.

func ExpiresAtEQ

func ExpiresAtEQ(v time.Time) predicate.MachineChannelToken

ExpiresAtEQ applies the EQ predicate on the "expires_at" field.

func ExpiresAtGT

func ExpiresAtGT(v time.Time) predicate.MachineChannelToken

ExpiresAtGT applies the GT predicate on the "expires_at" field.

func ExpiresAtGTE

func ExpiresAtGTE(v time.Time) predicate.MachineChannelToken

ExpiresAtGTE applies the GTE predicate on the "expires_at" field.

func ExpiresAtIn

func ExpiresAtIn(vs ...time.Time) predicate.MachineChannelToken

ExpiresAtIn applies the In predicate on the "expires_at" field.

func ExpiresAtLT

func ExpiresAtLT(v time.Time) predicate.MachineChannelToken

ExpiresAtLT applies the LT predicate on the "expires_at" field.

func ExpiresAtLTE

func ExpiresAtLTE(v time.Time) predicate.MachineChannelToken

ExpiresAtLTE applies the LTE predicate on the "expires_at" field.

func ExpiresAtNEQ

func ExpiresAtNEQ(v time.Time) predicate.MachineChannelToken

ExpiresAtNEQ applies the NEQ predicate on the "expires_at" field.

func ExpiresAtNotIn

func ExpiresAtNotIn(vs ...time.Time) predicate.MachineChannelToken

ExpiresAtNotIn applies the NotIn predicate on the "expires_at" field.

func HasMachine

func HasMachine() predicate.MachineChannelToken

HasMachine applies the HasEdge predicate on the "machine" edge.

func HasMachineWith

func HasMachineWith(preds ...predicate.Machine) predicate.MachineChannelToken

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

func ID

ID filters vertices based on their ID field.

func IDEQ

IDEQ applies the EQ 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

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 ...uuid.UUID) predicate.MachineChannelToken

IDNotIn applies the NotIn predicate on the ID field.

func LastUsedAt

func LastUsedAt(v time.Time) predicate.MachineChannelToken

LastUsedAt applies equality check predicate on the "last_used_at" field. It's identical to LastUsedAtEQ.

func LastUsedAtEQ

func LastUsedAtEQ(v time.Time) predicate.MachineChannelToken

LastUsedAtEQ applies the EQ predicate on the "last_used_at" field.

func LastUsedAtGT

func LastUsedAtGT(v time.Time) predicate.MachineChannelToken

LastUsedAtGT applies the GT predicate on the "last_used_at" field.

func LastUsedAtGTE

func LastUsedAtGTE(v time.Time) predicate.MachineChannelToken

LastUsedAtGTE applies the GTE predicate on the "last_used_at" field.

func LastUsedAtIn

func LastUsedAtIn(vs ...time.Time) predicate.MachineChannelToken

LastUsedAtIn applies the In predicate on the "last_used_at" field.

func LastUsedAtIsNil

func LastUsedAtIsNil() predicate.MachineChannelToken

LastUsedAtIsNil applies the IsNil predicate on the "last_used_at" field.

func LastUsedAtLT

func LastUsedAtLT(v time.Time) predicate.MachineChannelToken

LastUsedAtLT applies the LT predicate on the "last_used_at" field.

func LastUsedAtLTE

func LastUsedAtLTE(v time.Time) predicate.MachineChannelToken

LastUsedAtLTE applies the LTE predicate on the "last_used_at" field.

func LastUsedAtNEQ

func LastUsedAtNEQ(v time.Time) predicate.MachineChannelToken

LastUsedAtNEQ applies the NEQ predicate on the "last_used_at" field.

func LastUsedAtNotIn

func LastUsedAtNotIn(vs ...time.Time) predicate.MachineChannelToken

LastUsedAtNotIn applies the NotIn predicate on the "last_used_at" field.

func LastUsedAtNotNil

func LastUsedAtNotNil() predicate.MachineChannelToken

LastUsedAtNotNil applies the NotNil predicate on the "last_used_at" field.

func MachineID

MachineID applies equality check predicate on the "machine_id" field. It's identical to MachineIDEQ.

func MachineIDEQ

func MachineIDEQ(v uuid.UUID) predicate.MachineChannelToken

MachineIDEQ applies the EQ predicate on the "machine_id" field.

func MachineIDIn

func MachineIDIn(vs ...uuid.UUID) predicate.MachineChannelToken

MachineIDIn applies the In predicate on the "machine_id" field.

func MachineIDNEQ

func MachineIDNEQ(v uuid.UUID) predicate.MachineChannelToken

MachineIDNEQ applies the NEQ predicate on the "machine_id" field.

func MachineIDNotIn

func MachineIDNotIn(vs ...uuid.UUID) predicate.MachineChannelToken

MachineIDNotIn applies the NotIn predicate on the "machine_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 RevokedAt

RevokedAt applies equality check predicate on the "revoked_at" field. It's identical to RevokedAtEQ.

func RevokedAtEQ

func RevokedAtEQ(v time.Time) predicate.MachineChannelToken

RevokedAtEQ applies the EQ predicate on the "revoked_at" field.

func RevokedAtGT

func RevokedAtGT(v time.Time) predicate.MachineChannelToken

RevokedAtGT applies the GT predicate on the "revoked_at" field.

func RevokedAtGTE

func RevokedAtGTE(v time.Time) predicate.MachineChannelToken

RevokedAtGTE applies the GTE predicate on the "revoked_at" field.

func RevokedAtIn

func RevokedAtIn(vs ...time.Time) predicate.MachineChannelToken

RevokedAtIn applies the In predicate on the "revoked_at" field.

func RevokedAtIsNil

func RevokedAtIsNil() predicate.MachineChannelToken

RevokedAtIsNil applies the IsNil predicate on the "revoked_at" field.

func RevokedAtLT

func RevokedAtLT(v time.Time) predicate.MachineChannelToken

RevokedAtLT applies the LT predicate on the "revoked_at" field.

func RevokedAtLTE

func RevokedAtLTE(v time.Time) predicate.MachineChannelToken

RevokedAtLTE applies the LTE predicate on the "revoked_at" field.

func RevokedAtNEQ

func RevokedAtNEQ(v time.Time) predicate.MachineChannelToken

RevokedAtNEQ applies the NEQ predicate on the "revoked_at" field.

func RevokedAtNotIn

func RevokedAtNotIn(vs ...time.Time) predicate.MachineChannelToken

RevokedAtNotIn applies the NotIn predicate on the "revoked_at" field.

func RevokedAtNotNil

func RevokedAtNotNil() predicate.MachineChannelToken

RevokedAtNotNil applies the NotNil predicate on the "revoked_at" field.

func StatusEQ

StatusEQ applies the EQ predicate on the "status" field.

func StatusIn

func StatusIn(vs ...Status) predicate.MachineChannelToken

StatusIn applies the In predicate on the "status" field.

func StatusNEQ

StatusNEQ applies the NEQ predicate on the "status" field.

func StatusNotIn

func StatusNotIn(vs ...Status) predicate.MachineChannelToken

StatusNotIn applies the NotIn predicate on the "status" field.

func StatusValidator

func StatusValidator(s Status) error

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

func TokenHash

TokenHash applies equality check predicate on the "token_hash" field. It's identical to TokenHashEQ.

func TokenHashContains

func TokenHashContains(v string) predicate.MachineChannelToken

TokenHashContains applies the Contains predicate on the "token_hash" field.

func TokenHashContainsFold

func TokenHashContainsFold(v string) predicate.MachineChannelToken

TokenHashContainsFold applies the ContainsFold predicate on the "token_hash" field.

func TokenHashEQ

func TokenHashEQ(v string) predicate.MachineChannelToken

TokenHashEQ applies the EQ predicate on the "token_hash" field.

func TokenHashEqualFold

func TokenHashEqualFold(v string) predicate.MachineChannelToken

TokenHashEqualFold applies the EqualFold predicate on the "token_hash" field.

func TokenHashGT

func TokenHashGT(v string) predicate.MachineChannelToken

TokenHashGT applies the GT predicate on the "token_hash" field.

func TokenHashGTE

func TokenHashGTE(v string) predicate.MachineChannelToken

TokenHashGTE applies the GTE predicate on the "token_hash" field.

func TokenHashHasPrefix

func TokenHashHasPrefix(v string) predicate.MachineChannelToken

TokenHashHasPrefix applies the HasPrefix predicate on the "token_hash" field.

func TokenHashHasSuffix

func TokenHashHasSuffix(v string) predicate.MachineChannelToken

TokenHashHasSuffix applies the HasSuffix predicate on the "token_hash" field.

func TokenHashIn

func TokenHashIn(vs ...string) predicate.MachineChannelToken

TokenHashIn applies the In predicate on the "token_hash" field.

func TokenHashLT

func TokenHashLT(v string) predicate.MachineChannelToken

TokenHashLT applies the LT predicate on the "token_hash" field.

func TokenHashLTE

func TokenHashLTE(v string) predicate.MachineChannelToken

TokenHashLTE applies the LTE predicate on the "token_hash" field.

func TokenHashNEQ

func TokenHashNEQ(v string) predicate.MachineChannelToken

TokenHashNEQ applies the NEQ predicate on the "token_hash" field.

func TokenHashNotIn

func TokenHashNotIn(vs ...string) predicate.MachineChannelToken

TokenHashNotIn applies the NotIn predicate on the "token_hash" field.

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 MachineChannelToken queries.

func ByCreatedAt

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

ByCreatedAt orders the results by the created_at field.

func ByExpiresAt

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

ByExpiresAt orders the results by the expires_at field.

func ByID

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

ByID orders the results by the id field.

func ByLastUsedAt

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

ByLastUsedAt orders the results by the last_used_at field.

func ByMachineField

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

ByMachineField orders the results by machine field.

func ByMachineID

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

ByMachineID orders the results by the machine_id field.

func ByRevokedAt

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

ByRevokedAt orders the results by the revoked_at field.

func ByStatus

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

ByStatus orders the results by the status field.

func ByTokenHash

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

ByTokenHash orders the results by the token_hash field.

type Status

type Status string

Status defines the type for the "status" enum field.

const (
	StatusActive  Status = "active"
	StatusRevoked Status = "revoked"
)

Status values.

func (Status) String

func (s Status) String() string

Jump to

Keyboard shortcuts

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