Documentation ¶
Overview ¶
Package vm is a generated GoMock package.
Index ¶
- func CheckTxGasLimitValid(t *tx.Tx, currentGas *common.Fixed, dbVisitor *database.Visitor) (err error)
- func UnmarshalArgs(abi *contract.ABI, data string) ([]interface{}, error)
- type Isolator
- func (i *Isolator) ClearAll()
- func (i *Isolator) ClearTx()
- func (i *Isolator) Commit()
- func (i *Isolator) PayCost() (*tx.TxReceipt, error)
- func (i *Isolator) Prepare(bh *block.BlockHead, db *database.Visitor, logger *ilog.Logger) error
- func (i *Isolator) PrepareTx(t *tx.Tx, limit time.Duration) error
- func (i *Isolator) Run() (*tx.TxReceipt, error)
- func (i *Isolator) TriggerBlockBaseMode()
- type MockVM
- func (m *MockVM) Compile(arg0 *contract.Contract) (string, error)
- func (m *MockVM) EXPECT() *MockVMMockRecorder
- func (m *MockVM) Init() error
- func (m *MockVM) LoadAndCall(arg0 *host.Host, arg1 *contract.Contract, arg2 string, arg3 ...interface{}) ([]interface{}, contract.Cost, error)
- func (m *MockVM) Release()
- func (m *MockVM) Validate(arg0 *contract.Contract) error
- type MockVMMockRecorder
- func (mr *MockVMMockRecorder) Compile(arg0 interface{}) *gomock.Call
- func (mr *MockVMMockRecorder) Init() *gomock.Call
- func (mr *MockVMMockRecorder) LoadAndCall(arg0, arg1, arg2 interface{}, arg3 ...interface{}) *gomock.Call
- func (mr *MockVMMockRecorder) Release() *gomock.Call
- func (mr *MockVMMockRecorder) Validate(arg0 interface{}) *gomock.Call
- type Monitor
- type VM
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Isolator ¶ added in v1.1.0
type Isolator struct {
// contains filtered or unexported fields
}
Isolator new entrance instead of Engine
func (*Isolator) ClearAll ¶ added in v1.1.0
func (i *Isolator) ClearAll()
ClearAll clear this isolator
func (*Isolator) TriggerBlockBaseMode ¶ added in v1.1.0
func (i *Isolator) TriggerBlockBaseMode()
TriggerBlockBaseMode start blockbase mode
type MockVM ¶
type MockVM struct {
// contains filtered or unexported fields
}
MockVM is a mock of VM interface
func NewMockVM ¶
func NewMockVM(ctrl *gomock.Controller) *MockVM
NewMockVM creates a new mock instance
func (*MockVM) EXPECT ¶
func (m *MockVM) EXPECT() *MockVMMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
type MockVMMockRecorder ¶
type MockVMMockRecorder struct {
// contains filtered or unexported fields
}
MockVMMockRecorder is the mock recorder for MockVM
func (*MockVMMockRecorder) Compile ¶
func (mr *MockVMMockRecorder) Compile(arg0 interface{}) *gomock.Call
Compile indicates an expected call of Compile
func (*MockVMMockRecorder) Init ¶
func (mr *MockVMMockRecorder) Init() *gomock.Call
Init indicates an expected call of Init
func (*MockVMMockRecorder) LoadAndCall ¶
func (mr *MockVMMockRecorder) LoadAndCall(arg0, arg1, arg2 interface{}, arg3 ...interface{}) *gomock.Call
LoadAndCall indicates an expected call of LoadAndCall
func (*MockVMMockRecorder) Release ¶
func (mr *MockVMMockRecorder) Release() *gomock.Call
Release indicates an expected call of Release
func (*MockVMMockRecorder) Validate ¶ added in v1.1.0
func (mr *MockVMMockRecorder) Validate(arg0 interface{}) *gomock.Call
Validate indicates an expected call of Validate
type Monitor ¶
type Monitor struct {
// contains filtered or unexported fields
}
Monitor ...
func (*Monitor) Call ¶
func (m *Monitor) Call(h *host.Host, contractName, api string, jarg string) (rtn []interface{}, cost contract.Cost, err error)
Call ... nolint
type VM ¶
type VM interface { Init() error Validate(contract *contract.Contract) error Compile(contract *contract.Contract) (string, error) LoadAndCall(host *host.Host, contract *contract.Contract, api string, args ...interface{}) (rtn []interface{}, cost contract.Cost, err error) Release() }
VM ...
Click to show internal directories.
Click to hide internal directories.