Struct wasmer_types::module::ArchivableModuleInfo

source ·
pub struct ArchivableModuleInfo {
Show 23 fields name: Option<String>, hash: Option<ModuleHash>, imports: IndexMap<ImportKey, ImportIndex>, exports: IndexMap<String, ExportIndex>, start_function: Option<FunctionIndex>, table_initializers: Vec<TableInitializer>, passive_elements: BTreeMap<ElemIndex, Box<[FunctionIndex]>>, passive_data: BTreeMap<DataIndex, Box<[u8]>>, global_initializers: PrimaryMap<LocalGlobalIndex, GlobalInit>, function_names: BTreeMap<FunctionIndex, String>, signatures: PrimaryMap<SignatureIndex, FunctionType>, functions: PrimaryMap<FunctionIndex, SignatureIndex>, tables: PrimaryMap<TableIndex, TableType>, memories: PrimaryMap<MemoryIndex, MemoryType>, globals: PrimaryMap<GlobalIndex, GlobalType>, tags: PrimaryMap<TagIndex, SignatureIndex>, custom_sections: IndexMap<String, CustomSectionIndex>, custom_sections_data: PrimaryMap<CustomSectionIndex, Box<[u8]>>, num_imported_functions: usize, num_imported_tables: usize, num_imported_tags: usize, num_imported_memories: usize, num_imported_globals: usize,
}
Expand description

Mirror version of ModuleInfo that can derive rkyv traits

Fields§

§name: Option<String>§hash: Option<ModuleHash>§imports: IndexMap<ImportKey, ImportIndex>§exports: IndexMap<String, ExportIndex>§start_function: Option<FunctionIndex>§table_initializers: Vec<TableInitializer>§passive_elements: BTreeMap<ElemIndex, Box<[FunctionIndex]>>§passive_data: BTreeMap<DataIndex, Box<[u8]>>§global_initializers: PrimaryMap<LocalGlobalIndex, GlobalInit>§function_names: BTreeMap<FunctionIndex, String>§signatures: PrimaryMap<SignatureIndex, FunctionType>§functions: PrimaryMap<FunctionIndex, SignatureIndex>§tables: PrimaryMap<TableIndex, TableType>§memories: PrimaryMap<MemoryIndex, MemoryType>§globals: PrimaryMap<GlobalIndex, GlobalType>§tags: PrimaryMap<TagIndex, SignatureIndex>§custom_sections: IndexMap<String, CustomSectionIndex>§custom_sections_data: PrimaryMap<CustomSectionIndex, Box<[u8]>>§num_imported_functions: usize§num_imported_tables: usize§num_imported_tags: usize§num_imported_memories: usize§num_imported_globals: usize

Trait Implementations§

source§

impl Archive for ArchivableModuleInfo

§

type Archived = ArchivedArchivableModuleInfo

The archived representation of this type. Read more
§

type Resolver = ArchivableModuleInfoResolver

The resolver for this type. It must contain all the additional information from serializing needed to make the archived type from the normal type.
source§

const COPY_OPTIMIZATION: CopyOptimization<Self> = _

An optimization flag that allows the bytes of this type to be copied directly to a writer instead of calling serialize. Read more
source§

fn resolve(&self, resolver: Self::Resolver, out: Place<Self::Archived>)

Creates the archived version of this value at the given position and writes it to the given output. Read more
source§

impl Debug for ArchivableModuleInfo

source§

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

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

impl<__D: Fallible + ?Sized> Deserialize<ArchivableModuleInfo, __D> for Archived<ArchivableModuleInfo>
where Option<String>: Archive, <Option<String> as Archive>::Archived: Deserialize<Option<String>, __D>, Option<ModuleHash>: Archive, <Option<ModuleHash> as Archive>::Archived: Deserialize<Option<ModuleHash>, __D>, IndexMap<ImportKey, ImportIndex>: Archive, <IndexMap<ImportKey, ImportIndex> as Archive>::Archived: Deserialize<IndexMap<ImportKey, ImportIndex>, __D>, IndexMap<String, ExportIndex>: Archive, <IndexMap<String, ExportIndex> as Archive>::Archived: Deserialize<IndexMap<String, ExportIndex>, __D>, Option<FunctionIndex>: Archive, <Option<FunctionIndex> as Archive>::Archived: Deserialize<Option<FunctionIndex>, __D>, Vec<TableInitializer>: Archive, <Vec<TableInitializer> as Archive>::Archived: Deserialize<Vec<TableInitializer>, __D>, BTreeMap<ElemIndex, Box<[FunctionIndex]>>: Archive, <BTreeMap<ElemIndex, Box<[FunctionIndex]>> as Archive>::Archived: Deserialize<BTreeMap<ElemIndex, Box<[FunctionIndex]>>, __D>, BTreeMap<DataIndex, Box<[u8]>>: Archive, <BTreeMap<DataIndex, Box<[u8]>> as Archive>::Archived: Deserialize<BTreeMap<DataIndex, Box<[u8]>>, __D>, PrimaryMap<LocalGlobalIndex, GlobalInit>: Archive, <PrimaryMap<LocalGlobalIndex, GlobalInit> as Archive>::Archived: Deserialize<PrimaryMap<LocalGlobalIndex, GlobalInit>, __D>, BTreeMap<FunctionIndex, String>: Archive, <BTreeMap<FunctionIndex, String> as Archive>::Archived: Deserialize<BTreeMap<FunctionIndex, String>, __D>, PrimaryMap<SignatureIndex, FunctionType>: Archive, <PrimaryMap<SignatureIndex, FunctionType> as Archive>::Archived: Deserialize<PrimaryMap<SignatureIndex, FunctionType>, __D>, PrimaryMap<FunctionIndex, SignatureIndex>: Archive, <PrimaryMap<FunctionIndex, SignatureIndex> as Archive>::Archived: Deserialize<PrimaryMap<FunctionIndex, SignatureIndex>, __D>, PrimaryMap<TableIndex, TableType>: Archive, <PrimaryMap<TableIndex, TableType> as Archive>::Archived: Deserialize<PrimaryMap<TableIndex, TableType>, __D>, PrimaryMap<MemoryIndex, MemoryType>: Archive, <PrimaryMap<MemoryIndex, MemoryType> as Archive>::Archived: Deserialize<PrimaryMap<MemoryIndex, MemoryType>, __D>, PrimaryMap<GlobalIndex, GlobalType>: Archive, <PrimaryMap<GlobalIndex, GlobalType> as Archive>::Archived: Deserialize<PrimaryMap<GlobalIndex, GlobalType>, __D>, PrimaryMap<TagIndex, SignatureIndex>: Archive, <PrimaryMap<TagIndex, SignatureIndex> as Archive>::Archived: Deserialize<PrimaryMap<TagIndex, SignatureIndex>, __D>, IndexMap<String, CustomSectionIndex>: Archive, <IndexMap<String, CustomSectionIndex> as Archive>::Archived: Deserialize<IndexMap<String, CustomSectionIndex>, __D>, PrimaryMap<CustomSectionIndex, Box<[u8]>>: Archive, <PrimaryMap<CustomSectionIndex, Box<[u8]>> as Archive>::Archived: Deserialize<PrimaryMap<CustomSectionIndex, Box<[u8]>>, __D>, usize: Archive, <usize as Archive>::Archived: Deserialize<usize, __D>,

