Crate stp258_serp[−][src]
Setheum Tokenization Protocol 258 SERP Module
Multi-Currency Stablecoin SERP (Setheum Elastic Reserve Protocol) Module
Overview
The stp258 module provides fungible multiple stable currencies functionality that implements Stp258Currency
trait,
the SerpTes
trait, the SetheumCurrency
trait and the SerpMarket
trait.
The stp258 module provides functions for:
- Expanding and contracting stablecoin supply with SERP algorithms.
- Querying and setting the balance of a given account.
- Getting and managing total issuance.
- Balance transfer between accounts.
- Depositing and withdrawing balance.
- Slashing an account balance.
- Minting and Burning currencies.
Implementations
The stp258 module provides implementations for following traits.
Stp258Currency
- Abstraction over a fungible multi-currency stablecoin system.Stp258CurrencyExtended
- ExtendedStp258Currency
with additional helper types and methods, like updating balance by a given signed integer amount.SerpTes
- Abstraction over a fungible multi-currency stablecoin Token Elasticity of Supply system based on Setheum SERP.SerpMarket
- Abstraction over a fungible multi-currency stablecoin Token Stability system based on Setheum SERP.
Interface
Dispatchable Functions
transfer
- Transfer some balance to another account.transfer_all
- Transfer all balance to another account.
Genesis Config
The STP258 SERP module depends on the GenesisConfig
. Endowed accounts could be
configured in genesis configs.
Re-exports
pub use module::*; |
Modules
module |
Structs
AccountData | balance information for an account. |
BalanceLock | A single lock on a balance. There can be many of these on an account and they “overlap”, so the same balance is frozen by multiple locks. |
BurnDust | |
CurrencyAdapter | |
NegativeImbalance | Opaque, move-only struct with private fields that serves as a token denoting that funds have been destroyed without any equal and opposite accounting. |
PositiveImbalance | Opaque, move-only struct with private fields that serves as a token denoting that funds have been created without any equal and opposite accounting. |
TransferDust |