vmhooks

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 3, 2024 License: GPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BaseOpsAPIImports

func BaseOpsAPIImports() (*wasmer.Imports, error)

BaseOpsAPIImports creates a new wasmer.Imports populated with the BaseOpsAPI API methods

func BigIntImports

func BigIntImports(imports *wasmer.Imports) (*wasmer.Imports, error)

BigIntImports creates a new wasmer.Imports populated with the BigInt API methods

func DelegateExecutionWithHost

func DelegateExecutionWithHost(
	host vmhost.VMHost,
	gasLimit int64,
	addressOffset int32,
	functionOffset int32,
	functionLength int32,
	numArguments int32,
	argumentsLengthOffset int32,
	dataOffset int32,
) int32

DelegateExecutionWithHost - delegateExecution with host instead of pointer context

func DelegateExecutionWithTypedArgs

func DelegateExecutionWithTypedArgs(
	host vmhost.VMHost,
	gasLimit int64,
	function []byte,
	dest []byte,
	args [][]byte,
) int32

DelegateExecutionWithTypedArgs - delegateExecution with args already read from memory

func DeployFromSourceContractWithTypedArgs

func DeployFromSourceContractWithTypedArgs(
	host vmhost.VMHost,
	sourceContractAddress []byte,
	codeMetadata []byte,
	value *big.Int,
	data [][]byte,
	gasLimit int64,
) ([]byte, error)

DeployFromSourceContractWithTypedArgs - deployFromSourceContract with args already read from memory

func ExecuteOnDestContextByCallerWithHost

func ExecuteOnDestContextByCallerWithHost(
	host vmhost.VMHost,
	gasLimit int64,
	addressOffset int32,
	valueOffset int32,
	functionOffset int32,
	functionLength int32,
	numArguments int32,
	argumentsLengthOffset int32,
	dataOffset int32,
) int32

ExecuteOnDestContextByCallerWithHost - executeOnDestContextByCaller with host instead of pointer context

func ExecuteOnDestContextByCallerWithTypedArgs

func ExecuteOnDestContextByCallerWithTypedArgs(
	host vmhost.VMHost,
	gasLimit int64,
	value *big.Int,
	function []byte,
	dest []byte,
	args [][]byte,
) int32

ExecuteOnDestContextByCallerWithTypedArgs - executeOnDestContextByCaller with args already read from memory

func ExecuteOnDestContextWithHost

func ExecuteOnDestContextWithHost(
	host vmhost.VMHost,
	gasLimit int64,
	addressOffset int32,
	valueOffset int32,
	functionOffset int32,
	functionLength int32,
	numArguments int32,
	argumentsLengthOffset int32,
	dataOffset int32,
) int32

ExecuteOnDestContextWithHost - executeOnDestContext with host instead of pointer context

func ExecuteOnDestContextWithTypedArgs

func ExecuteOnDestContextWithTypedArgs(
	host vmhost.VMHost,
	gasLimit int64,
	value *big.Int,
	function []byte,
	dest []byte,
	args [][]byte,
) int32

ExecuteOnDestContextWithTypedArgs - executeOnDestContext with args already read from memory

func ExecuteOnSameContextWithHost

func ExecuteOnSameContextWithHost(
	host vmhost.VMHost,
	gasLimit int64,
	addressOffset int32,
	valueOffset int32,
	functionOffset int32,
	functionLength int32,
	numArguments int32,
	argumentsLengthOffset int32,
	dataOffset int32,
) int32

ExecuteOnSameContextWithHost - executeOnSameContext with host instead of pointer context

func ExecuteOnSameContextWithTypedArgs

func ExecuteOnSameContextWithTypedArgs(
	host vmhost.VMHost,
	gasLimit int64,
	value *big.Int,
	function []byte,
	dest []byte,
	args [][]byte,
) int32

ExecuteOnSameContextWithTypedArgs - executeOnSameContext with args already read from memory

func ExecuteReadOnlyWithHost

func ExecuteReadOnlyWithHost(
	host vmhost.VMHost,
	gasLimit int64,
	addressOffset int32,
	functionOffset int32,
	functionLength int32,
	numArguments int32,
	argumentsLengthOffset int32,
	dataOffset int32,
) int32

ExecuteReadOnlyWithHost - executeReadOnly with host instead of pointer context

func ExecuteReadOnlyWithTypedArguments

func ExecuteReadOnlyWithTypedArguments(
	host vmhost.VMHost,
	gasLimit int64,
	function []byte,
	dest []byte,
	args [][]byte,
) int32

ExecuteReadOnlyWithTypedArguments - executeReadOnly with args already read from memory

func SmallIntImports

func SmallIntImports(imports *wasmer.Imports) (*wasmer.Imports, error)

SmallIntImports creates a new wasmer.Imports populated with the small int (int64/uint64) API methods

func TransferDCDTNFTExecuteWithHost

func TransferDCDTNFTExecuteWithHost(
	host vmhost.VMHost,
	destOffset int32,
	tokenIDOffset int32,
	tokenIDLen int32,
	valueOffset int32,
	nonce int64,
	gasLimit int64,
	functionOffset int32,
	functionLength int32,
	numArguments int32,
	argumentsLengthOffset int32,
	dataOffset int32,
) int32

TransferDCDTNFTExecuteWithHost contains only memory reading of arguments

func TransferDCDTNFTExecuteWithTypedArgs

func TransferDCDTNFTExecuteWithTypedArgs(
	host vmhost.VMHost,
	dcdtValue *big.Int,
	dcdtTokenName []byte,
	dest []byte,
	nonce int64,
	gasLimit int64,
	function []byte,
	data [][]byte,
) int32

TransferDCDTNFTExecuteWithTypedArgs defines the actual transfer DCDT execute logic

func TransferValueExecuteWithHost

func TransferValueExecuteWithHost(
	host vmhost.VMHost,
	destOffset int32,
	valueOffset int32,
	gasLimit int64,
	functionOffset int32,
	functionLength int32,
	numArguments int32,
	argumentsLengthOffset int32,
	dataOffset int32,
) int32

TransferValueExecuteWithHost - transferValueExecute with host instead of pointer context

func TransferValueExecuteWithTypedArgs

func TransferValueExecuteWithTypedArgs(
	host vmhost.VMHost,
	dest []byte,
	value *big.Int,
	gasLimit int64,
	function []byte,
	args [][]byte,
) int32

TransferValueExecuteWithTypedArgs - transferValueExecute with args already read from memory

func UpgradeFromSourceContractWithTypedArgs

func UpgradeFromSourceContractWithTypedArgs(
	host vmhost.VMHost,
	sourceContractAddress []byte,
	destContractAddress []byte,
	value []byte,
	data [][]byte,
	gasLimit int64,
	codeMetadata []byte,
)

UpgradeFromSourceContractWithTypedArgs - upgradeFromSourceContract with args already read from memory

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL