referrerpolicy=no-referrer-when-downgrade
pallet_nfts

Type Alias PreSignedMintOf

Source
pub type PreSignedMintOf<T, I = ()> = PreSignedMint<<T as Config<I>>::CollectionId, <T as Config<I>>::ItemId, <T as SystemConfig>::AccountId, BlockNumberFor<T, I>, BalanceOf<T, I>>;
Expand description

A type alias for the pre-signed minting configuration for a specified collection.

Aliased Type§

struct PreSignedMintOf<T, I = ()> {
    pub collection: <T as Config<I>>::CollectionId,
    pub item: <T as Config<I>>::ItemId,
    pub attributes: Vec<(Vec<u8>, Vec<u8>)>,
    pub metadata: Vec<u8>,
    pub only_account: Option<<T as Config>::AccountId>,
    pub deadline: <<T as Config<I>>::BlockNumberProvider as BlockNumberProvider>::BlockNumber,
    pub mint_price: Option<<<T as Config<I>>::Currency as Currency<<T as Config>::AccountId>>::Balance>,
}

Fields§

§collection: <T as Config<I>>::CollectionId

A collection of the item to be minted.

§item: <T as Config<I>>::ItemId

Item’s ID.

§attributes: Vec<(Vec<u8>, Vec<u8>)>

Additional item’s key-value attributes.

§metadata: Vec<u8>

Additional item’s metadata.

§only_account: Option<<T as Config>::AccountId>

Restrict the claim to a particular account.

§deadline: <<T as Config<I>>::BlockNumberProvider as BlockNumberProvider>::BlockNumber

A deadline for the signature.

§mint_price: Option<<<T as Config<I>>::Currency as Currency<<T as Config>::AccountId>>::Balance>

An optional price the claimer would need to pay for the mint.

Trait Implementations

Source§

impl<CollectionId: Clone, ItemId: Clone, AccountId: Clone, Deadline: Clone, Balance: Clone> Clone for PreSignedMint<CollectionId, ItemId, AccountId, Deadline, Balance>

Source§

fn clone( &self, ) -> PreSignedMint<CollectionId, ItemId, AccountId, Deadline, Balance>

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<CollectionId, ItemId, AccountId, Deadline, Balance> Debug for PreSignedMint<CollectionId, ItemId, AccountId, Deadline, Balance>
where CollectionId: Debug, ItemId: Debug, AccountId: Debug, Deadline: Debug, Balance: Debug,

Source§

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

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

impl<CollectionId, ItemId, AccountId, Deadline, Balance> Decode for PreSignedMint<CollectionId, ItemId, AccountId, Deadline, Balance>
where CollectionId: Decode, ItemId: Decode, Option<AccountId>: Decode, Deadline: Decode, Option<Balance>: Decode,

Source§

fn decode<__CodecInputEdqy: Input>( __codec_input_edqy: &mut __CodecInputEdqy, ) -> Result<Self, Error>

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<CollectionId, ItemId, AccountId, Deadline, Balance> Encode for PreSignedMint<CollectionId, ItemId, AccountId, Deadline, Balance>
where CollectionId: Encode, ItemId: Encode, Option<AccountId>: Encode, Deadline: Encode, Option<Balance>: Encode,

Source§

fn size_hint(&self) -> usize

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

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

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

impl<CollectionId: PartialEq, ItemId: PartialEq, AccountId: PartialEq, Deadline: PartialEq, Balance: PartialEq> PartialEq for PreSignedMint<CollectionId, ItemId, AccountId, Deadline, Balance>

Source§

fn eq( &self, other: &PreSignedMint<CollectionId, ItemId, AccountId, Deadline, Balance>, ) -> 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<CollectionId, ItemId, AccountId, Deadline, Balance> TypeInfo for PreSignedMint<CollectionId, ItemId, AccountId, Deadline, Balance>
where CollectionId: TypeInfo + 'static, ItemId: TypeInfo + 'static, Option<AccountId>: TypeInfo + 'static, Deadline: TypeInfo + 'static, Option<Balance>: TypeInfo + 'static, AccountId: TypeInfo + 'static, Balance: TypeInfo + 'static,

Source§

type Identity = PreSignedMint<CollectionId, ItemId, AccountId, Deadline, Balance>

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<CollectionId, ItemId, AccountId, Deadline, Balance> DecodeWithMemTracking for PreSignedMint<CollectionId, ItemId, AccountId, Deadline, Balance>
where CollectionId: DecodeWithMemTracking, ItemId: DecodeWithMemTracking, Option<AccountId>: DecodeWithMemTracking, Deadline: DecodeWithMemTracking, Option<Balance>: DecodeWithMemTracking,

Source§

impl<CollectionId, ItemId, AccountId, Deadline, Balance> EncodeLike for PreSignedMint<CollectionId, ItemId, AccountId, Deadline, Balance>
where CollectionId: Encode, ItemId: Encode, Option<AccountId>: Encode, Deadline: Encode, Option<Balance>: Encode,

Source§

impl<CollectionId: Eq, ItemId: Eq, AccountId: Eq, Deadline: Eq, Balance: Eq> Eq for PreSignedMint<CollectionId, ItemId, AccountId, Deadline, Balance>

Source§

impl<CollectionId, ItemId, AccountId, Deadline, Balance> StructuralPartialEq for PreSignedMint<CollectionId, ItemId, AccountId, Deadline, Balance>