models

package
v0.0.29 Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2024 License: Apache-2.0 Imports: 17 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 InstanceIPAddressColumns = struct {
	ID         string
	InstanceID string
	Address    string
	CreatedAt  string
	UpdatedAt  string
}{
	ID:         "id",
	InstanceID: "instance_id",
	Address:    "address",
	CreatedAt:  "created_at",
	UpdatedAt:  "updated_at",
}
View Source
var InstanceIPAddressRels = struct {
}{}

InstanceIPAddressRels is where relationship names are stored.

View Source
var InstanceIPAddressTableColumns = struct {
	ID         string
	InstanceID string
	Address    string
	CreatedAt  string
	UpdatedAt  string
}{
	ID:         "instance_ip_addresses.id",
	InstanceID: "instance_ip_addresses.instance_id",
	Address:    "instance_ip_addresses.address",
	CreatedAt:  "instance_ip_addresses.created_at",
	UpdatedAt:  "instance_ip_addresses.updated_at",
}
View Source
var InstanceIPAddressWhere = struct {
	ID         whereHelperstring
	InstanceID whereHelperstring
	Address    whereHelperstring
	CreatedAt  whereHelpertime_Time
	UpdatedAt  whereHelpertime_Time
}{
	ID:         whereHelperstring{/* contains filtered or unexported fields */},
	InstanceID: whereHelperstring{/* contains filtered or unexported fields */},
	Address:    whereHelperstring{/* contains filtered or unexported fields */},
	CreatedAt:  whereHelpertime_Time{/* contains filtered or unexported fields */},
	UpdatedAt:  whereHelpertime_Time{/* contains filtered or unexported fields */},
}
View Source
var InstanceMetadatumColumns = struct {
	ID        string
	Metadata  string
	CreatedAt string
	UpdatedAt string
}{
	ID:        "id",
	Metadata:  "metadata",
	CreatedAt: "created_at",
	UpdatedAt: "updated_at",
}
View Source
var InstanceMetadatumRels = struct {
}{}

InstanceMetadatumRels is where relationship names are stored.

View Source
var InstanceMetadatumTableColumns = struct {
	ID        string
	Metadata  string
	CreatedAt string
	UpdatedAt string
}{
	ID:        "instance_metadata.id",
	Metadata:  "instance_metadata.metadata",
	CreatedAt: "instance_metadata.created_at",
	UpdatedAt: "instance_metadata.updated_at",
}
View Source
var InstanceMetadatumWhere = struct {
	ID        whereHelperstring
	Metadata  whereHelpertypes_JSON
	CreatedAt whereHelpertime_Time
	UpdatedAt whereHelpertime_Time
}{
	ID:        whereHelperstring{/* contains filtered or unexported fields */},
	Metadata:  whereHelpertypes_JSON{/* contains filtered or unexported fields */},
	CreatedAt: whereHelpertime_Time{/* contains filtered or unexported fields */},
	UpdatedAt: whereHelpertime_Time{/* contains filtered or unexported fields */},
}
View Source
var InstanceUserdatumColumns = struct {
	ID        string
	Userdata  string
	CreatedAt string
	UpdatedAt string
}{
	ID:        "id",
	Userdata:  "userdata",
	CreatedAt: "created_at",
	UpdatedAt: "updated_at",
}
View Source
var InstanceUserdatumRels = struct {
}{}

InstanceUserdatumRels is where relationship names are stored.

View Source
var InstanceUserdatumTableColumns = struct {
	ID        string
	Userdata  string
	CreatedAt string
	UpdatedAt string
}{
	ID:        "instance_userdata.id",
	Userdata:  "instance_userdata.userdata",
	CreatedAt: "instance_userdata.created_at",
	UpdatedAt: "instance_userdata.updated_at",
}
View Source
var InstanceUserdatumWhere = struct {
	ID        whereHelperstring
	Userdata  whereHelpernull_Bytes
	CreatedAt whereHelpertime_Time
	UpdatedAt whereHelpertime_Time
}{
	ID:        whereHelperstring{/* contains filtered or unexported fields */},
	Userdata:  whereHelpernull_Bytes{/* contains filtered or unexported fields */},
	CreatedAt: whereHelpertime_Time{/* contains filtered or unexported fields */},
	UpdatedAt: whereHelpertime_Time{/* contains filtered or unexported fields */},
}
View Source
var TableNames = struct {
	InstanceIPAddresses string
	InstanceMetadata    string
	InstanceUserdata    string
}{
	InstanceIPAddresses: "instance_ip_addresses",
	InstanceMetadata:    "instance_metadata",
	InstanceUserdata:    "instance_userdata",
}
View Source
var ViewNames = struct {
}{}

Functions

func AddInstanceIPAddressHook

func AddInstanceIPAddressHook(hookPoint boil.HookPoint, instanceIPAddressHook InstanceIPAddressHook)

AddInstanceIPAddressHook registers your hook function for all future operations.

func AddInstanceMetadatumHook

func AddInstanceMetadatumHook(hookPoint boil.HookPoint, instanceMetadatumHook InstanceMetadatumHook)

AddInstanceMetadatumHook registers your hook function for all future operations.

func AddInstanceUserdatumHook

func AddInstanceUserdatumHook(hookPoint boil.HookPoint, instanceUserdatumHook InstanceUserdatumHook)

AddInstanceUserdatumHook registers your hook function for all future operations.

func InstanceIPAddressExists

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

InstanceIPAddressExists checks if the InstanceIPAddress row exists.

func InstanceIPAddresses

func InstanceIPAddresses(mods ...qm.QueryMod) instanceIPAddressQuery

