pub struct EngineConfig { /* private fields */ }
Expand description
The runtime configuration of the execution engine
Implementations§
Source§impl EngineConfig
impl EngineConfig
Sourcepub fn max_associated_keys(&self) -> u32
pub fn max_associated_keys(&self) -> u32
Returns the current max associated keys config.
Sourcepub fn max_runtime_call_stack_height(&self) -> u32
pub fn max_runtime_call_stack_height(&self) -> u32
Returns the current max runtime call stack height config.
Sourcepub fn wasm_config(&self) -> &WasmConfig
pub fn wasm_config(&self) -> &WasmConfig
Returns the current wasm config.
Sourcepub fn system_config(&self) -> &SystemConfig
pub fn system_config(&self) -> &SystemConfig
Returns the current system config.
Sourcepub fn protocol_version(&self) -> ProtocolVersion
pub fn protocol_version(&self) -> ProtocolVersion
Returns the current protocol version.
Sourcepub fn minimum_delegation_amount(&self) -> u64
pub fn minimum_delegation_amount(&self) -> u64
Returns the minimum delegation amount in motes.
Sourcepub fn maximum_delegation_amount(&self) -> u64
pub fn maximum_delegation_amount(&self) -> u64
Returns the maximum delegation amount in motes.
Sourcepub fn minimum_bid_amount(&self) -> u64
pub fn minimum_bid_amount(&self) -> u64
Returns the minimum delegation amount in motes.
Sourcepub fn strict_argument_checking(&self) -> bool
pub fn strict_argument_checking(&self) -> bool
Get the engine config’s strict argument checking flag.
Sourcepub fn vesting_schedule_period_millis(&self) -> u64
pub fn vesting_schedule_period_millis(&self) -> u64
Get the vesting schedule period.
Sourcepub fn max_delegators_per_validator(&self) -> u32
pub fn max_delegators_per_validator(&self) -> u32
Get the max delegators per validator
Sourcepub fn administrative_accounts(&self) -> &BTreeSet<AccountHash>
pub fn administrative_accounts(&self) -> &BTreeSet<AccountHash>
Returns the engine config’s administrative accounts.
Sourcepub fn allow_auction_bids(&self) -> bool
pub fn allow_auction_bids(&self) -> bool
Returns true if auction bids are allowed.
Sourcepub fn allow_unrestricted_transfers(&self) -> bool
pub fn allow_unrestricted_transfers(&self) -> bool
Returns true if unrestricted transfers are allowed.
Sourcepub fn refund_handling(&self) -> RefundHandling
pub fn refund_handling(&self) -> RefundHandling
Returns the engine config’s refund ratio.
Sourcepub fn fee_handling(&self) -> FeeHandling
pub fn fee_handling(&self) -> FeeHandling
Returns the engine config’s fee handling strategy.
Sourcepub fn storage_costs(&self) -> &StorageCosts
pub fn storage_costs(&self) -> &StorageCosts
Returns the engine config’s storage_costs.
Sourcepub fn compute_rewards(&self) -> bool
pub fn compute_rewards(&self) -> bool
Returns the engine config’s compute rewards flag.
Sourcepub fn trap_on_ambiguous_entity_version(&self) -> bool
pub fn trap_on_ambiguous_entity_version(&self) -> bool
Returns the trap_on_ambiguous_entity_version
flag.
Sourcepub fn set_max_memory(&mut self, new_value: u32)
Available on crate feature test-support
only.
pub fn set_max_memory(&mut self, new_value: u32)
test-support
only.Sets the wasm_config.max_memory
to new_value
.
Trait Implementations§
Source§impl Clone for EngineConfig
impl Clone for EngineConfig
Source§fn clone(&self) -> EngineConfig
fn clone(&self) -> EngineConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for EngineConfig
impl Debug for EngineConfig
Auto Trait Implementations§
impl Freeze for EngineConfig
impl RefUnwindSafe for EngineConfig
impl Send for EngineConfig
impl Sync for EngineConfig
impl Unpin for EngineConfig
impl UnwindSafe for EngineConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more