EmergencyQueue

Git Source

Inherits: IEmergencyQueue

Author: Zeropoint Labs

SPDX-License-Identifier: Apache-2.0

stores withdrawal requests when forms are paused

State Variables

CHAIN_ID

is the chain id

uint64 public immutable CHAIN_ID;

superRegistry

is the address of super registry

ISuperRegistry public immutable superRegistry;

queueCounter

is the count of actions queued

uint256 public queueCounter;

queuedWithdrawal

is the queue of pending actions

mapping(uint256 id => QueuedWithdrawal) public queuedWithdrawal;

Functions

onlySuperform

modifier onlySuperform(uint256 superformId_);

onlyEmergencyAdmin

modifier onlyEmergencyAdmin();

constructor

constructor(address superRegistry_);

Parameters

NameTypeDescription
superRegistry_addressthe superform registry contract

queueWithdrawal

called by paused forms to queue up withdrawals for exit

function queueWithdrawal(
    InitSingleVaultData memory data_,
    address srcSender_
)
    external
    override
    onlySuperform(data_.superformId);

Parameters

NameTypeDescription
data_InitSingleVaultDatais the single vault data passed by the user
srcSender_address

executeQueuedWithdrawal

alled by emergency admin to processed queued withdrawal

function executeQueuedWithdrawal(uint256 id_) public override onlyEmergencyAdmin;

Parameters

NameTypeDescription
id_uint256is the identifier of the queued action

batchExecuteQueuedWithdrawal

function batchExecuteQueuedWithdrawal(uint256[] memory ids_) external override onlyEmergencyAdmin;

queuedWithdrawalStatus

returns the execution status of an id in the emergency queue

function queuedWithdrawalStatus(uint256 id) external view override returns (bool);

Parameters

NameTypeDescription
iduint256is the identifier of the queued action

Returns

NameTypeDescription
<none>boolboolean representing the execution status