Documentation
¶
Index ¶
- Constants
- Variables
- func And(predicates ...predicate.Audit) predicate.Audit
- func CreatedAt(v time.Time) predicate.Audit
- func CreatedAtEQ(v time.Time) predicate.Audit
- func CreatedAtGT(v time.Time) predicate.Audit
- func CreatedAtGTE(v time.Time) predicate.Audit
- func CreatedAtIn(vs ...time.Time) predicate.Audit
- func CreatedAtLT(v time.Time) predicate.Audit
- func CreatedAtLTE(v time.Time) predicate.Audit
- func CreatedAtNEQ(v time.Time) predicate.Audit
- func CreatedAtNotIn(vs ...time.Time) predicate.Audit
- func HasUser() predicate.Audit
- func HasUserWith(preds ...predicate.User) predicate.Audit
- func ID(id uuid.UUID) predicate.Audit
- func IDEQ(id uuid.UUID) predicate.Audit
- func IDGT(id uuid.UUID) predicate.Audit
- func IDGTE(id uuid.UUID) predicate.Audit
- func IDIn(ids ...uuid.UUID) predicate.Audit
- func IDLT(id uuid.UUID) predicate.Audit
- func IDLTE(id uuid.UUID) predicate.Audit
- func IDNEQ(id uuid.UUID) predicate.Audit
- func IDNotIn(ids ...uuid.UUID) predicate.Audit
- func Not(p predicate.Audit) predicate.Audit
- func Operation(v string) predicate.Audit
- func OperationContains(v string) predicate.Audit
- func OperationContainsFold(v string) predicate.Audit
- func OperationEQ(v string) predicate.Audit
- func OperationEqualFold(v string) predicate.Audit
- func OperationGT(v string) predicate.Audit
- func OperationGTE(v string) predicate.Audit
- func OperationHasPrefix(v string) predicate.Audit
- func OperationHasSuffix(v string) predicate.Audit
- func OperationIn(vs ...string) predicate.Audit
- func OperationLT(v string) predicate.Audit
- func OperationLTE(v string) predicate.Audit
- func OperationNEQ(v string) predicate.Audit
- func OperationNotIn(vs ...string) predicate.Audit
- func Or(predicates ...predicate.Audit) predicate.Audit
- func Request(v string) predicate.Audit
- func RequestContains(v string) predicate.Audit
- func RequestContainsFold(v string) predicate.Audit
- func RequestEQ(v string) predicate.Audit
- func RequestEqualFold(v string) predicate.Audit
- func RequestGT(v string) predicate.Audit
- func RequestGTE(v string) predicate.Audit
- func RequestHasPrefix(v string) predicate.Audit
- func RequestHasSuffix(v string) predicate.Audit
- func RequestIn(vs ...string) predicate.Audit
- func RequestLT(v string) predicate.Audit
- func RequestLTE(v string) predicate.Audit
- func RequestNEQ(v string) predicate.Audit
- func RequestNotIn(vs ...string) predicate.Audit
- func Response(v string) predicate.Audit
- func ResponseContains(v string) predicate.Audit
- func ResponseContainsFold(v string) predicate.Audit
- func ResponseEQ(v string) predicate.Audit
- func ResponseEqualFold(v string) predicate.Audit
- func ResponseGT(v string) predicate.Audit
- func ResponseGTE(v string) predicate.Audit
- func ResponseHasPrefix(v string) predicate.Audit
- func ResponseHasSuffix(v string) predicate.Audit
- func ResponseIn(vs ...string) predicate.Audit
- func ResponseIsNil() predicate.Audit
- func ResponseLT(v string) predicate.Audit
- func ResponseLTE(v string) predicate.Audit
- func ResponseNEQ(v string) predicate.Audit
- func ResponseNotIn(vs ...string) predicate.Audit
- func ResponseNotNil() predicate.Audit
- func SourceIP(v string) predicate.Audit
- func SourceIPContains(v string) predicate.Audit
- func SourceIPContainsFold(v string) predicate.Audit
- func SourceIPEQ(v string) predicate.Audit
- func SourceIPEqualFold(v string) predicate.Audit
- func SourceIPGT(v string) predicate.Audit
- func SourceIPGTE(v string) predicate.Audit
- func SourceIPHasPrefix(v string) predicate.Audit
- func SourceIPHasSuffix(v string) predicate.Audit
- func SourceIPIn(vs ...string) predicate.Audit
- func SourceIPLT(v string) predicate.Audit
- func SourceIPLTE(v string) predicate.Audit
- func SourceIPNEQ(v string) predicate.Audit
- func SourceIPNotIn(vs ...string) predicate.Audit
- func UserAgent(v string) predicate.Audit
- func UserAgentContains(v string) predicate.Audit
- func UserAgentContainsFold(v string) predicate.Audit
- func UserAgentEQ(v string) predicate.Audit
- func UserAgentEqualFold(v string) predicate.Audit
- func UserAgentGT(v string) predicate.Audit
- func UserAgentGTE(v string) predicate.Audit
- func UserAgentHasPrefix(v string) predicate.Audit
- func UserAgentHasSuffix(v string) predicate.Audit
- func UserAgentIn(vs ...string) predicate.Audit
- func UserAgentLT(v string) predicate.Audit
- func UserAgentLTE(v string) predicate.Audit
- func UserAgentNEQ(v string) predicate.Audit
- func UserAgentNotIn(vs ...string) predicate.Audit
- func UserID(v uuid.UUID) predicate.Audit
- func UserIDEQ(v uuid.UUID) predicate.Audit
- func UserIDIn(vs ...uuid.UUID) predicate.Audit
- func UserIDNEQ(v uuid.UUID) predicate.Audit
- func UserIDNotIn(vs ...uuid.UUID) predicate.Audit
- func ValidColumn(column string) bool
- type OrderOption
- func ByCreatedAt(opts ...sql.OrderTermOption) OrderOption
- func ByID(opts ...sql.OrderTermOption) OrderOption
- func ByOperation(opts ...sql.OrderTermOption) OrderOption
- func ByRequest(opts ...sql.OrderTermOption) OrderOption
- func ByResponse(opts ...sql.OrderTermOption) OrderOption
- func BySourceIP(opts ...sql.OrderTermOption) OrderOption
- func ByUserAgent(opts ...sql.OrderTermOption) OrderOption
- func ByUserField(field string, opts ...sql.OrderTermOption) OrderOption
- func ByUserID(opts ...sql.OrderTermOption) OrderOption
Constants ¶
const ( // Label holds the string label denoting the audit type in the database. Label = "audit" // FieldID holds the string denoting the id field in the database. FieldID = "id" // FieldUserID holds the string denoting the user_id field in the database. FieldUserID = "user_id" // FieldOperation holds the string denoting the operation field in the database. FieldOperation = "operation" // FieldSourceIP holds the string denoting the source_ip field in the database. FieldSourceIP = "source_ip" // FieldUserAgent holds the string denoting the user_agent field in the database. FieldUserAgent = "user_agent" // FieldRequest holds the string denoting the request field in the database. FieldRequest = "request" // FieldResponse holds the string denoting the response field in the database. FieldResponse = "response" // FieldCreatedAt holds the string denoting the created_at field in the database. FieldCreatedAt = "created_at" // EdgeUser holds the string denoting the user edge name in mutations. EdgeUser = "user" // Table holds the table name of the audit in the database. Table = "audits" // UserTable is the table that holds the user relation/edge. UserTable = "audits" // 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_id" )
Variables ¶
var Columns = []string{ FieldID, FieldUserID, FieldOperation, FieldSourceIP, FieldUserAgent, FieldRequest, FieldResponse, FieldCreatedAt, }
Columns holds all SQL columns for audit fields.
var ( // DefaultCreatedAt holds the default value on creation for the "created_at" field. DefaultCreatedAt func() time.Time )
Functions ¶
func CreatedAt ¶
CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.
func CreatedAtEQ ¶
CreatedAtEQ applies the EQ predicate on the "created_at" field.
func CreatedAtGT ¶
CreatedAtGT applies the GT predicate on the "created_at" field.
func CreatedAtGTE ¶
CreatedAtGTE applies the GTE predicate on the "created_at" field.
func CreatedAtIn ¶
CreatedAtIn applies the In predicate on the "created_at" field.
func CreatedAtLT ¶
CreatedAtLT applies the LT predicate on the "created_at" field.
func CreatedAtLTE ¶
CreatedAtLTE applies the LTE predicate on the "created_at" field.
func CreatedAtNEQ ¶
CreatedAtNEQ applies the NEQ predicate on the "created_at" field.
func CreatedAtNotIn ¶
CreatedAtNotIn applies the NotIn predicate on the "created_at" field.
func HasUserWith ¶
HasUserWith applies the HasEdge predicate on the "user" edge with a given conditions (other predicates).
func Operation ¶
Operation applies equality check predicate on the "operation" field. It's identical to OperationEQ.
func OperationContains ¶
OperationContains applies the Contains predicate on the "operation" field.
func OperationContainsFold ¶
OperationContainsFold applies the ContainsFold predicate on the "operation" field.
func OperationEQ ¶
OperationEQ applies the EQ predicate on the "operation" field.
func OperationEqualFold ¶
OperationEqualFold applies the EqualFold predicate on the "operation" field.
func OperationGT ¶
OperationGT applies the GT predicate on the "operation" field.
func OperationGTE ¶
OperationGTE applies the GTE predicate on the "operation" field.
func OperationHasPrefix ¶
OperationHasPrefix applies the HasPrefix predicate on the "operation" field.
func OperationHasSuffix ¶
OperationHasSuffix applies the HasSuffix predicate on the "operation" field.
func OperationIn ¶
OperationIn applies the In predicate on the "operation" field.
func OperationLT ¶
OperationLT applies the LT predicate on the "operation" field.
func OperationLTE ¶
OperationLTE applies the LTE predicate on the "operation" field.
func OperationNEQ ¶
OperationNEQ applies the NEQ predicate on the "operation" field.
func OperationNotIn ¶
OperationNotIn applies the NotIn predicate on the "operation" field.
func Request ¶
Request applies equality check predicate on the "request" field. It's identical to RequestEQ.
func RequestContains ¶
RequestContains applies the Contains predicate on the "request" field.
func RequestContainsFold ¶
RequestContainsFold applies the ContainsFold predicate on the "request" field.
func RequestEqualFold ¶
RequestEqualFold applies the EqualFold predicate on the "request" field.
func RequestGTE ¶
RequestGTE applies the GTE predicate on the "request" field.
func RequestHasPrefix ¶
RequestHasPrefix applies the HasPrefix predicate on the "request" field.
func RequestHasSuffix ¶
RequestHasSuffix applies the HasSuffix predicate on the "request" field.
func RequestLTE ¶
RequestLTE applies the LTE predicate on the "request" field.
func RequestNEQ ¶
RequestNEQ applies the NEQ predicate on the "request" field.
func RequestNotIn ¶
RequestNotIn applies the NotIn predicate on the "request" field.
func Response ¶
Response applies equality check predicate on the "response" field. It's identical to ResponseEQ.
func ResponseContains ¶
ResponseContains applies the Contains predicate on the "response" field.
func ResponseContainsFold ¶
ResponseContainsFold applies the ContainsFold predicate on the "response" field.
func ResponseEQ ¶
ResponseEQ applies the EQ predicate on the "response" field.
func ResponseEqualFold ¶
ResponseEqualFold applies the EqualFold predicate on the "response" field.
func ResponseGT ¶
ResponseGT applies the GT predicate on the "response" field.
func ResponseGTE ¶
ResponseGTE applies the GTE predicate on the "response" field.
func ResponseHasPrefix ¶
ResponseHasPrefix applies the HasPrefix predicate on the "response" field.
func ResponseHasSuffix ¶
ResponseHasSuffix applies the HasSuffix predicate on the "response" field.
func ResponseIn ¶
ResponseIn applies the In predicate on the "response" field.
func ResponseIsNil ¶
ResponseIsNil applies the IsNil predicate on the "response" field.
func ResponseLT ¶
ResponseLT applies the LT predicate on the "response" field.
func ResponseLTE ¶
ResponseLTE applies the LTE predicate on the "response" field.
func ResponseNEQ ¶
ResponseNEQ applies the NEQ predicate on the "response" field.
func ResponseNotIn ¶
ResponseNotIn applies the NotIn predicate on the "response" field.
func ResponseNotNil ¶
ResponseNotNil applies the NotNil predicate on the "response" field.
func SourceIP ¶
SourceIP applies equality check predicate on the "source_ip" field. It's identical to SourceIPEQ.
func SourceIPContains ¶
SourceIPContains applies the Contains predicate on the "source_ip" field.
func SourceIPContainsFold ¶
SourceIPContainsFold applies the ContainsFold predicate on the "source_ip" field.
func SourceIPEQ ¶
SourceIPEQ applies the EQ predicate on the "source_ip" field.
func SourceIPEqualFold ¶
SourceIPEqualFold applies the EqualFold predicate on the "source_ip" field.
func SourceIPGT ¶
SourceIPGT applies the GT predicate on the "source_ip" field.
func SourceIPGTE ¶
SourceIPGTE applies the GTE predicate on the "source_ip" field.
func SourceIPHasPrefix ¶
SourceIPHasPrefix applies the HasPrefix predicate on the "source_ip" field.
func SourceIPHasSuffix ¶
SourceIPHasSuffix applies the HasSuffix predicate on the "source_ip" field.
func SourceIPIn ¶
SourceIPIn applies the In predicate on the "source_ip" field.
func SourceIPLT ¶
SourceIPLT applies the LT predicate on the "source_ip" field.
func SourceIPLTE ¶
SourceIPLTE applies the LTE predicate on the "source_ip" field.
func SourceIPNEQ ¶
SourceIPNEQ applies the NEQ predicate on the "source_ip" field.
func SourceIPNotIn ¶
SourceIPNotIn applies the NotIn predicate on the "source_ip" field.
func UserAgent ¶
UserAgent applies equality check predicate on the "user_agent" field. It's identical to UserAgentEQ.
func UserAgentContains ¶
UserAgentContains applies the Contains predicate on the "user_agent" field.
func UserAgentContainsFold ¶
UserAgentContainsFold applies the ContainsFold predicate on the "user_agent" field.
func UserAgentEQ ¶
UserAgentEQ applies the EQ predicate on the "user_agent" field.
func UserAgentEqualFold ¶
UserAgentEqualFold applies the EqualFold predicate on the "user_agent" field.
func UserAgentGT ¶
UserAgentGT applies the GT predicate on the "user_agent" field.
func UserAgentGTE ¶
UserAgentGTE applies the GTE predicate on the "user_agent" field.
func UserAgentHasPrefix ¶
UserAgentHasPrefix applies the HasPrefix predicate on the "user_agent" field.
func UserAgentHasSuffix ¶
UserAgentHasSuffix applies the HasSuffix predicate on the "user_agent" field.
func UserAgentIn ¶
UserAgentIn applies the In predicate on the "user_agent" field.
func UserAgentLT ¶
UserAgentLT applies the LT predicate on the "user_agent" field.
func UserAgentLTE ¶
UserAgentLTE applies the LTE predicate on the "user_agent" field.
func UserAgentNEQ ¶
UserAgentNEQ applies the NEQ predicate on the "user_agent" field.
func UserAgentNotIn ¶
UserAgentNotIn applies the NotIn predicate on the "user_agent" field.
func UserID ¶
UserID applies equality check predicate on the "user_id" field. It's identical to UserIDEQ.
func UserIDNotIn ¶
UserIDNotIn applies the NotIn predicate on the "user_id" field.
func ValidColumn ¶
ValidColumn reports if the column name is valid (part of the table columns).
Types ¶
type OrderOption ¶
OrderOption defines the ordering options for the Audit queries.
func ByCreatedAt ¶
func ByCreatedAt(opts ...sql.OrderTermOption) OrderOption
ByCreatedAt orders the results by the created_at field.
func ByID ¶
func ByID(opts ...sql.OrderTermOption) OrderOption
ByID orders the results by the id field.
func ByOperation ¶
func ByOperation(opts ...sql.OrderTermOption) OrderOption
ByOperation orders the results by the operation field.
func ByRequest ¶
func ByRequest(opts ...sql.OrderTermOption) OrderOption
ByRequest orders the results by the request field.
func ByResponse ¶
func ByResponse(opts ...sql.OrderTermOption) OrderOption
ByResponse orders the results by the response field.
func BySourceIP ¶
func BySourceIP(opts ...sql.OrderTermOption) OrderOption
BySourceIP orders the results by the source_ip field.
func ByUserAgent ¶
func ByUserAgent(opts ...sql.OrderTermOption) OrderOption
ByUserAgent orders the results by the user_agent field.
func ByUserField ¶
func ByUserField(field string, opts ...sql.OrderTermOption) OrderOption
ByUserField orders the results by user field.
func ByUserID ¶
func ByUserID(opts ...sql.OrderTermOption) OrderOption
ByUserID orders the results by the user_id field.