GeneralDepartment

Git Source

Inherits: Department

Author: Daniel Yamagata & Naveen Ailawadi

A simple department which solely inherits the base functionality

Functions

constructor

constructor(address _mezzHub, address _mezzMigrator) Department(_mezzHub, _mezzMigrator);

init

Standardized init function that all departments must inherit

function init(
    address initTreasury,
    address[] memory _owners,
    uint256 _threshhold,
    address initGuard,
    address initParent,
    bytes memory params
) external virtual override initializer;

Parameters

__GeneralDepartment_init

Sets the 'departmentName' and calls the department's internal init function. The 'name' of the contract will be the concatenation of the company name, the department name, and " Department". For example, if the company name is "Foo" and 'departmentName' is "Bar", the contract name will be "Foo Bar Department".

function __GeneralDepartment_init(
    address initTreasury,
    address[] memory _owners,
    uint256 _threshhold,
    address initGuard,
    address initParent,
    bytes memory params
) internal virtual onlyInitializing;

coreId

Returns the coreId of the implementation as a bytes32

The core ID is the keccak256 hash of the contract name followed by a version under the following syntax: "mezzanine.coreId.ContractName.vX" For example, the core ID of the 2nd version of the Treasury would be the following: keccak256(abi.encodePacked("mezzanine.coreId.Treasury.v2"))

function coreId() public pure virtual override(Credentialed, ICredentialed) returns (bytes32);

version

Returns the version of the implementation as a uint256

function version() public pure virtual override(Credentialed, ICredentialed) returns (uint256);

Last updated