vm

package
v1.1.63 Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2021 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LogEntryApi

type LogEntryApi struct {
	Identifier []byte   `json:"identifier"`
	Address    string   `json:"address"`
	Topics     [][]byte `json:"topics"`
	Data       []byte   `json:"data"`
}

LogEntryApi is a wrapper over vmcommon's LogEntry

type OutputAccountApi

type OutputAccountApi struct {
	Address         string                       `json:"address"`
	Nonce           uint64                       `json:"nonce"`
	Balance         *big.Int                     `json:"balance"`
	BalanceDelta    *big.Int                     `json:"balanceDelta"`
	StorageUpdates  map[string]*StorageUpdateApi `json:"storageUpdates"`
	Code            []byte                       `json:"code"`
	CodeMetadata    []byte                       `json:"codeMetaData"`
	OutputTransfers []OutputTransferApi          `json:"outputTransfers"`
	CallType        vmcommon.CallType            `json:"callType"`
}

OutputAccountApi is a wrapper over vmcommon's OutputAccount

type OutputTransferApi added in v1.1.3

type OutputTransferApi struct {
	Value         *big.Int          `json:"value"`
	GasLimit      uint64            `json:"gasLimit"`
	Data          []byte            `json:"data"`
	CallType      vmcommon.CallType `json:"callType"`
	SenderAddress string            `json:"senderAddress"`
}

OutputTransferApi is a wrapper over vmcommon's OutputTransfer

type StorageUpdateApi

type StorageUpdateApi struct {
	Offset []byte `json:"offset"`
	Data   []byte `json:"data"`
}

StorageUpdateApi is a wrapper over vmcommon's StorageUpdate

type VMOutputApi

type VMOutputApi struct {
	ReturnData      [][]byte                     `json:"returnData"`
	ReturnCode      string                       `json:"returnCode"`
	ReturnMessage   string                       `json:"returnMessage"`
	GasRemaining    uint64                       `json:"gasRemaining"`
	GasRefund       *big.Int                     `json:"gasRefund"`
	OutputAccounts  map[string]*OutputAccountApi `json:"outputAccounts"`
	DeletedAccounts [][]byte                     `json:"deletedAccounts"`
	TouchedAccounts [][]byte                     `json:"touchedAccounts"`
	Logs            []*LogEntryApi               `json:"logs"`
}

VMOutputApi is a wrapper over the vmcommon's VMOutput

func (*VMOutputApi) GetFirstReturnData

func (vmOutput *VMOutputApi) GetFirstReturnData(asType vmcommon.ReturnDataKind) (interface{}, error)

GetFirstReturnData is a helper function that returns the first ReturnData of VMOutput, interpreted as specified.

Jump to

Keyboard shortcuts

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