Struct polymesh_api_client::type_def::TypeParameter
source · Expand description
A generic type parameter.
Implementations§
source§impl TypeParameter<MetaForm>
impl TypeParameter<MetaForm>
source§impl TypeParameter<PortableForm>
impl TypeParameter<PortableForm>
sourcepub fn new_portable(
name: <PortableForm as Form>::String,
ty: Option<<PortableForm as Form>::Type>
) -> TypeParameter<PortableForm>
pub fn new_portable(
name: <PortableForm as Form>::String,
ty: Option<<PortableForm as Form>::Type>
) -> TypeParameter<PortableForm>
Create a new TypeParameter in PortableForm.
Trait Implementations§
source§impl<T> Clone for TypeParameter<T>where
T: Clone + Form,
<T as Form>::String: Clone,
<T as Form>::Type: Clone,
impl<T> Clone for TypeParameter<T>where
T: Clone + Form,
<T as Form>::String: Clone,
<T as Form>::Type: Clone,
source§fn clone(&self) -> TypeParameter<T>
fn clone(&self) -> TypeParameter<T>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl<T> Debug for TypeParameter<T>where
T: Debug + Form,
<T as Form>::String: Debug,
<T as Form>::Type: Debug,
impl<T> Debug for TypeParameter<T>where
T: Debug + Form,
<T as Form>::String: Debug,
<T as Form>::Type: Debug,
source§impl<T> Decode for TypeParameter<T>where
T: Form,
<T as Form>::String: Decode,
Option<<T as Form>::Type>: Decode,
impl<T> Decode for TypeParameter<T>where
T: Form,
<T as Form>::String: Decode,
Option<<T as Form>::Type>: Decode,
source§fn decode<__CodecInputEdqy>(
__codec_input_edqy: &mut __CodecInputEdqy
) -> Result<TypeParameter<T>, Error>where
__CodecInputEdqy: Input,
fn decode<__CodecInputEdqy>(
__codec_input_edqy: &mut __CodecInputEdqy
) -> Result<TypeParameter<T>, Error>where
__CodecInputEdqy: Input,
Attempt to deserialise the value from input.
source§impl<'de, T> Deserialize<'de> for TypeParameter<T>where
T: Form,
<T as Form>::Type: DeserializeOwned,
<T as Form>::String: DeserializeOwned,
impl<'de, T> Deserialize<'de> for TypeParameter<T>where
T: Form,
<T as Form>::Type: DeserializeOwned,
<T as Form>::String: DeserializeOwned,
source§fn deserialize<__D>(
__deserializer: __D
) -> Result<TypeParameter<T>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D
) -> Result<TypeParameter<T>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl<T> Encode for TypeParameter<T>where
T: Form,
<T as Form>::String: Encode,
Option<<T as Form>::Type>: Encode,
impl<T> Encode for TypeParameter<T>where
T: Form,
<T as Form>::String: Encode,
Option<<T as Form>::Type>: Encode,
source§fn encode_to<__CodecOutputEdqy>(&self, __codec_dest_edqy: &mut __CodecOutputEdqy)where
__CodecOutputEdqy: Output + ?Sized,
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.
source§fn size_hint(&self) -> usize
fn size_hint(&self) -> usize
If possible give a hint of expected size of the encoding. Read more
source§fn using_encoded<R, F>(&self, f: F) -> Rwhere
F: FnOnce(&[u8]) -> R,
fn using_encoded<R, F>(&self, f: F) -> Rwhere
F: FnOnce(&[u8]) -> R,
Convert self to a slice and then invoke the given closure with it.
source§fn encoded_size(&self) -> usize
fn encoded_size(&self) -> usize
Calculates the encoded size. Read more
source§impl<T> From<(<T as Form>::String, Option<<T as Form>::Type>)> for TypeParameter<T>where
T: Form,
impl<T> From<(<T as Form>::String, Option<<T as Form>::Type>)> for TypeParameter<T>where
T: Form,
source§impl IntoPortable for TypeParameter<MetaForm>
impl IntoPortable for TypeParameter<MetaForm>
§type Output = TypeParameter<PortableForm>
type Output = TypeParameter<PortableForm>
The portable version of
Self.source§fn into_portable(
self,
registry: &mut Registry
) -> <TypeParameter<MetaForm> as IntoPortable>::Output
fn into_portable(
self,
registry: &mut Registry
) -> <TypeParameter<MetaForm> as IntoPortable>::Output
Convert
self to the portable form by using the registry for caching.source§impl<T> Ord for TypeParameter<T>where
T: Ord + Form,
<T as Form>::String: Ord,
<T as Form>::Type: Ord,
impl<T> Ord for TypeParameter<T>where
T: Ord + Form,
<T as Form>::String: Ord,
<T as Form>::Type: Ord,
source§fn cmp(&self, other: &TypeParameter<T>) -> Ordering
fn cmp(&self, other: &TypeParameter<T>) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl<T> PartialEq<TypeParameter<T>> for TypeParameter<T>where
T: PartialEq<T> + Form,
<T as Form>::String: PartialEq<<T as Form>::String>,
<T as Form>::Type: PartialEq<<T as Form>::Type>,
impl<T> PartialEq<TypeParameter<T>> for TypeParameter<T>where
T: PartialEq<T> + Form,
<T as Form>::String: PartialEq<<T as Form>::String>,
<T as Form>::Type: PartialEq<<T as Form>::Type>,
source§fn eq(&self, other: &TypeParameter<T>) -> bool
fn eq(&self, other: &TypeParameter<T>) -> bool
source§impl<T> PartialOrd<TypeParameter<T>> for TypeParameter<T>where
T: PartialOrd<T> + Form,
<T as Form>::String: PartialOrd<<T as Form>::String>,
<T as Form>::Type: PartialOrd<<T as Form>::Type>,
impl<T> PartialOrd<TypeParameter<T>> for TypeParameter<T>where
T: PartialOrd<T> + Form,
<T as Form>::String: PartialOrd<<T as Form>::String>,
<T as Form>::Type: PartialOrd<<T as Form>::Type>,
source§fn partial_cmp(&self, other: &TypeParameter<T>) -> Option<Ordering>
fn partial_cmp(&self, other: &TypeParameter<T>) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self and other) and is used by the <=
operator. Read moresource§impl<T> Serialize for TypeParameter<T>where
T: Form,
<T as Form>::Type: Serialize,
<T as Form>::String: Serialize,
impl<T> Serialize for TypeParameter<T>where
T: Form,
<T as Form>::Type: Serialize,
<T as Form>::String: Serialize,
source§fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl<T> EncodeLike<TypeParameter<T>> for TypeParameter<T>where
T: Form,
<T as Form>::String: Encode,
Option<<T as Form>::Type>: Encode,
impl<T> Eq for TypeParameter<T>where
T: Eq + Form,
<T as Form>::String: Eq,
<T as Form>::Type: Eq,
impl<T> StructuralEq for TypeParameter<T>where
T: Form,
impl<T> StructuralPartialEq for TypeParameter<T>where
T: Form,
Auto Trait Implementations§
impl<T> RefUnwindSafe for TypeParameter<T>where
<T as Form>::String: RefUnwindSafe,
<T as Form>::Type: RefUnwindSafe,
impl<T> Send for TypeParameter<T>where
<T as Form>::String: Send,
<T as Form>::Type: Send,
impl<T> Sync for TypeParameter<T>where
<T as Form>::String: Sync,
<T as Form>::Type: Sync,
impl<T> Unpin for TypeParameter<T>where
<T as Form>::String: Unpin,
<T as Form>::Type: Unpin,
impl<T> UnwindSafe for TypeParameter<T>where
<T as Form>::String: UnwindSafe,
<T as Form>::Type: UnwindSafe,
Blanket Implementations§
source§impl<T> CheckedConversion for T
impl<T> CheckedConversion for T
source§impl<T> DecodeLimit for Twhere
T: Decode,
impl<T> DecodeLimit for Twhere
T: Decode,
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait. Read more§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait. Read more§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s. Read more§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s. Read moresource§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T, Outer> IsWrappedBy<Outer> for Twhere
Outer: AsRef<T> + AsMut<T> + From<T>,
T: From<Outer>,
impl<T, Outer> IsWrappedBy<Outer> for Twhere
Outer: AsRef<T> + AsMut<T> + From<T>,
T: From<Outer>,
source§impl<T> SaturatedConversion for T
impl<T> SaturatedConversion for T
source§fn saturated_from<T>(t: T) -> Selfwhere
Self: UniqueSaturatedFrom<T>,
fn saturated_from<T>(t: T) -> Selfwhere
Self: UniqueSaturatedFrom<T>,
source§fn saturated_into<T>(self) -> Twhere
Self: UniqueSaturatedInto<T>,
fn saturated_into<T>(self) -> Twhere
Self: UniqueSaturatedInto<T>,
Consume self to return an equivalent value of
T. Read moresource§impl<S, T> UncheckedInto<T> for Swhere
T: UncheckedFrom<S>,
impl<S, T> UncheckedInto<T> for Swhere
T: UncheckedFrom<S>,
source§fn unchecked_into(self) -> T
fn unchecked_into(self) -> T
The counterpart to
unchecked_from.source§impl<T, S> UniqueSaturatedInto<T> for Swhere
T: Bounded,
S: TryInto<T>,
impl<T, S> UniqueSaturatedInto<T> for Swhere
T: Bounded,
S: TryInto<T>,
source§fn unique_saturated_into(self) -> T
fn unique_saturated_into(self) -> T
Consume self to return an equivalent value of
T.