MachineShare
Inherits: ERC20, Ownable2Step, IMachineShare
Functions
constructor
constructor(string memory _name, string memory _symbol, address _initialMinter)
ERC20(_name, _symbol)
Ownable(_initialMinter);Parameters
| Name | Type | Description |
|---|---|---|
| _name | string | |
| _symbol | string | |
| _initialMinter | address |
decimals
Returns the decimals places of the token.
function decimals() public pure override(ERC20, IERC20Metadata) returns (uint8);Returns
| Name | Type | Description |
|---|---|---|
| <none> | uint8 |
minter
Address of the authorized minter and burner.
function minter() external view override returns (address);Returns
| Name | Type | Description |
|---|---|---|
| <none> | address |
mint
Mints new shares to the specified address.
function mint(address to, uint256 amount) external override onlyOwner;Parameters
| Name | Type | Description |
|---|---|---|
| to | address | The recipient of the minted shares. |
| amount | uint256 | The amount of shares to mint. |
burn
Burns shares from the specified address.
function burn(address from, uint256 amount) external override;Parameters
| Name | Type | Description |
|---|---|---|
| from | address | The owner of the shares to burn. |
| amount | uint256 | The amount of shares to burn. |