rollupmanager

package
v0.0.0-...-44e5e6b Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2024 License: AGPL-3.0, AGPL-3.0-or-later Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CreateRollupInfo

type CreateRollupInfo struct {
	Root            common.Hash
	Block           uint64
	BlockHash       common.Hash
	ParentBlockHash common.Hash
	Timestamp       uint64
	ChainID         uint64
	RollupID        uint32
	GasToken        common.Address
}

type RollupManager

type RollupManager struct {
	Client             *ethclient.Client
	Contract           *polygonrollupmanager.Polygonrollupmanager `json:"-"`
	Address            common.Address
	BridgeAddress      common.Address
	GERAddr            common.Address
	POLAddr            common.Address
	CreationBlock      uint64
	UpdateToULxLyBlock uint64
}

func LoadFromFile

func LoadFromFile(client *ethclient.Client, filePath string) (*RollupManager, error)

func LoadFromL1

func LoadFromL1(ctx context.Context, client *ethclient.Client, address common.Address) (*RollupManager, error)

func (*RollupManager) GetAttachedRollups

func (rm *RollupManager) GetAttachedRollups(ctx context.Context) (map[uint64]string, error)

GetAttachedRollups returns a list of attached rollups

func (*RollupManager) GetConsensusDescription

func (rm *RollupManager) GetConsensusDescription(ctx context.Context, rollupID uint32) (string, error)

GetConsensusDescription returns the description of the consensus for a given rollup ID

func (*RollupManager) GetInitializedBlock

func (rm *RollupManager) GetInitializedBlock(ctx context.Context) (uint64, error)

GetInitializedBlock returns the block in which the contract was initialized

func (*RollupManager) GetRollupCreationInfo

func (rm *RollupManager) GetRollupCreationInfo(ctx context.Context, rollupID uint32) (CreateRollupInfo, error)

GetRollupCreation returns genesis root and the block number in which the rollup was created

func (*RollupManager) GetUpgradeBlocks

func (rm *RollupManager) GetUpgradeBlocks(ctx context.Context) (map[uint8]uint64, error)

GetUpgradeBlocks returns a mapping of version => block number of the rollup manager

func (*RollupManager) InitContract

func (rm *RollupManager) InitContract(ctx context.Context, client bind.ContractBackend) error

InitContract initializes the rollup manager contract if not already initialized

Jump to

Keyboard shortcuts

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