Documentation ¶
Index ¶
- Constants
- func BuildResultFromNeo(item VmValue, bf *common.ZeroCopySink) error
- type ArrayValue
- type IntValue
- func (self IntValue) Abs() (val IntValue)
- func (self IntValue) Add(other IntValue) (IntValue, error)
- func (self IntValue) And(other IntValue) (IntValue, error)
- func (self IntValue) Cmp(other IntValue) int
- func (self IntValue) Div(other IntValue) (IntValue, error)
- func (self *IntValue) IsZero() bool
- func (self IntValue) Lsh(other IntValue) (result IntValue, err error)
- func (self IntValue) Max(other IntValue) (IntValue, error)
- func (self IntValue) Min(other IntValue) (IntValue, error)
- func (self IntValue) Mod(other IntValue) (IntValue, error)
- func (self IntValue) Mul(other IntValue) (IntValue, error)
- func (self IntValue) Not() (val IntValue)
- func (self IntValue) Or(other IntValue) (IntValue, error)
- func (self IntValue) Rsh(other IntValue) (result IntValue, err error)
- func (self *IntValue) Sign() int
- func (self IntValue) Sub(other IntValue) (IntValue, error)
- func (self *IntValue) ToNeoBytes() []byte
- func (self IntValue) Xor(other IntValue) (IntValue, error)
- type InteropValue
- type MapValue
- func (this *MapValue) Get(key VmValue) (value VmValue, ok bool, err error)
- func (this *MapValue) GetMapSortedKey() []VmValue
- func (this *MapValue) GetValues() ([]VmValue, error)
- func (this *MapValue) Remove(key VmValue) error
- func (this *MapValue) Reset()
- func (this *MapValue) Set(key, value VmValue) error
- type StructValue
- type VmValue
- func NewMapVmValue() VmValue
- func VmValueFromArrayVal(array *ArrayValue) VmValue
- func VmValueFromBigInt(val *big.Int) (result VmValue, err error)
- func VmValueFromBool(val bool) VmValue
- func VmValueFromBytes(val []byte) (result VmValue, err error)
- func VmValueFromInt64(val int64) VmValue
- func VmValueFromIntValue(val IntValue) VmValue
- func VmValueFromInteropValue(val InteropValue) VmValue
- func VmValueFromMapValue(val *MapValue) VmValue
- func VmValueFromStructVal(val *StructValue) VmValue
- func VmValueFromUint64(val uint64) VmValue
- func (self *VmValue) AsArrayValue() (*ArrayValue, error)
- func (self *VmValue) AsBigInt() (*big.Int, error)
- func (self *VmValue) AsBool() (bool, error)
- func (self *VmValue) AsBytes() ([]byte, error)
- func (self *VmValue) AsInt64() (int64, error)
- func (self *VmValue) AsIntValue() (IntValue, error)
- func (self *VmValue) AsInteropValue() (InteropValue, error)
- func (self *VmValue) AsMapValue() (*MapValue, error)
- func (self *VmValue) AsStructValue() (*StructValue, error)
- func (self *VmValue) BuildParamToNative(sink *common.ZeroCopySink) error
- func (self *VmValue) CircularRefAndDepthDetection() (bool, error)
- func (self *VmValue) ConvertNeoVmValueHexString() (interface{}, error)
- func (self *VmValue) Deserialize(source *common.ZeroCopySource) error
- func (self *VmValue) Dump() string
- func (self *VmValue) Equals(other VmValue) bool
- func (self *VmValue) GetMapKey() (string, error)
- func (self *VmValue) GetType() byte
- func (self *VmValue) Serialize(sink *common.ZeroCopySink) error
- func (self *VmValue) Stringify() (string, error)
Constants ¶
View Source
const ( MAX_COUNT = 1024 MAX_NOTIFY_LENGTH = 64 * 1024 //64Kb )
View Source
const ( ByteArrayType byte = 0x00 BooleanType byte = 0x01 IntegerType byte = 0x02 InterfaceType byte = 0x40 ArrayType byte = 0x80 StructType byte = 0x81 MapType byte = 0x82 )
View Source
const ( MAX_STRUCT_DEPTH = 10 MAX_CLONE_LENGTH = 1024 )
Variables ¶
This section is empty.
Functions ¶
func BuildResultFromNeo ¶ added in v1.8.0
func BuildResultFromNeo(item VmValue, bf *common.ZeroCopySink) error
encode the neovm return vmval transform neovm contract result to encoded byte array
Types ¶
type ArrayValue ¶ added in v1.8.0
type ArrayValue struct {
Data []VmValue
}
func NewArrayValue ¶ added in v1.8.0
func NewArrayValue() *ArrayValue
func (*ArrayValue) Append ¶ added in v1.8.0
func (self *ArrayValue) Append(item VmValue) error
func (*ArrayValue) Len ¶ added in v1.8.0
func (self *ArrayValue) Len() int64
func (*ArrayValue) RemoveAt ¶ added in v1.8.0
func (self *ArrayValue) RemoveAt(index int64) error
type IntValue ¶ added in v1.8.0
type IntValue struct {
// contains filtered or unexported fields
}
func IntValFromBigInt ¶ added in v1.8.0
func IntValFromInt ¶ added in v1.8.0
func IntValFromNeoBytes ¶ added in v1.8.0
func (*IntValue) ToNeoBytes ¶ added in v1.8.0
type InteropValue ¶ added in v1.8.0
type InteropValue struct {
Data interfaces.Interop
}
func NewInteropValue ¶ added in v1.8.0
func NewInteropValue(value interfaces.Interop) InteropValue
func (*InteropValue) Equals ¶ added in v1.8.0
func (this *InteropValue) Equals(other InteropValue) bool
type MapValue ¶ added in v1.8.0
func NewMapValue ¶ added in v1.8.0
func NewMapValue() *MapValue
func (*MapValue) GetMapSortedKey ¶ added in v1.8.0
type StructValue ¶ added in v1.8.0
type StructValue struct {
Data []VmValue
}
struct value is value type
func NewStructValue ¶ added in v1.8.0
func NewStructValue() *StructValue
func (*StructValue) Append ¶ added in v1.8.0
func (self *StructValue) Append(item VmValue) error
func (*StructValue) Clone ¶ added in v1.8.0
func (self *StructValue) Clone() (*StructValue, error)
func (*StructValue) Len ¶ added in v1.8.0
func (self *StructValue) Len() int64
type VmValue ¶ added in v1.8.0
type VmValue struct {
// contains filtered or unexported fields
}
func NewMapVmValue ¶ added in v1.8.0
func NewMapVmValue() VmValue
func VmValueFromArrayVal ¶ added in v1.8.0
func VmValueFromArrayVal(array *ArrayValue) VmValue
func VmValueFromBigInt ¶ added in v1.8.0
func VmValueFromBool ¶ added in v1.8.0
func VmValueFromBytes ¶ added in v1.8.0
func VmValueFromInt64 ¶ added in v1.8.0
func VmValueFromIntValue ¶ added in v1.8.0
func VmValueFromInteropValue ¶ added in v1.8.0
func VmValueFromInteropValue(val InteropValue) VmValue
func VmValueFromMapValue ¶ added in v1.8.0
func VmValueFromStructVal ¶ added in v1.8.0
func VmValueFromStructVal(val *StructValue) VmValue
func VmValueFromUint64 ¶ added in v1.8.0
func (*VmValue) AsArrayValue ¶ added in v1.8.0
func (self *VmValue) AsArrayValue() (*ArrayValue, error)
func (*VmValue) AsBigInt ¶ added in v1.8.0
urgly hack: only used in cmp opcode to lift the 32byte limit of integer
func (*VmValue) AsIntValue ¶ added in v1.8.0
func (*VmValue) AsInteropValue ¶ added in v1.8.0
func (self *VmValue) AsInteropValue() (InteropValue, error)
func (*VmValue) AsMapValue ¶ added in v1.8.0
func (*VmValue) AsStructValue ¶ added in v1.8.0
func (self *VmValue) AsStructValue() (*StructValue, error)
func (*VmValue) BuildParamToNative ¶ added in v1.8.0
func (self *VmValue) BuildParamToNative(sink *common.ZeroCopySink) error
func (*VmValue) CircularRefAndDepthDetection ¶ added in v1.8.0
func (*VmValue) ConvertNeoVmValueHexString ¶ added in v1.8.0
func (*VmValue) Deserialize ¶ added in v1.8.0
func (self *VmValue) Deserialize(source *common.ZeroCopySource) error
Click to show internal directories.
Click to hide internal directories.