artifact

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2023 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the artifact type in the database.
	Label = "artifact"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "id"
	// FieldAlgorithm holds the string denoting the algorithm field in the database.
	FieldAlgorithm = "algorithm"
	// FieldDigest holds the string denoting the digest field in the database.
	FieldDigest = "digest"
	// EdgeOccurrences holds the string denoting the occurrences edge name in mutations.
	EdgeOccurrences = "occurrences"
	// EdgeSbom holds the string denoting the sbom edge name in mutations.
	EdgeSbom = "sbom"
	// EdgeAttestations holds the string denoting the attestations edge name in mutations.
	EdgeAttestations = "attestations"
	// EdgeSame holds the string denoting the same edge name in mutations.
	EdgeSame = "same"
	// Table holds the table name of the artifact in the database.
	Table = "artifacts"
	// OccurrencesTable is the table that holds the occurrences relation/edge.
	OccurrencesTable = "occurrences"
	// OccurrencesInverseTable is the table name for the Occurrence entity.
	// It exists in this package in order to avoid circular dependency with the "occurrence" package.
	OccurrencesInverseTable = "occurrences"
	// OccurrencesColumn is the table column denoting the occurrences relation/edge.
	OccurrencesColumn = "artifact_id"
	// SbomTable is the table that holds the sbom relation/edge.
	SbomTable = "bill_of_materials"
	// SbomInverseTable is the table name for the BillOfMaterials entity.
	// It exists in this package in order to avoid circular dependency with the "billofmaterials" package.
	SbomInverseTable = "bill_of_materials"
	// SbomColumn is the table column denoting the sbom relation/edge.
	SbomColumn = "artifact_id"
	// AttestationsTable is the table that holds the attestations relation/edge. The primary key declared below.
	AttestationsTable = "slsa_attestation_built_from"
	// AttestationsInverseTable is the table name for the SLSAAttestation entity.
	// It exists in this package in order to avoid circular dependency with the "slsaattestation" package.
	AttestationsInverseTable = "slsa_attestations"
	// SameTable is the table that holds the same relation/edge. The primary key declared below.
	SameTable = "hash_equal_artifacts"
	// SameInverseTable is the table name for the HashEqual entity.
	// It exists in this package in order to avoid circular dependency with the "hashequal" package.
	SameInverseTable = "hash_equals"
)

Variables

View Source
var (
	// AttestationsPrimaryKey and AttestationsColumn2 are the table columns denoting the
	// primary key for the attestations relation (M2M).
	AttestationsPrimaryKey = []string{"slsa_attestation_id", "artifact_id"}
	// SamePrimaryKey and SameColumn2 are the table columns denoting the
	// primary key for the same relation (M2M).
	SamePrimaryKey = []string{"hash_equal_id", "artifact_id"}
)

Columns holds all SQL columns for artifact fields.

Functions

func Algorithm

func Algorithm(v string) predicate.Artifact

Algorithm applies equality check predicate on the "algorithm" field. It's identical to AlgorithmEQ.

func AlgorithmContains

func AlgorithmContains(v string) predicate.Artifact

AlgorithmContains applies the Contains predicate on the "algorithm" field.

func AlgorithmContainsFold

func AlgorithmContainsFold(v string) predicate.Artifact

AlgorithmContainsFold applies the ContainsFold predicate on the "algorithm" field.

func AlgorithmEQ

func AlgorithmEQ(v string) predicate.Artifact

AlgorithmEQ applies the EQ predicate on the "algorithm" field.

func AlgorithmEqualFold

func AlgorithmEqualFold(v string) predicate.Artifact

AlgorithmEqualFold applies the EqualFold predicate on the "algorithm" field.

func AlgorithmGT

func AlgorithmGT(v string) predicate.Artifact

AlgorithmGT applies the GT predicate on the "algorithm" field.

func AlgorithmGTE

func AlgorithmGTE(v string) predicate.Artifact

AlgorithmGTE applies the GTE predicate on the "algorithm" field.

func AlgorithmHasPrefix

func AlgorithmHasPrefix(v string) predicate.Artifact

AlgorithmHasPrefix applies the HasPrefix predicate on the "algorithm" field.

func AlgorithmHasSuffix

func AlgorithmHasSuffix(v string) predicate.Artifact

AlgorithmHasSuffix applies the HasSuffix predicate on the "algorithm" field.

func AlgorithmIn

func AlgorithmIn(vs ...string) predicate.Artifact

AlgorithmIn applies the In predicate on the "algorithm" field.

func AlgorithmLT

func AlgorithmLT(v string) predicate.Artifact

AlgorithmLT applies the LT predicate on the "algorithm" field.