InstanceIPAddresses retrieves all the records using an executor.

func InstanceMetadata

func InstanceMetadata(mods ...qm.QueryMod) instanceMetadatumQuery

InstanceMetadata retrieves all the records using an executor.

func InstanceMetadatumExists

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

InstanceMetadatumExists checks if the InstanceMetadatum row exists.

func InstanceUserdata

func InstanceUserdata(mods ...qm.QueryMod) instanceUserdatumQuery

InstanceUserdata retrieves all the records using an executor.

func InstanceUserdatumExists

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

InstanceUserdatumExists checks if the InstanceUserdatum row exists.

func NewQuery

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

NewQuery initializes a new Query using the passed in QueryMods

Types

type InstanceIPAddress

type InstanceIPAddress struct {
	ID         string    `boil:"id" json:"id" toml:"id" yaml:"id"`
	InstanceID string    `boil:"instance_id" json:"instance_id" toml:"instance_id" yaml:"instance_id"`
	Address    string    `boil:"address" json:"address" toml:"address" yaml:"address"`
	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 *instanceIPAddressR `boil:"-" json:"-" toml:"-" yaml:"-"`
	L instanceIPAddressL  `boil:"-" json:"-" toml:"-" yaml:"-"`
}

InstanceIPAddress is an object representing the database table.

func FindInstanceIPAddress

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

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

func (*InstanceIPAddress) Delete

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

func (*InstanceIPAddress) Insert

func (o *InstanceIPAddress) 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 (*InstanceIPAddress) Reload

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

func (*InstanceIPAddress) Update

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

Update uses an executor to update the InstanceIPAddress. 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 (*InstanceIPAddress) Upsert

func (o *InstanceIPAddress) 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 InstanceIPAddressHook

type InstanceIPAddressHook func(context.Context, boil.ContextExecutor, *InstanceIPAddress) error

InstanceIPAddressHook is the signature for custom InstanceIPAddress hook methods

type InstanceIPAddressSlice

type InstanceIPAddressSlice []*InstanceIPAddress

InstanceIPAddressSlice is an alias for a slice of pointers to InstanceIPAddress. This should almost always be used instead of []InstanceIPAddress.

func (InstanceIPAddressSlice) DeleteAll

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

func (*InstanceIPAddressSlice) ReloadAll

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

func (InstanceIPAddressSlice) UpdateAll

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

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

type InstanceMetadatum

type InstanceMetadatum struct {
	ID        string     `boil:"id" json:"id" toml:"id" yaml:"id"`
	Metadata  types.JSON `boil:"metadata" json:"metadata" toml:"metadata" yaml:"metadata"`
	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 *instanceMetadatumR `boil:"-" json:"-" toml:"-" yaml:"-"`
	L instanceMetadatumL  `boil:"-" json:"-" toml:"-" yaml:"-"`
}

InstanceMetadatum is an object representing the database table.

func FindInstanceMetadatum

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

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

func (*InstanceMetadatum) Delete

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

func (*InstanceMetadatum) Insert

func (o *InstanceMetadatum) 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 (*InstanceMetadatum) Reload

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

func (*InstanceMetadatum) Update

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

Update uses an executor to update the InstanceMetadatum. 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 (*InstanceMetadatum) Upsert

func (o *InstanceMetadatum) 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 InstanceMetadatumHook

type InstanceMetadatumHook func(context.Context, boil.ContextExecutor, *InstanceMetadatum) error

InstanceMetadatumHook is the signature for custom InstanceMetadatum hook methods

type InstanceMetadatumSlice

type InstanceMetadatumSlice []*InstanceMetadatum

InstanceMetadatumSlice is an alias for a slice of pointers to InstanceMetadatum. This should almost always be used instead of []InstanceMetadatum.

func (InstanceMetadatumSlice) DeleteAll

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

func (*InstanceMetadatumSlice) ReloadAll

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

func (InstanceMetadatumSlice) UpdateAll

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

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

type InstanceUserdatum

type InstanceUserdatum struct {
	ID        string     `boil:"id" json:"id" toml:"id" yaml:"id"`
	Userdata  null.Bytes `boil:"userdata" json:"userdata,omitempty" toml:"userdata" yaml:"userdata,omitempty"`
	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 *instanceUserdatumR `boil:"-" json:"-" toml:"-" yaml:"-"`
	L instanceUserdatumL  `boil:"-" json:"-" toml:"-" yaml:"-"`
}

InstanceUserdatum is an object representing the database table.

func FindInstanceUserdatum

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

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

func (*InstanceUserdatum) Delete

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

func (*InstanceUserdatum) Insert

func (o *InstanceUserdatum) 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 (*InstanceUserdatum) Reload

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

func (*InstanceUserdatum) Update

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

Update uses an executor to update the InstanceUserdatum. 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 (*InstanceUserdatum) Upsert

func (o *InstanceUserdatum) 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 InstanceUserdatumHook

type InstanceUserdatumHook func(context.Context, boil.ContextExecutor, *InstanceUserdatum) error

InstanceUserdatumHook is the signature for custom InstanceUserdatum hook methods

type InstanceUserdatumSlice

type InstanceUserdatumSlice []*InstanceUserdatum

InstanceUserdatumSlice is an alias for a slice of pointers to InstanceUserdatum. This should almost always be used instead of []InstanceUserdatum.

func (InstanceUserdatumSlice) DeleteAll

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

func (*InstanceUserdatumSlice) ReloadAll

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

func (InstanceUserdatumSlice) UpdateAll

func (o InstanceUserdatumSlice) 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.

Jump to

Keyboard shortcuts

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