models

package
v0.0.0-...-7bf63ba Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2019 License: BSD-3-Clause Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrSyncFail = errors.New("models: failed to synchronize data after insert")

ErrSyncFail occurs during insert when the record could not be retrieved in order to populate default value information. This usually happens when LastInsertId fails or there was a primary key configuration that was not resolvable.

View Source
var GroupColumns = struct {
	ID        string
	CreatedAt string
	UpdatedAt string
	Name      string
}{
	ID:        "id",
	CreatedAt: "created_at",
	UpdatedAt: "updated_at",
	Name:      "name",
}
View Source
var GroupRels = struct {
	Users string
}{
	Users: "Users",
}

GroupRels is where relationship names are stored.

View Source
var GroupWhere = struct {
	ID        whereHelperint
	CreatedAt whereHelpertime_Time
	UpdatedAt whereHelpertime_Time
	Name      whereHelperstring
}{
	ID:        whereHelperint{/* contains filtered or unexported fields */},
	CreatedAt: whereHelpertime_Time{/* contains filtered or unexported fields */},
	UpdatedAt: whereHelpertime_Time{/* contains filtered or unexported fields */},
	Name:      whereHelperstring{/* contains filtered or unexported fields */},
}
View Source
var JWTKeyColumns = struct {
	ID        string
	PublicKey string
	CreatedAt string
}{
	ID:        "id",
	PublicKey: "public_key",
	CreatedAt: "created_at",
}
View Source
var JWTKeyRels = struct {
}{}

JWTKeyRels is where relationship names are stored.

View Source
var JWTKeyWhere = struct {
	ID        whereHelperint
	PublicKey whereHelper__byte
	CreatedAt whereHelpertime_Time
}{
	ID:        whereHelperint{/* contains filtered or unexported fields */},
	PublicKey: whereHelper__byte{/* contains filtered or unexported fields */},
	CreatedAt: whereHelpertime_Time{/* contains filtered or unexported fields */},
}
View Source
var MigrationColumns = struct {
	ID        string
	AppliedAt string
}{
	ID:        "id",
	AppliedAt: "applied_at",
}
View Source
var MigrationRels = struct {
}{}

MigrationRels is where relationship names are stored.

View Source
var MigrationWhere = struct {
	ID        whereHelperstring
	AppliedAt whereHelpernull_Time
}{
	ID:        whereHelperstring{/* contains filtered or unexported fields */},
	AppliedAt: whereHelpernull_Time{/* contains filtered or unexported fields */},
}
View Source
var PasswordColumns = struct {
	UserID    string
	CreatedAt string
	UpdatedAt string
	Salt      string
	Hash      string
}{
	UserID:    "user_id",
	CreatedAt: "created_at",
	UpdatedAt: "updated_at",
	Salt:      "salt",
	Hash:      "hash",
}
View Source
var PasswordRels = struct {
	User string
}{
	User: "User",
}

PasswordRels is where relationship names are stored.

View Source
var PasswordWhere = struct {
	UserID    whereHelperint
	CreatedAt whereHelpertime_Time
	UpdatedAt whereHelpertime_Time
	Salt      whereHelper__byte
	Hash      whereHelper__byte
}{
	UserID:    whereHelperint{/* contains filtered or unexported fields */},
	CreatedAt: whereHelpertime_Time{/* contains filtered or unexported fields */},
	UpdatedAt: whereHelpertime_Time{/* contains filtered or unexported fields */},
	Salt:      whereHelper__byte{/* contains filtered or unexported fields */},
	Hash:      whereHelper__byte{/* contains filtered or unexported fields */},
}
View Source
var TableNames = struct {
	Groups     string
	JWTKeys    string
	Migrations string
	Passwords  string
	UserGroups string
	Users      string
}{
	Groups:     "groups",
	JWTKeys:    "jwt_keys",
	Migrations: "migrations",
	Passwords:  "passwords",
	UserGroups: "user_groups",
	Users:      "users",
}
View Source
var UserColumns = struct {
	ID        string
	Email     string
	Name      string
	CreatedAt string
	UpdatedAt string
}{
	ID:        "id",
	Email:     "email",
	Name:      "name",
	CreatedAt: "created_at",
	UpdatedAt: "updated_at",
}
View Source
var UserRels = struct {
	Password string
	Groups   string
}{
	Password: "Password",
	Groups:   "Groups",
}