source§

fn deserialize( &self, deserializer: &mut __D, ) -> Result<ArchivableModuleInfo, <__D as Fallible>::Error>

Deserializes using the given deserializer
source§

impl From<&ModuleInfo> for ArchivableModuleInfo

source§

fn from(it: &ModuleInfo) -> Self

Converts to this type from the input type.
source§

impl From<ArchivableModuleInfo> for ModuleInfo

source§

fn from(it: ArchivableModuleInfo) -> Self

Converts to this type from the input type.
source§

impl From<ModuleInfo> for ArchivableModuleInfo

source§

fn from(it: ModuleInfo) -> Self

Converts to this type from the input type.
source§

impl<__S: Fallible + ?Sized> Serialize<__S> for ArchivableModuleInfo
where Option<String>: Serialize<__S>, Option<ModuleHash>: Serialize<__S>, IndexMap<ImportKey, ImportIndex>: Serialize<__S>, IndexMap<String, ExportIndex>: Serialize<__S>, Option<FunctionIndex>: Serialize<__S>, Vec<TableInitializer>: Serialize<__S>, BTreeMap<ElemIndex, Box<[FunctionIndex]>>: Serialize<__S>, BTreeMap<DataIndex, Box<[u8]>>: Serialize<__S>, PrimaryMap<LocalGlobalIndex, GlobalInit>: Serialize<__S>, BTreeMap<FunctionIndex, String>: Serialize<__S>, PrimaryMap<SignatureIndex, FunctionType>: Serialize<__S>, PrimaryMap<FunctionIndex, SignatureIndex>: Serialize<__S>, PrimaryMap<TableIndex, TableType>: Serialize<__S>, PrimaryMap<MemoryIndex, MemoryType>: Serialize<__S>, PrimaryMap<GlobalIndex, GlobalType>: Serialize<__S>, PrimaryMap<TagIndex, SignatureIndex>: Serialize<__S>, IndexMap<String, CustomSectionIndex>: Serialize<__S>, PrimaryMap<CustomSectionIndex, Box<[u8]>>: Serialize<__S>, usize: Serialize<__S>,

source§

fn serialize( &self, serializer: &mut __S, ) -> Result<<Self as Archive>::Resolver, <__S as Fallible>::Error>

Writes the dependencies for the object and returns a resolver that can create the archived type.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<T> ArchivePointee for T

§

type ArchivedMetadata = ()

The archived version of the pointer metadata for this type.
§

fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata

Converts some archived metadata to the pointer metadata for itself.
§

impl<T> ArchiveUnsized for T
where T: Archive,

§

type Archived = <T as Archive>::Archived

The archived counterpart of this type. Unlike Archive, it may be unsized. Read more
§

fn archived_metadata( &self, ) -> <<T as ArchiveUnsized>::Archived as ArchivePointee>::ArchivedMetadata

Creates the archived version of the metadata for this value.
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> LayoutRaw for T

§

fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>

Returns the layout of the type.
§

impl<T, N1, N2> Niching<NichedOption<T, N1>> for N2
where T: SharedNiching<N1, N2>, N1: Niching<T>, N2: Niching<T>,

§

unsafe fn is_niched(niched: *const NichedOption<T, N1>) -> bool

Returns whether the given value has been niched. Read more
§

fn resolve_niched(out: Place<NichedOption<T, N1>>)

Writes data to out indicating that a T is niched.
§

impl<T> Pointee for T

§

type Metadata = ()

The metadata type for pointers and references to this type.
source§

impl<T> Same for T

§

type Output = T

Should always be Self
§

impl<T, S> SerializeUnsized<S> for T
where T: Serialize<S>, S: Fallible + Writer + ?Sized,

§

fn serialize_unsized( &self, serializer: &mut S, ) -> Result<usize, <S as Fallible>::Error>

Writes the object and returns the position of the archived type.
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.