referrerpolicy=no-referrer-when-downgrade
parachain_template_runtime

Type Alias UncheckedExtrinsic

Source
pub type UncheckedExtrinsic = UncheckedExtrinsic<Address, RuntimeCall, Signature, TxExtension>;
Expand description

Unchecked extrinsic type as expected by this runtime.

Aliased Type§

struct UncheckedExtrinsic {
    pub preamble: Preamble<MultiAddress<AccountId32, ()>, MultiSignature, StorageWeightReclaim<Runtime, (CheckNonZeroSender<Runtime>, CheckSpecVersion<Runtime>, CheckTxVersion<Runtime>, CheckGenesis<Runtime>, CheckMortality<Runtime>, CheckNonce<Runtime>, CheckWeight<Runtime>, ChargeTransactionPayment<Runtime>, CheckMetadataHash<Runtime>)>>,
    pub function: RuntimeCall,
}

Fields§

§preamble: Preamble<MultiAddress<AccountId32, ()>, MultiSignature, StorageWeightReclaim<Runtime, (CheckNonZeroSender<Runtime>, CheckSpecVersion<Runtime>, CheckTxVersion<Runtime>, CheckGenesis<Runtime>, CheckMortality<Runtime>, CheckNonce<Runtime>, CheckWeight<Runtime>, ChargeTransactionPayment<Runtime>, CheckMetadataHash<Runtime>)>>

Information regarding the type of extrinsic this is (inherent or transaction) as well as associated extension (Extension) data if it’s a transaction and a possible signature.

§function: RuntimeCall

The function that should be called.

Implementations

Source§

impl<Address, Call, Signature, Extension> UncheckedExtrinsic<Address, Call, Signature, Extension>

Source

pub fn new_unsigned( function: Call, ) -> UncheckedExtrinsic<Address, Call, Signature, Extension>

👎Deprecated: Use new_bare instead

New instance of a bare (ne unsigned) extrinsic. This could be used for an inherent or an old-school “unsigned transaction” (which are new being deprecated in favour of general transactions).

Source

pub fn is_inherent(&self) -> bool

