Crate namada_shielded_token

Crate namada_shielded_token 

Source
Expand description

Namada shielded token.

Modules§

conversion
MASP rewards conversions
storage_key
Shielded token storage keys
utils
MASP utilities

Structs§

ConversionLeaf
A representation of a leaf in the conversion tree
ConversionState
A representation of the conversion state
Dec
A 256 bit number with POS_DECIMAL_PRECISION number of Dec places.
Key
A storage key is made of storage key segments DbKeySeg, separated by KEY_SEGMENT_SEPARATOR.
MaspEpoch
Wrapper type around Epoch for type safe operations involving the masp epoch
MaspTransaction
A MASP transaction.
MaspTxId
Wrapper for masp_primitive’s TxId
ShieldedParams
Token parameters for each kind of asset held on chain

Enums§

Error
MaspValue
Represents any MASP value

Traits§

OptionExt
An extension to Option to allow turning None case to an Error from a static string (handy for WASM).
ResultExt
Result extension to easily wrap custom errors into Error.
StorageRead
Common storage read interface
StorageWrite
Common storage write interface
WithConversionState
Able to borrow mutable conversion state.

Functions§

mint_rewards
Mint MASP rewards tokens and increment the stored total rewards.
read_token_map
Read the masp token map.
read_total_rewards
Read the total rewards minted by MASP.
read_undated_balance
Read the undated balance of the given token in the MASP.
write_params
Initialize parameters for the token in storage during the genesis block.
write_token_map
Write a new masp token map.

Type Aliases§

Result
Result of a storage API call.