StandardGovernorDeployer

Git Source

Inherits: IStandardGovernorDeployer

Author: M^0 Labs

State Variables

registrar

Returns the address of the Registrar.

address public immutable registrar;

vault

Returns the address of the Vault.

address public immutable vault;

zeroGovernor

Returns the address of the Zero Governor.

address public immutable zeroGovernor;

zeroToken

Returns the address of the Zero Token.

address public immutable zeroToken;

lastDeploy

Returns the address of the last contract deployed by this contract.

address public lastDeploy;

nonce

Returns the nonce used to pre deterministically compute the address of the next deployed contract.

uint256 public nonce;

Functions

onlyZeroGovernor

Throws if called by any contract other than the Zero Governor.

modifier onlyZeroGovernor();

constructor

Constructs a new StandardGovernorDeployer contract.

constructor(address zeroGovernor_, address registrar_, address vault_, address zeroToken_);

Parameters

Name
Type
Description

zeroGovernor_

address

The address of the ZeroGovernor contract.

registrar_

address

The address of the Registrar contract.

vault_

address

The address of the Vault contract.

zeroToken_

address

The address of the ZeroToken contract.

deploy

Deploys a new instance of a Standard Governor.

function deploy(
    address powerToken_,
    address emergencyGovernor_,
    address cashToken_,
    uint256 proposalFee_,
    uint256 maxTotalZeroRewardPerActiveEpoch_
) external onlyZeroGovernor returns (address);

Parameters

Name
Type
Description

powerToken_

address

emergencyGovernor_

address

cashToken_

address

proposalFee_

uint256

maxTotalZeroRewardPerActiveEpoch_

uint256

Returns

Name
Type
Description

<none>

address

The address of the deployed Standard Governor.

nextDeploy

Returns the address of the next contract this contract will deploy.

function nextDeploy() external view returns (address);

Copyright 2024 M^0 Foundation