Blockwell

yearn.finance

ERC20

This contract is an ERC20 token.

Name yearn.finance
Symbol YFI
Decimals 18
Total Supply 30,000 YFI

About link

yearn.finance (YFI) is a cryptocurrency token and operates on the Ethereum platform. yearn.finance has a current supply of 30,000 with 29,967.67 in circulation. The last known price of yearn.finance is $24,636.25 USD and is up 0.21% over the last 24 hours. It is currently trading on 181 active market(s) with $541,271,704.615 traded over the last 24 hours. More information can be found at https://yearn.finance/.

Stats

Public Functions 15
Event Types 2
Code Size 8,522 bytes

Library Use

Uses SafeERC20 for IERC20.
Uses Address for address.
Uses SafeMath for uint.

Approval Event

Parameters help
owner
address help
spender
address help
value
uint help

Transfer Event

Parameters help
from
address help
to
address help
value
uint help

Functions Expand All Collapse All

name keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
    function name() public view returns (string memory) {
        return _name;
    }

symbol keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
    function symbol() public view returns (string memory) {
        return _symbol;
    }

decimals keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
    function decimals() public view returns (uint8) {
        return _decimals;
    }

totalSupply keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
    function totalSupply() public view returns (uint) {
        return _totalSupply;
    }

balanceOf keyboard_arrow_up

Parameters help

Name Type
account
address help

Properties

Visibility help public
Mutability help view
Source Code
    function balanceOf(address account) public view returns (uint) {
        return _balances[account];
    }

transfer keyboard_arrow_up

Parameters help

Name Type
recipient
address help
amount
uint help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
    function transfer(address recipient, uint amount) public returns (bool) {
        _transfer(_msgSender(), recipient, amount);
        return true;
    }

allowance keyboard_arrow_up

Parameters help

Name Type
owner
address help
spender
address help

Properties

Visibility help public
Mutability help view
Source Code
    function allowance(address owner, address spender) public view returns (uint) {
        return _allowances[owner][spender];
    }

approve keyboard_arrow_up

Parameters help

Name Type
spender
address help
amount
uint help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
    function approve(address spender, uint amount) public returns (bool) {
        _approve(_msgSender(), spender, amount);
        return true;
    }

transferFrom keyboard_arrow_up

Parameters help

Name Type
sender
address help
recipient
address help
amount
uint help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
    function transferFrom(address sender, address recipient, uint amount) public returns (bool) {
        _transfer(sender, recipient, amount);
        _approve(sender, _msgSender(), _allowances[sender][_msgSender()].sub(amount, "ERC20: transfer amount exceeds allowance"));
        return true;
    }

increaseAllowance keyboard_arrow_up

Parameters help

Name Type
spender
address help
addedValue
uint help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
    function increaseAllowance(address spender, uint addedValue) public returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender].add(addedValue));
        return true;
    }

decreaseAllowance keyboard_arrow_up

Parameters help

Name Type
spender
address help
subtractedValue
uint help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
    function decreaseAllowance(address spender, uint subtractedValue) public returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender].sub(subtractedValue, "ERC20: decreased allowance below zero"));
        return true;
    }

mint keyboard_arrow_up

Parameters help

Name Type
account
address help
amount
uint help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
  function mint(address account, uint amount) public {
      require(minters[msg.sender], "!minter");
      _mint(account, amount);
  }

setGovernance keyboard_arrow_up

Parameters help

Name Type
_governance
address help

Properties

Visibility help public
Mutability help transaction
Source Code
  function setGovernance(address _governance) public {
      require(msg.sender == governance, "!governance");
      governance = _governance;
  }

addMinter keyboard_arrow_up

Parameters help

Name Type
_minter
address help

Properties

Visibility help public
Mutability help transaction
Source Code
  function addMinter(address _minter) public {
      require(msg.sender == governance, "!governance");
      minters[_minter] = true;
  }

removeMinter keyboard_arrow_up

Parameters help

Name Type
_minter
address help

Properties

Visibility help public
Mutability help transaction
Source Code
  function removeMinter(address _minter) public {
      require(msg.sender == governance, "!governance");
      minters[_minter] = false;
  }