Documentation ¶
Index ¶
- Constants
- func InboxEvent(name string) abi.Event
- func UnpackAppendTxBatchInput(tx *types.Transaction) ([]any, error)
- func UnpackBisectExecutionInput(tx *types.Transaction) ([]any, error)
- func UnpackCreateAssertionInput(tx *types.Transaction) (common.Hash, *big.Int, error)
- func UnpackL1OracleInput(tx *types.Transaction) (uint64, uint64, uint64, common.Hash, common.Hash, error)
- type BridgeClient
- func (c *BridgeClient) GetAssertion(ctx context.Context, assertionID *big.Int) (bindings.IRollupAssertion, error)
- func (c *BridgeClient) GetLastConfirmedAssertionID(ctx context.Context) (*big.Int, error)
- func (c *BridgeClient) GetRequiredStakeAmount(ctx context.Context) (*big.Int, error)
- func (c *BridgeClient) GetStaker(ctx context.Context, addr common.Address) (bindings.IRollupStaker, error)
- func (c *BridgeClient) RequireFirstUnresolvedAssertionIsConfirmable(ctx context.Context) error
- type EthTxManager
- type ProtocolConfig
- type TxManager
- func (m *TxManager) AdvanceStake(ctx context.Context, assertionID *big.Int) (*types.Receipt, error)
- func (m *TxManager) AppendTxBatch(ctx context.Context, batch []byte) (*types.Receipt, error)
- func (m *TxManager) ConfirmFirstUnresolvedAssertion(ctx context.Context) (*types.Receipt, error)
- func (m *TxManager) CreateAssertion(ctx context.Context, vmHash common.Hash, blockNum *big.Int) (*types.Receipt, error)
- func (m *TxManager) RejectFirstUnresolvedAssertion(ctx context.Context, stakerAddress common.Address) (*types.Receipt, error)
- func (m *TxManager) Stake(ctx context.Context, stakeAmount *big.Int) (*types.Receipt, error)
Constants ¶
View Source
const ( TxBatchAppendedEventName = "TxBatchAppended" // ISequencerInbox.sol functions AppendTxBatchFnName = "appendTxBatch" // IRollup.sol functions StakeFnName = "stake" AdvanceStakeFnName = "advanceStake" CreateAssertionFnName = "createAssertion" ConfirmFirstUnresolvedAssertionFnName = "confirmFirstUnresolvedAssertion" RejectFirstUnresolvedAssertionFnName = "rejectFirstUnresolvedAssertion" // IRollup.sol errors (TODO: figure out a work-around to hardcoding) NoUnresolvedAssertionErr = "Error: VM Exception while processing transaction: reverted with custom error 'NoUnresolvedAssertion()'" ConfirmationPeriodPendingErr = "Error: VM Exception while processing transaction: reverted with custom error 'ConfirmationPeriodPending()'" // L1Oracle.sol functions SetL1OracleValues = "setL1OracleValues" MethodNumBytes = 4 )
Variables ¶
This section is empty.
Functions ¶
func InboxEvent ¶
func UnpackAppendTxBatchInput ¶
func UnpackAppendTxBatchInput(tx *types.Transaction) ([]any, error)
func UnpackBisectExecutionInput ¶
func UnpackBisectExecutionInput(tx *types.Transaction) ([]any, error)
Types ¶
type BridgeClient ¶
type BridgeClient struct { *bindings.ISequencerInbox *bindings.IRollup }
func NewBridgeClient ¶
func NewBridgeClient(backend bind.ContractBackend, cfg ProtocolConfig) (*BridgeClient, error)
func (*BridgeClient) GetAssertion ¶
func (c *BridgeClient) GetAssertion(ctx context.Context, assertionID *big.Int) (bindings.IRollupAssertion, error)
func (*BridgeClient) GetLastConfirmedAssertionID ¶
func (*BridgeClient) GetRequiredStakeAmount ¶
func (*BridgeClient) GetStaker ¶
func (c *BridgeClient) GetStaker(ctx context.Context, addr common.Address) (bindings.IRollupStaker, error)
func (*BridgeClient) RequireFirstUnresolvedAssertionIsConfirmable ¶
func (c *BridgeClient) RequireFirstUnresolvedAssertionIsConfirmable(ctx context.Context) error
type EthTxManager ¶
type ProtocolConfig ¶
type TxManager ¶
type TxManager struct { EthTxManager // contains filtered or unexported fields }
Adds bridge contract method bindings to EthTxManager.
func NewTxManager ¶
func NewTxManager(txMgr EthTxManager, cfg bridgeConfig) (*TxManager, error)
func (*TxManager) AdvanceStake ¶
func (*TxManager) AppendTxBatch ¶
func (*TxManager) ConfirmFirstUnresolvedAssertion ¶
func (*TxManager) CreateAssertion ¶
func (*TxManager) RejectFirstUnresolvedAssertion ¶
Click to show internal directories.
Click to hide internal directories.