Returns true if this extrinsic instance is an inherent, `false`` otherwise.

Source

pub fn is_signed(&self) -> bool

Returns true if this extrinsic instance is an old-school signed transaction, false otherwise.

Source

pub fn from_parts( function: Call, preamble: Preamble<Address, Signature, Extension>, ) -> UncheckedExtrinsic<Address, Call, Signature, Extension>

Create an UncheckedExtrinsic from a Preamble and the actual Call.

Source

pub fn new_bare( function: Call, ) -> UncheckedExtrinsic<Address, Call, Signature, Extension>

New instance of a bare (ne unsigned) extrinsic.

Source

pub fn new_bare_legacy( function: Call, ) -> UncheckedExtrinsic<Address, Call, Signature, Extension>

New instance of a bare (ne unsigned) extrinsic on extrinsic format version 4.

Source

pub fn new_signed( function: Call, signed: Address, signature: Signature, tx_ext: Extension, ) -> UncheckedExtrinsic<Address, Call, Signature, Extension>

New instance of an old-school signed transaction on extrinsic format version 4.

Source

pub fn new_transaction( function: Call, tx_ext: Extension, ) -> UncheckedExtrinsic<Address, Call, Signature, Extension>

New instance of an new-school unsigned transaction.

Source§

impl<Address, Call, Signature, Extension> UncheckedExtrinsic<Address, Call, Signature, Extension>
where Call: Dispatchable, Extension: TransactionExtension<Call>,

Source

pub fn extension_weight(&self) -> Weight

Returns the weight of the extension of this transaction, if present. If the transaction doesn’t use any extension, the weight returned is equal to zero.

Trait Implementations

Source§

impl<LookupSource, AccountId, Call, Signature, Extension, Lookup> Checkable<Lookup> for UncheckedExtrinsic<LookupSource, Call, Signature, Extension>
where LookupSource: Member + MaybeDisplay, Call: Encode + Member + Dispatchable, Signature: Member + Verify, <Signature as Verify>::Signer: IdentifyAccount<AccountId = AccountId>, Extension: Encode + TransactionExtension<Call>, AccountId: Member + MaybeDisplay, Lookup: Lookup<Source = LookupSource, Target = AccountId>,

Source§

type Checked = CheckedExtrinsic<AccountId, Call, Extension>

Returned if check succeeds.
Source§

fn check( self, lookup: &Lookup, ) -> Result<<UncheckedExtrinsic<LookupSource, Call, Signature, Extension> as Checkable<Lookup>>::Checked, TransactionValidityError>

Check self, given an instance of Context.
Source§

fn unchecked_into_checked_i_know_what_i_am_doing( self, lookup: &Lookup, ) -> Result<<UncheckedExtrinsic<LookupSource, Call, Signature, Extension> as Checkable<Lookup>>::Checked, TransactionValidityError>

Blindly check self. Read more
Source§

impl<Address, Call, Signature, Extension> Clone for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Address: Clone, Call: Clone, Signature: Clone, Extension: Clone,

Source§

fn clone(&self) -> UncheckedExtrinsic<Address, Call, Signature, Extension>

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
Source§

impl<Address, Call, Signature, Extension> Debug for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Address: Debug, Call: Debug, Signature: Debug, Extension: Debug,

Source§

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

Formats the value using the given formatter. Read more
Source§

impl<Address, Call, Signature, Extension> Decode for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Address: Decode, Signature: Decode, Call: Decode, Extension: Decode,

Source§

fn decode<I>( input: &mut I, ) -> Result<UncheckedExtrinsic<Address, Call, Signature, Extension>, Error>
where I: 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
Source§

impl<'a, Address, Signature, Call, Extension> Deserialize<'a> for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Address: Decode, Signature: Decode, Call: Decode, Extension: Decode,

Source§

fn deserialize<D>( de: D, ) -> Result<UncheckedExtrinsic<Address, Call, Signature, Extension>, <D as Deserializer<'a>>::Error>
where D: Deserializer<'a>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl<Address, Call, Signature, Extension> Encode for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Preamble<Address, Signature, Extension>: Encode, Call: Encode, Extension: Encode,

Source§

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

Convert self to an owned vector.
§

fn size_hint(&self) -> usize

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

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

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

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
Source§

impl<Address, Call, Signature, Extra> ExtrinsicCall for UncheckedExtrinsic<Address, Call, Signature, Extra>
where Address: TypeInfo, Call: TypeInfo, Signature: TypeInfo, Extra: TypeInfo,

Source§

type Call = Call

Source§

fn call(&self) -> &Call

Get the call of the extrinsic.
Source§

impl<Address, Call, Signature, Extension> ExtrinsicLike for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Address: TypeInfo, Call: TypeInfo, Signature: TypeInfo, Extension: TypeInfo,

Source§

fn is_bare(&self) -> bool

Returns true if this Extrinsic is bare.
Source§

fn is_signed(&self) -> Option<bool>

👎Deprecated: Use and implement !is_bare() instead
Is this Extrinsic signed? If no information are available about signed/unsigned, None should be returned.
Source§

impl<Address, Call, Signature, Extension> ExtrinsicMetadata for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Call: Dispatchable, Extension: TransactionExtension<Call>,

Source§

const VERSIONS: &'static [u8] = _

The format versions of the Extrinsic. Read more
Source§

type TransactionExtensions = Extension

Transaction extensions attached to this Extrinsic.
Source§

impl<Address, Call, Signature, Extension> GetDispatchInfo for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Call: Dispatchable + GetDispatchInfo, Extension: TransactionExtension<Call>,

Implementation for unchecked extrinsic.

Source§

fn get_dispatch_info(&self) -> DispatchInfo

Return a DispatchInfo, containing relevant information of this dispatch. Read more
Source§

impl<Address, Call, Signature, Extra> InherentBuilder for UncheckedExtrinsic<Address, Call, Signature, Extra>
where Address: TypeInfo, Call: TypeInfo, Signature: TypeInfo, Extra: TypeInfo,

Source§

fn new_inherent( call: <UncheckedExtrinsic<Address, Call, Signature, Extra> as ExtrinsicCall>::Call, ) -> UncheckedExtrinsic<Address, Call, Signature, Extra>

Create a new inherent from a given call.
Source§

impl<Address, Call, Signature, Extension> PartialEq for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Address: PartialEq, Call: PartialEq, Signature: PartialEq, Extension: PartialEq,

Source§

fn eq( &self, other: &UncheckedExtrinsic<Address, Call, Signature, Extension>, ) -> 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.
Source§

impl<Address, Signature, Call, Extension> Serialize for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Address: Encode, Signature: Encode, Call: Encode, Extension: Encode,

Source§

fn serialize<S>( &self, seq: S, ) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>
where S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl<Address, Call, Signature, Extension> SignedTransactionBuilder for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Address: TypeInfo, Call: TypeInfo, Signature: TypeInfo, Extension: TypeInfo,

Source§

type Address = Address

Source§

type Signature = Signature

Source§

type Extension = Extension

Source§

fn new_signed_transaction( call: <UncheckedExtrinsic<Address, Call, Signature, Extension> as ExtrinsicCall>::Call, signed: Address, signature: Signature, tx_ext: Extension, ) -> UncheckedExtrinsic<Address, Call, Signature, Extension>

Create a new signed transaction from a given call and extension using the provided signature data.
Source§

impl<Address, Call, Signature, Extension> TypeInfo for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Address: StaticTypeInfo, Call: StaticTypeInfo, Signature: StaticTypeInfo, Extension: StaticTypeInfo,

Manual [TypeInfo] implementation because of custom encoding. The data is a valid encoded Vec<u8>, but requires some logic to extract the signature and payload.

See UncheckedExtrinsic::encode and UncheckedExtrinsic::decode.

Source§

type Identity = UncheckedExtrinsic<Address, Call, Signature, Extension>

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

fn type_info() -> Type

Returns the static type identifier for Self.
Source§

impl<Address, Call, Signature, Extension> DecodeWithMemTracking for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Address: DecodeWithMemTracking, Call: DecodeWithMemTracking, Signature: DecodeWithMemTracking, Extension: DecodeWithMemTracking,

Source§

impl<Address, Call, Signature, Extension> EncodeLike for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Address: Encode, Signature: Encode, Call: Encode + Dispatchable, Extension: TransactionExtension<Call>,

Source§

impl<Address, Call, Signature, Extension> Eq for UncheckedExtrinsic<Address, Call, Signature, Extension>
where Address: Eq, Call: Eq, Signature: Eq, Extension: Eq,

Source§

impl<Address, Call, Signature, Extension> StructuralPartialEq for UncheckedExtrinsic<Address, Call, Signature, Extension>