/
messagebus.go
748 lines (619 loc) · 41.6 KB
/
messagebus.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
// Code generated - DO NOT EDIT.
// This file is a generated binding and any manual changes will be lost.
package cbridge
import (
"errors"
"math/big"
"strings"
ethereum "github.com/ethereum/go-ethereum"
"github.com/ethereum/go-ethereum/accounts/abi"
"github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/core/types"
"github.com/ethereum/go-ethereum/event"
)
// Reference imports to suppress errors if they are not otherwise used.
var (
_ = errors.New
_ = big.NewInt
_ = strings.NewReader
_ = ethereum.NotFound
_ = bind.Bind
_ = common.Big1
_ = types.BloomLookup
_ = event.NewSubscription
)
// MsgDataTypesRouteInfo is an auto generated low-level Go binding around an user-defined struct.
type MsgDataTypesRouteInfo struct {
Sender common.Address
Receiver common.Address
SrcChainId uint64
SrcTxHash [32]byte
}
// MsgDataTypesTransferInfo is an auto generated low-level Go binding around an user-defined struct.
type MsgDataTypesTransferInfo struct {
T uint8
Sender common.Address
Receiver common.Address
Token common.Address
Amount *big.Int
Wdseq uint64
SrcChainId uint64
RefId [32]byte
SrcTxHash [32]byte
}
// IMessageBusMetaData contains all meta data concerning the IMessageBus contract.
var IMessageBusMetaData = &bind.MetaData{
ABI: "[{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"_message\",\"type\":\"bytes\"}],\"name\":\"calcFee\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"_message\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"receiver\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"srcChainId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"srcTxHash\",\"type\":\"bytes32\"}],\"internalType\":\"structMsgDataTypes.RouteInfo\",\"name\":\"_route\",\"type\":\"tuple\"},{\"internalType\":\"bytes[]\",\"name\":\"_sigs\",\"type\":\"bytes[]\"},{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"uint256[]\",\"name\":\"_powers\",\"type\":\"uint256[]\"}],\"name\":\"executeMessage\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"_message\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"enumMsgDataTypes.TransferType\",\"name\":\"t\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"receiver\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint64\",\"name\":\"wdseq\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"srcChainId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"refId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"srcTxHash\",\"type\":\"bytes32\"}],\"internalType\":\"structMsgDataTypes.TransferInfo\",\"name\":\"_transfer\",\"type\":\"tuple\"},{\"internalType\":\"bytes[]\",\"name\":\"_sigs\",\"type\":\"bytes[]\"},{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"uint256[]\",\"name\":\"_powers\",\"type\":\"uint256[]\"}],\"name\":\"executeMessageWithTransfer\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"_message\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"enumMsgDataTypes.TransferType\",\"name\":\"t\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"receiver\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint64\",\"name\":\"wdseq\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"srcChainId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"refId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"srcTxHash\",\"type\":\"bytes32\"}],\"internalType\":\"structMsgDataTypes.TransferInfo\",\"name\":\"_transfer\",\"type\":\"tuple\"},{\"internalType\":\"bytes[]\",\"name\":\"_sigs\",\"type\":\"bytes[]\"},{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"uint256[]\",\"name\":\"_powers\",\"type\":\"uint256[]\"}],\"name\":\"executeMessageWithTransferRefund\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feeBase\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feePerByte\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"liquidityBridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pegBridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pegBridgeV2\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pegVault\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pegVaultV2\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_receiver\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_dstChainId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_message\",\"type\":\"bytes\"}],\"name\":\"sendMessage\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_receiver\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_dstChainId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"_srcBridge\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"_srcTransferId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"_message\",\"type\":\"bytes\"}],\"name\":\"sendMessageWithTransfer\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_cumulativeFee\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"_sigs\",\"type\":\"bytes[]\"},{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"uint256[]\",\"name\":\"_powers\",\"type\":\"uint256[]\"}],\"name\":\"withdrawFee\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]",
}
// IMessageBusABI is the input ABI used to generate the binding from.
// Deprecated: Use IMessageBusMetaData.ABI instead.
var IMessageBusABI = IMessageBusMetaData.ABI
// IMessageBus is an auto generated Go binding around an Ethereum contract.
type IMessageBus struct {
IMessageBusCaller // Read-only binding to the contract
IMessageBusTransactor // Write-only binding to the contract
IMessageBusFilterer // Log filterer for contract events
}
// IMessageBusCaller is an auto generated read-only Go binding around an Ethereum contract.
type IMessageBusCaller struct {
contract *bind.BoundContract // Generic contract wrapper for the low level calls
}
// IMessageBusTransactor is an auto generated write-only Go binding around an Ethereum contract.
type IMessageBusTransactor struct {
contract *bind.BoundContract // Generic contract wrapper for the low level calls
}
// IMessageBusFilterer is an auto generated log filtering Go binding around an Ethereum contract events.
type IMessageBusFilterer struct {
contract *bind.BoundContract // Generic contract wrapper for the low level calls
}
// IMessageBusSession is an auto generated Go binding around an Ethereum contract,
// with pre-set call and transact options.
type IMessageBusSession struct {
Contract *IMessageBus // Generic contract binding to set the session for
CallOpts bind.CallOpts // Call options to use throughout this session
TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
}
// IMessageBusCallerSession is an auto generated read-only Go binding around an Ethereum contract,
// with pre-set call options.
type IMessageBusCallerSession struct {
Contract *IMessageBusCaller // Generic contract caller binding to set the session for
CallOpts bind.CallOpts // Call options to use throughout this session
}
// IMessageBusTransactorSession is an auto generated write-only Go binding around an Ethereum contract,
// with pre-set transact options.
type IMessageBusTransactorSession struct {
Contract *IMessageBusTransactor // Generic contract transactor binding to set the session for
TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
}
// IMessageBusRaw is an auto generated low-level Go binding around an Ethereum contract.
type IMessageBusRaw struct {
Contract *IMessageBus // Generic contract binding to access the raw methods on
}
// IMessageBusCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.
type IMessageBusCallerRaw struct {
Contract *IMessageBusCaller // Generic read-only contract binding to access the raw methods on
}
// IMessageBusTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.
type IMessageBusTransactorRaw struct {
Contract *IMessageBusTransactor // Generic write-only contract binding to access the raw methods on
}
// NewIMessageBus creates a new instance of IMessageBus, bound to a specific deployed contract.
func NewIMessageBus(address common.Address, backend bind.ContractBackend) (*IMessageBus, error) {
contract, err := bindIMessageBus(address, backend, backend, backend)
if err != nil {
return nil, err
}
return &IMessageBus{IMessageBusCaller: IMessageBusCaller{contract: contract}, IMessageBusTransactor: IMessageBusTransactor{contract: contract}, IMessageBusFilterer: IMessageBusFilterer{contract: contract}}, nil
}
// NewIMessageBusCaller creates a new read-only instance of IMessageBus, bound to a specific deployed contract.
func NewIMessageBusCaller(address common.Address, caller bind.ContractCaller) (*IMessageBusCaller, error) {
contract, err := bindIMessageBus(address, caller, nil, nil)
if err != nil {
return nil, err
}
return &IMessageBusCaller{contract: contract}, nil
}
// NewIMessageBusTransactor creates a new write-only instance of IMessageBus, bound to a specific deployed contract.
func NewIMessageBusTransactor(address common.Address, transactor bind.ContractTransactor) (*IMessageBusTransactor, error) {
contract, err := bindIMessageBus(address, nil, transactor, nil)
if err != nil {
return nil, err
}
return &IMessageBusTransactor{contract: contract}, nil
}
// NewIMessageBusFilterer creates a new log filterer instance of IMessageBus, bound to a specific deployed contract.
func NewIMessageBusFilterer(address common.Address, filterer bind.ContractFilterer) (*IMessageBusFilterer, error) {
contract, err := bindIMessageBus(address, nil, nil, filterer)
if err != nil {
return nil, err
}
return &IMessageBusFilterer{contract: contract}, nil
}
// bindIMessageBus binds a generic wrapper to an already deployed contract.
func bindIMessageBus(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) {
parsed, err := abi.JSON(strings.NewReader(IMessageBusABI))
if err != nil {
return nil, err
}
return bind.NewBoundContract(address, parsed, caller, transactor, filterer), nil
}
// Call invokes the (constant) contract method with params as input values and
// sets the output to result. The result type might be a single field for simple
// returns, a slice of interfaces for anonymous returns and a struct for named
// returns.
func (_IMessageBus *IMessageBusRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
return _IMessageBus.Contract.IMessageBusCaller.contract.Call(opts, result, method, params...)
}
// Transfer initiates a plain transaction to move funds to the contract, calling
// its default method if one is available.
func (_IMessageBus *IMessageBusRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
return _IMessageBus.Contract.IMessageBusTransactor.contract.Transfer(opts)
}
// Transact invokes the (paid) contract method with params as input values.
func (_IMessageBus *IMessageBusRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
return _IMessageBus.Contract.IMessageBusTransactor.contract.Transact(opts, method, params...)
}
// Call invokes the (constant) contract method with params as input values and
// sets the output to result. The result type might be a single field for simple
// returns, a slice of interfaces for anonymous returns and a struct for named
// returns.
func (_IMessageBus *IMessageBusCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
return _IMessageBus.Contract.contract.Call(opts, result, method, params...)
}
// Transfer initiates a plain transaction to move funds to the contract, calling
// its default method if one is available.
func (_IMessageBus *IMessageBusTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
return _IMessageBus.Contract.contract.Transfer(opts)
}
// Transact invokes the (paid) contract method with params as input values.
func (_IMessageBus *IMessageBusTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
return _IMessageBus.Contract.contract.Transact(opts, method, params...)
}
// CalcFee is a free data retrieval call binding the contract method 0x5335dca2.
//
// Solidity: function calcFee(bytes _message) view returns(uint256)
func (_IMessageBus *IMessageBusCaller) CalcFee(opts *bind.CallOpts, _message []byte) (*big.Int, error) {
var out []interface{}
err := _IMessageBus.contract.Call(opts, &out, "calcFee", _message)
if err != nil {
return *new(*big.Int), err
}
out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
return out0, err
}
// CalcFee is a free data retrieval call binding the contract method 0x5335dca2.
//
// Solidity: function calcFee(bytes _message) view returns(uint256)
func (_IMessageBus *IMessageBusSession) CalcFee(_message []byte) (*big.Int, error) {
return _IMessageBus.Contract.CalcFee(&_IMessageBus.CallOpts, _message)
}
// CalcFee is a free data retrieval call binding the contract method 0x5335dca2.
//
// Solidity: function calcFee(bytes _message) view returns(uint256)
func (_IMessageBus *IMessageBusCallerSession) CalcFee(_message []byte) (*big.Int, error) {
return _IMessageBus.Contract.CalcFee(&_IMessageBus.CallOpts, _message)
}
// FeeBase is a free data retrieval call binding the contract method 0x95e911a8.
//
// Solidity: function feeBase() view returns(uint256)
func (_IMessageBus *IMessageBusCaller) FeeBase(opts *bind.CallOpts) (*big.Int, error) {
var out []interface{}
err := _IMessageBus.contract.Call(opts, &out, "feeBase")
if err != nil {
return *new(*big.Int), err
}
out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
return out0, err
}
// FeeBase is a free data retrieval call binding the contract method 0x95e911a8.
//
// Solidity: function feeBase() view returns(uint256)
func (_IMessageBus *IMessageBusSession) FeeBase() (*big.Int, error) {
return _IMessageBus.Contract.FeeBase(&_IMessageBus.CallOpts)
}
// FeeBase is a free data retrieval call binding the contract method 0x95e911a8.
//
// Solidity: function feeBase() view returns(uint256)
func (_IMessageBus *IMessageBusCallerSession) FeeBase() (*big.Int, error) {
return _IMessageBus.Contract.FeeBase(&_IMessageBus.CallOpts)
}
// FeePerByte is a free data retrieval call binding the contract method 0xf60bbe2a.
//
// Solidity: function feePerByte() view returns(uint256)
func (_IMessageBus *IMessageBusCaller) FeePerByte(opts *bind.CallOpts) (*big.Int, error) {
var out []interface{}
err := _IMessageBus.contract.Call(opts, &out, "feePerByte")
if err != nil {
return *new(*big.Int), err
}
out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
return out0, err
}
// FeePerByte is a free data retrieval call binding the contract method 0xf60bbe2a.
//
// Solidity: function feePerByte() view returns(uint256)
func (_IMessageBus *IMessageBusSession) FeePerByte() (*big.Int, error) {
return _IMessageBus.Contract.FeePerByte(&_IMessageBus.CallOpts)
}
// FeePerByte is a free data retrieval call binding the contract method 0xf60bbe2a.
//
// Solidity: function feePerByte() view returns(uint256)
func (_IMessageBus *IMessageBusCallerSession) FeePerByte() (*big.Int, error) {
return _IMessageBus.Contract.FeePerByte(&_IMessageBus.CallOpts)
}
// LiquidityBridge is a free data retrieval call binding the contract method 0x82980dc4.
//
// Solidity: function liquidityBridge() view returns(address)
func (_IMessageBus *IMessageBusCaller) LiquidityBridge(opts *bind.CallOpts) (common.Address, error) {
var out []interface{}
err := _IMessageBus.contract.Call(opts, &out, "liquidityBridge")
if err != nil {
return *new(common.Address), err
}
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
return out0, err
}
// LiquidityBridge is a free data retrieval call binding the contract method 0x82980dc4.
//
// Solidity: function liquidityBridge() view returns(address)
func (_IMessageBus *IMessageBusSession) LiquidityBridge() (common.Address, error) {
return _IMessageBus.Contract.LiquidityBridge(&_IMessageBus.CallOpts)
}
// LiquidityBridge is a free data retrieval call binding the contract method 0x82980dc4.
//
// Solidity: function liquidityBridge() view returns(address)
func (_IMessageBus *IMessageBusCallerSession) LiquidityBridge() (common.Address, error) {
return _IMessageBus.Contract.LiquidityBridge(&_IMessageBus.CallOpts)
}
// PegBridge is a free data retrieval call binding the contract method 0xdfa2dbaf.
//
// Solidity: function pegBridge() view returns(address)
func (_IMessageBus *IMessageBusCaller) PegBridge(opts *bind.CallOpts) (common.Address, error) {
var out []interface{}
err := _IMessageBus.contract.Call(opts, &out, "pegBridge")
if err != nil {
return *new(common.Address), err
}
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
return out0, err
}
// PegBridge is a free data retrieval call binding the contract method 0xdfa2dbaf.
//
// Solidity: function pegBridge() view returns(address)
func (_IMessageBus *IMessageBusSession) PegBridge() (common.Address, error) {
return _IMessageBus.Contract.PegBridge(&_IMessageBus.CallOpts)
}
// PegBridge is a free data retrieval call binding the contract method 0xdfa2dbaf.
//
// Solidity: function pegBridge() view returns(address)
func (_IMessageBus *IMessageBusCallerSession) PegBridge() (common.Address, error) {
return _IMessageBus.Contract.PegBridge(&_IMessageBus.CallOpts)
}
// PegBridgeV2 is a free data retrieval call binding the contract method 0x95b12c27.
//
// Solidity: function pegBridgeV2() view returns(address)
func (_IMessageBus *IMessageBusCaller) PegBridgeV2(opts *bind.CallOpts) (common.Address, error) {
var out []interface{}
err := _IMessageBus.contract.Call(opts, &out, "pegBridgeV2")
if err != nil {
return *new(common.Address), err
}
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
return out0, err
}
// PegBridgeV2 is a free data retrieval call binding the contract method 0x95b12c27.
//
// Solidity: function pegBridgeV2() view returns(address)
func (_IMessageBus *IMessageBusSession) PegBridgeV2() (common.Address, error) {
return _IMessageBus.Contract.PegBridgeV2(&_IMessageBus.CallOpts)
}
// PegBridgeV2 is a free data retrieval call binding the contract method 0x95b12c27.
//
// Solidity: function pegBridgeV2() view returns(address)
func (_IMessageBus *IMessageBusCallerSession) PegBridgeV2() (common.Address, error) {
return _IMessageBus.Contract.PegBridgeV2(&_IMessageBus.CallOpts)
}
// PegVault is a free data retrieval call binding the contract method 0xd8257d17.
//
// Solidity: function pegVault() view returns(address)
func (_IMessageBus *IMessageBusCaller) PegVault(opts *bind.CallOpts) (common.Address, error) {
var out []interface{}
err := _IMessageBus.contract.Call(opts, &out, "pegVault")
if err != nil {
return *new(common.Address), err
}
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
return out0, err
}
// PegVault is a free data retrieval call binding the contract method 0xd8257d17.
//
// Solidity: function pegVault() view returns(address)
func (_IMessageBus *IMessageBusSession) PegVault() (common.Address, error) {
return _IMessageBus.Contract.PegVault(&_IMessageBus.CallOpts)
}
// PegVault is a free data retrieval call binding the contract method 0xd8257d17.
//
// Solidity: function pegVault() view returns(address)
func (_IMessageBus *IMessageBusCallerSession) PegVault() (common.Address, error) {
return _IMessageBus.Contract.PegVault(&_IMessageBus.CallOpts)
}
// PegVaultV2 is a free data retrieval call binding the contract method 0xc66a9c5a.
//
// Solidity: function pegVaultV2() view returns(address)
func (_IMessageBus *IMessageBusCaller) PegVaultV2(opts *bind.CallOpts) (common.Address, error) {
var out []interface{}
err := _IMessageBus.contract.Call(opts, &out, "pegVaultV2")
if err != nil {
return *new(common.Address), err
}
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
return out0, err
}
// PegVaultV2 is a free data retrieval call binding the contract method 0xc66a9c5a.
//
// Solidity: function pegVaultV2() view returns(address)
func (_IMessageBus *IMessageBusSession) PegVaultV2() (common.Address, error) {
return _IMessageBus.Contract.PegVaultV2(&_IMessageBus.CallOpts)
}
// PegVaultV2 is a free data retrieval call binding the contract method 0xc66a9c5a.
//
// Solidity: function pegVaultV2() view returns(address)
func (_IMessageBus *IMessageBusCallerSession) PegVaultV2() (common.Address, error) {
return _IMessageBus.Contract.PegVaultV2(&_IMessageBus.CallOpts)
}
// ExecuteMessage is a paid mutator transaction binding the contract method 0x468a2d04.
//
// Solidity: function executeMessage(bytes _message, (address,address,uint64,bytes32) _route, bytes[] _sigs, address[] _signers, uint256[] _powers) payable returns()
func (_IMessageBus *IMessageBusTransactor) ExecuteMessage(opts *bind.TransactOpts, _message []byte, _route MsgDataTypesRouteInfo, _sigs [][]byte, _signers []common.Address, _powers []*big.Int) (*types.Transaction, error) {
return _IMessageBus.contract.Transact(opts, "executeMessage", _message, _route, _sigs, _signers, _powers)
}
// ExecuteMessage is a paid mutator transaction binding the contract method 0x468a2d04.
//
// Solidity: function executeMessage(bytes _message, (address,address,uint64,bytes32) _route, bytes[] _sigs, address[] _signers, uint256[] _powers) payable returns()
func (_IMessageBus *IMessageBusSession) ExecuteMessage(_message []byte, _route MsgDataTypesRouteInfo, _sigs [][]byte, _signers []common.Address, _powers []*big.Int) (*types.Transaction, error) {
return _IMessageBus.Contract.ExecuteMessage(&_IMessageBus.TransactOpts, _message, _route, _sigs, _signers, _powers)
}
// ExecuteMessage is a paid mutator transaction binding the contract method 0x468a2d04.
//
// Solidity: function executeMessage(bytes _message, (address,address,uint64,bytes32) _route, bytes[] _sigs, address[] _signers, uint256[] _powers) payable returns()
func (_IMessageBus *IMessageBusTransactorSession) ExecuteMessage(_message []byte, _route MsgDataTypesRouteInfo, _sigs [][]byte, _signers []common.Address, _powers []*big.Int) (*types.Transaction, error) {
return _IMessageBus.Contract.ExecuteMessage(&_IMessageBus.TransactOpts, _message, _route, _sigs, _signers, _powers)
}
// ExecuteMessageWithTransfer is a paid mutator transaction binding the contract method 0x3f395aff.
//
// Solidity: function executeMessageWithTransfer(bytes _message, (uint8,address,address,address,uint256,uint64,uint64,bytes32,bytes32) _transfer, bytes[] _sigs, address[] _signers, uint256[] _powers) payable returns()
func (_IMessageBus *IMessageBusTransactor) ExecuteMessageWithTransfer(opts *bind.TransactOpts, _message []byte, _transfer MsgDataTypesTransferInfo, _sigs [][]byte, _signers []common.Address, _powers []*big.Int) (*types.Transaction, error) {
return _IMessageBus.contract.Transact(opts, "executeMessageWithTransfer", _message, _transfer, _sigs, _signers, _powers)
}
// ExecuteMessageWithTransfer is a paid mutator transaction binding the contract method 0x3f395aff.
//
// Solidity: function executeMessageWithTransfer(bytes _message, (uint8,address,address,address,uint256,uint64,uint64,bytes32,bytes32) _transfer, bytes[] _sigs, address[] _signers, uint256[] _powers) payable returns()
func (_IMessageBus *IMessageBusSession) ExecuteMessageWithTransfer(_message []byte, _transfer MsgDataTypesTransferInfo, _sigs [][]byte, _signers []common.Address, _powers []*big.Int) (*types.Transaction, error) {
return _IMessageBus.Contract.ExecuteMessageWithTransfer(&_IMessageBus.TransactOpts, _message, _transfer, _sigs, _signers, _powers)
}
// ExecuteMessageWithTransfer is a paid mutator transaction binding the contract method 0x3f395aff.
//
// Solidity: function executeMessageWithTransfer(bytes _message, (uint8,address,address,address,uint256,uint64,uint64,bytes32,bytes32) _transfer, bytes[] _sigs, address[] _signers, uint256[] _powers) payable returns()
func (_IMessageBus *IMessageBusTransactorSession) ExecuteMessageWithTransfer(_message []byte, _transfer MsgDataTypesTransferInfo, _sigs [][]byte, _signers []common.Address, _powers []*big.Int) (*types.Transaction, error) {
return _IMessageBus.Contract.ExecuteMessageWithTransfer(&_IMessageBus.TransactOpts, _message, _transfer, _sigs, _signers, _powers)
}
// ExecuteMessageWithTransferRefund is a paid mutator transaction binding the contract method 0x7b80ab20.
//
// Solidity: function executeMessageWithTransferRefund(bytes _message, (uint8,address,address,address,uint256,uint64,uint64,bytes32,bytes32) _transfer, bytes[] _sigs, address[] _signers, uint256[] _powers) payable returns()
func (_IMessageBus *IMessageBusTransactor) ExecuteMessageWithTransferRefund(opts *bind.TransactOpts, _message []byte, _transfer MsgDataTypesTransferInfo, _sigs [][]byte, _signers []common.Address, _powers []*big.Int) (*types.Transaction, error) {
return _IMessageBus.contract.Transact(opts, "executeMessageWithTransferRefund", _message, _transfer, _sigs, _signers, _powers)
}
// ExecuteMessageWithTransferRefund is a paid mutator transaction binding the contract method 0x7b80ab20.
//
// Solidity: function executeMessageWithTransferRefund(bytes _message, (uint8,address,address,address,uint256,uint64,uint64,bytes32,bytes32) _transfer, bytes[] _sigs, address[] _signers, uint256[] _powers) payable returns()
func (_IMessageBus *IMessageBusSession) ExecuteMessageWithTransferRefund(_message []byte, _transfer MsgDataTypesTransferInfo, _sigs [][]byte, _signers []common.Address, _powers []*big.Int) (*types.Transaction, error) {
return _IMessageBus.Contract.ExecuteMessageWithTransferRefund(&_IMessageBus.TransactOpts, _message, _transfer, _sigs, _signers, _powers)
}
// ExecuteMessageWithTransferRefund is a paid mutator transaction binding the contract method 0x7b80ab20.
//
// Solidity: function executeMessageWithTransferRefund(bytes _message, (uint8,address,address,address,uint256,uint64,uint64,bytes32,bytes32) _transfer, bytes[] _sigs, address[] _signers, uint256[] _powers) payable returns()
func (_IMessageBus *IMessageBusTransactorSession) ExecuteMessageWithTransferRefund(_message []byte, _transfer MsgDataTypesTransferInfo, _sigs [][]byte, _signers []common.Address, _powers []*big.Int) (*types.Transaction, error) {
return _IMessageBus.Contract.ExecuteMessageWithTransferRefund(&_IMessageBus.TransactOpts, _message, _transfer, _sigs, _signers, _powers)
}
// SendMessage is a paid mutator transaction binding the contract method 0x9f3ce55a.
//
// Solidity: function sendMessage(address _receiver, uint256 _dstChainId, bytes _message) payable returns()
func (_IMessageBus *IMessageBusTransactor) SendMessage(opts *bind.TransactOpts, _receiver common.Address, _dstChainId *big.Int, _message []byte) (*types.Transaction, error) {
return _IMessageBus.contract.Transact(opts, "sendMessage", _receiver, _dstChainId, _message)
}
// SendMessage is a paid mutator transaction binding the contract method 0x9f3ce55a.
//
// Solidity: function sendMessage(address _receiver, uint256 _dstChainId, bytes _message) payable returns()
func (_IMessageBus *IMessageBusSession) SendMessage(_receiver common.Address, _dstChainId *big.Int, _message []byte) (*types.Transaction, error) {
return _IMessageBus.Contract.SendMessage(&_IMessageBus.TransactOpts, _receiver, _dstChainId, _message)
}
// SendMessage is a paid mutator transaction binding the contract method 0x9f3ce55a.
//
// Solidity: function sendMessage(address _receiver, uint256 _dstChainId, bytes _message) payable returns()
func (_IMessageBus *IMessageBusTransactorSession) SendMessage(_receiver common.Address, _dstChainId *big.Int, _message []byte) (*types.Transaction, error) {
return _IMessageBus.Contract.SendMessage(&_IMessageBus.TransactOpts, _receiver, _dstChainId, _message)
}
// SendMessageWithTransfer is a paid mutator transaction binding the contract method 0x4289fbb3.
//
// Solidity: function sendMessageWithTransfer(address _receiver, uint256 _dstChainId, address _srcBridge, bytes32 _srcTransferId, bytes _message) payable returns()
func (_IMessageBus *IMessageBusTransactor) SendMessageWithTransfer(opts *bind.TransactOpts, _receiver common.Address, _dstChainId *big.Int, _srcBridge common.Address, _srcTransferId [32]byte, _message []byte) (*types.Transaction, error) {
return _IMessageBus.contract.Transact(opts, "sendMessageWithTransfer", _receiver, _dstChainId, _srcBridge, _srcTransferId, _message)
}
// SendMessageWithTransfer is a paid mutator transaction binding the contract method 0x4289fbb3.
//
// Solidity: function sendMessageWithTransfer(address _receiver, uint256 _dstChainId, address _srcBridge, bytes32 _srcTransferId, bytes _message) payable returns()
func (_IMessageBus *IMessageBusSession) SendMessageWithTransfer(_receiver common.Address, _dstChainId *big.Int, _srcBridge common.Address, _srcTransferId [32]byte, _message []byte) (*types.Transaction, error) {
return _IMessageBus.Contract.SendMessageWithTransfer(&_IMessageBus.TransactOpts, _receiver, _dstChainId, _srcBridge, _srcTransferId, _message)
}
// SendMessageWithTransfer is a paid mutator transaction binding the contract method 0x4289fbb3.
//
// Solidity: function sendMessageWithTransfer(address _receiver, uint256 _dstChainId, address _srcBridge, bytes32 _srcTransferId, bytes _message) payable returns()
func (_IMessageBus *IMessageBusTransactorSession) SendMessageWithTransfer(_receiver common.Address, _dstChainId *big.Int, _srcBridge common.Address, _srcTransferId [32]byte, _message []byte) (*types.Transaction, error) {
return _IMessageBus.Contract.SendMessageWithTransfer(&_IMessageBus.TransactOpts, _receiver, _dstChainId, _srcBridge, _srcTransferId, _message)
}
// WithdrawFee is a paid mutator transaction binding the contract method 0x2ff4c411.
//
// Solidity: function withdrawFee(address _account, uint256 _cumulativeFee, bytes[] _sigs, address[] _signers, uint256[] _powers) returns()
func (_IMessageBus *IMessageBusTransactor) WithdrawFee(opts *bind.TransactOpts, _account common.Address, _cumulativeFee *big.Int, _sigs [][]byte, _signers []common.Address, _powers []*big.Int) (*types.Transaction, error) {
return _IMessageBus.contract.Transact(opts, "withdrawFee", _account, _cumulativeFee, _sigs, _signers, _powers)
}
// WithdrawFee is a paid mutator transaction binding the contract method 0x2ff4c411.
//
// Solidity: function withdrawFee(address _account, uint256 _cumulativeFee, bytes[] _sigs, address[] _signers, uint256[] _powers) returns()
func (_IMessageBus *IMessageBusSession) WithdrawFee(_account common.Address, _cumulativeFee *big.Int, _sigs [][]byte, _signers []common.Address, _powers []*big.Int) (*types.Transaction, error) {
return _IMessageBus.Contract.WithdrawFee(&_IMessageBus.TransactOpts, _account, _cumulativeFee, _sigs, _signers, _powers)
}
// WithdrawFee is a paid mutator transaction binding the contract method 0x2ff4c411.
//
// Solidity: function withdrawFee(address _account, uint256 _cumulativeFee, bytes[] _sigs, address[] _signers, uint256[] _powers) returns()
func (_IMessageBus *IMessageBusTransactorSession) WithdrawFee(_account common.Address, _cumulativeFee *big.Int, _sigs [][]byte, _signers []common.Address, _powers []*big.Int) (*types.Transaction, error) {
return _IMessageBus.Contract.WithdrawFee(&_IMessageBus.TransactOpts, _account, _cumulativeFee, _sigs, _signers, _powers)
}
// MsgDataTypesMetaData contains all meta data concerning the MsgDataTypes contract.
var MsgDataTypesMetaData = &bind.MetaData{
ABI: "[]",
Bin: "0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220623342e0418be6ac3b4de01a1763c1d8311a3483683f2a366814784af245669d64736f6c634300080f0033",
}
// MsgDataTypesABI is the input ABI used to generate the binding from.
// Deprecated: Use MsgDataTypesMetaData.ABI instead.
var MsgDataTypesABI = MsgDataTypesMetaData.ABI
// MsgDataTypesBin is the compiled bytecode used for deploying new contracts.
// Deprecated: Use MsgDataTypesMetaData.Bin instead.
var MsgDataTypesBin = MsgDataTypesMetaData.Bin
// DeployMsgDataTypes deploys a new Ethereum contract, binding an instance of MsgDataTypes to it.
func DeployMsgDataTypes(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *MsgDataTypes, error) {
parsed, err := MsgDataTypesMetaData.GetAbi()
if err != nil {
return common.Address{}, nil, nil, err
}
if parsed == nil {
return common.Address{}, nil, nil, errors.New("GetABI returned nil")
}
address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(MsgDataTypesBin), backend)
if err != nil {
return common.Address{}, nil, nil, err
}
return address, tx, &MsgDataTypes{MsgDataTypesCaller: MsgDataTypesCaller{contract: contract}, MsgDataTypesTransactor: MsgDataTypesTransactor{contract: contract}, MsgDataTypesFilterer: MsgDataTypesFilterer{contract: contract}}, nil
}
// MsgDataTypes is an auto generated Go binding around an Ethereum contract.
type MsgDataTypes struct {
MsgDataTypesCaller // Read-only binding to the contract
MsgDataTypesTransactor // Write-only binding to the contract
MsgDataTypesFilterer // Log filterer for contract events
}
// MsgDataTypesCaller is an auto generated read-only Go binding around an Ethereum contract.
type MsgDataTypesCaller struct {
contract *bind.BoundContract // Generic contract wrapper for the low level calls
}
// MsgDataTypesTransactor is an auto generated write-only Go binding around an Ethereum contract.
type MsgDataTypesTransactor struct {
contract *bind.BoundContract // Generic contract wrapper for the low level calls
}
// MsgDataTypesFilterer is an auto generated log filtering Go binding around an Ethereum contract events.
type MsgDataTypesFilterer struct {
contract *bind.BoundContract // Generic contract wrapper for the low level calls
}
// MsgDataTypesSession is an auto generated Go binding around an Ethereum contract,
// with pre-set call and transact options.
type MsgDataTypesSession struct {
Contract *MsgDataTypes // Generic contract binding to set the session for
CallOpts bind.CallOpts // Call options to use throughout this session
TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
}
// MsgDataTypesCallerSession is an auto generated read-only Go binding around an Ethereum contract,
// with pre-set call options.
type MsgDataTypesCallerSession struct {
Contract *MsgDataTypesCaller // Generic contract caller binding to set the session for
CallOpts bind.CallOpts // Call options to use throughout this session
}
// MsgDataTypesTransactorSession is an auto generated write-only Go binding around an Ethereum contract,
// with pre-set transact options.
type MsgDataTypesTransactorSession struct {
Contract *MsgDataTypesTransactor // Generic contract transactor binding to set the session for
TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
}
// MsgDataTypesRaw is an auto generated low-level Go binding around an Ethereum contract.
type MsgDataTypesRaw struct {
Contract *MsgDataTypes // Generic contract binding to access the raw methods on
}
// MsgDataTypesCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.
type MsgDataTypesCallerRaw struct {
Contract *MsgDataTypesCaller // Generic read-only contract binding to access the raw methods on
}
// MsgDataTypesTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.
type MsgDataTypesTransactorRaw struct {
Contract *MsgDataTypesTransactor // Generic write-only contract binding to access the raw methods on
}
// NewMsgDataTypes creates a new instance of MsgDataTypes, bound to a specific deployed contract.
func NewMsgDataTypes(address common.Address, backend bind.ContractBackend) (*MsgDataTypes, error) {
contract, err := bindMsgDataTypes(address, backend, backend, backend)
if err != nil {
return nil, err
}
return &MsgDataTypes{MsgDataTypesCaller: MsgDataTypesCaller{contract: contract}, MsgDataTypesTransactor: MsgDataTypesTransactor{contract: contract}, MsgDataTypesFilterer: MsgDataTypesFilterer{contract: contract}}, nil
}
// NewMsgDataTypesCaller creates a new read-only instance of MsgDataTypes, bound to a specific deployed contract.
func NewMsgDataTypesCaller(address common.Address, caller bind.ContractCaller) (*MsgDataTypesCaller, error) {
contract, err := bindMsgDataTypes(address, caller, nil, nil)
if err != nil {
return nil, err
}
return &MsgDataTypesCaller{contract: contract}, nil
}
// NewMsgDataTypesTransactor creates a new write-only instance of MsgDataTypes, bound to a specific deployed contract.
func NewMsgDataTypesTransactor(address common.Address, transactor bind.ContractTransactor) (*MsgDataTypesTransactor, error) {
contract, err := bindMsgDataTypes(address, nil, transactor, nil)
if err != nil {
return nil, err
}
return &MsgDataTypesTransactor{contract: contract}, nil
}
// NewMsgDataTypesFilterer creates a new log filterer instance of MsgDataTypes, bound to a specific deployed contract.
func NewMsgDataTypesFilterer(address common.Address, filterer bind.ContractFilterer) (*MsgDataTypesFilterer, error) {
contract, err := bindMsgDataTypes(address, nil, nil, filterer)
if err != nil {
return nil, err
}
return &MsgDataTypesFilterer{contract: contract}, nil
}
// bindMsgDataTypes binds a generic wrapper to an already deployed contract.
func bindMsgDataTypes(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) {
parsed, err := abi.JSON(strings.NewReader(MsgDataTypesABI))
if err != nil {
return nil, err
}
return bind.NewBoundContract(address, parsed, caller, transactor, filterer), nil
}
// Call invokes the (constant) contract method with params as input values and
// sets the output to result. The result type might be a single field for simple
// returns, a slice of interfaces for anonymous returns and a struct for named
// returns.
func (_MsgDataTypes *MsgDataTypesRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
return _MsgDataTypes.Contract.MsgDataTypesCaller.contract.Call(opts, result, method, params...)
}
// Transfer initiates a plain transaction to move funds to the contract, calling
// its default method if one is available.
func (_MsgDataTypes *MsgDataTypesRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
return _MsgDataTypes.Contract.MsgDataTypesTransactor.contract.Transfer(opts)
}
// Transact invokes the (paid) contract method with params as input values.
func (_MsgDataTypes *MsgDataTypesRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
return _MsgDataTypes.Contract.MsgDataTypesTransactor.contract.Transact(opts, method, params...)
}
// Call invokes the (constant) contract method with params as input values and
// sets the output to result. The result type might be a single field for simple
// returns, a slice of interfaces for anonymous returns and a struct for named
// returns.
func (_MsgDataTypes *MsgDataTypesCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
return _MsgDataTypes.Contract.contract.Call(opts, result, method, params...)
}
// Transfer initiates a plain transaction to move funds to the contract, calling
// its default method if one is available.
func (_MsgDataTypes *MsgDataTypesTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
return _MsgDataTypes.Contract.contract.Transfer(opts)
}
// Transact invokes the (paid) contract method with params as input values.
func (_MsgDataTypes *MsgDataTypesTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
return _MsgDataTypes.Contract.contract.Transact(opts, method, params...)
}