Kagome
Polkadot Runtime Engine in C++17
kagome::runtime::wavm::WavmExternalMemoryProvider Class Referencefinal

#include <wavm_external_memory_provider.hpp>

Inheritance diagram for kagome::runtime::wavm::WavmExternalMemoryProvider:
Collaboration diagram for kagome::runtime::wavm::WavmExternalMemoryProvider:

Public Member Functions

 WavmExternalMemoryProvider (std::shared_ptr< IntrinsicModuleInstance > intrinsic_module)
 
std::optional< std::reference_wrapper< runtime::Memory > > getCurrentMemory () const override
 
outcome::result< void > resetMemory (WasmSize heap_base) override
 
- Public Member Functions inherited from kagome::runtime::MemoryProvider
virtual ~MemoryProvider ()=default
 

Private Attributes

std::shared_ptr< IntrinsicModuleInstanceintrinsic_module_
 
std::shared_ptr< Memorycurrent_memory_
 

Detailed Description

Definition at line 16 of file wavm_external_memory_provider.hpp.

Constructor & Destructor Documentation

kagome::runtime::wavm::WavmExternalMemoryProvider::WavmExternalMemoryProvider ( std::shared_ptr< IntrinsicModuleInstance intrinsic_module)
explicit

Definition at line 14 of file wavm_external_memory_provider.cpp.

Member Function Documentation

std::optional< std::reference_wrapper< runtime::Memory > > kagome::runtime::wavm::WavmExternalMemoryProvider::getCurrentMemory ( ) const
overridevirtual

Implements kagome::runtime::MemoryProvider.

Definition at line 21 of file wavm_external_memory_provider.cpp.

outcome::result< void > kagome::runtime::wavm::WavmExternalMemoryProvider::resetMemory ( WasmSize  heap_base)
overridevirtual

Implements kagome::runtime::MemoryProvider.

Definition at line 28 of file wavm_external_memory_provider.cpp.

Member Data Documentation

std::shared_ptr<Memory> kagome::runtime::wavm::WavmExternalMemoryProvider::current_memory_
private

Definition at line 28 of file wavm_external_memory_provider.hpp.

std::shared_ptr<IntrinsicModuleInstance> kagome::runtime::wavm::WavmExternalMemoryProvider::intrinsic_module_
private

Definition at line 27 of file wavm_external_memory_provider.hpp.


The documentation for this class was generated from the following files: