forked from taikoxyz/taiko-mono
-
Notifications
You must be signed in to change notification settings - Fork 0
/
bridge.go
22 lines (19 loc) · 821 Bytes
/
bridge.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
package relayer
import (
"math/big"
"github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/ethereum/go-ethereum/core/types"
"github.com/ethereum/go-ethereum/event"
"github.com/taikoxyz/taiko-mono/packages/relayer/contracts/bridge"
)
type Bridge interface {
WatchMessageSent(
opts *bind.WatchOpts,
sink chan<- *bridge.BridgeMessageSent,
msgHash [][32]byte,
) (event.Subscription, error)
FilterMessageSent(opts *bind.FilterOpts, msgHash [][32]byte) (*bridge.BridgeMessageSentIterator, error)
GetMessageStatus(opts *bind.CallOpts, msgHash [32]byte) (uint8, error)
ProcessMessage(opts *bind.TransactOpts, message bridge.IBridgeMessage, proof []byte) (*types.Transaction, error)
IsMessageReceived(opts *bind.CallOpts, msgHash [32]byte, srcChainId *big.Int, proof []byte) (bool, error) // nolint
}