Versions in this module Expand all Collapse all v1 v1.0.0 Mar 14, 2024 Changes in this version + type Memory struct + func NewMemory(mem api.Memory) *Memory + func (m *Memory) Read(offset uint64, byteCount uint64) ([]byte, bool) + func (m *Memory) Write(ptr uint64, data []byte) bool + type ModFunc struct + func NewModFunc(mod api.Module, name string) *ModFunc + func (f *ModFunc) Call(ctx context.Context, params ...uint64) (uint64, error) + type Runtime struct + func NewRuntime(ctx context.Context) (*Runtime, error) + func (r *Runtime) BufferFree(ctx context.Context, bufferPtr uint64) error + func (r *Runtime) BufferInit(ctx context.Context, bufferPtr uint64) error + func (r *Runtime) BufferLength(ctx context.Context, bufferPtr uint64) (uint64, error) + func (r *Runtime) BufferSizeOf(ctx context.Context) (uint64, error) + func (r *Runtime) BufferValue(ctx context.Context, bufferPtr uint64) (uint64, error) + func (r *Runtime) Calloc(ctx context.Context, size uint64, count uint64) (uint64, error) + func (r *Runtime) Close(ctx context.Context) error + func (r *Runtime) Free(ctx context.Context, ptr uint64) error + func (r *Runtime) MemoryRead(offset uint64, byteCount uint64) ([]byte, bool) + func (r *Runtime) MemoryWrite(ptr uint64, data []byte) bool + func (r *Runtime) SerializeParse(ctx context.Context, bufferPtr, sourcePtr, sourceLen, optPtr uint64) (uint64, error)