[][src]Struct pallet_contracts::Schedule

pub struct Schedule {
    pub version: u32,
    pub put_code_per_byte_cost: Gas,
    pub grow_mem_cost: Gas,
    pub regular_op_cost: Gas,
    pub return_data_per_byte_cost: Gas,
    pub event_data_per_byte_cost: Gas,
    pub event_per_topic_cost: Gas,
    pub event_base_cost: Gas,
    pub call_base_cost: Gas,
    pub instantiate_base_cost: Gas,
    pub dispatch_base_cost: Gas,
    pub sandbox_data_read_cost: Gas,
    pub sandbox_data_write_cost: Gas,
    pub transfer_cost: Gas,
    pub instantiate_cost: Gas,
    pub max_event_topics: u32,
    pub max_stack_height: u32,
    pub max_memory_pages: u32,
    pub max_table_size: u32,
    pub enable_println: bool,
    pub max_subject_len: u32,
    pub max_code_size: u32,
}

Definition of the cost schedule and other parameterizations for wasm vm.

Fields

version: u32

Version of the schedule.

put_code_per_byte_cost: Gas

Cost of putting a byte of code into storage.

grow_mem_cost: Gas

Gas cost of a growing memory by single page.

regular_op_cost: Gas

Gas cost of a regular operation.

return_data_per_byte_cost: Gas

Gas cost per one byte returned.

event_data_per_byte_cost: Gas

Gas cost to deposit an event; the per-byte portion.

event_per_topic_cost: Gas

Gas cost to deposit an event; the cost per topic.

event_base_cost: Gas

Gas cost to deposit an event; the base.

call_base_cost: Gas

Base gas cost to call into a contract.

instantiate_base_cost: Gas

Base gas cost to instantiate a contract.

dispatch_base_cost: Gas

Base gas cost to dispatch a runtime call.

sandbox_data_read_cost: Gas

Gas cost per one byte read from the sandbox memory.

sandbox_data_write_cost: Gas

Gas cost per one byte written to the sandbox memory.

transfer_cost: Gas

Cost for a simple balance transfer.

instantiate_cost: Gas

Cost for instantiating a new contract.

max_event_topics: u32

The maximum number of topics supported by an event.

max_stack_height: u32

Maximum allowed stack height.

See https://wiki.parity.io/WebAssembly-StackHeight to find out how the stack frame cost is calculated.

max_memory_pages: u32

Maximum number of memory pages allowed for a contract.

max_table_size: u32

Maximum allowed size of a declared table.

enable_println: bool

Whether the seal_println function is allowed to be used contracts. MUST only be enabled for dev chains, NOT for production chains

max_subject_len: u32

The maximum length of a subject used for PRNG generation.

max_code_size: u32

The maximum length of a contract code in bytes. This limit applies to the uninstrumented

Trait Implementations

impl Clone for Schedule[src]

impl Debug for Schedule[src]

impl Decode for Schedule[src]

impl Default for Schedule[src]

impl<'de> Deserialize<'de> for Schedule[src]

impl Encode for Schedule[src]

impl EncodeLike<Schedule> for Schedule[src]

impl Eq for Schedule[src]

impl PartialEq<Schedule> for Schedule[src]

impl Serialize for Schedule[src]

impl StructuralEq for Schedule[src]

impl StructuralPartialEq for Schedule[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> CheckedConversion for T[src]

impl<T> Clear for T where
    T: PartialEq<T> + Eq + Default
[src]

impl<S> Codec for S where
    S: Encode + Decode
[src]

impl<T> DecodeAll for T where
    T: Decode
[src]

impl<T> DecodeLimit for T where
    T: Decode
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> DynClone for T where
    T: Clone
[src]

impl<'_, '_, T> EncodeLike<&'_ &'_ T> for T where
    T: Encode
[src]

impl<'_, T> EncodeLike<&'_ T> for T where
    T: Encode
[src]

impl<'_, T> EncodeLike<&'_ mut T> for T where
    T: Encode
[src]

impl<T> EncodeLike<Arc<T>> for T where
    T: Encode
[src]

impl<T> EncodeLike<Box<T, Global>> for T where
    T: Encode
[src]

impl<'a, T> EncodeLike<Cow<'a, T>> for T where
    T: Encode + ToOwned
[src]

impl<T> EncodeLike<Rc<T>> for T where
    T: Encode
[src]

impl<T> From<T> for T[src]

impl<S> FullCodec for S where
    S: Decode + FullEncode
[src]

impl<S> FullEncode for S where
    S: Encode + EncodeLike<S>, 
[src]

impl<T> Hashable for T where
    T: Codec
[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> IsType<T> for T[src]

impl<T, Outer> IsWrappedBy<Outer> for T where
    T: From<Outer>,
    Outer: AsRef<T> + AsMut<T> + From<T>, 
[src]

pub fn from_ref(outer: &Outer) -> &T[src]

Get a reference to the inner from the outer.

pub fn from_mut(outer: &mut Outer) -> &mut T[src]

Get a mutable reference to the inner from the outer.

impl<T> KeyedVec for T where
    T: Codec
[src]

impl<T> MaybeDebug for T where
    T: Debug

impl<T> MaybeDebug for T where
    T: Debug

impl<T> MaybeRefUnwindSafe for T where
    T: RefUnwindSafe

impl<T> MaybeSerialize for T where
    T: Serialize
[src]

impl<T> MaybeSerializeDeserialize for T where
    T: DeserializeOwned + Serialize
[src]

impl<T> Member for T where
    T: 'static + Clone + PartialEq<T> + Eq + Send + Sync + Debug
[src]

impl<T> Parameter for T where
    T: Codec + EncodeLike<T> + Clone + Eq + Debug
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> SaturatedConversion for T

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<S, T> UncheckedInto<T> for S where
    T: UncheckedFrom<S>, 
[src]

impl<T, S> UniqueSaturatedInto<T> for S where
    T: Bounded,
    S: TryInto<T>, 

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,