UserRels is where relationship names are stored.

View Source
var UserWhere = struct {
	ID        whereHelperint
	Email     whereHelperstring
	Name      whereHelperstring
	CreatedAt whereHelpertime_Time
	UpdatedAt whereHelpertime_Time
}{
	ID:        whereHelperint{/* contains filtered or unexported fields */},
	Email:     whereHelperstring{/* contains filtered or unexported fields */},
	Name:      whereHelperstring{/* contains filtered or unexported fields */},
	CreatedAt: whereHelpertime_Time{/* contains filtered or unexported fields */},
	UpdatedAt: whereHelpertime_Time{/* contains filtered or unexported fields */},
}

Functions

func AddGroupHook

func AddGroupHook(hookPoint boil.HookPoint, groupHook GroupHook)

AddGroupHook registers your hook function for all future operations.

func AddJWTKeyHook

func AddJWTKeyHook(hookPoint boil.HookPoint, jwtKeyHook JWTKeyHook)

AddJWTKeyHook registers your hook function for all future operations.

func AddMigrationHook

func AddMigrationHook(hookPoint boil.HookPoint, migrationHook MigrationHook)

AddMigrationHook registers your hook function for all future operations.

func AddPasswordHook

func AddPasswordHook(hookPoint boil.HookPoint, passwordHook PasswordHook)

AddPasswordHook registers your hook function for all future operations.

func AddUserHook

func AddUserHook(hookPoint boil.HookPoint, userHook UserHook)

AddUserHook registers your hook function for all future operations.

func GroupExists

func GroupExists(ctx context.Context, exec boil.ContextExecutor, iD int) (bool, error)

GroupExists checks if the Group row exists.

func Groups

func Groups(mods ...qm.QueryMod) groupQuery

Groups retrieves all the records using an executor.

func JWTKeyExists

func JWTKeyExists(ctx context.Context, exec boil.ContextExecutor, iD int) (bool, error)

JWTKeyExists checks if the JWTKey row exists.

func JWTKeys

func JWTKeys(mods ...qm.QueryMod) jwtKeyQuery

JWTKeys retrieves all the records using an executor.

func MigrationExists

func MigrationExists(ctx context.Context, exec boil.ContextExecutor, iD string) (bool, error)

MigrationExists checks if the Migration row exists.

func Migrations

func Migrations(mods ...qm.QueryMod) migrationQuery

Migrations retrieves all the records using an executor.

func NewQuery

func NewQuery(mods ...qm.QueryMod) *queries.Query

NewQuery initializes a new Query using the passed in QueryMods

func PasswordExists

func PasswordExists(ctx context.Context, exec boil.ContextExecutor, userID int) (bool, error)

PasswordExists checks if the Password row exists.

func Passwords

func Passwords(mods ...qm.QueryMod) passwordQuery

Passwords retrieves all the records using an executor.

func UserExists

func UserExists(ctx context.Context, exec boil.ContextExecutor, iD int) (bool, error)

UserExists checks if the User row exists.

func Users

func Users(mods ...qm.QueryMod) userQuery

Users retrieves all the records using an executor.

Types

type Group

type Group struct {
	ID        int       `boil:"id" json:"id" toml:"id" yaml:"id"`
	CreatedAt time.Time `boil:"created_at" json:"created_at" toml:"created_at" yaml:"created_at"`
	UpdatedAt time.Time `boil:"updated_at" json:"updated_at" toml:"updated_at" yaml:"updated_at"`
	Name      string    `boil:"name" json:"name" toml:"name" yaml:"name"`

	R *groupR `boil:"-" json:"-" toml:"-" yaml:"-"`
	L groupL  `boil:"-" json:"-" toml:"-" yaml:"-"`
}

Group is an object representing the database table.

func FindGroup

func FindGroup(ctx context.Context, exec boil.ContextExecutor, iD int, selectCols ...string) (*Group, error)

FindGroup retrieves a single record by ID with an executor. If selectCols is empty Find will return all columns.

func (*Group) AddUsers

func (o *Group) AddUsers(ctx context.Context, exec boil.ContextExecutor, insert bool, related ...*User) error

AddUsers adds the given related objects to the existing relationships of the group, optionally inserting them as new records. Appends related to o.R.Users. Sets related.R.Groups appropriately.

func (*Group) Delete

func (o *Group) Delete(ctx context.Context, exec boil.ContextExecutor) (int64, error)

