Documentation
¶
Index ¶
- func NewBuilder(ref *moduleref.WasmModuleRef, API api.HostAPI) runtime.RuntimeBuilder
- type WasmerBuilder
- type WasmerHostFn
- type WasmerRuntime
- func (w *WasmerRuntime) Call(fn string, args ...interface{}) (interface{}, error)
- func (w *WasmerRuntime) Close()
- func (w *WasmerRuntime) Deallocate(pointer int32, length int)
- func (w *WasmerRuntime) ReadMemory(pointer int32, size int32) []byte
- func (w *WasmerRuntime) WriteMemory(data []byte) (int32, error)
- func (w *WasmerRuntime) WriteMemoryAtLocation(pointer int32, data []byte)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewBuilder ¶
func NewBuilder(ref *moduleref.WasmModuleRef, API api.HostAPI) runtime.RuntimeBuilder
NewBuilder creates a new WasmerBuilder
Types ¶
type WasmerBuilder ¶
type WasmerBuilder struct {
// contains filtered or unexported fields
}
WasmerBuilder is a Wasmer implementation of the instanceBuilder interface
func (*WasmerBuilder) New ¶
func (w *WasmerBuilder) New() (runtime.RuntimeInstance, error)
type WasmerHostFn ¶
type WasmerHostFn struct {
// contains filtered or unexported fields
}
WasmerHostFn describes a host function callable from within a Runnable module
type WasmerRuntime ¶
type WasmerRuntime struct {
// contains filtered or unexported fields
}
WasmerRuntime is a Wasmer implementation of the runtimeInstance interface
func (*WasmerRuntime) Call ¶
func (w *WasmerRuntime) Call(fn string, args ...interface{}) (interface{}, error)
func (*WasmerRuntime) Deallocate ¶
func (w *WasmerRuntime) Deallocate(pointer int32, length int)
Deallocate deallocates memory in the instance
func (*WasmerRuntime) ReadMemory ¶
func (w *WasmerRuntime) ReadMemory(pointer int32, size int32) []byte
ReadMemory reads memory from the instance
func (*WasmerRuntime) WriteMemory ¶
func (w *WasmerRuntime) WriteMemory(data []byte) (int32, error)
WriteMemory writes memory into the instance
func (*WasmerRuntime) WriteMemoryAtLocation ¶
func (w *WasmerRuntime) WriteMemoryAtLocation(pointer int32, data []byte)
WriteMemoryAtLocation writes memory at the given location
Click to show internal directories.
Click to hide internal directories.