Module frame_support::dispatch[][src]

Dispatch system. Contains a macro for defining runtime modules and generating values representing lazy module function calls.

Re-exports

pub use crate::weights::GetDispatchInfo;
pub use crate::weights::DispatchInfo;
pub use crate::weights::WeighData;
pub use crate::weights::ClassifyDispatch;
pub use crate::weights::Weight;
pub use crate::weights::PaysFee;
pub use crate::weights::PostDispatchInfo;
pub use crate::weights::WithPostDispatchInfo;
pub use crate::traits::CallMetadata;
pub use crate::traits::GetCallMetadata;
pub use crate::traits::GetCallName;
pub use crate::traits::UnfilteredDispatchable;

Modules

fmt

Utilities for formatting and printing Strings.

marker

Primitive traits and types representing basic properties of types.

result

Error handling with the Result type.

Macros

Clone

Derive macro generating an impl of the trait Clone.

Eq

Derive macro generating an impl of the trait Eq.

PartialEq

Derive macro generating an impl of the trait PartialEq.

Structs

DefaultByteGetter

Wrapper over dyn pointer for accessing a cached once byte value.

ErrorMetadata

All the metadata about a module error.

FunctionArgumentMetadata

All the metadata about a function argument.

FunctionMetadata

All the metadata about a function.

ModuleConstantMetadata

All the metadata about one module constant.

Vec

A contiguous growable array type, written Vec<T> but pronounced ‘vector’.

Enums

DecodeDifferent

A type that decodes to a different type than it encodes. The user needs to make sure that both types use the same encoding.

DispatchError

Reason why a dispatch call failed.

Traits

Callable

Serializable version of pallet dispatchable.

Clone

A common trait for the ability to explicitly duplicate an object.

Codec

Trait that allows zero-copy read/write of value-references to/from slices in LE format.

Decode

Trait that allows zero-copy read of value-references from slices in LE format.

DefaultByte

A technical trait to store lazy initiated vec value as static dyn pointer.

Dispatchable

A lazy call (module function and argument values) that can be executed via its dispatch method.

Encode

Trait that allows zero-copy write of value-references to slices in LE format.

EncodeAsRef

Something that can be encoded as a reference.

EncodeLike

A marker trait that tells the compiler that a type encode to the same representation as another type.

Eq

Trait for equality comparisons which are equivalence relations.

HasCompact

Trait that tells you if a given type can be encoded/decoded in a compact way.

Input

Trait that allows reading of data into a slice.

IsSubType
ModuleErrorMetadata

All the metadata about errors in a module.

Output

Trait that allows writing of data.

Parameter

A type that can be used as a parameter in a dispatchable function.

PartialEq

Trait for equality comparisons which are partial equivalence relations.

Type Definitions

CallableCallFor
DecodeDifferentArray
DispatchErrorWithPostInfo

The error type contained in a DispatchResultWithPostInfo.

DispatchResult

Unaugmented version of DispatchResultWithPostInfo that can be returned from dispatchable functions and is automatically converted to the augmented type. Should be used whenever the PostDispatchInfo does not need to be overwritten. As this should be the common case it is the implicit return type when none is specified.

DispatchResultWithPostInfo

The return typ of a Dispatchable in frame. When returned explicitly from a dispatchable function it allows overriding the default PostDispatchInfo returned from a dispatch.

TransactionPriority

Priority for a transaction. Additive. Higher is better.

Derive Macros

Decode

Derive parity_scale_codec::Decode and for struct and enum.

Encode

Derive parity_scale_codec::Encode and parity_scale_codec::EncodeLike for struct and enum.