Delete deletes a single Group record with an executor. Delete will match against the primary key column to find the record to delete.

func (*Group) Insert

func (o *Group) Insert(ctx context.Context, exec boil.ContextExecutor, columns boil.Columns) error

Insert a single record using an executor. See boil.Columns.InsertColumnSet documentation to understand column list inference for inserts.

func (*Group) Reload

func (o *Group) Reload(ctx context.Context, exec boil.ContextExecutor) error

Reload refetches the object from the database using the primary keys with an executor.

func (*Group) RemoveUsers

func (o *Group) RemoveUsers(ctx context.Context, exec boil.ContextExecutor, related ...*User) error

RemoveUsers relationships from objects passed in. Removes related items from R.Users (uses pointer comparison, removal does not keep order) Sets related.R.Groups.

func (*Group) SetUsers

func (o *Group) SetUsers(ctx context.Context, exec boil.ContextExecutor, insert bool, related ...*User) error

SetUsers removes all previously related items of the group replacing them completely with the passed in related items, optionally inserting them as new records. Sets o.R.Groups's Users accordingly. Replaces o.R.Users with related. Sets related.R.Groups's Users accordingly.

func (*Group) Update

func (o *Group) Update(ctx context.Context, exec boil.ContextExecutor, columns boil.Columns) (int64, error)

Update uses an executor to update the Group. See boil.Columns.UpdateColumnSet documentation to understand column list inference for updates. Update does not automatically update the record in case of default values. Use .Reload() to refresh the records.

func (*Group) Upsert

func (o *Group) Upsert(ctx context.Context, exec boil.ContextExecutor, updateOnConflict bool, conflictColumns []string, updateColumns, insertColumns boil.Columns) error

Upsert attempts an insert using an executor, and does an update or ignore on conflict. See boil.Columns documentation for how to properly use updateColumns and insertColumns.

func (*Group) Users

func (o *Group) Users(mods ...qm.QueryMod) userQuery

Users retrieves all the user's Users with an executor.

type GroupHook

type GroupHook func(context.Context, boil.ContextExecutor, *Group) error

GroupHook is the signature for custom Group hook methods

type GroupSlice

type GroupSlice []*Group

GroupSlice is an alias for a slice of pointers to Group. This should generally be used opposed to []Group.

func (GroupSlice) DeleteAll

func (o GroupSlice) DeleteAll(ctx context.Context, exec boil.ContextExecutor) (int64, error)

DeleteAll deletes all rows in the slice, using an executor.

func (*GroupSlice) ReloadAll

func (o *GroupSlice) ReloadAll(ctx context.Context, exec boil.ContextExecutor) error

ReloadAll refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice.

func (GroupSlice) UpdateAll

func (o GroupSlice) UpdateAll(ctx context.Context, exec boil.ContextExecutor, cols M) (int64, error)

UpdateAll updates all rows with the specified column values, using an executor.

type JWTKey

type JWTKey struct {
	ID        int       `boil:"id" json:"id" toml:"id" yaml:"id"`
	PublicKey []byte    `boil:"public_key" json:"public_key" toml:"public_key" yaml:"public_key"`
	CreatedAt time.Time `boil:"created_at" json:"created_at" toml:"created_at" yaml:"created_at"`

	R *jwtKeyR `boil:"-" json:"-" toml:"-" yaml:"-"`
	L jwtKeyL  `boil:"-" json:"-" toml:"-" yaml:"-"`
}

JWTKey is an object representing the database table.

func FindJWTKey

func FindJWTKey(ctx context.Context, exec boil.ContextExecutor, iD int, selectCols ...string) (*JWTKey, error)

FindJWTKey retrieves a single record by ID with an executor. If selectCols is empty Find will return all columns.

func (*JWTKey) Delete

func (o *JWTKey) Delete(ctx context.Context, exec boil.ContextExecutor) (int64, error)

Delete deletes a single JWTKey record with an executor. Delete will match against the primary key column to find the record to delete.

func (*JWTKey) Insert

func (o *JWTKey) Insert(ctx context.Context, exec boil.ContextExecutor, columns boil.Columns) error

Insert a single record using an executor. See boil.Columns.InsertColumnSet documentation to understand column list inference for inserts.

func (*JWTKey) Reload

func (o *JWTKey) Reload(ctx context.Context, exec boil.ContextExecutor) error

Reload refetches the object from the database using the primary keys with an executor.

func (*JWTKey) Update

func (o *JWTKey) Update(ctx context.Context, exec boil.ContextExecutor, columns boil.Columns) (int64, error)

Update uses an executor to update the JWTKey. See boil.Columns.UpdateColumnSet documentation to understand column list inference for updates. Update does not automatically update the record in case of default values. Use .Reload() to refresh the records.

func (*JWTKey) Upsert

func (o *JWTKey) Upsert(ctx context.Context, exec boil.ContextExecutor, updateOnConflict bool, conflictColumns []string, updateColumns, insertColumns boil.Columns) error

Upsert attempts an insert using an executor, and does an update or ignore on conflict. See boil.Columns documentation for how to properly use updateColumns and insertColumns.

type JWTKeyHook

type JWTKeyHook func(context.Context, boil.ContextExecutor, *JWTKey) error

JWTKeyHook is the signature for custom JWTKey hook methods

type JWTKeySlice

type JWTKeySlice []*JWTKey

JWTKeySlice is an alias for a slice of pointers to JWTKey. This should generally be used opposed to []JWTKey.

func (JWTKeySlice) DeleteAll

func (o JWTKeySlice) DeleteAll(ctx context.Context, exec boil.ContextExecutor) (int64, error)

DeleteAll deletes all rows in the slice, using an executor.

func (*JWTKeySlice) ReloadAll

func (o *JWTKeySlice) ReloadAll(ctx context.Context, exec boil.ContextExecutor) error

ReloadAll refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice.

func (JWTKeySlice) UpdateAll

func (o JWTKeySlice) UpdateAll(ctx context.Context, exec boil.ContextExecutor, cols M) (int64, error)

UpdateAll updates all rows with the specified column values, using an executor.

type M

type M map[string]interface{}

M type is for providing columns and column values to UpdateAll.

type Migration

type Migration struct {
	ID        string    `boil:"id" json:"id" toml:"id" yaml:"id"`
	AppliedAt null.Time `boil:"applied_at" json:"applied_at,omitempty" toml:"applied_at" yaml:"applied_at,omitempty"`

	R *migrationR `boil:"-" json:"-" toml:"-" yaml:"-"`
	L migrationL  `boil:"-" json:"-" toml:"-" yaml:"-"`
}

Migration is an object representing the database table.

func FindMigration

func FindMigration(ctx context.Context, exec boil.ContextExecutor, iD string, selectCols ...string) (*Migration, error)

FindMigration retrieves a single record by ID with an executor. If selectCols is empty Find will return all columns.

func (*Migration) Delete

func (o *Migration) Delete(ctx context.Context, exec boil.ContextExecutor) (int64, error)

Delete deletes a single Migration record with an executor. Delete will match against the primary key column to find the record to delete.

func (*Migration) Insert

func (o *Migration) Insert(ctx context.Context, exec boil.ContextExecutor, columns boil.Columns) error

Insert a single record using an executor. See boil.Columns.InsertColumnSet documentation to understand column list inference for inserts.

func (*Migration) Reload

func (o *Migration) Reload(ctx context.Context, exec boil.ContextExecutor) error

Reload refetches the object from the database using the primary keys with an executor.

func (*Migration) Update

func (o *Migration) Update(ctx context.Context, exec boil.ContextExecutor, columns boil.Columns) (int64, error)

Update uses an executor to update the Migration. See boil.Columns.UpdateColumnSet documentation to understand column list inference for updates. Update does not automatically update the record in case of default values. Use .Reload() to refresh the records.

func (*Migration) Upsert

func (o *Migration) Upsert(ctx context.Context, exec boil.ContextExecutor, updateOnConflict bool, conflictColumns []string, updateColumns, insertColumns boil.Columns) error

Upsert attempts an insert using an executor, and does an update or ignore on conflict. See boil.Columns documentation for how to properly use updateColumns and insertColumns.

type MigrationHook

type MigrationHook func(context.Context, boil.ContextExecutor, *Migration) error

MigrationHook is the signature for custom Migration hook methods

type MigrationSlice

type MigrationSlice []*Migration

MigrationSlice is an alias for a slice of pointers to Migration. This should generally be used opposed to []Migration.

func (MigrationSlice) DeleteAll

func (o MigrationSlice) DeleteAll(ctx context.Context, exec boil.ContextExecutor) (int64, error)

DeleteAll deletes all rows in the slice, using an executor.

func (*MigrationSlice) ReloadAll

func (o *MigrationSlice) ReloadAll(ctx context.Context, exec boil.ContextExecutor) error

ReloadAll refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice.

func (MigrationSlice) UpdateAll

func (o MigrationSlice) UpdateAll(ctx context.Context, exec boil.ContextExecutor, cols M) (int64, error)

UpdateAll updates all rows with the specified column values, using an executor.

type Password

type Password struct {
	UserID    int       `boil:"user_id" json:"user_id" toml:"user_id" yaml:"user_id"`
	CreatedAt time.Time `boil:"created_at" json:"created_at" toml:"created_at" yaml:"created_at"`
	UpdatedAt time.Time `boil:"updated_at" json:"updated_at" toml:"updated_at" yaml:"updated_at"`
	Salt      []byte    `boil:"salt" json:"salt" toml:"salt" yaml:"salt"`
	Hash      []byte    `boil:"hash" json:"hash" toml:"hash" yaml:"hash"`

	R *passwordR `boil:"-" json:"-" toml:"-" yaml:"-"`
	L passwordL  `boil:"-" json:"-" toml:"-" yaml:"-"`
}

Password is an object representing the database table.

func FindPassword

func FindPassword(ctx context.Context, exec boil.ContextExecutor, userID int, selectCols ...string) (*Password, error)

FindPassword retrieves a single record by ID with an executor. If selectCols is empty Find will return all columns.

func (*Password) Delete

func (o *Password) Delete(ctx context.Context, exec boil.ContextExecutor) (int64, error)

Delete deletes a single Password record with an executor. Delete will match against the primary key column to find the record to delete.

func (*Password) Insert

func (o *Password) Insert(ctx context.Context, exec boil.ContextExecutor, columns boil.Columns) error

Insert a single record using an executor. See boil.Columns.InsertColumnSet documentation to understand column list inference for inserts.

func (*Password) Reload

func (o *Password) Reload(ctx context.Context, exec boil.ContextExecutor) error

Reload refetches the object from the database using the primary keys with an executor.

func (*Password) SetUser

func (o *Password) SetUser(ctx context.Context, exec boil.ContextExecutor, insert bool, related *User) error

SetUser of the password to the related item. Sets o.R.User to related. Adds o to related.R.Password.

func (*Password) Update

func (o *Password) Update(ctx context.Context, exec boil.ContextExecutor, columns boil.Columns) (int64, error)

Update uses an executor to update the Password. See boil.Columns.UpdateColumnSet documentation to understand column list inference for updates. Update does not automatically update the record in case of default values. Use .Reload() to refresh the records.

func (*Password) Upsert

func (o *Password) Upsert(ctx context.Context, exec boil.ContextExecutor, updateOnConflict bool, conflictColumns []string, updateColumns, insertColumns boil.Columns) error

Upsert attempts an insert using an executor, and does an update or ignore on conflict. See boil.Columns documentation for how to properly use updateColumns and insertColumns.

func (*Password) User

func (o *Password) User(mods ...qm.QueryMod) userQuery

User pointed to by the foreign key.

type PasswordHook

type PasswordHook func(context.Context, boil.ContextExecutor, *Password) error

PasswordHook is the signature for custom Password hook methods

type PasswordSlice

type PasswordSlice []*Password

PasswordSlice is an alias for a slice of pointers to Password. This should generally be used opposed to []Password.

func (PasswordSlice) DeleteAll

func (o PasswordSlice) DeleteAll(ctx context.Context, exec boil.ContextExecutor) (int64, error)

DeleteAll deletes all rows in the slice, using an executor.

func (*PasswordSlice) ReloadAll

func (o *PasswordSlice) ReloadAll(ctx context.Context, exec boil.ContextExecutor) error

ReloadAll refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice.

func (PasswordSlice) UpdateAll

func (o PasswordSlice) UpdateAll(ctx context.Context, exec boil.ContextExecutor, cols M) (int64, error)

UpdateAll updates all rows with the specified column values, using an executor.

type User

