47 lines
1.1 KiB
Solidity
47 lines
1.1 KiB
Solidity
pragma solidity ^0.4.24;
|
|
|
|
import "zos-lib/contracts/Initializable.sol";
|
|
import "./IERC20.sol";
|
|
|
|
|
|
/**
|
|
* @title ERC20Detailed token
|
|
* @dev The decimals are only for visualization purposes.
|
|
* All the operations are done using the smallest and indivisible token unit,
|
|
* just as on Ethereum all the operations are done in wei.
|
|
*/
|
|
contract ERC20Detailed is Initializable, IERC20 {
|
|
string private _name;
|
|
string private _symbol;
|
|
uint8 private _decimals;
|
|
|
|
function initialize(string name, string symbol, uint8 decimals) public initializer {
|
|
_name = name;
|
|
_symbol = symbol;
|
|
_decimals = decimals;
|
|
}
|
|
|
|
/**
|
|
* @return the name of the token.
|
|
*/
|
|
function name() public view returns(string) {
|
|
return _name;
|
|
}
|
|
|
|
/**
|
|
* @return the symbol of the token.
|
|
*/
|
|
function symbol() public view returns(string) {
|
|
return _symbol;
|
|
}
|
|
|
|
/**
|
|
* @return the number of decimals of the token.
|
|
*/
|
|
function decimals() public view returns(uint8) {
|
|
return _decimals;
|
|
}
|
|
|
|
uint256[50] private ______gap;
|
|
}
|