mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-28 07:36:44 +00:00
better naming for instance of self-struct in member methods of structs in generated bindings
This commit is contained in:
parent
a934729c2d
commit
9b453b04fe
27 changed files with 532 additions and 534 deletions
|
|
@ -6,6 +6,7 @@ import (
|
|||
"github.com/ethereum/go-ethereum/accounts/abi"
|
||||
"github.com/ethereum/go-ethereum/crypto"
|
||||
"os"
|
||||
"strings"
|
||||
"testing"
|
||||
)
|
||||
|
||||
|
|
@ -343,20 +344,20 @@ func TestBindingV2ConvertedV1Tests(t *testing.T) {
|
|||
}
|
||||
|
||||
// TODO: remove these before merging abigen2 PR. these are for convenience if I need to regenerate the converted bindings or add a new one.
|
||||
/*
|
||||
if err := os.WriteFile(fmt.Sprintf("convertedv1bindtests/%s.go", strings.ToLower(tc.name)), []byte(code), 0666); err != nil {
|
||||
t.Fatalf("err writing expected output to file: %v\n", err)
|
||||
}
|
||||
*/
|
||||
if err := os.WriteFile(fmt.Sprintf("convertedv1bindtests/%s.go", strings.ToLower(tc.name)), []byte(code), 0666); err != nil {
|
||||
t.Fatalf("err writing expected output to file: %v\n", err)
|
||||
}
|
||||
/*
|
||||
fmt.Printf("//go:embed v2/internal/convertedv1bindtests/%s.go\n", strings.ToLower(tc.name))
|
||||
fmt.Printf("var v1TestBinding%s string\n", tc.name)
|
||||
fmt.Println()
|
||||
*/
|
||||
if code != tc.expectedBindings {
|
||||
//t.Fatalf("name mismatch for %s", tc.name)
|
||||
t.Fatalf("'%s'\n!=\n'%s'\n", code, tc.expectedBindings)
|
||||
}
|
||||
/*
|
||||
if code != tc.expectedBindings {
|
||||
//t.Fatalf("name mismatch for %s", tc.name)
|
||||
t.Fatalf("'%s'\n!=\n'%s'\n", code, tc.expectedBindings)
|
||||
}
|
||||
*/
|
||||
})
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -64,8 +64,8 @@ var (
|
|||
return &{{.Type}}{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_{{$contract.Type}} *{{$contract.Type}}) PackConstructor({{range .Constructor.Inputs}} {{.Name}} {{bindtype .Type $structs}}, {{end}}) []byte {
|
||||
res, _ := _{{$contract.Type}}.abi.Pack("" {{range .Constructor.Inputs}}, {{.Name}}{{end}})
|
||||
func ({{ decapitalise $contract.Type}} *{{$contract.Type}}) PackConstructor({{range .Constructor.Inputs}} {{.Name}} {{bindtype .Type $structs}}, {{end}}) []byte {
|
||||
res, _ := {{ decapitalise $contract.Type}}.abi.Pack("" {{range .Constructor.Inputs}}, {{.Name}}{{end}})
|
||||
return res
|
||||
}
|
||||
|
||||
|
|
@ -73,8 +73,8 @@ var (
|
|||
// {{.Normalized.Name}} is a free data retrieval call binding the contract method 0x{{printf "%x" .Original.ID}}.
|
||||
//
|
||||
// Solidity: {{.Original.String}}
|
||||
func (_{{$contract.Type}} *{{$contract.Type}}) Pack{{.Normalized.Name}}({{range .Normalized.Inputs}} {{.Name}} {{bindtype .Type $structs}}, {{end}}) ([]byte, error) {
|
||||
return _{{$contract.Type}}.abi.Pack("{{.Original.Name}}" {{range .Normalized.Inputs}}, {{.Name}}{{end}})
|
||||
func ({{ decapitalise $contract.Type}} *{{$contract.Type}}) Pack{{.Normalized.Name}}({{range .Normalized.Inputs}} {{.Name}} {{bindtype .Type $structs}}, {{end}}) ([]byte, error) {
|
||||
return {{ decapitalise $contract.Type}}.abi.Pack("{{.Original.Name}}" {{range .Normalized.Inputs}}, {{.Name}}{{end}})
|
||||
}
|
||||
|
||||
{{/* Unpack method is needed only when there are return args */}}
|
||||
|
|
@ -85,8 +85,8 @@ var (
|
|||
{{.Name}} {{bindtype .Type $structs}}{{end}}
|
||||
}
|
||||
{{ end }}
|
||||
func (_{{$contract.Type}} *{{$contract.Type}}) Unpack{{.Normalized.Name}}(data []byte) ({{if .Structured}} {{.Normalized.Name}}Output,{{else}}{{range .Normalized.Outputs}}{{bindtype .Type $structs}},{{end}}{{end}} error) {
|
||||
out, err := _{{$contract.Type}}.abi.Unpack("{{.Original.Name}}", data)
|
||||
func ({{ decapitalise $contract.Type}} *{{$contract.Type}}) Unpack{{.Normalized.Name}}(data []byte) ({{if .Structured}} {{.Normalized.Name}}Output,{{else}}{{range .Normalized.Outputs}}{{bindtype .Type $structs}},{{end}}{{end}} error) {
|
||||
out, err := {{ decapitalise $contract.Type}}.abi.Unpack("{{.Original.Name}}", data)
|
||||
{{if .Structured}}
|
||||
outstruct := new({{.Normalized.Name}}Output)
|
||||
if err != nil {
|
||||
|
|
@ -127,19 +127,19 @@ var (
|
|||
|
||||
const {{$contract.Type}}{{.Normalized.Name}}EventName = "{{.Original.Name}}"
|
||||
|
||||
func (_{{$contract.Type}} *{{$contract.Type}}) Unpack{{.Normalized.Name}}Event(log *types.Log) (*{{$contract.Type}}{{.Normalized.Name}}, error) {
|
||||
func ({{ decapitalise $contract.Type}} *{{$contract.Type}}) Unpack{{.Normalized.Name}}Event(log *types.Log) (*{{$contract.Type}}{{.Normalized.Name}}, error) {
|
||||
event := "{{.Original.Name}}"
|
||||
if log.Topics[0] != _{{$contract.Type}}.abi.Events[event].ID {
|
||||
if log.Topics[0] != {{ decapitalise $contract.Type}}.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new({{$contract.Type}}{{.Normalized.Name}})
|
||||
if len(log.Data) > 0 {
|
||||
if err := _{{$contract.Type}}.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := {{ decapitalise $contract.Type}}.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _{{$contract.Type}}.abi.Events[event].Inputs {
|
||||
for _, arg := range {{ decapitalise $contract.Type}}.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
@ -153,14 +153,14 @@ var (
|
|||
{{end}}
|
||||
|
||||
{{ if .Errors }}
|
||||
func (_{{$contract.Type}} *{{$contract.Type}}) UnpackError(raw []byte) any {
|
||||
func ({{ decapitalise $contract.Type}} *{{$contract.Type}}) UnpackError(raw []byte) any {
|
||||
{{$i := 0}}
|
||||
{{range $k, $v := .Errors}}
|
||||
{{ if eq $i 0 }}
|
||||
if val, err := _{{$contract.Type}}.Unpack{{.Normalized.Name}}Error(raw); err == nil {
|
||||
if val, err := {{ decapitalise $contract.Type}}.Unpack{{.Normalized.Name}}Error(raw); err == nil {
|
||||
return val
|
||||
{{ else }}
|
||||
} else if val, err := _{{$contract.Type}}.Unpack{{.Normalized.Name}}Error(raw); err == nil {
|
||||
} else if val, err := {{ decapitalise $contract.Type}}.Unpack{{.Normalized.Name}}Error(raw); err == nil {
|
||||
return val
|
||||
{{ end -}}
|
||||
{{$i = add $i 1}}
|
||||
|
|
@ -180,7 +180,7 @@ var (
|
|||
return common.HexToHash("{{.Original.ID}}")
|
||||
}
|
||||
|
||||
func (_{{$contract.Type}} *{{$contract.Type}}) Unpack{{.Normalized.Name}}Error(raw []byte) (*{{$contract.Type}}{{.Normalized.Name}}, error) {
|
||||
func ({{ decapitalise $contract.Type}} *{{$contract.Type}}) Unpack{{.Normalized.Name}}Error(raw []byte) (*{{$contract.Type}}{{.Normalized.Name}}, error) {
|
||||
errName := "{{.Normalized.Name}}"
|
||||
out := new({{$contract.Type}}{{.Normalized.Name}})
|
||||
if err := _{{$contract.Type}}.abi.UnpackIntoInterface(out, errName, raw); err != nil {
|
||||
|
|
|
|||
|
|
@ -52,20 +52,20 @@ func NewDB() (*DB, error) {
|
|||
return &DB{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_DB *DB) PackConstructor() []byte {
|
||||
res, _ := _DB.abi.Pack("")
|
||||
func (dB *DB) PackConstructor() []byte {
|
||||
res, _ := dB.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Get is a free data retrieval call binding the contract method 0x9507d39a.
|
||||
//
|
||||
// Solidity: function get(uint256 k) returns(uint256)
|
||||
func (_DB *DB) PackGet(K *big.Int) ([]byte, error) {
|
||||
return _DB.abi.Pack("get", K)
|
||||
func (dB *DB) PackGet(K *big.Int) ([]byte, error) {
|
||||
return dB.abi.Pack("get", K)
|
||||
}
|
||||
|
||||
func (_DB *DB) UnpackGet(data []byte) (*big.Int, error) {
|
||||
out, err := _DB.abi.Unpack("get", data)
|
||||
func (dB *DB) UnpackGet(data []byte) (*big.Int, error) {
|
||||
out, err := dB.abi.Unpack("get", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -80,8 +80,8 @@ func (_DB *DB) UnpackGet(data []byte) (*big.Int, error) {
|
|||
// GetNamedStatParams is a free data retrieval call binding the contract method 0xe369ba3b.
|
||||
//
|
||||
// Solidity: function getNamedStatParams() view returns(uint256 gets, uint256 inserts, uint256 mods)
|
||||
func (_DB *DB) PackGetNamedStatParams() ([]byte, error) {
|
||||
return _DB.abi.Pack("getNamedStatParams")
|
||||
func (dB *DB) PackGetNamedStatParams() ([]byte, error) {
|
||||
return dB.abi.Pack("getNamedStatParams")
|
||||
}
|
||||
|
||||
type GetNamedStatParamsOutput struct {
|
||||
|
|
@ -90,8 +90,8 @@ type GetNamedStatParamsOutput struct {
|
|||
Mods *big.Int
|
||||
}
|
||||
|
||||
func (_DB *DB) UnpackGetNamedStatParams(data []byte) (GetNamedStatParamsOutput, error) {
|
||||
out, err := _DB.abi.Unpack("getNamedStatParams", data)
|
||||
func (dB *DB) UnpackGetNamedStatParams(data []byte) (GetNamedStatParamsOutput, error) {
|
||||
out, err := dB.abi.Unpack("getNamedStatParams", data)
|
||||
|
||||
outstruct := new(GetNamedStatParamsOutput)
|
||||
if err != nil {
|
||||
|
|
@ -111,8 +111,8 @@ func (_DB *DB) UnpackGetNamedStatParams(data []byte) (GetNamedStatParamsOutput,
|
|||
// GetStatParams is a free data retrieval call binding the contract method 0x6fcb9c70.
|
||||
//
|
||||
// Solidity: function getStatParams() view returns(uint256, uint256, uint256)
|
||||
func (_DB *DB) PackGetStatParams() ([]byte, error) {
|
||||
return _DB.abi.Pack("getStatParams")
|
||||
func (dB *DB) PackGetStatParams() ([]byte, error) {
|
||||
return dB.abi.Pack("getStatParams")
|
||||
}
|
||||
|
||||
type GetStatParamsOutput struct {
|
||||
|
|
@ -121,8 +121,8 @@ type GetStatParamsOutput struct {
|
|||
Arg2 *big.Int
|
||||
}
|
||||
|
||||
func (_DB *DB) UnpackGetStatParams(data []byte) (GetStatParamsOutput, error) {
|
||||
out, err := _DB.abi.Unpack("getStatParams", data)
|
||||
func (dB *DB) UnpackGetStatParams(data []byte) (GetStatParamsOutput, error) {
|
||||
out, err := dB.abi.Unpack("getStatParams", data)
|
||||
|
||||
outstruct := new(GetStatParamsOutput)
|
||||
if err != nil {
|
||||
|
|
@ -142,12 +142,12 @@ func (_DB *DB) UnpackGetStatParams(data []byte) (GetStatParamsOutput, error) {
|
|||
// GetStatsStruct is a free data retrieval call binding the contract method 0xee8161e0.
|
||||
//
|
||||
// Solidity: function getStatsStruct() view returns((uint256,uint256,uint256))
|
||||
func (_DB *DB) PackGetStatsStruct() ([]byte, error) {
|
||||
return _DB.abi.Pack("getStatsStruct")
|
||||
func (dB *DB) PackGetStatsStruct() ([]byte, error) {
|
||||
return dB.abi.Pack("getStatsStruct")
|
||||
}
|
||||
|
||||
func (_DB *DB) UnpackGetStatsStruct(data []byte) (DBStats, error) {
|
||||
out, err := _DB.abi.Unpack("getStatsStruct", data)
|
||||
func (dB *DB) UnpackGetStatsStruct(data []byte) (DBStats, error) {
|
||||
out, err := dB.abi.Unpack("getStatsStruct", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(DBStats), err
|
||||
|
|
@ -162,12 +162,12 @@ func (_DB *DB) UnpackGetStatsStruct(data []byte) (DBStats, error) {
|
|||
// Insert is a free data retrieval call binding the contract method 0x1d834a1b.
|
||||
//
|
||||
// Solidity: function insert(uint256 k, uint256 v) returns(uint256)
|
||||
func (_DB *DB) PackInsert(K *big.Int, V *big.Int) ([]byte, error) {
|
||||
return _DB.abi.Pack("insert", K, V)
|
||||
func (dB *DB) PackInsert(K *big.Int, V *big.Int) ([]byte, error) {
|
||||
return dB.abi.Pack("insert", K, V)
|
||||
}
|
||||
|
||||
func (_DB *DB) UnpackInsert(data []byte) (*big.Int, error) {
|
||||
out, err := _DB.abi.Unpack("insert", data)
|
||||
func (dB *DB) UnpackInsert(data []byte) (*big.Int, error) {
|
||||
out, err := dB.abi.Unpack("insert", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -189,19 +189,19 @@ type DBInsert struct {
|
|||
|
||||
const DBInsertEventName = "Insert"
|
||||
|
||||
func (_DB *DB) UnpackInsertEvent(log *types.Log) (*DBInsert, error) {
|
||||
func (dB *DB) UnpackInsertEvent(log *types.Log) (*DBInsert, error) {
|
||||
event := "Insert"
|
||||
if log.Topics[0] != _DB.abi.Events[event].ID {
|
||||
if log.Topics[0] != dB.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(DBInsert)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _DB.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := dB.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _DB.abi.Events[event].Inputs {
|
||||
for _, arg := range dB.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
@ -222,19 +222,19 @@ type DBKeyedInsert struct {
|
|||
|
||||
const DBKeyedInsertEventName = "KeyedInsert"
|
||||
|
||||
func (_DB *DB) UnpackKeyedInsertEvent(log *types.Log) (*DBKeyedInsert, error) {
|
||||
func (dB *DB) UnpackKeyedInsertEvent(log *types.Log) (*DBKeyedInsert, error) {
|
||||
event := "KeyedInsert"
|
||||
if log.Topics[0] != _DB.abi.Events[event].ID {
|
||||
if log.Topics[0] != dB.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(DBKeyedInsert)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _DB.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := dB.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _DB.abi.Events[event].Inputs {
|
||||
for _, arg := range dB.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -51,16 +51,16 @@ func NewC() (*C, error) {
|
|||
return &C{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_C *C) PackConstructor() []byte {
|
||||
res, _ := _C.abi.Pack("")
|
||||
func (c *C) PackConstructor() []byte {
|
||||
res, _ := c.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// DoSomethingWithManyArgs is a free data retrieval call binding the contract method 0x6fd8b968.
|
||||
//
|
||||
// Solidity: function DoSomethingWithManyArgs() pure returns(uint256, uint256, uint256, bool)
|
||||
func (_C *C) PackDoSomethingWithManyArgs() ([]byte, error) {
|
||||
return _C.abi.Pack("DoSomethingWithManyArgs")
|
||||
func (c *C) PackDoSomethingWithManyArgs() ([]byte, error) {
|
||||
return c.abi.Pack("DoSomethingWithManyArgs")
|
||||
}
|
||||
|
||||
type DoSomethingWithManyArgsOutput struct {
|
||||
|
|
@ -70,8 +70,8 @@ type DoSomethingWithManyArgsOutput struct {
|
|||
Arg3 bool
|
||||
}
|
||||
|
||||
func (_C *C) UnpackDoSomethingWithManyArgs(data []byte) (DoSomethingWithManyArgsOutput, error) {
|
||||
out, err := _C.abi.Unpack("DoSomethingWithManyArgs", data)
|
||||
func (c *C) UnpackDoSomethingWithManyArgs(data []byte) (DoSomethingWithManyArgsOutput, error) {
|
||||
out, err := c.abi.Unpack("DoSomethingWithManyArgs", data)
|
||||
|
||||
outstruct := new(DoSomethingWithManyArgsOutput)
|
||||
if err != nil {
|
||||
|
|
@ -93,12 +93,12 @@ func (_C *C) UnpackDoSomethingWithManyArgs(data []byte) (DoSomethingWithManyArgs
|
|||
// DoSomethingWithPoint is a free data retrieval call binding the contract method 0xedcdc894.
|
||||
//
|
||||
// Solidity: function DoSomethingWithPoint((uint256,uint256) p) pure returns((uint256,uint256))
|
||||
func (_C *C) PackDoSomethingWithPoint(P CPoint) ([]byte, error) {
|
||||
return _C.abi.Pack("DoSomethingWithPoint", P)
|
||||
func (c *C) PackDoSomethingWithPoint(P CPoint) ([]byte, error) {
|
||||
return c.abi.Pack("DoSomethingWithPoint", P)
|
||||
}
|
||||
|
||||
func (_C *C) UnpackDoSomethingWithPoint(data []byte) (CPoint, error) {
|
||||
out, err := _C.abi.Unpack("DoSomethingWithPoint", data)
|
||||
func (c *C) UnpackDoSomethingWithPoint(data []byte) (CPoint, error) {
|
||||
out, err := c.abi.Unpack("DoSomethingWithPoint", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(CPoint), err
|
||||
|
|
@ -113,15 +113,15 @@ func (_C *C) UnpackDoSomethingWithPoint(data []byte) (CPoint, error) {
|
|||
// EmitMulti is a free data retrieval call binding the contract method 0xcb493749.
|
||||
//
|
||||
// Solidity: function EmitMulti() returns()
|
||||
func (_C *C) PackEmitMulti() ([]byte, error) {
|
||||
return _C.abi.Pack("EmitMulti")
|
||||
func (c *C) PackEmitMulti() ([]byte, error) {
|
||||
return c.abi.Pack("EmitMulti")
|
||||
}
|
||||
|
||||
// EmitOne is a free data retrieval call binding the contract method 0xe8e49a71.
|
||||
//
|
||||
// Solidity: function EmitOne() returns()
|
||||
func (_C *C) PackEmitOne() ([]byte, error) {
|
||||
return _C.abi.Pack("EmitOne")
|
||||
func (c *C) PackEmitOne() ([]byte, error) {
|
||||
return c.abi.Pack("EmitOne")
|
||||
}
|
||||
|
||||
// CBasic1 represents a Basic1 event raised by the C contract.
|
||||
|
|
@ -133,19 +133,19 @@ type CBasic1 struct {
|
|||
|
||||
const CBasic1EventName = "basic1"
|
||||
|
||||
func (_C *C) UnpackBasic1Event(log *types.Log) (*CBasic1, error) {
|
||||
func (c *C) UnpackBasic1Event(log *types.Log) (*CBasic1, error) {
|
||||
event := "basic1"
|
||||
if log.Topics[0] != _C.abi.Events[event].ID {
|
||||
if log.Topics[0] != c.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(CBasic1)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _C.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := c.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _C.abi.Events[event].Inputs {
|
||||
for _, arg := range c.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
@ -166,19 +166,19 @@ type CBasic2 struct {
|
|||
|
||||
const CBasic2EventName = "basic2"
|
||||
|
||||
func (_C *C) UnpackBasic2Event(log *types.Log) (*CBasic2, error) {
|
||||
func (c *C) UnpackBasic2Event(log *types.Log) (*CBasic2, error) {
|
||||
event := "basic2"
|
||||
if log.Topics[0] != _C.abi.Events[event].ID {
|
||||
if log.Topics[0] != c.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(CBasic2)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _C.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := c.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _C.abi.Events[event].Inputs {
|
||||
for _, arg := range c.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -49,20 +49,20 @@ func NewC1() (*C1, error) {
|
|||
return &C1{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_C1 *C1) PackConstructor(v1 *big.Int, v2 *big.Int) []byte {
|
||||
res, _ := _C1.abi.Pack("", v1, v2)
|
||||
func (c1 *C1) PackConstructor(v1 *big.Int, v2 *big.Int) []byte {
|
||||
res, _ := c1.abi.Pack("", v1, v2)
|
||||
return res
|
||||
}
|
||||
|
||||
// Do is a free data retrieval call binding the contract method 0x2ad11272.
|
||||
//
|
||||
// Solidity: function Do(uint256 val) pure returns(uint256 res)
|
||||
func (_C1 *C1) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return _C1.abi.Pack("Do", Val)
|
||||
func (c1 *C1) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return c1.abi.Pack("Do", Val)
|
||||
}
|
||||
|
||||
func (_C1 *C1) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := _C1.abi.Unpack("Do", data)
|
||||
func (c1 *C1) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := c1.abi.Unpack("Do", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -100,20 +100,20 @@ func NewC2() (*C2, error) {
|
|||
return &C2{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_C2 *C2) PackConstructor(v1 *big.Int, v2 *big.Int) []byte {
|
||||
res, _ := _C2.abi.Pack("", v1, v2)
|
||||
func (c2 *C2) PackConstructor(v1 *big.Int, v2 *big.Int) []byte {
|
||||
res, _ := c2.abi.Pack("", v1, v2)
|
||||
return res
|
||||
}
|
||||
|
||||
// Do is a free data retrieval call binding the contract method 0x2ad11272.
|
||||
//
|
||||
// Solidity: function Do(uint256 val) pure returns(uint256 res)
|
||||
func (_C2 *C2) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return _C2.abi.Pack("Do", Val)
|
||||
func (c2 *C2) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return c2.abi.Pack("Do", Val)
|
||||
}
|
||||
|
||||
func (_C2 *C2) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := _C2.abi.Unpack("Do", data)
|
||||
func (c2 *C2) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := c2.abi.Unpack("Do", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -147,20 +147,20 @@ func NewL1() (*L1, error) {
|
|||
return &L1{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_L1 *L1) PackConstructor() []byte {
|
||||
res, _ := _L1.abi.Pack("")
|
||||
func (l1 *L1) PackConstructor() []byte {
|
||||
res, _ := l1.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Do is a free data retrieval call binding the contract method 0x2ad11272.
|
||||
//
|
||||
// Solidity: function Do(uint256 val) pure returns(uint256)
|
||||
func (_L1 *L1) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return _L1.abi.Pack("Do", Val)
|
||||
func (l1 *L1) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return l1.abi.Pack("Do", Val)
|
||||
}
|
||||
|
||||
func (_L1 *L1) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := _L1.abi.Unpack("Do", data)
|
||||
func (l1 *L1) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := l1.abi.Unpack("Do", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -197,20 +197,20 @@ func NewL2() (*L2, error) {
|
|||
return &L2{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_L2 *L2) PackConstructor() []byte {
|
||||
res, _ := _L2.abi.Pack("")
|
||||
func (l2 *L2) PackConstructor() []byte {
|
||||
res, _ := l2.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Do is a free data retrieval call binding the contract method 0x2ad11272.
|
||||
//
|
||||
// Solidity: function Do(uint256 val) pure returns(uint256)
|
||||
func (_L2 *L2) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return _L2.abi.Pack("Do", Val)
|
||||
func (l2 *L2) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return l2.abi.Pack("Do", Val)
|
||||
}
|
||||
|
||||
func (_L2 *L2) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := _L2.abi.Unpack("Do", data)
|
||||
func (l2 *L2) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := l2.abi.Unpack("Do", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -247,20 +247,20 @@ func NewL2b() (*L2b, error) {
|
|||
return &L2b{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_L2b *L2b) PackConstructor() []byte {
|
||||
res, _ := _L2b.abi.Pack("")
|
||||
func (l2b *L2b) PackConstructor() []byte {
|
||||
res, _ := l2b.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Do is a free data retrieval call binding the contract method 0x2ad11272.
|
||||
//
|
||||
// Solidity: function Do(uint256 val) pure returns(uint256)
|
||||
func (_L2b *L2b) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return _L2b.abi.Pack("Do", Val)
|
||||
func (l2b *L2b) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return l2b.abi.Pack("Do", Val)
|
||||
}
|
||||
|
||||
func (_L2b *L2b) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := _L2b.abi.Unpack("Do", data)
|
||||
func (l2b *L2b) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := l2b.abi.Unpack("Do", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -294,20 +294,20 @@ func NewL3() (*L3, error) {
|
|||
return &L3{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_L3 *L3) PackConstructor() []byte {
|
||||
res, _ := _L3.abi.Pack("")
|
||||
func (l3 *L3) PackConstructor() []byte {
|
||||
res, _ := l3.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Do is a free data retrieval call binding the contract method 0x2ad11272.
|
||||
//
|
||||
// Solidity: function Do(uint256 val) pure returns(uint256)
|
||||
func (_L3 *L3) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return _L3.abi.Pack("Do", Val)
|
||||
func (l3 *L3) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return l3.abi.Pack("Do", Val)
|
||||
}
|
||||
|
||||
func (_L3 *L3) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := _L3.abi.Unpack("Do", data)
|
||||
func (l3 *L3) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := l3.abi.Unpack("Do", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -345,20 +345,20 @@ func NewL4() (*L4, error) {
|
|||
return &L4{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_L4 *L4) PackConstructor() []byte {
|
||||
res, _ := _L4.abi.Pack("")
|
||||
func (l4 *L4) PackConstructor() []byte {
|
||||
res, _ := l4.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Do is a free data retrieval call binding the contract method 0x2ad11272.
|
||||
//
|
||||
// Solidity: function Do(uint256 val) pure returns(uint256)
|
||||
func (_L4 *L4) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return _L4.abi.Pack("Do", Val)
|
||||
func (l4 *L4) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return l4.abi.Pack("Do", Val)
|
||||
}
|
||||
|
||||
func (_L4 *L4) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := _L4.abi.Unpack("Do", data)
|
||||
func (l4 *L4) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := l4.abi.Unpack("Do", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -395,20 +395,20 @@ func NewL4b() (*L4b, error) {
|
|||
return &L4b{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_L4b *L4b) PackConstructor() []byte {
|
||||
res, _ := _L4b.abi.Pack("")
|
||||
func (l4b *L4b) PackConstructor() []byte {
|
||||
res, _ := l4b.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Do is a free data retrieval call binding the contract method 0x2ad11272.
|
||||
//
|
||||
// Solidity: function Do(uint256 val) pure returns(uint256)
|
||||
func (_L4b *L4b) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return _L4b.abi.Pack("Do", Val)
|
||||
func (l4b *L4b) PackDo(Val *big.Int) ([]byte, error) {
|
||||
return l4b.abi.Pack("Do", Val)
|
||||
}
|
||||
|
||||
func (_L4b *L4b) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := _L4b.abi.Unpack("Do", data)
|
||||
func (l4b *L4b) UnpackDo(data []byte) (*big.Int, error) {
|
||||
out, err := l4b.abi.Unpack("Do", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
|
|||
|
|
@ -45,31 +45,31 @@ func NewC() (*C, error) {
|
|||
return &C{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_C *C) PackConstructor() []byte {
|
||||
res, _ := _C.abi.Pack("")
|
||||
func (c *C) PackConstructor() []byte {
|
||||
res, _ := c.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Bar is a free data retrieval call binding the contract method 0xb0a378b0.
|
||||
//
|
||||
// Solidity: function Bar() pure returns()
|
||||
func (_C *C) PackBar() ([]byte, error) {
|
||||
return _C.abi.Pack("Bar")
|
||||
func (c *C) PackBar() ([]byte, error) {
|
||||
return c.abi.Pack("Bar")
|
||||
}
|
||||
|
||||
// Foo is a free data retrieval call binding the contract method 0xbfb4ebcf.
|
||||
//
|
||||
// Solidity: function Foo() pure returns()
|
||||
func (_C *C) PackFoo() ([]byte, error) {
|
||||
return _C.abi.Pack("Foo")
|
||||
func (c *C) PackFoo() ([]byte, error) {
|
||||
return c.abi.Pack("Foo")
|
||||
}
|
||||
|
||||
func (_C *C) UnpackError(raw []byte) any {
|
||||
func (c *C) UnpackError(raw []byte) any {
|
||||
|
||||
if val, err := _C.UnpackBadThingError(raw); err == nil {
|
||||
if val, err := c.UnpackBadThingError(raw); err == nil {
|
||||
return val
|
||||
|
||||
} else if val, err := _C.UnpackBadThing2Error(raw); err == nil {
|
||||
} else if val, err := c.UnpackBadThing2Error(raw); err == nil {
|
||||
return val
|
||||
|
||||
}
|
||||
|
|
@ -88,11 +88,10 @@ func CBadThingErrorID() common.Hash {
|
|||
return common.HexToHash("0xbb6a82f123854747ef4381e30e497f934a3854753fec99a69c35c30d4b46714d")
|
||||
}
|
||||
|
||||
func (_C *C) UnpackBadThingError(raw []byte) (*CBadThing, error) {
|
||||
func (c *C) UnpackBadThingError(raw []byte) (*CBadThing, error) {
|
||||
errName := "BadThing"
|
||||
out := new(CBadThing)
|
||||
if err := _C.abi.UnpackIntoInterface(out, errName, raw); err != nil {
|
||||
// TODO: output can be non-pointer type.
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
|
|
@ -110,11 +109,10 @@ func CBadThing2ErrorID() common.Hash {
|
|||
return common.HexToHash("0xd233a24f02271fe7c9470e060d0fda6447a142bf12ab31fed7ab65affd546175")
|
||||
}
|
||||
|
||||
func (_C *C) UnpackBadThing2Error(raw []byte) (*CBadThing2, error) {
|
||||
func (c *C) UnpackBadThing2Error(raw []byte) (*CBadThing2, error) {
|
||||
errName := "BadThing2"
|
||||
out := new(CBadThing2)
|
||||
if err := _C.abi.UnpackIntoInterface(out, errName, raw); err != nil {
|
||||
// TODO: output can be non-pointer type.
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
|
|
@ -142,21 +140,21 @@ func NewC2() (*C2, error) {
|
|||
return &C2{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_C2 *C2) PackConstructor() []byte {
|
||||
res, _ := _C2.abi.Pack("")
|
||||
func (c2 *C2) PackConstructor() []byte {
|
||||
res, _ := c2.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Foo is a free data retrieval call binding the contract method 0xbfb4ebcf.
|
||||
//
|
||||
// Solidity: function Foo() pure returns()
|
||||
func (_C2 *C2) PackFoo() ([]byte, error) {
|
||||
return _C2.abi.Pack("Foo")
|
||||
func (c2 *C2) PackFoo() ([]byte, error) {
|
||||
return c2.abi.Pack("Foo")
|
||||
}
|
||||
|
||||
func (_C2 *C2) UnpackError(raw []byte) any {
|
||||
func (c2 *C2) UnpackError(raw []byte) any {
|
||||
|
||||
if val, err := _C2.UnpackBadThingError(raw); err == nil {
|
||||
if val, err := c2.UnpackBadThingError(raw); err == nil {
|
||||
return val
|
||||
|
||||
}
|
||||
|
|
@ -175,11 +173,10 @@ func C2BadThingErrorID() common.Hash {
|
|||
return common.HexToHash("0xbb6a82f123854747ef4381e30e497f934a3854753fec99a69c35c30d4b46714d")
|
||||
}
|
||||
|
||||
func (_C2 *C2) UnpackBadThingError(raw []byte) (*C2BadThing, error) {
|
||||
func (c2 *C2) UnpackBadThingError(raw []byte) (*C2BadThing, error) {
|
||||
errName := "BadThing"
|
||||
out := new(C2BadThing)
|
||||
if err := _C2.abi.UnpackIntoInterface(out, errName, raw); err != nil {
|
||||
// TODO: output can be non-pointer type.
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
|
|
|
|||
|
|
@ -45,14 +45,14 @@ func NewCallbackParam() (*CallbackParam, error) {
|
|||
return &CallbackParam{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_CallbackParam *CallbackParam) PackConstructor() []byte {
|
||||
res, _ := _CallbackParam.abi.Pack("")
|
||||
func (callbackParam *CallbackParam) PackConstructor() []byte {
|
||||
res, _ := callbackParam.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Test is a free data retrieval call binding the contract method 0xd7a5aba2.
|
||||
//
|
||||
// Solidity: function test(function callback) returns()
|
||||
func (_CallbackParam *CallbackParam) PackTest(Callback [24]byte) ([]byte, error) {
|
||||
return _CallbackParam.abi.Pack("test", Callback)
|
||||
func (callbackParam *CallbackParam) PackTest(Callback [24]byte) ([]byte, error) {
|
||||
return callbackParam.abi.Pack("test", Callback)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,20 +45,20 @@ func NewCrowdsale() (*Crowdsale, error) {
|
|||
return &Crowdsale{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_Crowdsale *Crowdsale) PackConstructor(ifSuccessfulSendTo common.Address, fundingGoalInEthers *big.Int, durationInMinutes *big.Int, etherCostOfEachToken *big.Int, addressOfTokenUsedAsReward common.Address) []byte {
|
||||
res, _ := _Crowdsale.abi.Pack("", ifSuccessfulSendTo, fundingGoalInEthers, durationInMinutes, etherCostOfEachToken, addressOfTokenUsedAsReward)
|
||||
func (crowdsale *Crowdsale) PackConstructor(ifSuccessfulSendTo common.Address, fundingGoalInEthers *big.Int, durationInMinutes *big.Int, etherCostOfEachToken *big.Int, addressOfTokenUsedAsReward common.Address) []byte {
|
||||
res, _ := crowdsale.abi.Pack("", ifSuccessfulSendTo, fundingGoalInEthers, durationInMinutes, etherCostOfEachToken, addressOfTokenUsedAsReward)
|
||||
return res
|
||||
}
|
||||
|
||||
// AmountRaised is a free data retrieval call binding the contract method 0x7b3e5e7b.
|
||||
//
|
||||
// Solidity: function amountRaised() returns(uint256)
|
||||
func (_Crowdsale *Crowdsale) PackAmountRaised() ([]byte, error) {
|
||||
return _Crowdsale.abi.Pack("amountRaised")
|
||||
func (crowdsale *Crowdsale) PackAmountRaised() ([]byte, error) {
|
||||
return crowdsale.abi.Pack("amountRaised")
|
||||
}
|
||||
|
||||
func (_Crowdsale *Crowdsale) UnpackAmountRaised(data []byte) (*big.Int, error) {
|
||||
out, err := _Crowdsale.abi.Unpack("amountRaised", data)
|
||||
func (crowdsale *Crowdsale) UnpackAmountRaised(data []byte) (*big.Int, error) {
|
||||
out, err := crowdsale.abi.Unpack("amountRaised", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -73,12 +73,12 @@ func (_Crowdsale *Crowdsale) UnpackAmountRaised(data []byte) (*big.Int, error) {
|
|||
// Beneficiary is a free data retrieval call binding the contract method 0x38af3eed.
|
||||
//
|
||||
// Solidity: function beneficiary() returns(address)
|
||||
func (_Crowdsale *Crowdsale) PackBeneficiary() ([]byte, error) {
|
||||
return _Crowdsale.abi.Pack("beneficiary")
|
||||
func (crowdsale *Crowdsale) PackBeneficiary() ([]byte, error) {
|
||||
return crowdsale.abi.Pack("beneficiary")
|
||||
}
|
||||
|
||||
func (_Crowdsale *Crowdsale) UnpackBeneficiary(data []byte) (common.Address, error) {
|
||||
out, err := _Crowdsale.abi.Unpack("beneficiary", data)
|
||||
func (crowdsale *Crowdsale) UnpackBeneficiary(data []byte) (common.Address, error) {
|
||||
out, err := crowdsale.abi.Unpack("beneficiary", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(common.Address), err
|
||||
|
|
@ -93,19 +93,19 @@ func (_Crowdsale *Crowdsale) UnpackBeneficiary(data []byte) (common.Address, err
|
|||
// CheckGoalReached is a free data retrieval call binding the contract method 0x01cb3b20.
|
||||
//
|
||||
// Solidity: function checkGoalReached() returns()
|
||||
func (_Crowdsale *Crowdsale) PackCheckGoalReached() ([]byte, error) {
|
||||
return _Crowdsale.abi.Pack("checkGoalReached")
|
||||
func (crowdsale *Crowdsale) PackCheckGoalReached() ([]byte, error) {
|
||||
return crowdsale.abi.Pack("checkGoalReached")
|
||||
}
|
||||
|
||||
// Deadline is a free data retrieval call binding the contract method 0x29dcb0cf.
|
||||
//
|
||||
// Solidity: function deadline() returns(uint256)
|
||||
func (_Crowdsale *Crowdsale) PackDeadline() ([]byte, error) {
|
||||
return _Crowdsale.abi.Pack("deadline")
|
||||
func (crowdsale *Crowdsale) PackDeadline() ([]byte, error) {
|
||||
return crowdsale.abi.Pack("deadline")
|
||||
}
|
||||
|
||||
func (_Crowdsale *Crowdsale) UnpackDeadline(data []byte) (*big.Int, error) {
|
||||
out, err := _Crowdsale.abi.Unpack("deadline", data)
|
||||
func (crowdsale *Crowdsale) UnpackDeadline(data []byte) (*big.Int, error) {
|
||||
out, err := crowdsale.abi.Unpack("deadline", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -120,8 +120,8 @@ func (_Crowdsale *Crowdsale) UnpackDeadline(data []byte) (*big.Int, error) {
|
|||
// Funders is a free data retrieval call binding the contract method 0xdc0d3dff.
|
||||
//
|
||||
// Solidity: function funders(uint256 ) returns(address addr, uint256 amount)
|
||||
func (_Crowdsale *Crowdsale) PackFunders(Arg0 *big.Int) ([]byte, error) {
|
||||
return _Crowdsale.abi.Pack("funders", Arg0)
|
||||
func (crowdsale *Crowdsale) PackFunders(Arg0 *big.Int) ([]byte, error) {
|
||||
return crowdsale.abi.Pack("funders", Arg0)
|
||||
}
|
||||
|
||||
type FundersOutput struct {
|
||||
|
|
@ -129,8 +129,8 @@ type FundersOutput struct {
|
|||
Amount *big.Int
|
||||
}
|
||||
|
||||
func (_Crowdsale *Crowdsale) UnpackFunders(data []byte) (FundersOutput, error) {
|
||||
out, err := _Crowdsale.abi.Unpack("funders", data)
|
||||
func (crowdsale *Crowdsale) UnpackFunders(data []byte) (FundersOutput, error) {
|
||||
out, err := crowdsale.abi.Unpack("funders", data)
|
||||
|
||||
outstruct := new(FundersOutput)
|
||||
if err != nil {
|
||||
|
|
@ -148,12 +148,12 @@ func (_Crowdsale *Crowdsale) UnpackFunders(data []byte) (FundersOutput, error) {
|
|||
// FundingGoal is a free data retrieval call binding the contract method 0x7a3a0e84.
|
||||
//
|
||||
// Solidity: function fundingGoal() returns(uint256)
|
||||
func (_Crowdsale *Crowdsale) PackFundingGoal() ([]byte, error) {
|
||||
return _Crowdsale.abi.Pack("fundingGoal")
|
||||
func (crowdsale *Crowdsale) PackFundingGoal() ([]byte, error) {
|
||||
return crowdsale.abi.Pack("fundingGoal")
|
||||
}
|
||||
|
||||
func (_Crowdsale *Crowdsale) UnpackFundingGoal(data []byte) (*big.Int, error) {
|
||||
out, err := _Crowdsale.abi.Unpack("fundingGoal", data)
|
||||
func (crowdsale *Crowdsale) UnpackFundingGoal(data []byte) (*big.Int, error) {
|
||||
out, err := crowdsale.abi.Unpack("fundingGoal", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -168,12 +168,12 @@ func (_Crowdsale *Crowdsale) UnpackFundingGoal(data []byte) (*big.Int, error) {
|
|||
// Price is a free data retrieval call binding the contract method 0xa035b1fe.
|
||||
//
|
||||
// Solidity: function price() returns(uint256)
|
||||
func (_Crowdsale *Crowdsale) PackPrice() ([]byte, error) {
|
||||
return _Crowdsale.abi.Pack("price")
|
||||
func (crowdsale *Crowdsale) PackPrice() ([]byte, error) {
|
||||
return crowdsale.abi.Pack("price")
|
||||
}
|
||||
|
||||
func (_Crowdsale *Crowdsale) UnpackPrice(data []byte) (*big.Int, error) {
|
||||
out, err := _Crowdsale.abi.Unpack("price", data)
|
||||
func (crowdsale *Crowdsale) UnpackPrice(data []byte) (*big.Int, error) {
|
||||
out, err := crowdsale.abi.Unpack("price", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -188,12 +188,12 @@ func (_Crowdsale *Crowdsale) UnpackPrice(data []byte) (*big.Int, error) {
|
|||
// TokenReward is a free data retrieval call binding the contract method 0x6e66f6e9.
|
||||
//
|
||||
// Solidity: function tokenReward() returns(address)
|
||||
func (_Crowdsale *Crowdsale) PackTokenReward() ([]byte, error) {
|
||||
return _Crowdsale.abi.Pack("tokenReward")
|
||||
func (crowdsale *Crowdsale) PackTokenReward() ([]byte, error) {
|
||||
return crowdsale.abi.Pack("tokenReward")
|
||||
}
|
||||
|
||||
func (_Crowdsale *Crowdsale) UnpackTokenReward(data []byte) (common.Address, error) {
|
||||
out, err := _Crowdsale.abi.Unpack("tokenReward", data)
|
||||
func (crowdsale *Crowdsale) UnpackTokenReward(data []byte) (common.Address, error) {
|
||||
out, err := crowdsale.abi.Unpack("tokenReward", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(common.Address), err
|
||||
|
|
@ -215,19 +215,19 @@ type CrowdsaleFundTransfer struct {
|
|||
|
||||
const CrowdsaleFundTransferEventName = "FundTransfer"
|
||||
|
||||
func (_Crowdsale *Crowdsale) UnpackFundTransferEvent(log *types.Log) (*CrowdsaleFundTransfer, error) {
|
||||
func (crowdsale *Crowdsale) UnpackFundTransferEvent(log *types.Log) (*CrowdsaleFundTransfer, error) {
|
||||
event := "FundTransfer"
|
||||
if log.Topics[0] != _Crowdsale.abi.Events[event].ID {
|
||||
if log.Topics[0] != crowdsale.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(CrowdsaleFundTransfer)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _Crowdsale.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := crowdsale.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _Crowdsale.abi.Events[event].Inputs {
|
||||
for _, arg := range crowdsale.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,34 +45,34 @@ func NewDAO() (*DAO, error) {
|
|||
return &DAO{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_DAO *DAO) PackConstructor(minimumQuorumForProposals *big.Int, minutesForDebate *big.Int, marginOfVotesForMajority *big.Int, congressLeader common.Address) []byte {
|
||||
res, _ := _DAO.abi.Pack("", minimumQuorumForProposals, minutesForDebate, marginOfVotesForMajority, congressLeader)
|
||||
func (dAO *DAO) PackConstructor(minimumQuorumForProposals *big.Int, minutesForDebate *big.Int, marginOfVotesForMajority *big.Int, congressLeader common.Address) []byte {
|
||||
res, _ := dAO.abi.Pack("", minimumQuorumForProposals, minutesForDebate, marginOfVotesForMajority, congressLeader)
|
||||
return res
|
||||
}
|
||||
|
||||
// ChangeMembership is a free data retrieval call binding the contract method 0x9644fcbd.
|
||||
//
|
||||
// Solidity: function changeMembership(address targetMember, bool canVote, string memberName) returns()
|
||||
func (_DAO *DAO) PackChangeMembership(TargetMember common.Address, CanVote bool, MemberName string) ([]byte, error) {
|
||||
return _DAO.abi.Pack("changeMembership", TargetMember, CanVote, MemberName)
|
||||
func (dAO *DAO) PackChangeMembership(TargetMember common.Address, CanVote bool, MemberName string) ([]byte, error) {
|
||||
return dAO.abi.Pack("changeMembership", TargetMember, CanVote, MemberName)
|
||||
}
|
||||
|
||||
// ChangeVotingRules is a free data retrieval call binding the contract method 0xbcca1fd3.
|
||||
//
|
||||
// Solidity: function changeVotingRules(uint256 minimumQuorumForProposals, uint256 minutesForDebate, int256 marginOfVotesForMajority) returns()
|
||||
func (_DAO *DAO) PackChangeVotingRules(MinimumQuorumForProposals *big.Int, MinutesForDebate *big.Int, MarginOfVotesForMajority *big.Int) ([]byte, error) {
|
||||
return _DAO.abi.Pack("changeVotingRules", MinimumQuorumForProposals, MinutesForDebate, MarginOfVotesForMajority)
|
||||
func (dAO *DAO) PackChangeVotingRules(MinimumQuorumForProposals *big.Int, MinutesForDebate *big.Int, MarginOfVotesForMajority *big.Int) ([]byte, error) {
|
||||
return dAO.abi.Pack("changeVotingRules", MinimumQuorumForProposals, MinutesForDebate, MarginOfVotesForMajority)
|
||||
}
|
||||
|
||||
// CheckProposalCode is a free data retrieval call binding the contract method 0xeceb2945.
|
||||
//
|
||||
// Solidity: function checkProposalCode(uint256 proposalNumber, address beneficiary, uint256 etherAmount, bytes transactionBytecode) returns(bool codeChecksOut)
|
||||
func (_DAO *DAO) PackCheckProposalCode(ProposalNumber *big.Int, Beneficiary common.Address, EtherAmount *big.Int, TransactionBytecode []byte) ([]byte, error) {
|
||||
return _DAO.abi.Pack("checkProposalCode", ProposalNumber, Beneficiary, EtherAmount, TransactionBytecode)
|
||||
func (dAO *DAO) PackCheckProposalCode(ProposalNumber *big.Int, Beneficiary common.Address, EtherAmount *big.Int, TransactionBytecode []byte) ([]byte, error) {
|
||||
return dAO.abi.Pack("checkProposalCode", ProposalNumber, Beneficiary, EtherAmount, TransactionBytecode)
|
||||
}
|
||||
|
||||
func (_DAO *DAO) UnpackCheckProposalCode(data []byte) (bool, error) {
|
||||
out, err := _DAO.abi.Unpack("checkProposalCode", data)
|
||||
func (dAO *DAO) UnpackCheckProposalCode(data []byte) (bool, error) {
|
||||
out, err := dAO.abi.Unpack("checkProposalCode", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(bool), err
|
||||
|
|
@ -87,12 +87,12 @@ func (_DAO *DAO) UnpackCheckProposalCode(data []byte) (bool, error) {
|
|||
// DebatingPeriodInMinutes is a free data retrieval call binding the contract method 0x69bd3436.
|
||||
//
|
||||
// Solidity: function debatingPeriodInMinutes() returns(uint256)
|
||||
func (_DAO *DAO) PackDebatingPeriodInMinutes() ([]byte, error) {
|
||||
return _DAO.abi.Pack("debatingPeriodInMinutes")
|
||||
func (dAO *DAO) PackDebatingPeriodInMinutes() ([]byte, error) {
|
||||
return dAO.abi.Pack("debatingPeriodInMinutes")
|
||||
}
|
||||
|
||||
func (_DAO *DAO) UnpackDebatingPeriodInMinutes(data []byte) (*big.Int, error) {
|
||||
out, err := _DAO.abi.Unpack("debatingPeriodInMinutes", data)
|
||||
func (dAO *DAO) UnpackDebatingPeriodInMinutes(data []byte) (*big.Int, error) {
|
||||
out, err := dAO.abi.Unpack("debatingPeriodInMinutes", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -107,12 +107,12 @@ func (_DAO *DAO) UnpackDebatingPeriodInMinutes(data []byte) (*big.Int, error) {
|
|||
// ExecuteProposal is a free data retrieval call binding the contract method 0x237e9492.
|
||||
//
|
||||
// Solidity: function executeProposal(uint256 proposalNumber, bytes transactionBytecode) returns(int256 result)
|
||||
func (_DAO *DAO) PackExecuteProposal(ProposalNumber *big.Int, TransactionBytecode []byte) ([]byte, error) {
|
||||
return _DAO.abi.Pack("executeProposal", ProposalNumber, TransactionBytecode)
|
||||
func (dAO *DAO) PackExecuteProposal(ProposalNumber *big.Int, TransactionBytecode []byte) ([]byte, error) {
|
||||
return dAO.abi.Pack("executeProposal", ProposalNumber, TransactionBytecode)
|
||||
}
|
||||
|
||||
func (_DAO *DAO) UnpackExecuteProposal(data []byte) (*big.Int, error) {
|
||||
out, err := _DAO.abi.Unpack("executeProposal", data)
|
||||
func (dAO *DAO) UnpackExecuteProposal(data []byte) (*big.Int, error) {
|
||||
out, err := dAO.abi.Unpack("executeProposal", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -127,12 +127,12 @@ func (_DAO *DAO) UnpackExecuteProposal(data []byte) (*big.Int, error) {
|
|||
// MajorityMargin is a free data retrieval call binding the contract method 0xaa02a90f.
|
||||
//
|
||||
// Solidity: function majorityMargin() returns(int256)
|
||||
func (_DAO *DAO) PackMajorityMargin() ([]byte, error) {
|
||||
return _DAO.abi.Pack("majorityMargin")
|
||||
func (dAO *DAO) PackMajorityMargin() ([]byte, error) {
|
||||
return dAO.abi.Pack("majorityMargin")
|
||||
}
|
||||
|
||||
func (_DAO *DAO) UnpackMajorityMargin(data []byte) (*big.Int, error) {
|
||||
out, err := _DAO.abi.Unpack("majorityMargin", data)
|
||||
func (dAO *DAO) UnpackMajorityMargin(data []byte) (*big.Int, error) {
|
||||
out, err := dAO.abi.Unpack("majorityMargin", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -147,12 +147,12 @@ func (_DAO *DAO) UnpackMajorityMargin(data []byte) (*big.Int, error) {
|
|||
// MemberId is a free data retrieval call binding the contract method 0x39106821.
|
||||
//
|
||||
// Solidity: function memberId(address ) returns(uint256)
|
||||
func (_DAO *DAO) PackMemberId(Arg0 common.Address) ([]byte, error) {
|
||||
return _DAO.abi.Pack("memberId", Arg0)
|
||||
func (dAO *DAO) PackMemberId(Arg0 common.Address) ([]byte, error) {
|
||||
return dAO.abi.Pack("memberId", Arg0)
|
||||
}
|
||||
|
||||
func (_DAO *DAO) UnpackMemberId(data []byte) (*big.Int, error) {
|
||||
out, err := _DAO.abi.Unpack("memberId", data)
|
||||
func (dAO *DAO) UnpackMemberId(data []byte) (*big.Int, error) {
|
||||
out, err := dAO.abi.Unpack("memberId", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -167,8 +167,8 @@ func (_DAO *DAO) UnpackMemberId(data []byte) (*big.Int, error) {
|
|||
// Members is a free data retrieval call binding the contract method 0x5daf08ca.
|
||||
//
|
||||
// Solidity: function members(uint256 ) returns(address member, bool canVote, string name, uint256 memberSince)
|
||||
func (_DAO *DAO) PackMembers(Arg0 *big.Int) ([]byte, error) {
|
||||
return _DAO.abi.Pack("members", Arg0)
|
||||
func (dAO *DAO) PackMembers(Arg0 *big.Int) ([]byte, error) {
|
||||
return dAO.abi.Pack("members", Arg0)
|
||||
}
|
||||
|
||||
type MembersOutput struct {
|
||||
|
|
@ -178,8 +178,8 @@ type MembersOutput struct {
|
|||
MemberSince *big.Int
|
||||
}
|
||||
|
||||
func (_DAO *DAO) UnpackMembers(data []byte) (MembersOutput, error) {
|
||||
out, err := _DAO.abi.Unpack("members", data)
|
||||
func (dAO *DAO) UnpackMembers(data []byte) (MembersOutput, error) {
|
||||
out, err := dAO.abi.Unpack("members", data)
|
||||
|
||||
outstruct := new(MembersOutput)
|
||||
if err != nil {
|
||||
|
|
@ -201,12 +201,12 @@ func (_DAO *DAO) UnpackMembers(data []byte) (MembersOutput, error) {
|
|||
// MinimumQuorum is a free data retrieval call binding the contract method 0x8160f0b5.
|
||||
//
|
||||
// Solidity: function minimumQuorum() returns(uint256)
|
||||
func (_DAO *DAO) PackMinimumQuorum() ([]byte, error) {
|
||||
return _DAO.abi.Pack("minimumQuorum")
|
||||
func (dAO *DAO) PackMinimumQuorum() ([]byte, error) {
|
||||
return dAO.abi.Pack("minimumQuorum")
|
||||
}
|
||||
|
||||
func (_DAO *DAO) UnpackMinimumQuorum(data []byte) (*big.Int, error) {
|
||||
out, err := _DAO.abi.Unpack("minimumQuorum", data)
|
||||
func (dAO *DAO) UnpackMinimumQuorum(data []byte) (*big.Int, error) {
|
||||
out, err := dAO.abi.Unpack("minimumQuorum", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -221,12 +221,12 @@ func (_DAO *DAO) UnpackMinimumQuorum(data []byte) (*big.Int, error) {
|
|||
// NewProposal is a free data retrieval call binding the contract method 0xb1050da5.
|
||||
//
|
||||
// Solidity: function newProposal(address beneficiary, uint256 etherAmount, string JobDescription, bytes transactionBytecode) returns(uint256 proposalID)
|
||||
func (_DAO *DAO) PackNewProposal(Beneficiary common.Address, EtherAmount *big.Int, JobDescription string, TransactionBytecode []byte) ([]byte, error) {
|
||||
return _DAO.abi.Pack("newProposal", Beneficiary, EtherAmount, JobDescription, TransactionBytecode)
|
||||
func (dAO *DAO) PackNewProposal(Beneficiary common.Address, EtherAmount *big.Int, JobDescription string, TransactionBytecode []byte) ([]byte, error) {
|
||||
return dAO.abi.Pack("newProposal", Beneficiary, EtherAmount, JobDescription, TransactionBytecode)
|
||||
}
|
||||
|
||||
func (_DAO *DAO) UnpackNewProposal(data []byte) (*big.Int, error) {
|
||||
out, err := _DAO.abi.Unpack("newProposal", data)
|
||||
func (dAO *DAO) UnpackNewProposal(data []byte) (*big.Int, error) {
|
||||
out, err := dAO.abi.Unpack("newProposal", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -241,12 +241,12 @@ func (_DAO *DAO) UnpackNewProposal(data []byte) (*big.Int, error) {
|
|||
// NumProposals is a free data retrieval call binding the contract method 0x400e3949.
|
||||
//
|
||||
// Solidity: function numProposals() returns(uint256)
|
||||
func (_DAO *DAO) PackNumProposals() ([]byte, error) {
|
||||
return _DAO.abi.Pack("numProposals")
|
||||
func (dAO *DAO) PackNumProposals() ([]byte, error) {
|
||||
return dAO.abi.Pack("numProposals")
|
||||
}
|
||||
|
||||
func (_DAO *DAO) UnpackNumProposals(data []byte) (*big.Int, error) {
|
||||
out, err := _DAO.abi.Unpack("numProposals", data)
|
||||
func (dAO *DAO) UnpackNumProposals(data []byte) (*big.Int, error) {
|
||||
out, err := dAO.abi.Unpack("numProposals", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -261,12 +261,12 @@ func (_DAO *DAO) UnpackNumProposals(data []byte) (*big.Int, error) {
|
|||
// Owner is a free data retrieval call binding the contract method 0x8da5cb5b.
|
||||
//
|
||||
// Solidity: function owner() returns(address)
|
||||
func (_DAO *DAO) PackOwner() ([]byte, error) {
|
||||
return _DAO.abi.Pack("owner")
|
||||
func (dAO *DAO) PackOwner() ([]byte, error) {
|
||||
return dAO.abi.Pack("owner")
|
||||
}
|
||||
|
||||
func (_DAO *DAO) UnpackOwner(data []byte) (common.Address, error) {
|
||||
out, err := _DAO.abi.Unpack("owner", data)
|
||||
func (dAO *DAO) UnpackOwner(data []byte) (common.Address, error) {
|
||||
out, err := dAO.abi.Unpack("owner", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(common.Address), err
|
||||
|
|
@ -281,8 +281,8 @@ func (_DAO *DAO) UnpackOwner(data []byte) (common.Address, error) {
|
|||
// Proposals is a free data retrieval call binding the contract method 0x013cf08b.
|
||||
//
|
||||
// Solidity: function proposals(uint256 ) returns(address recipient, uint256 amount, string description, uint256 votingDeadline, bool executed, bool proposalPassed, uint256 numberOfVotes, int256 currentResult, bytes32 proposalHash)
|
||||
func (_DAO *DAO) PackProposals(Arg0 *big.Int) ([]byte, error) {
|
||||
return _DAO.abi.Pack("proposals", Arg0)
|
||||
func (dAO *DAO) PackProposals(Arg0 *big.Int) ([]byte, error) {
|
||||
return dAO.abi.Pack("proposals", Arg0)
|
||||
}
|
||||
|
||||
type ProposalsOutput struct {
|
||||
|
|
@ -297,8 +297,8 @@ type ProposalsOutput struct {
|
|||
ProposalHash [32]byte
|
||||
}
|
||||
|
||||
func (_DAO *DAO) UnpackProposals(data []byte) (ProposalsOutput, error) {
|
||||
out, err := _DAO.abi.Unpack("proposals", data)
|
||||
func (dAO *DAO) UnpackProposals(data []byte) (ProposalsOutput, error) {
|
||||
out, err := dAO.abi.Unpack("proposals", data)
|
||||
|
||||
outstruct := new(ProposalsOutput)
|
||||
if err != nil {
|
||||
|
|
@ -330,19 +330,19 @@ func (_DAO *DAO) UnpackProposals(data []byte) (ProposalsOutput, error) {
|
|||
// TransferOwnership is a free data retrieval call binding the contract method 0xf2fde38b.
|
||||
//
|
||||
// Solidity: function transferOwnership(address newOwner) returns()
|
||||
func (_DAO *DAO) PackTransferOwnership(NewOwner common.Address) ([]byte, error) {
|
||||
return _DAO.abi.Pack("transferOwnership", NewOwner)
|
||||
func (dAO *DAO) PackTransferOwnership(NewOwner common.Address) ([]byte, error) {
|
||||
return dAO.abi.Pack("transferOwnership", NewOwner)
|
||||
}
|
||||
|
||||
// Vote is a free data retrieval call binding the contract method 0xd3c0715b.
|
||||
//
|
||||
// Solidity: function vote(uint256 proposalNumber, bool supportsProposal, string justificationText) returns(uint256 voteID)
|
||||
func (_DAO *DAO) PackVote(ProposalNumber *big.Int, SupportsProposal bool, JustificationText string) ([]byte, error) {
|
||||
return _DAO.abi.Pack("vote", ProposalNumber, SupportsProposal, JustificationText)
|
||||
func (dAO *DAO) PackVote(ProposalNumber *big.Int, SupportsProposal bool, JustificationText string) ([]byte, error) {
|
||||
return dAO.abi.Pack("vote", ProposalNumber, SupportsProposal, JustificationText)
|
||||
}
|
||||
|
||||
func (_DAO *DAO) UnpackVote(data []byte) (*big.Int, error) {
|
||||
out, err := _DAO.abi.Unpack("vote", data)
|
||||
func (dAO *DAO) UnpackVote(data []byte) (*big.Int, error) {
|
||||
out, err := dAO.abi.Unpack("vote", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -364,19 +364,19 @@ type DAOChangeOfRules struct {
|
|||
|
||||
const DAOChangeOfRulesEventName = "ChangeOfRules"
|
||||
|
||||
func (_DAO *DAO) UnpackChangeOfRulesEvent(log *types.Log) (*DAOChangeOfRules, error) {
|
||||
func (dAO *DAO) UnpackChangeOfRulesEvent(log *types.Log) (*DAOChangeOfRules, error) {
|
||||
event := "ChangeOfRules"
|
||||
if log.Topics[0] != _DAO.abi.Events[event].ID {
|
||||
if log.Topics[0] != dAO.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(DAOChangeOfRules)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _DAO.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := dAO.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _DAO.abi.Events[event].Inputs {
|
||||
for _, arg := range dAO.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
@ -397,19 +397,19 @@ type DAOMembershipChanged struct {
|
|||
|
||||
const DAOMembershipChangedEventName = "MembershipChanged"
|
||||
|
||||
func (_DAO *DAO) UnpackMembershipChangedEvent(log *types.Log) (*DAOMembershipChanged, error) {
|
||||
func (dAO *DAO) UnpackMembershipChangedEvent(log *types.Log) (*DAOMembershipChanged, error) {
|
||||
event := "MembershipChanged"
|
||||
if log.Topics[0] != _DAO.abi.Events[event].ID {
|
||||
if log.Topics[0] != dAO.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(DAOMembershipChanged)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _DAO.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := dAO.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _DAO.abi.Events[event].Inputs {
|
||||
for _, arg := range dAO.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
@ -432,19 +432,19 @@ type DAOProposalAdded struct {
|
|||
|
||||
const DAOProposalAddedEventName = "ProposalAdded"
|
||||
|
||||
func (_DAO *DAO) UnpackProposalAddedEvent(log *types.Log) (*DAOProposalAdded, error) {
|
||||
func (dAO *DAO) UnpackProposalAddedEvent(log *types.Log) (*DAOProposalAdded, error) {
|
||||
event := "ProposalAdded"
|
||||
if log.Topics[0] != _DAO.abi.Events[event].ID {
|
||||
if log.Topics[0] != dAO.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(DAOProposalAdded)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _DAO.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := dAO.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _DAO.abi.Events[event].Inputs {
|
||||
for _, arg := range dAO.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
@ -467,19 +467,19 @@ type DAOProposalTallied struct {
|
|||
|
||||
const DAOProposalTalliedEventName = "ProposalTallied"
|
||||
|
||||
func (_DAO *DAO) UnpackProposalTalliedEvent(log *types.Log) (*DAOProposalTallied, error) {
|
||||
func (dAO *DAO) UnpackProposalTalliedEvent(log *types.Log) (*DAOProposalTallied, error) {
|
||||
event := "ProposalTallied"
|
||||
if log.Topics[0] != _DAO.abi.Events[event].ID {
|
||||
if log.Topics[0] != dAO.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(DAOProposalTallied)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _DAO.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := dAO.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _DAO.abi.Events[event].Inputs {
|
||||
for _, arg := range dAO.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
@ -502,19 +502,19 @@ type DAOVoted struct {
|
|||
|
||||
const DAOVotedEventName = "Voted"
|
||||
|
||||
func (_DAO *DAO) UnpackVotedEvent(log *types.Log) (*DAOVoted, error) {
|
||||
func (dAO *DAO) UnpackVotedEvent(log *types.Log) (*DAOVoted, error) {
|
||||
event := "Voted"
|
||||
if log.Topics[0] != _DAO.abi.Events[event].ID {
|
||||
if log.Topics[0] != dAO.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(DAOVoted)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _DAO.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := dAO.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _DAO.abi.Events[event].Inputs {
|
||||
for _, arg := range dAO.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,20 +45,20 @@ func NewDeeplyNestedArray() (*DeeplyNestedArray, error) {
|
|||
return &DeeplyNestedArray{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_DeeplyNestedArray *DeeplyNestedArray) PackConstructor() []byte {
|
||||
res, _ := _DeeplyNestedArray.abi.Pack("")
|
||||
func (deeplyNestedArray *DeeplyNestedArray) PackConstructor() []byte {
|
||||
res, _ := deeplyNestedArray.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// DeepUint64Array is a free data retrieval call binding the contract method 0x98ed1856.
|
||||
//
|
||||
// Solidity: function deepUint64Array(uint256 , uint256 , uint256 ) view returns(uint64)
|
||||
func (_DeeplyNestedArray *DeeplyNestedArray) PackDeepUint64Array(Arg0 *big.Int, Arg1 *big.Int, Arg2 *big.Int) ([]byte, error) {
|
||||
return _DeeplyNestedArray.abi.Pack("deepUint64Array", Arg0, Arg1, Arg2)
|
||||
func (deeplyNestedArray *DeeplyNestedArray) PackDeepUint64Array(Arg0 *big.Int, Arg1 *big.Int, Arg2 *big.Int) ([]byte, error) {
|
||||
return deeplyNestedArray.abi.Pack("deepUint64Array", Arg0, Arg1, Arg2)
|
||||
}
|
||||
|
||||
func (_DeeplyNestedArray *DeeplyNestedArray) UnpackDeepUint64Array(data []byte) (uint64, error) {
|
||||
out, err := _DeeplyNestedArray.abi.Unpack("deepUint64Array", data)
|
||||
func (deeplyNestedArray *DeeplyNestedArray) UnpackDeepUint64Array(data []byte) (uint64, error) {
|
||||
out, err := deeplyNestedArray.abi.Unpack("deepUint64Array", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(uint64), err
|
||||
|
|
@ -73,12 +73,12 @@ func (_DeeplyNestedArray *DeeplyNestedArray) UnpackDeepUint64Array(data []byte)
|
|||
// RetrieveDeepArray is a free data retrieval call binding the contract method 0x8ed4573a.
|
||||
//
|
||||
// Solidity: function retrieveDeepArray() view returns(uint64[3][4][5])
|
||||
func (_DeeplyNestedArray *DeeplyNestedArray) PackRetrieveDeepArray() ([]byte, error) {
|
||||
return _DeeplyNestedArray.abi.Pack("retrieveDeepArray")
|
||||
func (deeplyNestedArray *DeeplyNestedArray) PackRetrieveDeepArray() ([]byte, error) {
|
||||
return deeplyNestedArray.abi.Pack("retrieveDeepArray")
|
||||
}
|
||||
|
||||
func (_DeeplyNestedArray *DeeplyNestedArray) UnpackRetrieveDeepArray(data []byte) ([5][4][3]uint64, error) {
|
||||
out, err := _DeeplyNestedArray.abi.Unpack("retrieveDeepArray", data)
|
||||
func (deeplyNestedArray *DeeplyNestedArray) UnpackRetrieveDeepArray(data []byte) ([5][4][3]uint64, error) {
|
||||
out, err := deeplyNestedArray.abi.Unpack("retrieveDeepArray", data)
|
||||
|
||||
if err != nil {
|
||||
return *new([5][4][3]uint64), err
|
||||
|
|
@ -93,6 +93,6 @@ func (_DeeplyNestedArray *DeeplyNestedArray) UnpackRetrieveDeepArray(data []byte
|
|||
// StoreDeepUintArray is a free data retrieval call binding the contract method 0x34424855.
|
||||
//
|
||||
// Solidity: function storeDeepUintArray(uint64[3][4][5] arr) returns()
|
||||
func (_DeeplyNestedArray *DeeplyNestedArray) PackStoreDeepUintArray(Arr [5][4][3]uint64) ([]byte, error) {
|
||||
return _DeeplyNestedArray.abi.Pack("storeDeepUintArray", Arr)
|
||||
func (deeplyNestedArray *DeeplyNestedArray) PackStoreDeepUintArray(Arr [5][4][3]uint64) ([]byte, error) {
|
||||
return deeplyNestedArray.abi.Pack("storeDeepUintArray", Arr)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ func NewEmpty() (*Empty, error) {
|
|||
return &Empty{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_Empty *Empty) PackConstructor() []byte {
|
||||
res, _ := _Empty.abi.Pack("")
|
||||
func (empty *Empty) PackConstructor() []byte {
|
||||
res, _ := empty.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
|
|
|||
|
|
@ -44,8 +44,8 @@ func NewEventChecker() (*EventChecker, error) {
|
|||
return &EventChecker{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_EventChecker *EventChecker) PackConstructor() []byte {
|
||||
res, _ := _EventChecker.abi.Pack("")
|
||||
func (eventChecker *EventChecker) PackConstructor() []byte {
|
||||
res, _ := eventChecker.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
|
|
@ -60,19 +60,19 @@ type EventCheckerDynamic struct {
|
|||
|
||||
const EventCheckerDynamicEventName = "dynamic"
|
||||
|
||||
func (_EventChecker *EventChecker) UnpackDynamicEvent(log *types.Log) (*EventCheckerDynamic, error) {
|
||||
func (eventChecker *EventChecker) UnpackDynamicEvent(log *types.Log) (*EventCheckerDynamic, error) {
|
||||
event := "dynamic"
|
||||
if log.Topics[0] != _EventChecker.abi.Events[event].ID {
|
||||
if log.Topics[0] != eventChecker.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(EventCheckerDynamic)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _EventChecker.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := eventChecker.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _EventChecker.abi.Events[event].Inputs {
|
||||
for _, arg := range eventChecker.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
@ -91,19 +91,19 @@ type EventCheckerEmpty struct {
|
|||
|
||||
const EventCheckerEmptyEventName = "empty"
|
||||
|
||||
func (_EventChecker *EventChecker) UnpackEmptyEvent(log *types.Log) (*EventCheckerEmpty, error) {
|
||||
func (eventChecker *EventChecker) UnpackEmptyEvent(log *types.Log) (*EventCheckerEmpty, error) {
|
||||
event := "empty"
|
||||
if log.Topics[0] != _EventChecker.abi.Events[event].ID {
|
||||
if log.Topics[0] != eventChecker.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(EventCheckerEmpty)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _EventChecker.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := eventChecker.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _EventChecker.abi.Events[event].Inputs {
|
||||
for _, arg := range eventChecker.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
@ -124,19 +124,19 @@ type EventCheckerIndexed struct {
|
|||
|
||||
const EventCheckerIndexedEventName = "indexed"
|
||||
|
||||
func (_EventChecker *EventChecker) UnpackIndexedEvent(log *types.Log) (*EventCheckerIndexed, error) {
|
||||
func (eventChecker *EventChecker) UnpackIndexedEvent(log *types.Log) (*EventCheckerIndexed, error) {
|
||||
event := "indexed"
|
||||
if log.Topics[0] != _EventChecker.abi.Events[event].ID {
|
||||
if log.Topics[0] != eventChecker.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(EventCheckerIndexed)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _EventChecker.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := eventChecker.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _EventChecker.abi.Events[event].Inputs {
|
||||
for _, arg := range eventChecker.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
@ -157,19 +157,19 @@ type EventCheckerMixed struct {
|
|||
|
||||
const EventCheckerMixedEventName = "mixed"
|
||||
|
||||
func (_EventChecker *EventChecker) UnpackMixedEvent(log *types.Log) (*EventCheckerMixed, error) {
|
||||
func (eventChecker *EventChecker) UnpackMixedEvent(log *types.Log) (*EventCheckerMixed, error) {
|
||||
event := "mixed"
|
||||
if log.Topics[0] != _EventChecker.abi.Events[event].ID {
|
||||
if log.Topics[0] != eventChecker.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(EventCheckerMixed)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _EventChecker.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := eventChecker.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _EventChecker.abi.Events[event].Inputs {
|
||||
for _, arg := range eventChecker.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
@ -190,19 +190,19 @@ type EventCheckerUnnamed struct {
|
|||
|
||||
const EventCheckerUnnamedEventName = "unnamed"
|
||||
|
||||
func (_EventChecker *EventChecker) UnpackUnnamedEvent(log *types.Log) (*EventCheckerUnnamed, error) {
|
||||
func (eventChecker *EventChecker) UnpackUnnamedEvent(log *types.Log) (*EventCheckerUnnamed, error) {
|
||||
event := "unnamed"
|
||||
if log.Topics[0] != _EventChecker.abi.Events[event].ID {
|
||||
if log.Topics[0] != eventChecker.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(EventCheckerUnnamed)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _EventChecker.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := eventChecker.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _EventChecker.abi.Events[event].Inputs {
|
||||
for _, arg := range eventChecker.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,16 +45,16 @@ func NewGetter() (*Getter, error) {
|
|||
return &Getter{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_Getter *Getter) PackConstructor() []byte {
|
||||
res, _ := _Getter.abi.Pack("")
|
||||
func (getter *Getter) PackConstructor() []byte {
|
||||
res, _ := getter.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Getter is a free data retrieval call binding the contract method 0x993a04b7.
|
||||
//
|
||||
// Solidity: function getter() returns(string, int256, bytes32)
|
||||
func (_Getter *Getter) PackGetter() ([]byte, error) {
|
||||
return _Getter.abi.Pack("getter")
|
||||
func (getter *Getter) PackGetter() ([]byte, error) {
|
||||
return getter.abi.Pack("getter")
|
||||
}
|
||||
|
||||
type GetterOutput struct {
|
||||
|
|
@ -63,8 +63,8 @@ type GetterOutput struct {
|
|||
Arg2 [32]byte
|
||||
}
|
||||
|
||||
func (_Getter *Getter) UnpackGetter(data []byte) (GetterOutput, error) {
|
||||
out, err := _Getter.abi.Unpack("getter", data)
|
||||
func (getter *Getter) UnpackGetter(data []byte) (GetterOutput, error) {
|
||||
out, err := getter.abi.Unpack("getter", data)
|
||||
|
||||
outstruct := new(GetterOutput)
|
||||
if err != nil {
|
||||
|
|
|
|||
|
|
@ -45,20 +45,20 @@ func NewIdentifierCollision() (*IdentifierCollision, error) {
|
|||
return &IdentifierCollision{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_IdentifierCollision *IdentifierCollision) PackConstructor() []byte {
|
||||
res, _ := _IdentifierCollision.abi.Pack("")
|
||||
func (identifierCollision *IdentifierCollision) PackConstructor() []byte {
|
||||
res, _ := identifierCollision.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// MyVar is a free data retrieval call binding the contract method 0x4ef1f0ad.
|
||||
//
|
||||
// Solidity: function MyVar() view returns(uint256)
|
||||
func (_IdentifierCollision *IdentifierCollision) PackMyVar() ([]byte, error) {
|
||||
return _IdentifierCollision.abi.Pack("MyVar")
|
||||
func (identifierCollision *IdentifierCollision) PackMyVar() ([]byte, error) {
|
||||
return identifierCollision.abi.Pack("MyVar")
|
||||
}
|
||||
|
||||
func (_IdentifierCollision *IdentifierCollision) UnpackMyVar(data []byte) (*big.Int, error) {
|
||||
out, err := _IdentifierCollision.abi.Unpack("MyVar", data)
|
||||
func (identifierCollision *IdentifierCollision) UnpackMyVar(data []byte) (*big.Int, error) {
|
||||
out, err := identifierCollision.abi.Unpack("MyVar", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -73,12 +73,12 @@ func (_IdentifierCollision *IdentifierCollision) UnpackMyVar(data []byte) (*big.
|
|||
// PubVar is a free data retrieval call binding the contract method 0x01ad4d87.
|
||||
//
|
||||
// Solidity: function _myVar() view returns(uint256)
|
||||
func (_IdentifierCollision *IdentifierCollision) PackPubVar() ([]byte, error) {
|
||||
return _IdentifierCollision.abi.Pack("_myVar")
|
||||
func (identifierCollision *IdentifierCollision) PackPubVar() ([]byte, error) {
|
||||
return identifierCollision.abi.Pack("_myVar")
|
||||
}
|
||||
|
||||
func (_IdentifierCollision *IdentifierCollision) UnpackPubVar(data []byte) (*big.Int, error) {
|
||||
out, err := _IdentifierCollision.abi.Unpack("_myVar", data)
|
||||
func (identifierCollision *IdentifierCollision) UnpackPubVar(data []byte) (*big.Int, error) {
|
||||
out, err := identifierCollision.abi.Unpack("_myVar", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
|
|||
|
|
@ -44,49 +44,49 @@ func NewInputChecker() (*InputChecker, error) {
|
|||
return &InputChecker{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_InputChecker *InputChecker) PackConstructor() []byte {
|
||||
res, _ := _InputChecker.abi.Pack("")
|
||||
func (inputChecker *InputChecker) PackConstructor() []byte {
|
||||
res, _ := inputChecker.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// AnonInput is a free data retrieval call binding the contract method 0x3e708e82.
|
||||
//
|
||||
// Solidity: function anonInput(string ) returns()
|
||||
func (_InputChecker *InputChecker) PackAnonInput(Arg0 string) ([]byte, error) {
|
||||
return _InputChecker.abi.Pack("anonInput", Arg0)
|
||||
func (inputChecker *InputChecker) PackAnonInput(Arg0 string) ([]byte, error) {
|
||||
return inputChecker.abi.Pack("anonInput", Arg0)
|
||||
}
|
||||
|
||||
// AnonInputs is a free data retrieval call binding the contract method 0x28160527.
|
||||
//
|
||||
// Solidity: function anonInputs(string , string ) returns()
|
||||
func (_InputChecker *InputChecker) PackAnonInputs(Arg0 string, Arg1 string) ([]byte, error) {
|
||||
return _InputChecker.abi.Pack("anonInputs", Arg0, Arg1)
|
||||
func (inputChecker *InputChecker) PackAnonInputs(Arg0 string, Arg1 string) ([]byte, error) {
|
||||
return inputChecker.abi.Pack("anonInputs", Arg0, Arg1)
|
||||
}
|
||||
|
||||
// MixedInputs is a free data retrieval call binding the contract method 0xc689ebdc.
|
||||
//
|
||||
// Solidity: function mixedInputs(string , string str) returns()
|
||||
func (_InputChecker *InputChecker) PackMixedInputs(Arg0 string, Str string) ([]byte, error) {
|
||||
return _InputChecker.abi.Pack("mixedInputs", Arg0, Str)
|
||||
func (inputChecker *InputChecker) PackMixedInputs(Arg0 string, Str string) ([]byte, error) {
|
||||
return inputChecker.abi.Pack("mixedInputs", Arg0, Str)
|
||||
}
|
||||
|
||||
// NamedInput is a free data retrieval call binding the contract method 0x0d402005.
|
||||
//
|
||||
// Solidity: function namedInput(string str) returns()
|
||||
func (_InputChecker *InputChecker) PackNamedInput(Str string) ([]byte, error) {
|
||||
return _InputChecker.abi.Pack("namedInput", Str)
|
||||
func (inputChecker *InputChecker) PackNamedInput(Str string) ([]byte, error) {
|
||||
return inputChecker.abi.Pack("namedInput", Str)
|
||||
}
|
||||
|
||||
// NamedInputs is a free data retrieval call binding the contract method 0x63c796ed.
|
||||
//
|
||||
// Solidity: function namedInputs(string str1, string str2) returns()
|
||||
func (_InputChecker *InputChecker) PackNamedInputs(Str1 string, Str2 string) ([]byte, error) {
|
||||
return _InputChecker.abi.Pack("namedInputs", Str1, Str2)
|
||||
func (inputChecker *InputChecker) PackNamedInputs(Str1 string, Str2 string) ([]byte, error) {
|
||||
return inputChecker.abi.Pack("namedInputs", Str1, Str2)
|
||||
}
|
||||
|
||||
// NoInput is a free data retrieval call binding the contract method 0x53539029.
|
||||
//
|
||||
// Solidity: function noInput() returns()
|
||||
func (_InputChecker *InputChecker) PackNoInput() ([]byte, error) {
|
||||
return _InputChecker.abi.Pack("noInput")
|
||||
func (inputChecker *InputChecker) PackNoInput() ([]byte, error) {
|
||||
return inputChecker.abi.Pack("noInput")
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,20 +45,20 @@ func NewInteractor() (*Interactor, error) {
|
|||
return &Interactor{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_Interactor *Interactor) PackConstructor(str string) []byte {
|
||||
res, _ := _Interactor.abi.Pack("", str)
|
||||
func (interactor *Interactor) PackConstructor(str string) []byte {
|
||||
res, _ := interactor.abi.Pack("", str)
|
||||
return res
|
||||
}
|
||||
|
||||
// DeployString is a free data retrieval call binding the contract method 0x6874e809.
|
||||
//
|
||||
// Solidity: function deployString() returns(string)
|
||||
func (_Interactor *Interactor) PackDeployString() ([]byte, error) {
|
||||
return _Interactor.abi.Pack("deployString")
|
||||
func (interactor *Interactor) PackDeployString() ([]byte, error) {
|
||||
return interactor.abi.Pack("deployString")
|
||||
}
|
||||
|
||||
func (_Interactor *Interactor) UnpackDeployString(data []byte) (string, error) {
|
||||
out, err := _Interactor.abi.Unpack("deployString", data)
|
||||
func (interactor *Interactor) UnpackDeployString(data []byte) (string, error) {
|
||||
out, err := interactor.abi.Unpack("deployString", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(string), err
|
||||
|
|
@ -73,19 +73,19 @@ func (_Interactor *Interactor) UnpackDeployString(data []byte) (string, error) {
|
|||
// Transact is a free data retrieval call binding the contract method 0xd736c513.
|
||||
//
|
||||
// Solidity: function transact(string str) returns()
|
||||
func (_Interactor *Interactor) PackTransact(Str string) ([]byte, error) {
|
||||
return _Interactor.abi.Pack("transact", Str)
|
||||
func (interactor *Interactor) PackTransact(Str string) ([]byte, error) {
|
||||
return interactor.abi.Pack("transact", Str)
|
||||
}
|
||||
|
||||
// TransactString is a free data retrieval call binding the contract method 0x0d86a0e1.
|
||||
//
|
||||
// Solidity: function transactString() returns(string)
|
||||
func (_Interactor *Interactor) PackTransactString() ([]byte, error) {
|
||||
return _Interactor.abi.Pack("transactString")
|
||||
func (interactor *Interactor) PackTransactString() ([]byte, error) {
|
||||
return interactor.abi.Pack("transactString")
|
||||
}
|
||||
|
||||
func (_Interactor *Interactor) UnpackTransactString(data []byte) (string, error) {
|
||||
out, err := _Interactor.abi.Unpack("transactString", data)
|
||||
func (interactor *Interactor) UnpackTransactString(data []byte) (string, error) {
|
||||
out, err := interactor.abi.Unpack("transactString", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(string), err
|
||||
|
|
|
|||
|
|
@ -51,27 +51,27 @@ func NewNameConflict() (*NameConflict, error) {
|
|||
return &NameConflict{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_NameConflict *NameConflict) PackConstructor() []byte {
|
||||
res, _ := _NameConflict.abi.Pack("")
|
||||
func (nameConflict *NameConflict) PackConstructor() []byte {
|
||||
res, _ := nameConflict.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// AddRequest is a free data retrieval call binding the contract method 0xcce7b048.
|
||||
//
|
||||
// Solidity: function addRequest((bytes,bytes) req) pure returns()
|
||||
func (_NameConflict *NameConflict) PackAddRequest(Req Oraclerequest) ([]byte, error) {
|
||||
return _NameConflict.abi.Pack("addRequest", Req)
|
||||
func (nameConflict *NameConflict) PackAddRequest(Req Oraclerequest) ([]byte, error) {
|
||||
return nameConflict.abi.Pack("addRequest", Req)
|
||||
}
|
||||
|
||||
// GetRequest is a free data retrieval call binding the contract method 0xc2bb515f.
|
||||
//
|
||||
// Solidity: function getRequest() pure returns((bytes,bytes))
|
||||
func (_NameConflict *NameConflict) PackGetRequest() ([]byte, error) {
|
||||
return _NameConflict.abi.Pack("getRequest")
|
||||
func (nameConflict *NameConflict) PackGetRequest() ([]byte, error) {
|
||||
return nameConflict.abi.Pack("getRequest")
|
||||
}
|
||||
|
||||
func (_NameConflict *NameConflict) UnpackGetRequest(data []byte) (Oraclerequest, error) {
|
||||
out, err := _NameConflict.abi.Unpack("getRequest", data)
|
||||
func (nameConflict *NameConflict) UnpackGetRequest(data []byte) (Oraclerequest, error) {
|
||||
out, err := nameConflict.abi.Unpack("getRequest", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(Oraclerequest), err
|
||||
|
|
@ -92,19 +92,19 @@ type NameConflictLog struct {
|
|||
|
||||
const NameConflictLogEventName = "log"
|
||||
|
||||
func (_NameConflict *NameConflict) UnpackLogEvent(log *types.Log) (*NameConflictLog, error) {
|
||||
func (nameConflict *NameConflict) UnpackLogEvent(log *types.Log) (*NameConflictLog, error) {
|
||||
event := "log"
|
||||
if log.Topics[0] != _NameConflict.abi.Events[event].ID {
|
||||
if log.Topics[0] != nameConflict.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(NameConflictLog)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _NameConflict.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := nameConflict.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _NameConflict.abi.Events[event].Inputs {
|
||||
for _, arg := range nameConflict.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,30 +45,30 @@ func NewNumericMethodName() (*NumericMethodName, error) {
|
|||
return &NumericMethodName{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_NumericMethodName *NumericMethodName) PackConstructor() []byte {
|
||||
res, _ := _NumericMethodName.abi.Pack("")
|
||||
func (numericMethodName *NumericMethodName) PackConstructor() []byte {
|
||||
res, _ := numericMethodName.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// E1test is a free data retrieval call binding the contract method 0xffa02795.
|
||||
//
|
||||
// Solidity: function _1test() pure returns()
|
||||
func (_NumericMethodName *NumericMethodName) PackE1test() ([]byte, error) {
|
||||
return _NumericMethodName.abi.Pack("_1test")
|
||||
func (numericMethodName *NumericMethodName) PackE1test() ([]byte, error) {
|
||||
return numericMethodName.abi.Pack("_1test")
|
||||
}
|
||||
|
||||
// E1test0 is a free data retrieval call binding the contract method 0xd02767c7.
|
||||
//
|
||||
// Solidity: function __1test() pure returns()
|
||||
func (_NumericMethodName *NumericMethodName) PackE1test0() ([]byte, error) {
|
||||
return _NumericMethodName.abi.Pack("__1test")
|
||||
func (numericMethodName *NumericMethodName) PackE1test0() ([]byte, error) {
|
||||
return numericMethodName.abi.Pack("__1test")
|
||||
}
|
||||
|
||||
// E2test is a free data retrieval call binding the contract method 0x9d993132.
|
||||
//
|
||||
// Solidity: function __2test() pure returns()
|
||||
func (_NumericMethodName *NumericMethodName) PackE2test() ([]byte, error) {
|
||||
return _NumericMethodName.abi.Pack("__2test")
|
||||
func (numericMethodName *NumericMethodName) PackE2test() ([]byte, error) {
|
||||
return numericMethodName.abi.Pack("__2test")
|
||||
}
|
||||
|
||||
// NumericMethodNameE1TestEvent represents a E1TestEvent event raised by the NumericMethodName contract.
|
||||
|
|
@ -79,19 +79,19 @@ type NumericMethodNameE1TestEvent struct {
|
|||
|
||||
const NumericMethodNameE1TestEventEventName = "_1TestEvent"
|
||||
|
||||
func (_NumericMethodName *NumericMethodName) UnpackE1TestEventEvent(log *types.Log) (*NumericMethodNameE1TestEvent, error) {
|
||||
func (numericMethodName *NumericMethodName) UnpackE1TestEventEvent(log *types.Log) (*NumericMethodNameE1TestEvent, error) {
|
||||
event := "_1TestEvent"
|
||||
if log.Topics[0] != _NumericMethodName.abi.Events[event].ID {
|
||||
if log.Topics[0] != numericMethodName.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(NumericMethodNameE1TestEvent)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _NumericMethodName.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := numericMethodName.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _NumericMethodName.abi.Events[event].Inputs {
|
||||
for _, arg := range numericMethodName.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -44,20 +44,20 @@ func NewOutputChecker() (*OutputChecker, error) {
|
|||
return &OutputChecker{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_OutputChecker *OutputChecker) PackConstructor() []byte {
|
||||
res, _ := _OutputChecker.abi.Pack("")
|
||||
func (outputChecker *OutputChecker) PackConstructor() []byte {
|
||||
res, _ := outputChecker.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// AnonOutput is a free data retrieval call binding the contract method 0x008bda05.
|
||||
//
|
||||
// Solidity: function anonOutput() returns(string)
|
||||
func (_OutputChecker *OutputChecker) PackAnonOutput() ([]byte, error) {
|
||||
return _OutputChecker.abi.Pack("anonOutput")
|
||||
func (outputChecker *OutputChecker) PackAnonOutput() ([]byte, error) {
|
||||
return outputChecker.abi.Pack("anonOutput")
|
||||
}
|
||||
|
||||
func (_OutputChecker *OutputChecker) UnpackAnonOutput(data []byte) (string, error) {
|
||||
out, err := _OutputChecker.abi.Unpack("anonOutput", data)
|
||||
func (outputChecker *OutputChecker) UnpackAnonOutput(data []byte) (string, error) {
|
||||
out, err := outputChecker.abi.Unpack("anonOutput", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(string), err
|
||||
|
|
@ -72,8 +72,8 @@ func (_OutputChecker *OutputChecker) UnpackAnonOutput(data []byte) (string, erro
|
|||
// AnonOutputs is a free data retrieval call binding the contract method 0x3c401115.
|
||||
//
|
||||
// Solidity: function anonOutputs() returns(string, string)
|
||||
func (_OutputChecker *OutputChecker) PackAnonOutputs() ([]byte, error) {
|
||||
return _OutputChecker.abi.Pack("anonOutputs")
|
||||
func (outputChecker *OutputChecker) PackAnonOutputs() ([]byte, error) {
|
||||
return outputChecker.abi.Pack("anonOutputs")
|
||||
}
|
||||
|
||||
type AnonOutputsOutput struct {
|
||||
|
|
@ -81,8 +81,8 @@ type AnonOutputsOutput struct {
|
|||
Arg1 string
|
||||
}
|
||||
|
||||
func (_OutputChecker *OutputChecker) UnpackAnonOutputs(data []byte) (AnonOutputsOutput, error) {
|
||||
out, err := _OutputChecker.abi.Unpack("anonOutputs", data)
|
||||
func (outputChecker *OutputChecker) UnpackAnonOutputs(data []byte) (AnonOutputsOutput, error) {
|
||||
out, err := outputChecker.abi.Unpack("anonOutputs", data)
|
||||
|
||||
outstruct := new(AnonOutputsOutput)
|
||||
if err != nil {
|
||||
|
|
@ -100,8 +100,8 @@ func (_OutputChecker *OutputChecker) UnpackAnonOutputs(data []byte) (AnonOutputs
|
|||
// CollidingOutputs is a free data retrieval call binding the contract method 0xeccbc1ee.
|
||||
//
|
||||
// Solidity: function collidingOutputs() returns(string str, string Str)
|
||||
func (_OutputChecker *OutputChecker) PackCollidingOutputs() ([]byte, error) {
|
||||
return _OutputChecker.abi.Pack("collidingOutputs")
|
||||
func (outputChecker *OutputChecker) PackCollidingOutputs() ([]byte, error) {
|
||||
return outputChecker.abi.Pack("collidingOutputs")
|
||||
}
|
||||
|
||||
type CollidingOutputsOutput struct {
|
||||
|
|
@ -109,8 +109,8 @@ type CollidingOutputsOutput struct {
|
|||
Str0 string
|
||||
}
|
||||
|
||||
func (_OutputChecker *OutputChecker) UnpackCollidingOutputs(data []byte) (CollidingOutputsOutput, error) {
|
||||
out, err := _OutputChecker.abi.Unpack("collidingOutputs", data)
|
||||
func (outputChecker *OutputChecker) UnpackCollidingOutputs(data []byte) (CollidingOutputsOutput, error) {
|
||||
out, err := outputChecker.abi.Unpack("collidingOutputs", data)
|
||||
|
||||
outstruct := new(CollidingOutputsOutput)
|
||||
if err != nil {
|
||||
|
|
@ -128,8 +128,8 @@ func (_OutputChecker *OutputChecker) UnpackCollidingOutputs(data []byte) (Collid
|
|||
// MixedOutputs is a free data retrieval call binding the contract method 0x21b77b44.
|
||||
//
|
||||
// Solidity: function mixedOutputs() returns(string, string str)
|
||||
func (_OutputChecker *OutputChecker) PackMixedOutputs() ([]byte, error) {
|
||||
return _OutputChecker.abi.Pack("mixedOutputs")
|
||||
func (outputChecker *OutputChecker) PackMixedOutputs() ([]byte, error) {
|
||||
return outputChecker.abi.Pack("mixedOutputs")
|
||||
}
|
||||
|
||||
type MixedOutputsOutput struct {
|
||||
|
|
@ -137,8 +137,8 @@ type MixedOutputsOutput struct {
|
|||
Str string
|
||||
}
|
||||
|
||||
func (_OutputChecker *OutputChecker) UnpackMixedOutputs(data []byte) (MixedOutputsOutput, error) {
|
||||
out, err := _OutputChecker.abi.Unpack("mixedOutputs", data)
|
||||
func (outputChecker *OutputChecker) UnpackMixedOutputs(data []byte) (MixedOutputsOutput, error) {
|
||||
out, err := outputChecker.abi.Unpack("mixedOutputs", data)
|
||||
|
||||
outstruct := new(MixedOutputsOutput)
|
||||
if err != nil {
|
||||
|
|
@ -156,12 +156,12 @@ func (_OutputChecker *OutputChecker) UnpackMixedOutputs(data []byte) (MixedOutpu
|
|||
// NamedOutput is a free data retrieval call binding the contract method 0x5e632bd5.
|
||||
//
|
||||
// Solidity: function namedOutput() returns(string str)
|
||||
func (_OutputChecker *OutputChecker) PackNamedOutput() ([]byte, error) {
|
||||
return _OutputChecker.abi.Pack("namedOutput")
|
||||
func (outputChecker *OutputChecker) PackNamedOutput() ([]byte, error) {
|
||||
return outputChecker.abi.Pack("namedOutput")
|
||||
}
|
||||
|
||||
func (_OutputChecker *OutputChecker) UnpackNamedOutput(data []byte) (string, error) {
|
||||
out, err := _OutputChecker.abi.Unpack("namedOutput", data)
|
||||
func (outputChecker *OutputChecker) UnpackNamedOutput(data []byte) (string, error) {
|
||||
out, err := outputChecker.abi.Unpack("namedOutput", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(string), err
|
||||
|
|
@ -176,8 +176,8 @@ func (_OutputChecker *OutputChecker) UnpackNamedOutput(data []byte) (string, err
|
|||
// NamedOutputs is a free data retrieval call binding the contract method 0x7970a189.
|
||||
//
|
||||
// Solidity: function namedOutputs() returns(string str1, string str2)
|
||||
func (_OutputChecker *OutputChecker) PackNamedOutputs() ([]byte, error) {
|
||||
return _OutputChecker.abi.Pack("namedOutputs")
|
||||
func (outputChecker *OutputChecker) PackNamedOutputs() ([]byte, error) {
|
||||
return outputChecker.abi.Pack("namedOutputs")
|
||||
}
|
||||
|
||||
type NamedOutputsOutput struct {
|
||||
|
|
@ -185,8 +185,8 @@ type NamedOutputsOutput struct {
|
|||
Str2 string
|
||||
}
|
||||
|
||||
func (_OutputChecker *OutputChecker) UnpackNamedOutputs(data []byte) (NamedOutputsOutput, error) {
|
||||
out, err := _OutputChecker.abi.Unpack("namedOutputs", data)
|
||||
func (outputChecker *OutputChecker) UnpackNamedOutputs(data []byte) (NamedOutputsOutput, error) {
|
||||
out, err := outputChecker.abi.Unpack("namedOutputs", data)
|
||||
|
||||
outstruct := new(NamedOutputsOutput)
|
||||
if err != nil {
|
||||
|
|
@ -204,6 +204,6 @@ func (_OutputChecker *OutputChecker) UnpackNamedOutputs(data []byte) (NamedOutpu
|
|||
// NoOutput is a free data retrieval call binding the contract method 0x625f0306.
|
||||
//
|
||||
// Solidity: function noOutput() returns()
|
||||
func (_OutputChecker *OutputChecker) PackNoOutput() ([]byte, error) {
|
||||
return _OutputChecker.abi.Pack("noOutput")
|
||||
func (outputChecker *OutputChecker) PackNoOutput() ([]byte, error) {
|
||||
return outputChecker.abi.Pack("noOutput")
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,23 +45,23 @@ func NewOverload() (*Overload, error) {
|
|||
return &Overload{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_Overload *Overload) PackConstructor() []byte {
|
||||
res, _ := _Overload.abi.Pack("")
|
||||
func (overload *Overload) PackConstructor() []byte {
|
||||
res, _ := overload.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Foo is a free data retrieval call binding the contract method 0x04bc52f8.
|
||||
//
|
||||
// Solidity: function foo(uint256 i, uint256 j) returns()
|
||||
func (_Overload *Overload) PackFoo(I *big.Int, J *big.Int) ([]byte, error) {
|
||||
return _Overload.abi.Pack("foo", I, J)
|
||||
func (overload *Overload) PackFoo(I *big.Int, J *big.Int) ([]byte, error) {
|
||||
return overload.abi.Pack("foo", I, J)
|
||||
}
|
||||
|
||||
// Foo0 is a free data retrieval call binding the contract method 0x2fbebd38.
|
||||
//
|
||||
// Solidity: function foo(uint256 i) returns()
|
||||
func (_Overload *Overload) PackFoo0(I *big.Int) ([]byte, error) {
|
||||
return _Overload.abi.Pack("foo0", I)
|
||||
func (overload *Overload) PackFoo0(I *big.Int) ([]byte, error) {
|
||||
return overload.abi.Pack("foo0", I)
|
||||
}
|
||||
|
||||
// OverloadBar represents a Bar event raised by the Overload contract.
|
||||
|
|
@ -72,19 +72,19 @@ type OverloadBar struct {
|
|||
|
||||
const OverloadBarEventName = "bar"
|
||||
|
||||
func (_Overload *Overload) UnpackBarEvent(log *types.Log) (*OverloadBar, error) {
|
||||
func (overload *Overload) UnpackBarEvent(log *types.Log) (*OverloadBar, error) {
|
||||
event := "bar"
|
||||
if log.Topics[0] != _Overload.abi.Events[event].ID {
|
||||
if log.Topics[0] != overload.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(OverloadBar)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _Overload.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := overload.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _Overload.abi.Events[event].Inputs {
|
||||
for _, arg := range overload.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
@ -105,19 +105,19 @@ type OverloadBar0 struct {
|
|||
|
||||
const OverloadBar0EventName = "bar0"
|
||||
|
||||
func (_Overload *Overload) UnpackBar0Event(log *types.Log) (*OverloadBar0, error) {
|
||||
func (overload *Overload) UnpackBar0Event(log *types.Log) (*OverloadBar0, error) {
|
||||
event := "bar0"
|
||||
if log.Topics[0] != _Overload.abi.Events[event].ID {
|
||||
if log.Topics[0] != overload.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(OverloadBar0)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _Overload.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := overload.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _Overload.abi.Events[event].Inputs {
|
||||
for _, arg := range overload.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,14 +45,14 @@ func NewRangeKeyword() (*RangeKeyword, error) {
|
|||
return &RangeKeyword{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_RangeKeyword *RangeKeyword) PackConstructor() []byte {
|
||||
res, _ := _RangeKeyword.abi.Pack("")
|
||||
func (rangeKeyword *RangeKeyword) PackConstructor() []byte {
|
||||
res, _ := rangeKeyword.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// FunctionWithKeywordParameter is a free data retrieval call binding the contract method 0x527a119f.
|
||||
//
|
||||
// Solidity: function functionWithKeywordParameter(uint256 range) pure returns()
|
||||
func (_RangeKeyword *RangeKeyword) PackFunctionWithKeywordParameter(Arg0 *big.Int) ([]byte, error) {
|
||||
return _RangeKeyword.abi.Pack("functionWithKeywordParameter", Arg0)
|
||||
func (rangeKeyword *RangeKeyword) PackFunctionWithKeywordParameter(Arg0 *big.Int) ([]byte, error) {
|
||||
return rangeKeyword.abi.Pack("functionWithKeywordParameter", Arg0)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,20 +45,20 @@ func NewSlicer() (*Slicer, error) {
|
|||
return &Slicer{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_Slicer *Slicer) PackConstructor() []byte {
|
||||
res, _ := _Slicer.abi.Pack("")
|
||||
func (slicer *Slicer) PackConstructor() []byte {
|
||||
res, _ := slicer.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// EchoAddresses is a free data retrieval call binding the contract method 0xbe1127a3.
|
||||
//
|
||||
// Solidity: function echoAddresses(address[] input) returns(address[] output)
|
||||
func (_Slicer *Slicer) PackEchoAddresses(Input []common.Address) ([]byte, error) {
|
||||
return _Slicer.abi.Pack("echoAddresses", Input)
|
||||
func (slicer *Slicer) PackEchoAddresses(Input []common.Address) ([]byte, error) {
|
||||
return slicer.abi.Pack("echoAddresses", Input)
|
||||
}
|
||||
|
||||
func (_Slicer *Slicer) UnpackEchoAddresses(data []byte) ([]common.Address, error) {
|
||||
out, err := _Slicer.abi.Unpack("echoAddresses", data)
|
||||
func (slicer *Slicer) UnpackEchoAddresses(data []byte) ([]common.Address, error) {
|
||||
out, err := slicer.abi.Unpack("echoAddresses", data)
|
||||
|
||||
if err != nil {
|
||||
return *new([]common.Address), err
|
||||
|
|
@ -73,12 +73,12 @@ func (_Slicer *Slicer) UnpackEchoAddresses(data []byte) ([]common.Address, error
|
|||
// EchoBools is a free data retrieval call binding the contract method 0xf637e589.
|
||||
//
|
||||
// Solidity: function echoBools(bool[] input) returns(bool[] output)
|
||||
func (_Slicer *Slicer) PackEchoBools(Input []bool) ([]byte, error) {
|
||||
return _Slicer.abi.Pack("echoBools", Input)
|
||||
func (slicer *Slicer) PackEchoBools(Input []bool) ([]byte, error) {
|
||||
return slicer.abi.Pack("echoBools", Input)
|
||||
}
|
||||
|
||||
func (_Slicer *Slicer) UnpackEchoBools(data []byte) ([]bool, error) {
|
||||
out, err := _Slicer.abi.Unpack("echoBools", data)
|
||||
func (slicer *Slicer) UnpackEchoBools(data []byte) ([]bool, error) {
|
||||
out, err := slicer.abi.Unpack("echoBools", data)
|
||||
|
||||
if err != nil {
|
||||
return *new([]bool), err
|
||||
|
|
@ -93,12 +93,12 @@ func (_Slicer *Slicer) UnpackEchoBools(data []byte) ([]bool, error) {
|
|||
// EchoFancyInts is a free data retrieval call binding the contract method 0xd88becc0.
|
||||
//
|
||||
// Solidity: function echoFancyInts(uint24[23] input) returns(uint24[23] output)
|
||||
func (_Slicer *Slicer) PackEchoFancyInts(Input [23]*big.Int) ([]byte, error) {
|
||||
return _Slicer.abi.Pack("echoFancyInts", Input)
|
||||
func (slicer *Slicer) PackEchoFancyInts(Input [23]*big.Int) ([]byte, error) {
|
||||
return slicer.abi.Pack("echoFancyInts", Input)
|
||||
}
|
||||
|
||||
func (_Slicer *Slicer) UnpackEchoFancyInts(data []byte) ([23]*big.Int, error) {
|
||||
out, err := _Slicer.abi.Unpack("echoFancyInts", data)
|
||||
func (slicer *Slicer) UnpackEchoFancyInts(data []byte) ([23]*big.Int, error) {
|
||||
out, err := slicer.abi.Unpack("echoFancyInts", data)
|
||||
|
||||
if err != nil {
|
||||
return *new([23]*big.Int), err
|
||||
|
|
@ -113,12 +113,12 @@ func (_Slicer *Slicer) UnpackEchoFancyInts(data []byte) ([23]*big.Int, error) {
|
|||
// EchoInts is a free data retrieval call binding the contract method 0xe15a3db7.
|
||||
//
|
||||
// Solidity: function echoInts(int256[] input) returns(int256[] output)
|
||||
func (_Slicer *Slicer) PackEchoInts(Input []*big.Int) ([]byte, error) {
|
||||
return _Slicer.abi.Pack("echoInts", Input)
|
||||
func (slicer *Slicer) PackEchoInts(Input []*big.Int) ([]byte, error) {
|
||||
return slicer.abi.Pack("echoInts", Input)
|
||||
}
|
||||
|
||||
func (_Slicer *Slicer) UnpackEchoInts(data []byte) ([]*big.Int, error) {
|
||||
out, err := _Slicer.abi.Unpack("echoInts", data)
|
||||
func (slicer *Slicer) UnpackEchoInts(data []byte) ([]*big.Int, error) {
|
||||
out, err := slicer.abi.Unpack("echoInts", data)
|
||||
|
||||
if err != nil {
|
||||
return *new([]*big.Int), err
|
||||
|
|
|
|||
|
|
@ -50,16 +50,16 @@ func NewStructs() (*Structs, error) {
|
|||
return &Structs{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_Structs *Structs) PackConstructor() []byte {
|
||||
res, _ := _Structs.abi.Pack("")
|
||||
func (structs *Structs) PackConstructor() []byte {
|
||||
res, _ := structs.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// F is a free data retrieval call binding the contract method 0x28811f59.
|
||||
//
|
||||
// Solidity: function F() view returns((bytes32)[] a, uint256[] c, bool[] d)
|
||||
func (_Structs *Structs) PackF() ([]byte, error) {
|
||||
return _Structs.abi.Pack("F")
|
||||
func (structs *Structs) PackF() ([]byte, error) {
|
||||
return structs.abi.Pack("F")
|
||||
}
|
||||
|
||||
type FOutput struct {
|
||||
|
|
@ -68,8 +68,8 @@ type FOutput struct {
|
|||
D []bool
|
||||
}
|
||||
|
||||
func (_Structs *Structs) UnpackF(data []byte) (FOutput, error) {
|
||||
out, err := _Structs.abi.Unpack("F", data)
|
||||
func (structs *Structs) UnpackF(data []byte) (FOutput, error) {
|
||||
out, err := structs.abi.Unpack("F", data)
|
||||
|
||||
outstruct := new(FOutput)
|
||||
if err != nil {
|
||||
|
|
@ -89,12 +89,12 @@ func (_Structs *Structs) UnpackF(data []byte) (FOutput, error) {
|
|||
// G is a free data retrieval call binding the contract method 0x6fecb623.
|
||||
//
|
||||
// Solidity: function G() view returns((bytes32)[] a)
|
||||
func (_Structs *Structs) PackG() ([]byte, error) {
|
||||
return _Structs.abi.Pack("G")
|
||||
func (structs *Structs) PackG() ([]byte, error) {
|
||||
return structs.abi.Pack("G")
|
||||
}
|
||||
|
||||
func (_Structs *Structs) UnpackG(data []byte) ([]Struct0, error) {
|
||||
out, err := _Structs.abi.Unpack("G", data)
|
||||
func (structs *Structs) UnpackG(data []byte) ([]Struct0, error) {
|
||||
out, err := structs.abi.Unpack("G", data)
|
||||
|
||||
if err != nil {
|
||||
return *new([]Struct0), err
|
||||
|
|
|
|||
|
|
@ -45,20 +45,20 @@ func NewToken() (*Token, error) {
|
|||
return &Token{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_Token *Token) PackConstructor(initialSupply *big.Int, tokenName string, decimalUnits uint8, tokenSymbol string) []byte {
|
||||
res, _ := _Token.abi.Pack("", initialSupply, tokenName, decimalUnits, tokenSymbol)
|
||||
func (token *Token) PackConstructor(initialSupply *big.Int, tokenName string, decimalUnits uint8, tokenSymbol string) []byte {
|
||||
res, _ := token.abi.Pack("", initialSupply, tokenName, decimalUnits, tokenSymbol)
|
||||
return res
|
||||
}
|
||||
|
||||
// Allowance is a free data retrieval call binding the contract method 0xdd62ed3e.
|
||||
//
|
||||
// Solidity: function allowance(address , address ) returns(uint256)
|
||||
func (_Token *Token) PackAllowance(Arg0 common.Address, Arg1 common.Address) ([]byte, error) {
|
||||
return _Token.abi.Pack("allowance", Arg0, Arg1)
|
||||
func (token *Token) PackAllowance(Arg0 common.Address, Arg1 common.Address) ([]byte, error) {
|
||||
return token.abi.Pack("allowance", Arg0, Arg1)
|
||||
}
|
||||
|
||||
func (_Token *Token) UnpackAllowance(data []byte) (*big.Int, error) {
|
||||
out, err := _Token.abi.Unpack("allowance", data)
|
||||
func (token *Token) UnpackAllowance(data []byte) (*big.Int, error) {
|
||||
out, err := token.abi.Unpack("allowance", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -73,12 +73,12 @@ func (_Token *Token) UnpackAllowance(data []byte) (*big.Int, error) {
|
|||
// ApproveAndCall is a free data retrieval call binding the contract method 0xcae9ca51.
|
||||
//
|
||||
// Solidity: function approveAndCall(address _spender, uint256 _value, bytes _extraData) returns(bool success)
|
||||
func (_Token *Token) PackApproveAndCall(Spender common.Address, Value *big.Int, ExtraData []byte) ([]byte, error) {
|
||||
return _Token.abi.Pack("approveAndCall", Spender, Value, ExtraData)
|
||||
func (token *Token) PackApproveAndCall(Spender common.Address, Value *big.Int, ExtraData []byte) ([]byte, error) {
|
||||
return token.abi.Pack("approveAndCall", Spender, Value, ExtraData)
|
||||
}
|
||||
|
||||
func (_Token *Token) UnpackApproveAndCall(data []byte) (bool, error) {
|
||||
out, err := _Token.abi.Unpack("approveAndCall", data)
|
||||
func (token *Token) UnpackApproveAndCall(data []byte) (bool, error) {
|
||||
out, err := token.abi.Unpack("approveAndCall", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(bool), err
|
||||
|
|
@ -93,12 +93,12 @@ func (_Token *Token) UnpackApproveAndCall(data []byte) (bool, error) {
|
|||
// BalanceOf is a free data retrieval call binding the contract method 0x70a08231.
|
||||
//
|
||||
// Solidity: function balanceOf(address ) returns(uint256)
|
||||
func (_Token *Token) PackBalanceOf(Arg0 common.Address) ([]byte, error) {
|
||||
return _Token.abi.Pack("balanceOf", Arg0)
|
||||
func (token *Token) PackBalanceOf(Arg0 common.Address) ([]byte, error) {
|
||||
return token.abi.Pack("balanceOf", Arg0)
|
||||
}
|
||||
|
||||
func (_Token *Token) UnpackBalanceOf(data []byte) (*big.Int, error) {
|
||||
out, err := _Token.abi.Unpack("balanceOf", data)
|
||||
func (token *Token) UnpackBalanceOf(data []byte) (*big.Int, error) {
|
||||
out, err := token.abi.Unpack("balanceOf", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -113,12 +113,12 @@ func (_Token *Token) UnpackBalanceOf(data []byte) (*big.Int, error) {
|
|||
// Decimals is a free data retrieval call binding the contract method 0x313ce567.
|
||||
//
|
||||
// Solidity: function decimals() returns(uint8)
|
||||
func (_Token *Token) PackDecimals() ([]byte, error) {
|
||||
return _Token.abi.Pack("decimals")
|
||||
func (token *Token) PackDecimals() ([]byte, error) {
|
||||
return token.abi.Pack("decimals")
|
||||
}
|
||||
|
||||
func (_Token *Token) UnpackDecimals(data []byte) (uint8, error) {
|
||||
out, err := _Token.abi.Unpack("decimals", data)
|
||||
func (token *Token) UnpackDecimals(data []byte) (uint8, error) {
|
||||
out, err := token.abi.Unpack("decimals", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(uint8), err
|
||||
|
|
@ -133,12 +133,12 @@ func (_Token *Token) UnpackDecimals(data []byte) (uint8, error) {
|
|||
// Name is a free data retrieval call binding the contract method 0x06fdde03.
|
||||
//
|
||||
// Solidity: function name() returns(string)
|
||||
func (_Token *Token) PackName() ([]byte, error) {
|
||||
return _Token.abi.Pack("name")
|
||||
func (token *Token) PackName() ([]byte, error) {
|
||||
return token.abi.Pack("name")
|
||||
}
|
||||
|
||||
func (_Token *Token) UnpackName(data []byte) (string, error) {
|
||||
out, err := _Token.abi.Unpack("name", data)
|
||||
func (token *Token) UnpackName(data []byte) (string, error) {
|
||||
out, err := token.abi.Unpack("name", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(string), err
|
||||
|
|
@ -153,12 +153,12 @@ func (_Token *Token) UnpackName(data []byte) (string, error) {
|
|||
// SpentAllowance is a free data retrieval call binding the contract method 0xdc3080f2.
|
||||
//
|
||||
// Solidity: function spentAllowance(address , address ) returns(uint256)
|
||||
func (_Token *Token) PackSpentAllowance(Arg0 common.Address, Arg1 common.Address) ([]byte, error) {
|
||||
return _Token.abi.Pack("spentAllowance", Arg0, Arg1)
|
||||
func (token *Token) PackSpentAllowance(Arg0 common.Address, Arg1 common.Address) ([]byte, error) {
|
||||
return token.abi.Pack("spentAllowance", Arg0, Arg1)
|
||||
}
|
||||
|
||||
func (_Token *Token) UnpackSpentAllowance(data []byte) (*big.Int, error) {
|
||||
out, err := _Token.abi.Unpack("spentAllowance", data)
|
||||
func (token *Token) UnpackSpentAllowance(data []byte) (*big.Int, error) {
|
||||
out, err := token.abi.Unpack("spentAllowance", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
@ -173,12 +173,12 @@ func (_Token *Token) UnpackSpentAllowance(data []byte) (*big.Int, error) {
|
|||
// Symbol is a free data retrieval call binding the contract method 0x95d89b41.
|
||||
//
|
||||
// Solidity: function symbol() returns(string)
|
||||
func (_Token *Token) PackSymbol() ([]byte, error) {
|
||||
return _Token.abi.Pack("symbol")
|
||||
func (token *Token) PackSymbol() ([]byte, error) {
|
||||
return token.abi.Pack("symbol")
|
||||
}
|
||||
|
||||
func (_Token *Token) UnpackSymbol(data []byte) (string, error) {
|
||||
out, err := _Token.abi.Unpack("symbol", data)
|
||||
func (token *Token) UnpackSymbol(data []byte) (string, error) {
|
||||
out, err := token.abi.Unpack("symbol", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(string), err
|
||||
|
|
@ -193,19 +193,19 @@ func (_Token *Token) UnpackSymbol(data []byte) (string, error) {
|
|||
// Transfer is a free data retrieval call binding the contract method 0xa9059cbb.
|
||||
//
|
||||
// Solidity: function transfer(address _to, uint256 _value) returns()
|
||||
func (_Token *Token) PackTransfer(To common.Address, Value *big.Int) ([]byte, error) {
|
||||
return _Token.abi.Pack("transfer", To, Value)
|
||||
func (token *Token) PackTransfer(To common.Address, Value *big.Int) ([]byte, error) {
|
||||
return token.abi.Pack("transfer", To, Value)
|
||||
}
|
||||
|
||||
// TransferFrom is a free data retrieval call binding the contract method 0x23b872dd.
|
||||
//
|
||||
// Solidity: function transferFrom(address _from, address _to, uint256 _value) returns(bool success)
|
||||
func (_Token *Token) PackTransferFrom(From common.Address, To common.Address, Value *big.Int) ([]byte, error) {
|
||||
return _Token.abi.Pack("transferFrom", From, To, Value)
|
||||
func (token *Token) PackTransferFrom(From common.Address, To common.Address, Value *big.Int) ([]byte, error) {
|
||||
return token.abi.Pack("transferFrom", From, To, Value)
|
||||
}
|
||||
|
||||
func (_Token *Token) UnpackTransferFrom(data []byte) (bool, error) {
|
||||
out, err := _Token.abi.Unpack("transferFrom", data)
|
||||
func (token *Token) UnpackTransferFrom(data []byte) (bool, error) {
|
||||
out, err := token.abi.Unpack("transferFrom", data)
|
||||
|
||||
if err != nil {
|
||||
return *new(bool), err
|
||||
|
|
@ -227,19 +227,19 @@ type TokenTransfer struct {
|
|||
|
||||
const TokenTransferEventName = "Transfer"
|
||||
|
||||
func (_Token *Token) UnpackTransferEvent(log *types.Log) (*TokenTransfer, error) {
|
||||
func (token *Token) UnpackTransferEvent(log *types.Log) (*TokenTransfer, error) {
|
||||
event := "Transfer"
|
||||
if log.Topics[0] != _Token.abi.Events[event].ID {
|
||||
if log.Topics[0] != token.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(TokenTransfer)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _Token.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := token.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _Token.abi.Events[event].Inputs {
|
||||
for _, arg := range token.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -70,16 +70,16 @@ func NewTuple() (*Tuple, error) {
|
|||
return &Tuple{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_Tuple *Tuple) PackConstructor() []byte {
|
||||
res, _ := _Tuple.abi.Pack("")
|
||||
func (tuple *Tuple) PackConstructor() []byte {
|
||||
res, _ := tuple.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Func1 is a free data retrieval call binding the contract method 0x443c79b4.
|
||||
//
|
||||
// Solidity: function func1((uint256,uint256[],(uint256,uint256)[]) a, (uint256,uint256)[2][] b, (uint256,uint256)[][2] c, (uint256,uint256[],(uint256,uint256)[])[] d, uint256[] e) pure returns((uint256,uint256[],(uint256,uint256)[]), (uint256,uint256)[2][], (uint256,uint256)[][2], (uint256,uint256[],(uint256,uint256)[])[], uint256[])
|
||||
func (_Tuple *Tuple) PackFunc1(A TupleS, B [][2]TupleT, C [2][]TupleT, D []TupleS, E []*big.Int) ([]byte, error) {
|
||||
return _Tuple.abi.Pack("func1", A, B, C, D, E)
|
||||
func (tuple *Tuple) PackFunc1(A TupleS, B [][2]TupleT, C [2][]TupleT, D []TupleS, E []*big.Int) ([]byte, error) {
|
||||
return tuple.abi.Pack("func1", A, B, C, D, E)
|
||||
}
|
||||
|
||||
type Func1Output struct {
|
||||
|
|
@ -90,8 +90,8 @@ type Func1Output struct {
|
|||
Arg4 []*big.Int
|
||||
}
|
||||
|
||||
func (_Tuple *Tuple) UnpackFunc1(data []byte) (Func1Output, error) {
|
||||
out, err := _Tuple.abi.Unpack("func1", data)
|
||||
func (tuple *Tuple) UnpackFunc1(data []byte) (Func1Output, error) {
|
||||
out, err := tuple.abi.Unpack("func1", data)
|
||||
|
||||
outstruct := new(Func1Output)
|
||||
if err != nil {
|
||||
|
|
@ -115,15 +115,15 @@ func (_Tuple *Tuple) UnpackFunc1(data []byte) (Func1Output, error) {
|
|||
// Func2 is a free data retrieval call binding the contract method 0xd0062cdd.
|
||||
//
|
||||
// Solidity: function func2((uint256,uint256[],(uint256,uint256)[]) a, (uint256,uint256)[2][] b, (uint256,uint256)[][2] c, (uint256,uint256[],(uint256,uint256)[])[] d, uint256[] e) returns()
|
||||
func (_Tuple *Tuple) PackFunc2(A TupleS, B [][2]TupleT, C [2][]TupleT, D []TupleS, E []*big.Int) ([]byte, error) {
|
||||
return _Tuple.abi.Pack("func2", A, B, C, D, E)
|
||||
func (tuple *Tuple) PackFunc2(A TupleS, B [][2]TupleT, C [2][]TupleT, D []TupleS, E []*big.Int) ([]byte, error) {
|
||||
return tuple.abi.Pack("func2", A, B, C, D, E)
|
||||
}
|
||||
|
||||
// Func3 is a free data retrieval call binding the contract method 0xe4d9a43b.
|
||||
//
|
||||
// Solidity: function func3((uint16,uint16)[] ) pure returns()
|
||||
func (_Tuple *Tuple) PackFunc3(Arg0 []TupleQ) ([]byte, error) {
|
||||
return _Tuple.abi.Pack("func3", Arg0)
|
||||
func (tuple *Tuple) PackFunc3(Arg0 []TupleQ) ([]byte, error) {
|
||||
return tuple.abi.Pack("func3", Arg0)
|
||||
}
|
||||
|
||||
// TupleTupleEvent represents a TupleEvent event raised by the Tuple contract.
|
||||
|
|
@ -138,19 +138,19 @@ type TupleTupleEvent struct {
|
|||
|
||||
const TupleTupleEventEventName = "TupleEvent"
|
||||
|
||||
func (_Tuple *Tuple) UnpackTupleEventEvent(log *types.Log) (*TupleTupleEvent, error) {
|
||||
func (tuple *Tuple) UnpackTupleEventEvent(log *types.Log) (*TupleTupleEvent, error) {
|
||||
event := "TupleEvent"
|
||||
if log.Topics[0] != _Tuple.abi.Events[event].ID {
|
||||
if log.Topics[0] != tuple.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(TupleTupleEvent)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _Tuple.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := tuple.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _Tuple.abi.Events[event].Inputs {
|
||||
for _, arg := range tuple.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
@ -170,19 +170,19 @@ type TupleTupleEvent2 struct {
|
|||
|
||||
const TupleTupleEvent2EventName = "TupleEvent2"
|
||||
|
||||
func (_Tuple *Tuple) UnpackTupleEvent2Event(log *types.Log) (*TupleTupleEvent2, error) {
|
||||
func (tuple *Tuple) UnpackTupleEvent2Event(log *types.Log) (*TupleTupleEvent2, error) {
|
||||
event := "TupleEvent2"
|
||||
if log.Topics[0] != _Tuple.abi.Events[event].ID {
|
||||
if log.Topics[0] != tuple.abi.Events[event].ID {
|
||||
return nil, errors.New("event signature mismatch")
|
||||
}
|
||||
out := new(TupleTupleEvent2)
|
||||
if len(log.Data) > 0 {
|
||||
if err := _Tuple.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
if err := tuple.abi.UnpackIntoInterface(out, event, log.Data); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
var indexed abi.Arguments
|
||||
for _, arg := range _Tuple.abi.Events[event].Inputs {
|
||||
for _, arg := range tuple.abi.Events[event].Inputs {
|
||||
if arg.Indexed {
|
||||
indexed = append(indexed, arg)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,16 +45,16 @@ func NewTupler() (*Tupler, error) {
|
|||
return &Tupler{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_Tupler *Tupler) PackConstructor() []byte {
|
||||
res, _ := _Tupler.abi.Pack("")
|
||||
func (tupler *Tupler) PackConstructor() []byte {
|
||||
res, _ := tupler.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// Tuple is a free data retrieval call binding the contract method 0x3175aae2.
|
||||
//
|
||||
// Solidity: function tuple() returns(string a, int256 b, bytes32 c)
|
||||
func (_Tupler *Tupler) PackTuple() ([]byte, error) {
|
||||
return _Tupler.abi.Pack("tuple")
|
||||
func (tupler *Tupler) PackTuple() ([]byte, error) {
|
||||
return tupler.abi.Pack("tuple")
|
||||
}
|
||||
|
||||
type TupleOutput struct {
|
||||
|
|
@ -63,8 +63,8 @@ type TupleOutput struct {
|
|||
C [32]byte
|
||||
}
|
||||
|
||||
func (_Tupler *Tupler) UnpackTuple(data []byte) (TupleOutput, error) {
|
||||
out, err := _Tupler.abi.Unpack("tuple", data)
|
||||
func (tupler *Tupler) UnpackTuple(data []byte) (TupleOutput, error) {
|
||||
out, err := tupler.abi.Unpack("tuple", data)
|
||||
|
||||
outstruct := new(TupleOutput)
|
||||
if err != nil {
|
||||
|
|
|
|||
|
|
@ -45,16 +45,16 @@ func NewUnderscorer() (*Underscorer, error) {
|
|||
return &Underscorer{abi: *parsed}, nil
|
||||
}
|
||||
|
||||
func (_Underscorer *Underscorer) PackConstructor() []byte {
|
||||
res, _ := _Underscorer.abi.Pack("")
|
||||
func (underscorer *Underscorer) PackConstructor() []byte {
|
||||
res, _ := underscorer.abi.Pack("")
|
||||
return res
|
||||
}
|
||||
|
||||
// AllPurelyUnderscoredOutput is a free data retrieval call binding the contract method 0xb564b34d.
|
||||
//
|
||||
// Solidity: function AllPurelyUnderscoredOutput() view returns(int256 _, int256 __)
|
||||
func (_Underscorer *Underscorer) PackAllPurelyUnderscoredOutput() ([]byte, error) {
|
||||
return _Underscorer.abi.Pack("AllPurelyUnderscoredOutput")
|
||||
func (underscorer *Underscorer) PackAllPurelyUnderscoredOutput() ([]byte, error) {
|
||||
return underscorer.abi.Pack("AllPurelyUnderscoredOutput")
|
||||
}
|
||||
|
||||
type AllPurelyUnderscoredOutputOutput struct {
|
||||
|
|
@ -62,8 +62,8 @@ type AllPurelyUnderscoredOutputOutput struct {
|
|||
Arg1 *big.Int
|
||||
}
|
||||
|
||||
func (_Underscorer *Underscorer) UnpackAllPurelyUnderscoredOutput(data []byte) (AllPurelyUnderscoredOutputOutput, error) {
|
||||
out, err := _Underscorer.abi.Unpack("AllPurelyUnderscoredOutput", data)
|
||||
func (underscorer *Underscorer) UnpackAllPurelyUnderscoredOutput(data []byte) (AllPurelyUnderscoredOutputOutput, error) {
|
||||
out, err := underscorer.abi.Unpack("AllPurelyUnderscoredOutput", data)
|
||||
|
||||
outstruct := new(AllPurelyUnderscoredOutputOutput)
|
||||
if err != nil {
|
||||
|
|
@ -81,8 +81,8 @@ func (_Underscorer *Underscorer) UnpackAllPurelyUnderscoredOutput(data []byte) (
|
|||
// LowerLowerCollision is a free data retrieval call binding the contract method 0xe409ca45.
|
||||
//
|
||||
// Solidity: function LowerLowerCollision() view returns(int256 _res, int256 res)
|
||||
func (_Underscorer *Underscorer) PackLowerLowerCollision() ([]byte, error) {
|
||||
return _Underscorer.abi.Pack("LowerLowerCollision")
|
||||
func (underscorer *Underscorer) PackLowerLowerCollision() ([]byte, error) {
|
||||
return underscorer.abi.Pack("LowerLowerCollision")
|
||||
}
|
||||
|
||||
type LowerLowerCollisionOutput struct {
|
||||
|
|
@ -90,8 +90,8 @@ type LowerLowerCollisionOutput struct {
|
|||
Res0 *big.Int
|
||||
}
|
||||
|
||||
func (_Underscorer *Underscorer) UnpackLowerLowerCollision(data []byte) (LowerLowerCollisionOutput, error) {
|
||||
out, err := _Underscorer.abi.Unpack("LowerLowerCollision", data)
|
||||
func (underscorer *Underscorer) UnpackLowerLowerCollision(data []byte) (LowerLowerCollisionOutput, error) {
|
||||
out, err := underscorer.abi.Unpack("LowerLowerCollision", data)
|
||||
|
||||
outstruct := new(LowerLowerCollisionOutput)
|
||||
if err != nil {
|
||||
|
|
@ -109,8 +109,8 @@ func (_Underscorer *Underscorer) UnpackLowerLowerCollision(data []byte) (LowerLo
|
|||
// LowerUpperCollision is a free data retrieval call binding the contract method 0x03a59213.
|
||||
//
|
||||
// Solidity: function LowerUpperCollision() view returns(int256 _res, int256 Res)
|
||||
func (_Underscorer *Underscorer) PackLowerUpperCollision() ([]byte, error) {
|
||||
return _Underscorer.abi.Pack("LowerUpperCollision")
|
||||
func (underscorer *Underscorer) PackLowerUpperCollision() ([]byte, error) {
|
||||
return underscorer.abi.Pack("LowerUpperCollision")
|
||||
}
|
||||
|
||||
type LowerUpperCollisionOutput struct {
|
||||
|
|
@ -118,8 +118,8 @@ type LowerUpperCollisionOutput struct {
|
|||
Res0 *big.Int
|
||||
}
|
||||
|
||||
func (_Underscorer *Underscorer) UnpackLowerUpperCollision(data []byte) (LowerUpperCollisionOutput, error) {
|
||||
out, err := _Underscorer.abi.Unpack("LowerUpperCollision", data)
|
||||
func (underscorer *Underscorer) UnpackLowerUpperCollision(data []byte) (LowerUpperCollisionOutput, error) {
|
||||
out, err := underscorer.abi.Unpack("LowerUpperCollision", data)
|
||||
|
||||
outstruct := new(LowerUpperCollisionOutput)
|
||||
if err != nil {
|
||||
|
|
@ -137,8 +137,8 @@ func (_Underscorer *Underscorer) UnpackLowerUpperCollision(data []byte) (LowerUp
|
|||
// PurelyUnderscoredOutput is a free data retrieval call binding the contract method 0x9df48485.
|
||||
//
|
||||
// Solidity: function PurelyUnderscoredOutput() view returns(int256 _, int256 res)
|
||||
func (_Underscorer *Underscorer) PackPurelyUnderscoredOutput() ([]byte, error) {
|
||||
return _Underscorer.abi.Pack("PurelyUnderscoredOutput")
|
||||
func (underscorer *Underscorer) PackPurelyUnderscoredOutput() ([]byte, error) {
|
||||
return underscorer.abi.Pack("PurelyUnderscoredOutput")
|
||||
}
|
||||
|
||||
type PurelyUnderscoredOutputOutput struct {
|
||||
|
|
@ -146,8 +146,8 @@ type PurelyUnderscoredOutputOutput struct {
|
|||
Res *big.Int
|
||||
}
|
||||
|
||||
func (_Underscorer *Underscorer) UnpackPurelyUnderscoredOutput(data []byte) (PurelyUnderscoredOutputOutput, error) {
|
||||
out, err := _Underscorer.abi.Unpack("PurelyUnderscoredOutput", data)
|
||||
func (underscorer *Underscorer) UnpackPurelyUnderscoredOutput(data []byte) (PurelyUnderscoredOutputOutput, error) {
|
||||
out, err := underscorer.abi.Unpack("PurelyUnderscoredOutput", data)
|
||||
|
||||
outstruct := new(PurelyUnderscoredOutputOutput)
|
||||
if err != nil {
|
||||
|
|
@ -165,8 +165,8 @@ func (_Underscorer *Underscorer) UnpackPurelyUnderscoredOutput(data []byte) (Pur
|
|||
// UnderscoredOutput is a free data retrieval call binding the contract method 0x67e6633d.
|
||||
//
|
||||
// Solidity: function UnderscoredOutput() view returns(int256 _int, string _string)
|
||||
func (_Underscorer *Underscorer) PackUnderscoredOutput() ([]byte, error) {
|
||||
return _Underscorer.abi.Pack("UnderscoredOutput")
|
||||
func (underscorer *Underscorer) PackUnderscoredOutput() ([]byte, error) {
|
||||
return underscorer.abi.Pack("UnderscoredOutput")
|
||||
}
|
||||
|
||||
type UnderscoredOutputOutput struct {
|
||||
|
|
@ -174,8 +174,8 @@ type UnderscoredOutputOutput struct {
|
|||
String string
|
||||
}
|
||||
|
||||
func (_Underscorer *Underscorer) UnpackUnderscoredOutput(data []byte) (UnderscoredOutputOutput, error) {
|
||||
out, err := _Underscorer.abi.Unpack("UnderscoredOutput", data)
|
||||
func (underscorer *Underscorer) UnpackUnderscoredOutput(data []byte) (UnderscoredOutputOutput, error) {
|
||||
out, err := underscorer.abi.Unpack("UnderscoredOutput", data)
|
||||
|
||||
outstruct := new(UnderscoredOutputOutput)
|
||||
if err != nil {
|
||||
|
|
@ -193,8 +193,8 @@ func (_Underscorer *Underscorer) UnpackUnderscoredOutput(data []byte) (Underscor
|
|||
// UpperLowerCollision is a free data retrieval call binding the contract method 0xaf7486ab.
|
||||
//
|
||||
// Solidity: function UpperLowerCollision() view returns(int256 _Res, int256 res)
|
||||
func (_Underscorer *Underscorer) PackUpperLowerCollision() ([]byte, error) {
|
||||
return _Underscorer.abi.Pack("UpperLowerCollision")
|
||||
func (underscorer *Underscorer) PackUpperLowerCollision() ([]byte, error) {
|
||||
return underscorer.abi.Pack("UpperLowerCollision")
|
||||
}
|
||||
|
||||
type UpperLowerCollisionOutput struct {
|
||||
|
|
@ -202,8 +202,8 @@ type UpperLowerCollisionOutput struct {
|
|||
Res0 *big.Int
|
||||
}
|
||||
|
||||
func (_Underscorer *Underscorer) UnpackUpperLowerCollision(data []byte) (UpperLowerCollisionOutput, error) {
|
||||
out, err := _Underscorer.abi.Unpack("UpperLowerCollision", data)
|
||||
func (underscorer *Underscorer) UnpackUpperLowerCollision(data []byte) (UpperLowerCollisionOutput, error) {
|
||||
out, err := underscorer.abi.Unpack("UpperLowerCollision", data)
|
||||
|
||||
outstruct := new(UpperLowerCollisionOutput)
|
||||
if err != nil {
|
||||
|
|
@ -221,8 +221,8 @@ func (_Underscorer *Underscorer) UnpackUpperLowerCollision(data []byte) (UpperLo
|
|||
// UpperUpperCollision is a free data retrieval call binding the contract method 0xe02ab24d.
|
||||
//
|
||||
// Solidity: function UpperUpperCollision() view returns(int256 _Res, int256 Res)
|
||||
func (_Underscorer *Underscorer) PackUpperUpperCollision() ([]byte, error) {
|
||||
return _Underscorer.abi.Pack("UpperUpperCollision")
|
||||
func (underscorer *Underscorer) PackUpperUpperCollision() ([]byte, error) {
|
||||
return underscorer.abi.Pack("UpperUpperCollision")
|
||||
}
|
||||
|
||||
type UpperUpperCollisionOutput struct {
|
||||
|
|
@ -230,8 +230,8 @@ type UpperUpperCollisionOutput struct {
|
|||
Res0 *big.Int
|
||||
}
|
||||
|
||||
func (_Underscorer *Underscorer) UnpackUpperUpperCollision(data []byte) (UpperUpperCollisionOutput, error) {
|
||||
out, err := _Underscorer.abi.Unpack("UpperUpperCollision", data)
|
||||
func (underscorer *Underscorer) UnpackUpperUpperCollision(data []byte) (UpperUpperCollisionOutput, error) {
|
||||
out, err := underscorer.abi.Unpack("UpperUpperCollision", data)
|
||||
|
||||
outstruct := new(UpperUpperCollisionOutput)
|
||||
if err != nil {
|
||||
|
|
@ -249,12 +249,12 @@ func (_Underscorer *Underscorer) UnpackUpperUpperCollision(data []byte) (UpperUp
|
|||
// UnderScoredFunc is a free data retrieval call binding the contract method 0x46546dbe.
|
||||
//
|
||||
// Solidity: function _under_scored_func() view returns(int256 _int)
|
||||
func (_Underscorer *Underscorer) PackUnderScoredFunc() ([]byte, error) {
|
||||
return _Underscorer.abi.Pack("_under_scored_func")
|
||||
func (underscorer *Underscorer) PackUnderScoredFunc() ([]byte, error) {
|
||||
return underscorer.abi.Pack("_under_scored_func")
|
||||
}
|
||||
|
||||
func (_Underscorer *Underscorer) UnpackUnderScoredFunc(data []byte) (*big.Int, error) {
|
||||
out, err := _Underscorer.abi.Unpack("_under_scored_func", data)
|
||||
func (underscorer *Underscorer) UnpackUnderScoredFunc(data []byte) (*big.Int, error) {
|
||||
out, err := underscorer.abi.Unpack("_under_scored_func", data)
|
||||
|
||||
if err != nil {
|
||||
return new(big.Int), err
|
||||
|
|
|
|||
Loading…
Reference in a new issue