Staking Allowance

SDL is a staking allowance token which enables stakers to earn a percentage of protocol rewards and grants stakers the right to priority staking access over non SDL holders.

ERC20 Functions

All standard ERC20 functions are implemented for StakingAllowance

Write Functions

mint

Mints tokens to an account

function mint(address _account, uint256 _amount) public

Parameters

NameTypeDescription

_account

address

Address to mint to

_amount

uint256

Amount of tokens to mint

mintToContract

Mints tokens to a contract on behalf of an account via ERC677

function mintToContract(address _contract, address _account, uint256 _amount, bytes _calldata) public

Parameters

NameTypeDescription

_contract

address

Address of contract to send tokens to

_account

address

Address to mint to

_amount

uint256

Amount of tokens to mint

_calldata

bytes

burn

Burns tokens from the sender

function burn(uint256 _amount) public

Parameters

NameTypeDescription

_amount

uint256

Amount of tokens to burn

burnFrom

Burns _amount tokens from _account, deducting from the sender's allowance

function burnFrom(address account, uint256 amount) public

Parameters

NameTypeDescription

_account

address

Address to burn from

_amount

uint256

Amount of tokens to burn

transferAndCall

Transfers tokens to an address and calls onTokenTransfer with additional data if the recipient is a contract

function transferAndCall(address _to, uint256 _value, bytes _data) external returns (bool)

Parameters

NameTypeDescription

_to

address

Address to send the tokens to

_value

uint256

Value of token transfer

_data

bytes

Calldata included in the transfer

transferAndCallWithSender

Similar to transferAndCall but allows the caller to specify a custom sender (used to mint allowance on behalf of an address and send to a contract fallback)

function transferAndCallWithSender(address _sender, address _to, uint256 _value, bytes _data) private returns (bool)

Parameters

NameTypeDescription

_sender

address

Specified sender of the tokens, the party who 'receives' them into a contract

_to

address

Contract address to send the tokens to

_value

uint256

Value of token transfer

_data

bytes

Calldata included in the transfer

Last updated