type User struct {
	ID        int       `boil:"id" json:"id" toml:"id" yaml:"id"`
	Email     string    `boil:"email" json:"email" toml:"email" yaml:"email"`
	Name      string    `boil:"name" json:"name" toml:"name" yaml:"name"`
	CreatedAt time.Time `boil:"created_at" json:"created_at" toml:"created_at" yaml:"created_at"`
	UpdatedAt time.Time `boil:"updated_at" json:"updated_at" toml:"updated_at" yaml:"updated_at"`

	R *userR `boil:"-" json:"-" toml:"-" yaml:"-"`
	L userL  `boil:"-" json:"-" toml:"-" yaml:"-"`
}

User is an object representing the database table.

func FindUser

func FindUser(ctx context.Context, exec boil.ContextExecutor, iD int, selectCols ...string) (*User, error)

FindUser retrieves a single record by ID with an executor. If selectCols is empty Find will return all columns.

func (*User) AddGroups

func (o *User) AddGroups(ctx context.Context, exec boil.ContextExecutor, insert bool, related ...*Group) error

AddGroups adds the given related objects to the existing relationships of the user, optionally inserting them as new records. Appends related to o.R.Groups. Sets related.R.Users appropriately.

func (*User) Delete

func (o *User) Delete(ctx context.Context, exec boil.ContextExecutor) (int64, error)

Delete deletes a single User record with an executor. Delete will match against the primary key column to find the record to delete.

func (*User) Groups

func (o *User) Groups(mods ...qm.QueryMod) groupQuery

Groups retrieves all the group's Groups with an executor.

func (*User) Insert

func (o *User) Insert(ctx context.Context, exec boil.ContextExecutor, columns boil.Columns) error

Insert a single record using an executor. See boil.Columns.InsertColumnSet documentation to understand column list inference for inserts.

func (*User) Password

func (o *User) Password(mods ...qm.QueryMod) passwordQuery

Password pointed to by the foreign key.

func (*User) Reload

func (o *User) Reload(ctx context.Context, exec boil.ContextExecutor) error

Reload refetches the object from the database using the primary keys with an executor.

func (*User) RemoveGroups

func (o *User) RemoveGroups(ctx context.Context, exec boil.ContextExecutor, related ...*Group) error

RemoveGroups relationships from objects passed in. Removes related items from R.Groups (uses pointer comparison, removal does not keep order) Sets related.R.Users.

func (*User) SetGroups

func (o *User) SetGroups(ctx context.Context, exec boil.ContextExecutor, insert bool, related ...*Group) error

SetGroups removes all previously related items of the user replacing them completely with the passed in related items, optionally inserting them as new records. Sets o.R.Users's Groups accordingly. Replaces o.R.Groups with related. Sets related.R.Users's Groups accordingly.

func (*User) SetPassword

func (o *User) SetPassword(ctx context.Context, exec boil.ContextExecutor, insert bool, related *Password) error

SetPassword of the user to the related item. Sets o.R.Password to related. Adds o to related.R.User.

func (*User) Update

func (o *User) Update(ctx context.Context, exec boil.ContextExecutor, columns boil.Columns) (int64, error)

Update uses an executor to update the User. See boil.Columns.UpdateColumnSet documentation to understand column list inference for updates. Update does not automatically update the record in case of default values. Use .Reload() to refresh the records.

func (*User) Upsert

func (o *User) Upsert(ctx context.Context, exec boil.ContextExecutor, updateOnConflict bool, conflictColumns []string, updateColumns, insertColumns boil.Columns) error

Upsert attempts an insert using an executor, and does an update or ignore on conflict. See boil.Columns documentation for how to properly use updateColumns and insertColumns.

type UserHook

type UserHook func(context.Context, boil.ContextExecutor, *User) error

UserHook is the signature for custom User hook methods

type UserSlice

type UserSlice []*User

UserSlice is an alias for a slice of pointers to User. This should generally be used opposed to []User.

func (UserSlice) DeleteAll

func (o UserSlice) DeleteAll(ctx context.Context, exec boil.ContextExecutor) (int64, error)

DeleteAll deletes all rows in the slice, using an executor.

func (*UserSlice) ReloadAll

func (o *UserSlice) ReloadAll(ctx context.Context, exec boil.ContextExecutor) error

ReloadAll refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice.

func (UserSlice) UpdateAll

func (o UserSlice) UpdateAll(ctx context.Context, exec boil.ContextExecutor, cols M) (int64, error)

UpdateAll updates all rows with the specified column values, using an executor.

Jump to

Keyboard shortcuts

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