Trait gear_common::gas_provider::Provider
source · pub trait Provider {
type ExternalOrigin;
type NodeId;
type Balance;
type Funds;
type InternalError: Error;
type Error: From<Self::InternalError>;
type GasTree: LockableTree<ExternalOrigin = Self::ExternalOrigin, NodeId = Self::NodeId, Balance = Self::Balance, Funds = Self::Funds, InternalError = Self::InternalError, Error = Self::Error> + ReservableTree;
// Provided method
fn reset() { ... }
}
Expand description
Represents logic of centralized GasTree-algorithm.
Required Associated Types§
sourcetype ExternalOrigin
type ExternalOrigin
Type representing the external owner of a value (gas) item.
sourcetype InternalError: Error
type InternalError: Error
Types to denote a result of some unbalancing operation - that is operations that create inequality between the underlying value supply and some hypothetical “collateral” asset.
sourcetype Error: From<Self::InternalError>
type Error: From<Self::InternalError>
Error type.
sourcetype GasTree: LockableTree<ExternalOrigin = Self::ExternalOrigin, NodeId = Self::NodeId, Balance = Self::Balance, Funds = Self::Funds, InternalError = Self::InternalError, Error = Self::Error> + ReservableTree
type GasTree: LockableTree<ExternalOrigin = Self::ExternalOrigin, NodeId = Self::NodeId, Balance = Self::Balance, Funds = Self::Funds, InternalError = Self::InternalError, Error = Self::Error> + ReservableTree
A ledger to account for gas creation and consumption.
Provided Methods§
Object Safety§
This trait is not object safe.