#
MintSettings#
The settings for the initial mint of the token.
Input | Type | Description |
---|---|---|
Notice
The lengths of receivers
and amounts
must match.
struct MintSettings {
address[] receivers;
uint256[] amounts;
}
IERC20MintableUpgradeable#
Interface to allow minting of ERC-20 tokens.
mint#
Mints ERC-20 tokens for a receiving address.
function mint(address _to, uint256 _amount) external
Input | Type | Description |
---|---|---|
_to |
address |
The receiving address. |
_amount |
uint256 |
The amount of tokens. |
DistributableGovernanceERC20#
An OpenZeppelin Votes
compatible ERC-20 token that can be used for voting and is managed by a DAO.
MintSettingsArrayLengthMismatch#
Thrown if the number of receivers and amounts specified in the mint settings do not match.
error MintSettingsArrayLengthMismatch(uint256 receiversArrayLength, uint256 amountsArrayLength)
Input | Type | Description |
---|---|---|
receiversArrayLength |
uint256 |
The length of the receivers array. |
amountsArrayLength |
uint256 |
The length of the amounts array. |
constructor#
Calls the initialize function.
constructor(string _name, string _symbol, struct MintSettings _mintSettings, address _accessManager) public
Input | Type | Description |
---|---|---|
_name |
string |
The name of the ERC-20 governance token. |
_symbol |
string |
The symbol of the ERC-20 governance token. |
_mintSettings |
struct MintSettings |
The token mint settings struct containing the receivers and amounts . |
_accessManager |
address |
initialize#
Initializes the contract and mints tokens to a list of receivers.
function initialize(string _name, string _symbol, struct MintSettings _mintSettings, address accessManager) public
Input | Type | Description |
---|---|---|
_name |
string |
The name of the ERC-20 governance token. |
_symbol |
string |
The symbol of the ERC-20 governance token. |
_mintSettings |
struct MintSettings |
The token mint settings struct containing the receivers and amounts . |
accessManager |
address |
supportsInterface#
Checks if this or the parent contract supports an interface by its ID.
function supportsInterface(bytes4 interfaceId) public view virtual returns (bool)
Input | Type | Description |
---|---|---|
interfaceId |
bytes4 |
The ID of the interface. |
Output | ||
0 |
bool |
Returns true if the interface is supported. |
mint#
Mints tokens to an address.
function mint(address to, uint256 amount) external
Input | Type | Description |
---|---|---|
to |
address |
The address receiving the tokens. |
amount |
uint256 |
The amount of tokens to be minted. |
Notice
Move voting power when tokens are transferred.
Notice
Emits a IVotes-DelegateVotesChanged event.