migration

package
v0.0.0-...-3eec7cb Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Migration

type Migration struct {
	bun.BaseModel `bun:"migrations"`

	ID             int64 `bun:"id,pk,notnull,autoincrement"`
	ProtocolID     int64 `bun:"protocol_id,type:SMALLINT"`
	PrevProtocolID int64
	Hash           []byte
	Timestamp      time.Time `bun:"timestamp,pk,notnull"`
	Level          int64
	Kind           types.MigrationKind `bun:"kind,type:SMALLINT"`
	ContractID     int64
	Contract       contract.Contract `bun:"rel:belongs-to"`
}

Migration -

func (*Migration) GetID

func (m *Migration) GetID() int64

GetID -

func (*Migration) LogFields

func (m *Migration) LogFields() map[string]interface{}

LogFields -

func (Migration) TableName

func (Migration) TableName() string

TableName -

type Repository

type Repository interface {
	Get(ctx context.Context, contractID int64) ([]Migration, error)
}

Jump to

Keyboard shortcuts

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