Documentation ¶
Index ¶
- Variables
- func AddUnlockedBalance(ctx context.Context, db chain.Database, pk crypto.PublicKey, amount uint64, ...) (bool, error)
- func DeleteBalance(ctx context.Context, db chain.Database, pk crypto.PublicKey) error
- func DeletePermissions(ctx context.Context, db chain.Database, actor crypto.PublicKey, ...) error
- func GetBalance(ctx context.Context, db chain.Database, pk crypto.PublicKey) (uint64, uint64, error)
- func GetBalanceFromState(ctx context.Context, f ReadState, pk crypto.PublicKey) (uint64, uint64, error)
- func GetContent(ctx context.Context, db chain.Database, contentID ids.ID) (crypto.PublicKey, uint64, bool, error)
- func GetContentFromState(ctx context.Context, f ReadState, contentID ids.ID) (crypto.PublicKey, uint64, bool, error)
- func GetPermissions(ctx context.Context, db chain.Database, actor crypto.PublicKey, ...) (uint8, uint8, error)
- func GetTransaction(_ context.Context, db database.KeyValueReader, id ids.ID) (bool, int64, bool, uint64, error)
- func IndexContent(ctx context.Context, db chain.Database, contentID ids.ID, pk crypto.PublicKey, ...) error
- func LockBalance(ctx context.Context, db chain.Database, pk crypto.PublicKey, amount uint64) error
- func PrefixBalanceKey(pk crypto.PublicKey) (k []byte)
- func PrefixContentKey(contentID ids.ID) (k []byte)
- func PrefixPermissionsKey(actor crypto.PublicKey, signer crypto.PublicKey) (k []byte)
- func PrefixTxKey(id ids.ID) (k []byte)
- func RewardSearcher(ctx context.Context, db chain.Database, contentID ids.ID, ...) (crypto.PublicKey, error)
- func SetBalance(ctx context.Context, db chain.Database, pk crypto.PublicKey, ...) error
- func SetContent(ctx context.Context, db chain.Database, contentID ids.ID, ...) error
- func SetPermissions(ctx context.Context, db chain.Database, actor crypto.PublicKey, ...) error
- func StoreTransaction(_ context.Context, db database.KeyValueWriter, id ids.ID, t int64, ...) error
- func SubUnlockedBalance(ctx context.Context, db chain.Database, pk crypto.PublicKey, amount uint64) error
- func UnindexContent(ctx context.Context, db chain.Database, contentID ids.ID, pk crypto.PublicKey) error
- func UnlockBalance(ctx context.Context, db chain.Database, pk crypto.PublicKey, amount uint64) error
- type ReadState
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func AddUnlockedBalance ¶
func AddUnlockedBalance( ctx context.Context, db chain.Database, pk crypto.PublicKey, amount uint64, dropIfGone bool, ) (bool, error)
[dropIfGone] is used if the address is cleared out
func DeleteBalance ¶
func DeletePermissions ¶
func GetBalance ¶
func GetBalance( ctx context.Context, db chain.Database, pk crypto.PublicKey, ) (uint64, uint64, error)
If locked is 0, then account does not exist
func GetBalanceFromState ¶
func GetBalanceFromState( ctx context.Context, f ReadState, pk crypto.PublicKey, ) (uint64, uint64, error)
Used to serve RPC queries
func GetContent ¶
func GetContentFromState ¶
func GetPermissions ¶
func GetTransaction ¶
func IndexContent ¶
func LockBalance ¶
func PrefixBalanceKey ¶
[accountPrefix] + [address]
func PrefixContentKey ¶
[contentPrefix] + [contentID]
func PrefixPermissionsKey ¶
[accountPrefix] + [actor] + [signer]
func RewardSearcher ¶
func SetBalance ¶
func SetContent ¶
func SetPermissions ¶
func StoreTransaction ¶
func SubUnlockedBalance ¶
func UnindexContent ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.