rollup

package
v0.0.14 Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2026 License: AGPL-3.0, AGPL-3.0-or-later Imports: 21 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var L2GERManager = common.HexToAddress("0xa40d5f56745a118d0906a34e69aec8c0db1cb8fa")

https://github.com/0xPolygonHermez/zkevm-commonjs/blob/bb0e77e9158a0fc3d06eb5de53b458bb87f77bc7/src/constants.js#L58

Functions

This section is empty.

Types

type RollupMetadata

type RollupMetadata struct {
	Address                 common.Address
	GenesisRoot             common.Hash
	CreationBlock           uint64
	CreationBlockHash       common.Hash
	CreationParentBlockHash common.Hash
	CreationTimestamp       uint64
	ChainID                 uint64
	Name                    string
	RollupID                uint32
	GasToken                common.Address
	VerifierType            rollupmanager.VerifierType
	AggchainType            rollupmanager.AggchainType
}

func LoadMetadataFromFile

func LoadMetadataFromFile(filePath string) (*RollupMetadata, error)

LoadMetadataFromFile reads the rollup metadata from the json file

func LoadMetadataFromL1ByChainID

func LoadMetadataFromL1ByChainID(
	ctx context.Context,
	client *ethclient.Client,
	rm *rollupmanager.RollupManager,
	chainID uint64,
) (*RollupMetadata, error)

LoadMetadataFromL1ByChainID reads the on-chain rollup metadata by the given chain id

func NewRollupMetadata

func NewRollupMetadata(rollupName string, chainID uint64, rollupAddr common.Address,
	aggchainType rollupmanager.AggchainType, rollupInfo rollupmanager.CreateRollupInfo) *RollupMetadata

func (*RollupMetadata) IsPessimistic added in v0.0.12

func (r *RollupMetadata) IsPessimistic() bool

IsPessimistic returns true if the rollup uses pessimistic proofs

type RollupPessimisticProofs

type RollupPessimisticProofs struct {
	*RollupMetadata

	Contract *aggchainecdsamultisig.Aggchainecdsamultisig `json:"-"`
}

func (*RollupPessimisticProofs) GetBatchL2Data

func (r *RollupPessimisticProofs) GetBatchL2Data(client bind.ContractBackend) (string, error)

GetBatchL2Data constructs bridge initialization transaction. The logic is implemented according to the following snippet: https://github.com/0xPolygonHermez/zkevm-contracts/blob/v9.0.0-rc.3-pp/deployment/v2/4_createRollup.ts#L404-L456

func (*RollupPessimisticProofs) GetRollupGlobalExitRoot

func (r *RollupPessimisticProofs) GetRollupGlobalExitRoot(rm *rollupmanager.RollupManager, client bind.ContractBackend) (common.Hash, error)

GetRollupGlobalExitRoot retrieves the actual global exit root at the rollup creation time

func (*RollupPessimisticProofs) InitContract

func (r *RollupPessimisticProofs) InitContract(ctx context.Context, client bind.ContractBackend) error

type RollupValidium

type RollupValidium struct {
	*RollupMetadata

	Contract *polygonvalidiumetrog.Polygonvalidiumetrog `json:"-"`
}

func (*RollupValidium) InitContract

func (r *RollupValidium) InitContract(ctx context.Context, client bind.ContractBackend) error

InitContract initializes the rollup contract if not already initialized

Jump to

Keyboard shortcuts

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