This repository has been archived by the owner. It is now read-only.
Find file Copy path
7db34f7 Jan 31, 2017
2 contributors

Users who have contributed to this file

@maraoz @izqui
55 lines (40 sloc) 1.38 KB
pragma solidity ^0.4.6;
import './ERC20Lib.sol';
* Standard ERC20 token
* Based on code by FirstBlood:
contract StandardToken {
using ERC20Lib for ERC20Lib.TokenStorage;
ERC20Lib.TokenStorage token;
string public name = "SimpleToken";
string public symbol = "SIM";
uint public decimals = 18;
uint public INITIAL_SUPPLY = 10000;
function StandardToken() {
function totalSupply() constant returns (uint) {
return token.totalSupply;
function balanceOf(address who) constant returns (uint) {
return token.balanceOf(who);
function allowance(address owner, address spender) constant returns (uint) {
return token.allowance(owner, spender);
function transfer(address to, uint value) returns (bool ok) {
return token.transfer(to, value);
function transferFrom(address from, address to, uint value) returns (bool ok) {
return token.transferFrom(from, to, value);
function approve(address spender, uint value) returns (bool ok) {
return token.approve(spender, value);
event Transfer(address indexed from, address indexed to, uint value);
event Approval(address indexed owner, address indexed spender, uint value);