Skip to main content

GFI

GFI

Deployment on Ethereum mainnet:

https://etherscan.io/address/0xdab396cCF3d84Cf2D07C4454e10C8A6F5b008D2b

GFI is Goldfinch's governance token.

OWNER_ROLE

bytes32 OWNER_ROLE

MINTER_ROLE

bytes32 MINTER_ROLE

PAUSER_ROLE

bytes32 PAUSER_ROLE

cap

uint256 cap

The maximum number of tokens that can be minted

CapUpdated

event CapUpdated(address who, uint256 cap)

constructor

constructor(address owner, string name, string symbol, uint256 initialCap) public

mint

function mint(address account, uint256 amount) public

create and send tokens to a specified address

this function will fail if the caller attempts to mint over the current cap

setCap

function setCap(uint256 _cap) external

sets the maximum number of tokens that can be minted

the cap must be greater than the current total supply

mintingAmountIsWithinCap

function mintingAmountIsWithinCap(uint256 amount) internal returns (bool)

pause

function pause() external

_Pauses all token transfers.

See {ERC20Pausable} and {Pausable-_pause}.

Requirements:

  • the caller must have the `PAUSERROLE`.

unpause

function unpause() external

_Unpauses all token transfers.

See {ERC20Pausable} and {Pausable-_unpause}.

Requirements:

  • the caller must have the `PAUSERROLE`.

_beforeTokenTransfer

function _beforeTokenTransfer(address from, address to, uint256 amount) internal

onlyOwner

modifier onlyOwner()

onlyMinter

modifier onlyMinter()

onlyPauser

modifier onlyPauser()