cat

package
v0.2.17 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2019 License: AGPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Live = "live"
	Vat  = "vat"
	Vow  = "vow"

	IlkFlip = "flip"
	IlkChop = "chop"
	IlkLump = "lump"
)
View Source
const (
	InsertCatIlkChopQuery = `INSERT INTO maker.cat_ilk_chop (diff_id, header_id, ilk_id, chop) VALUES ($1, $2, $3, $4) ON CONFLICT DO NOTHING`
	InsertCatIlkFlipQuery = `INSERT INTO maker.cat_ilk_flip (diff_id, header_id, ilk_id, flip) VALUES ($1, $2, $3, $4) ON CONFLICT DO NOTHING`
	InsertCatIlkLumpQuery = `INSERT INTO maker.cat_ilk_lump (diff_id, header_id, ilk_id, lump) VALUES ($1, $2, $3, $4) ON CONFLICT DO NOTHING`
)

Variables

View Source
var (
	// wards takes up index 0
	IlksMappingIndex = vdbStorage.IndexOne // bytes32 => flip address; chop (ray), lump (wad) uint256

	LiveKey      = common.HexToHash(vdbStorage.IndexTwo)
	LiveMetadata = vdbStorage.GetValueMetadata(Live, nil, vdbStorage.Uint256)

	VatKey      = common.HexToHash(vdbStorage.IndexThree)
	VatMetadata = vdbStorage.GetValueMetadata(Vat, nil, vdbStorage.Address)

	VowKey      = common.HexToHash(vdbStorage.IndexFour)
	VowMetadata = vdbStorage.GetValueMetadata(Vow, nil, vdbStorage.Address)
)

Functions

func NewKeysLoader added in v0.2.15

func NewKeysLoader(storageRepository mcdStorage.IMakerStorageRepository) storage.KeysLoader

Types

type CatStorageRepository

type CatStorageRepository struct {
	// contains filtered or unexported fields
}

func (*CatStorageRepository) Create

func (repository *CatStorageRepository) Create(diffID, headerID int64, metadata storage.ValueMetadata, value interface{}) error

func (*CatStorageRepository) SetDB

func (repository *CatStorageRepository) SetDB(db *postgres.DB)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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