pub struct ModuleMetadata {
pub name: DecodeDifferent<&'static str, String>,
pub storage: Option<DecodeDifferent<FnEncode<StorageMetadata>, StorageMetadata>>,
pub calls: Option<DecodeDifferent<FnEncode<&'static [FunctionMetadata]>, Vec<FunctionMetadata>>>,
pub event: Option<DecodeDifferent<FnEncode<&'static [EventMetadata]>, Vec<EventMetadata>>>,
pub constants: DecodeDifferent<FnEncode<&'static [ModuleConstantMetadata]>, Vec<ModuleConstantMetadata>>,
pub errors: DecodeDifferent<FnEncode<&'static [ErrorMetadata]>, Vec<ErrorMetadata>>,
pub index: u8,
}Expand description
All metadata about an runtime module.
Fields§
§name: DecodeDifferent<&'static str, String>§storage: Option<DecodeDifferent<FnEncode<StorageMetadata>, StorageMetadata>>§calls: Option<DecodeDifferent<FnEncode<&'static [FunctionMetadata]>, Vec<FunctionMetadata>>>§event: Option<DecodeDifferent<FnEncode<&'static [EventMetadata]>, Vec<EventMetadata>>>§constants: DecodeDifferent<FnEncode<&'static [ModuleConstantMetadata]>, Vec<ModuleConstantMetadata>>§errors: DecodeDifferent<FnEncode<&'static [ErrorMetadata]>, Vec<ErrorMetadata>>§index: u8Define the index of the module, this index will be used for the encoding of module event, call and origin variants.
Trait Implementations§
Source§impl Clone for ModuleMetadata
impl Clone for ModuleMetadata
Source§fn clone(&self) -> ModuleMetadata
fn clone(&self) -> ModuleMetadata
Returns a duplicate 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 Debug for ModuleMetadata
impl Debug for ModuleMetadata
Source§impl Decode for ModuleMetadata
impl Decode for ModuleMetadata
Source§impl Encode for ModuleMetadata
impl Encode for ModuleMetadata
Source§fn encode_to<__CodecOutputEdqy: Output + ?Sized>(
&self,
__codec_dest_edqy: &mut __CodecOutputEdqy,
)
fn encode_to<__CodecOutputEdqy: Output + ?Sized>( &self, __codec_dest_edqy: &mut __CodecOutputEdqy, )
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) -> R
fn using_encoded<R, F>(&self, f: F) -> 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 PartialEq for ModuleMetadata
impl PartialEq for ModuleMetadata
Source§impl Serialize for ModuleMetadata
impl Serialize for ModuleMetadata
impl EncodeLike for ModuleMetadata
impl Eq for ModuleMetadata
impl StructuralPartialEq for ModuleMetadata
Auto Trait Implementations§
impl Freeze for ModuleMetadata
impl !RefUnwindSafe for ModuleMetadata
impl Send for ModuleMetadata
impl Sync for ModuleMetadata
impl Unpin for ModuleMetadata
impl !UnwindSafe for ModuleMetadata
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> DecodeLimit for Twhere
T: Decode,
impl<T> DecodeLimit for Twhere
T: Decode,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
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.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§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.Source§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.Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
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 T
impl<T, Outer> IsWrappedBy<Outer> for T
Source§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.