Type Alias frontier_template_runtime::SignedExtra

source ·
pub type SignedExtra = StorageWeightReclaim<Runtime, (CheckNonZeroSender<Runtime>, CheckSpecVersion<Runtime>, CheckTxVersion<Runtime>, CheckGenesis<Runtime>, CheckEra<Runtime>, CheckNonce<Runtime>, CheckWeight<Runtime>, ChargeTransactionPayment<Runtime>)>;
Expand description

The SignedExtension to the basic transaction logic.

Aliased Type§

struct SignedExtra(pub (CheckNonZeroSender<Runtime>, CheckSpecVersion<Runtime>, CheckTxVersion<Runtime>, CheckGenesis<Runtime>, CheckMortality<Runtime>, CheckNonce<Runtime>, CheckWeight<Runtime>, ChargeTransactionPayment<Runtime>), _);

Fields§

§0: (CheckNonZeroSender<Runtime>, CheckSpecVersion<Runtime>, CheckTxVersion<Runtime>, CheckGenesis<Runtime>, CheckMortality<Runtime>, CheckNonce<Runtime>, CheckWeight<Runtime>, ChargeTransactionPayment<Runtime>)

Implementations

§

impl<T, S> StorageWeightReclaim<T, S>

pub fn new(s: S) -> StorageWeightReclaim<T, S>

Create a new StorageWeightReclaim instance.

Trait Implementations

§

impl<T, S> Clone for StorageWeightReclaim<T, S>
where S: Clone,

§

fn clone(&self) -> StorageWeightReclaim<T, S>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
§

impl<T, S> Debug for StorageWeightReclaim<T, S>
where S: Debug,

§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
§

impl<T, S> Decode for StorageWeightReclaim<T, S>
where S: Decode, PhantomData<T>: Decode,

§

fn decode<__CodecInputEdqy>( __codec_input_edqy: &mut __CodecInputEdqy, ) -> Result<StorageWeightReclaim<T, S>, Error>
where __CodecInputEdqy: Input,

Attempt to deserialise the value from input.
§

fn decode_into<I>( input: &mut I, dst: &mut MaybeUninit<Self>, ) -> Result<DecodeFinished, Error>
where I: Input,

Attempt to deserialize the value from input into a pre-allocated piece of memory. Read more
§

fn skip<I>(input: &mut I) -> Result<(), Error>
where I: Input,

Attempt to skip the encoded value from input. Read more
§

fn encoded_fixed_size() -> Option<usize>

Returns the fixed encoded size of the type. Read more
§

impl<T, S> Default for StorageWeightReclaim<T, S>
where S: Default,

§

fn default() -> StorageWeightReclaim<T, S>

Returns the “default value” for a type. Read more
§

impl<T, S> Encode for StorageWeightReclaim<T, S>
where S: Encode, PhantomData<T>: Encode,

§

fn size_hint(&self) -> usize

If possible give a hint of expected size of the encoding. Read more
§

fn encode_to<__CodecOutputEdqy>( &self, __codec_dest_edqy: &mut __CodecOutputEdqy, )
where __CodecOutputEdqy: Output + ?Sized,

Convert self to a slice and append it to the destination.
§

fn encode(&self) -> Vec<u8>

Convert self to an owned vector.
§

fn using_encoded<R, F>(&self, f: F) -> R
where F: FnOnce(&[u8]) -> R,

Convert self to a slice and then invoke the given closure with it.
§

fn encoded_size(&self) -> usize

Calculates the encoded size. Read more
§

impl<T, S> From<S> for StorageWeightReclaim<T, S>

§

fn from(s: S) -> StorageWeightReclaim<T, S>

Converts to this type from the input type.
§

impl<T, S> PartialEq for StorageWeightReclaim<T, S>
where S: PartialEq,

§

fn eq(&self, __other: &StorageWeightReclaim<T, S>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
§

impl<T, S> TransactionExtension<<T as Config>::RuntimeCall> for StorageWeightReclaim<T, S>
where T: Config + Send + Sync, S: TransactionExtension<<T as Config>::RuntimeCall>, <T as Config>::RuntimeCall: Dispatchable<Info = DispatchInfo, PostInfo = PostDispatchInfo>,

§

const IDENTIFIER: &'static str = "StorageWeightReclaim<Use `metadata()`!>"

Unique identifier of this signed extension. Read more
§

type Implicit = <S as TransactionExtension<<T as Config>::RuntimeCall>>::Implicit

Any additional data which was known at the time of transaction construction and can be useful in authenticating the transaction. This is determined dynamically in part from the on-chain environment using the implicit function and not directly contained in the transaction itself and therefore is considered “implicit”.
§

type Val = (Option<u64>, <S as TransactionExtension<<T as Config>::RuntimeCall>>::Val)

The type that encodes information that can be passed from validate to prepare.
§

type Pre = (Option<u64>, <S as TransactionExtension<<T as Config>::RuntimeCall>>::Pre)

The type that encodes information that can be passed from prepare to post_dispatch.
§

fn implicit( &self, ) -> Result<<StorageWeightReclaim<T, S> as TransactionExtension<<T as Config>::RuntimeCall>>::Implicit, TransactionValidityError>

Determine any additional data which was known at the time of transaction construction and can be useful in authenticating the transaction. The expected usage of this is to include in any data which is signed and verified as part of transaction validation. Also perform any pre-signature-verification checks and return an error if needed.
§

fn metadata() -> Vec<TransactionExtensionMetadata>

Returns the metadata for this extension. Read more
§

fn weight(&self, call: &<T as Config>::RuntimeCall) -> Weight

The weight consumed by executing this extension instance fully during transaction dispatch.
§

fn validate( &self, origin: <T as Config>::RuntimeOrigin, call: &<T as Config>::RuntimeCall, info: &<<T as Config>::RuntimeCall as Dispatchable>::Info, len: usize, self_implicit: <StorageWeightReclaim<T, S> as TransactionExtension<<T as Config>::RuntimeCall>>::Implicit, inherited_implication: &impl Implication, source: TransactionSource, ) -> Result<(ValidTransaction, <StorageWeightReclaim<T, S> as TransactionExtension<<T as Config>::RuntimeCall>>::Val, <T as Config>::RuntimeOrigin), TransactionValidityError>

Validate a transaction for the transaction queue. Read more
§

fn prepare( self, val: <StorageWeightReclaim<T, S> as TransactionExtension<<T as Config>::RuntimeCall>>::Val, origin: &<T as Config>::RuntimeOrigin, call: &<T as Config>::RuntimeCall, info: &<<T as Config>::RuntimeCall as Dispatchable>::Info, len: usize, ) -> Result<<StorageWeightReclaim<T, S> as TransactionExtension<<T as Config>::RuntimeCall>>::Pre, TransactionValidityError>

Do any pre-flight stuff for a transaction after validation. Read more
§

fn post_dispatch_details( pre: <StorageWeightReclaim<T, S> as TransactionExtension<<T as Config>::RuntimeCall>>::Pre, info: &<<T as Config>::RuntimeCall as Dispatchable>::Info, post_info: &<<T as Config>::RuntimeCall as Dispatchable>::PostInfo, len: usize, result: &Result<(), DispatchError>, ) -> Result<Weight, TransactionValidityError>

Do any post-flight stuff for an extrinsic. Read more
§

fn bare_validate( call: &<T as Config>::RuntimeCall, info: &<<T as Config>::RuntimeCall as Dispatchable>::Info, len: usize, ) -> Result<ValidTransaction, TransactionValidityError>

Validation logic for bare extrinsics. Read more
§

fn bare_validate_and_prepare( call: &<T as Config>::RuntimeCall, info: &<<T as Config>::RuntimeCall as Dispatchable>::Info, len: usize, ) -> Result<(), TransactionValidityError>

All pre-flight logic run before dispatching bare extrinsics. Read more
§

fn bare_post_dispatch( info: &<<T as Config>::RuntimeCall as Dispatchable>::Info, post_info: &mut <<T as Config>::RuntimeCall as Dispatchable>::PostInfo, len: usize, result: &Result<(), DispatchError>, ) -> Result<(), TransactionValidityError>

Post dispatch logic run after dispatching bare extrinsics. Read more
§

fn post_dispatch( pre: Self::Pre, info: &<Call as Dispatchable>::Info, post_info: &mut <Call as Dispatchable>::PostInfo, len: usize, result: &Result<(), DispatchError>, ) -> Result<(), TransactionValidityError>

A wrapper for post_dispatch_details that refunds the unspent weight consumed by this extension into the post dispatch information. Read more
§

impl<T, S> TypeInfo for StorageWeightReclaim<T, S>
where S: TypeInfo + 'static, PhantomData<T>: TypeInfo + 'static, T: 'static,

§

type Identity = StorageWeightReclaim<T, S>

The type identifying for which type info is provided. Read more
§

fn type_info() -> Type

Returns the static type identifier for Self.
§

impl<T, S> DecodeWithMemTracking for StorageWeightReclaim<T, S>
where S: DecodeWithMemTracking, PhantomData<T>: DecodeWithMemTracking,

§

impl<T, S> EncodeLike for StorageWeightReclaim<T, S>
where S: Encode, PhantomData<T>: Encode,

§

impl<T, S> Eq for StorageWeightReclaim<T, S>
where S: Eq,