func AlgorithmLTE

func AlgorithmLTE(v string) predicate.Artifact

AlgorithmLTE applies the LTE predicate on the "algorithm" field.

func AlgorithmNEQ

func AlgorithmNEQ(v string) predicate.Artifact

AlgorithmNEQ applies the NEQ predicate on the "algorithm" field.

func AlgorithmNotIn

func AlgorithmNotIn(vs ...string) predicate.Artifact

AlgorithmNotIn applies the NotIn predicate on the "algorithm" field.

func And

func And(predicates ...predicate.Artifact) predicate.Artifact

And groups predicates with the AND operator between them.

func Digest

func Digest(v string) predicate.Artifact

Digest applies equality check predicate on the "digest" field. It's identical to DigestEQ.

func DigestContains

func DigestContains(v string) predicate.Artifact

DigestContains applies the Contains predicate on the "digest" field.

func DigestContainsFold

func DigestContainsFold(v string) predicate.Artifact

DigestContainsFold applies the ContainsFold predicate on the "digest" field.

func DigestEQ

func DigestEQ(v string) predicate.Artifact

DigestEQ applies the EQ predicate on the "digest" field.

func DigestEqualFold

func DigestEqualFold(v string) predicate.Artifact

DigestEqualFold applies the EqualFold predicate on the "digest" field.

func DigestGT

func DigestGT(v string) predicate.Artifact

DigestGT applies the GT predicate on the "digest" field.

func DigestGTE

func DigestGTE(v string) predicate.Artifact

DigestGTE applies the GTE predicate on the "digest" field.

func DigestHasPrefix

func DigestHasPrefix(v string) predicate.Artifact

DigestHasPrefix applies the HasPrefix predicate on the "digest" field.

func DigestHasSuffix

func DigestHasSuffix(v string) predicate.Artifact

DigestHasSuffix applies the HasSuffix predicate on the "digest" field.

func DigestIn

func DigestIn(vs ...string) predicate.Artifact

DigestIn applies the In predicate on the "digest" field.

func DigestLT

func DigestLT(v string) predicate.Artifact

DigestLT applies the LT predicate on the "digest" field.

func DigestLTE

func DigestLTE(v string) predicate.Artifact

DigestLTE applies the LTE predicate on the "digest" field.

func DigestNEQ

func DigestNEQ(v string) predicate.Artifact

DigestNEQ applies the NEQ predicate on the "digest" field.

func DigestNotIn

func DigestNotIn(vs ...string) predicate.Artifact

DigestNotIn applies the NotIn predicate on the "digest" field.

func HasAttestations

func HasAttestations() predicate.Artifact

HasAttestations applies the HasEdge predicate on the "attestations" edge.

func HasAttestationsWith

func HasAttestationsWith(preds ...predicate.SLSAAttestation) predicate.Artifact

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

func HasOccurrences

func HasOccurrences() predicate.Artifact

HasOccurrences applies the HasEdge predicate on the "occurrences" edge.

func HasOccurrencesWith

func HasOccurrencesWith(preds ...predicate.Occurrence) predicate.Artifact

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

func HasSame

func HasSame() predicate.Artifact

HasSame applies the HasEdge predicate on the "same" edge.

func HasSameWith

func HasSameWith(preds ...predicate.HashEqual) predicate.Artifact

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

func HasSbom

func HasSbom() predicate.Artifact

HasSbom applies the HasEdge predicate on the "sbom" edge.

func HasSbomWith

func HasSbomWith(preds ...predicate.BillOfMaterials) predicate.Artifact

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

func ID

func ID(id int) predicate.Artifact

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id int) predicate.Artifact

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id int) predicate.Artifact

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id int) predicate.Artifact

IDGTE applies the GTE predicate on the ID field.

func IDIn

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

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id int) predicate.Artifact

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id int) predicate.Artifact

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id int) predicate.Artifact

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

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

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

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

func ByAlgorithm

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

ByAlgorithm orders the results by the algorithm field.

func ByAttestations

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

ByAttestations orders the results by attestations terms.

func ByAttestationsCount

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

ByAttestationsCount orders the results by attestations count.

func ByDigest

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

ByDigest orders the results by the digest field.

func ByID

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

ByID orders the results by the id field.

func ByOccurrences

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

ByOccurrences orders the results by occurrences terms.

func ByOccurrencesCount

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

ByOccurrencesCount orders the results by occurrences count.

func BySame

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

BySame orders the results by same terms.

func BySameCount

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

BySameCount orders the results by same count.

func BySbom

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

BySbom orders the results by sbom terms.

func BySbomCount

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

BySbomCount orders the results by sbom count.

Jump to

Keyboard shortcuts

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