contracthandler

package
v0.0.0-...-61fb7ef Latest Latest
Warning

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

Go to latest
Published: Oct 11, 2020 License: Apache-2.0 Imports: 5 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsSupported

func IsSupported(sig string) bool

* supports below formats * functionName(datatype1, datatype2,...) * datatype1, datatype2,... * datatype1, datatype2,.., (with an extra comma and the end *

Types

type Address

type Address struct {
	UintLarge
}

func (Address) Decode

func (t Address) Decode(data []string, index int) (int, interface{})

func (Address) New

func (t Address) New(i interface{}, sig string) DataType

type AddressDA

type AddressDA struct {
	UintLargeDA
}

func (AddressDA) Decode

func (t AddressDA) Decode(data []string, index int) (int, interface{})

func (AddressDA) New

func (t AddressDA) New(i interface{}, sig string) DataType

type AddressFA

type AddressFA struct {
	UintLargeFA
}

func (AddressFA) Decode

func (t AddressFA) Decode(data []string, index int) (int, interface{})

func (AddressFA) New

func (t AddressFA) New(i interface{}, sig string) DataType

type BaseDataType

type BaseDataType struct {
	// contains filtered or unexported fields
}

type Bool

type Bool struct {
	Uint
}

func (Bool) Decode

func (t Bool) Decode(data []string, index int) (int, interface{})

func (Bool) New

func (t Bool) New(i interface{}, sig string) DataType

type Bytes

type Bytes struct {
	BaseDataType
}

func (Bytes) Decode

func (t Bytes) Decode(data []string, index int) (int, interface{})

func (Bytes) Encode

func (t Bytes) Encode() []string

func (Bytes) IsDynamic

func (t Bytes) IsDynamic() bool

func (Bytes) Length

func (t Bytes) Length() int

func (Bytes) New

func (t Bytes) New(i interface{}, sig string) DataType

type Bytes32DA

type Bytes32DA struct {
	BaseDataType
}

func (Bytes32DA) Decode

func (t Bytes32DA) Decode(data []string, index int) (int, interface{})

func (Bytes32DA) Encode

func (t Bytes32DA) Encode() []string

func (Bytes32DA) IsDynamic

func (t Bytes32DA) IsDynamic() bool

func (Bytes32DA) Length

func (t Bytes32DA) Length() int

func (Bytes32DA) New

func (t Bytes32DA) New(i interface{}, sig string) DataType

type Bytes32FA

type Bytes32FA struct {
	BaseDataType
}

func (Bytes32FA) Decode

func (t Bytes32FA) Decode(data []string, index int) (int, interface{})

func (Bytes32FA) Encode

func (t Bytes32FA) Encode() []string

func (Bytes32FA) IsDynamic

func (t Bytes32FA) IsDynamic() bool

func (Bytes32FA) Length

func (t Bytes32FA) Length() int

func (Bytes32FA) New

func (t Bytes32FA) New(i interface{}, sig string) DataType

type BytesFixed

type BytesFixed struct {
	Uint
}

func (BytesFixed) Decode

func (t BytesFixed) Decode(data []string, index int) (int, interface{})

func (BytesFixed) Encode

func (t BytesFixed) Encode() []string

func (BytesFixed) New

func (t BytesFixed) New(i interface{}, sig string) DataType

type ContractParam

type ContractParam struct {
	From    string
	To      string
	Passwd  string
	Parties []string
}

type DataType

type DataType interface {
	IsDynamic() bool
	Length() int
	Encode() []string
	New(interface{}, string) DataType
	Decode([]string, int) (int, interface{})
}

type DeployContractHandler

type DeployContractHandler struct {
	Binary string
}

func (DeployContractHandler) Encode

func (d DeployContractHandler) Encode() string

type FunctionProcessor

type FunctionProcessor struct {
	Signature string
}

func (FunctionProcessor) Decode

func (fp FunctionProcessor) Decode(encodedString string) []interface{}

func (FunctionProcessor) Encode

func (fp FunctionProcessor) Encode(paramValues []interface{}) string

type RequestHandler

type RequestHandler interface {
	Encode() string
}

type ResponseHandler

type ResponseHandler interface {
	Decode(r string)
}

type String

type String struct {
	Bytes
}

func (String) Decode

func (t String) Decode(data []string, index int) (int, interface{})

func (String) New

func (t String) New(i interface{}, sig string) DataType

type Uint

type Uint struct {
	BaseDataType
}

func (Uint) Decode

func (t Uint) Decode(data []string, index int) (int, interface{})

func (Uint) Encode

func (t Uint) Encode() []string

func (Uint) IsDynamic

func (t Uint) IsDynamic() bool

func (Uint) Length

func (t Uint) Length() int

func (Uint) New

func (t Uint) New(i interface{}, sig string) DataType

type UintDA

type UintDA struct {
	BaseDataType
}

func (UintDA) Decode

func (t UintDA) Decode(data []string, index int) (int, interface{})

func (UintDA) Encode

func (t UintDA) Encode() []string

func (UintDA) IsDynamic

func (t UintDA) IsDynamic() bool

func (UintDA) Length

func (t UintDA) Length() int

func (UintDA) New

func (t UintDA) New(i interface{}, sig string) DataType

type UintFA

type UintFA struct {
	UintDA
}

func (UintFA) Decode

func (t UintFA) Decode(data []string, index int) (int, interface{})

func (UintFA) Encode

func (t UintFA) Encode() []string

func (UintFA) IsDynamic

func (t UintFA) IsDynamic() bool

func (UintFA) Length

func (t UintFA) Length() int

func (UintFA) New

func (t UintFA) New(i interface{}, sig string) DataType

type UintLarge

type UintLarge struct {
	BaseDataType
}

func (UintLarge) Decode

func (t UintLarge) Decode(data []string, index int) (int, interface{})

func (UintLarge) Encode

func (t UintLarge) Encode() []string

func (UintLarge) IsDynamic

func (t UintLarge) IsDynamic() bool

func (UintLarge) Length

func (t UintLarge) Length() int

func (UintLarge) New

func (t UintLarge) New(i interface{}, sig string) DataType

type UintLargeDA

type UintLargeDA struct {
	BaseDataType
}

func (UintLargeDA) Decode

func (t UintLargeDA) Decode(data []string, index int) (int, interface{})

func (UintLargeDA) Encode

func (t UintLargeDA) Encode() []string

func (UintLargeDA) IsDynamic

func (t UintLargeDA) IsDynamic() bool

func (UintLargeDA) Length

func (t UintLargeDA) Length() int

func (UintLargeDA) New

func (t UintLargeDA) New(i interface{}, sig string) DataType

type UintLargeFA

type UintLargeFA struct {
	UintLargeDA
}

func (UintLargeFA) Decode

func (t UintLargeFA) Decode(data []string, index int) (int, interface{})

func (UintLargeFA) Encode

func (t UintLargeFA) Encode() []string

func (UintLargeFA) IsDynamic

func (t UintLargeFA) IsDynamic() bool

func (UintLargeFA) Length

func (t UintLargeFA) Length() int

func (UintLargeFA) New

func (t UintLargeFA) New(i interface{}, sig string) DataType

Jump to

Keyboard shortcuts

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