contract BitcapsHongKongToken is ERC20Interface, Owned {
    using SafeMath for uint;


// ----------------------------------------------------------------------------
// This area is executed once in the initial stage with Constructor.
// ----------------------------------------------------------------------------
    string public constant symbol = "BHKT";
    string public constant name = "Bitcaps Hong Kong Token";
    uint8 public constant decimals = 6;
	
	string public constant features = "Bitcaps Hong Kong Token (BHKT) is a stable cryptocurrency with a value meant to mirror the value of the fiat Hong Kong Dollar (HKD), at 1BHKT:1HKD. BHKT/HKD conversion services are offered by the project's partnering licensed money service operators in Hong Kong.";

	string public constant website = "https://www.bitcaps.com.hk/bhkt";

    uint _totalSupply;
	
    mapping(address => uint) balances;
    mapping(address => mapping(address => uint)) allowed;


// ------------------------------------------------------------------------
// Constructor
// ------------------------------------------------------------------------
    constructor() public {
        _totalSupply = 100000000000 * 10**uint(decimals);
        balances[owner] = _totalSupply;
        emit Transfer(address(0), owner, _totalSupply);
    }


// ------------------------------------------------------------------------
// Total supply
// ------------------------------------------------------------------------
    function totalSupply() public view returns (uint) {
        return _totalSupply.sub(balances[address(0)]);
    }


// ------------------------------------------------------------------------
// Get the token balance for account.
//   @param tokenOwner. The address from which the balance will be retrieved.
//   @return The balance of tokenOwner.
// ------------------------------------------------------------------------
    function balanceOf(address tokenOwner) public view returns (uint balance) {
        return balances[tokenOwner];
    }


// ------------------------------------------------------------------------
// Transfer the balance from token owner's account to `to` account.
//   - Owner's account must have sufficient balance to transfer
//   - 0 value transfers are allowed
// Implements ERC 20 Token standard:https://github.com/ethereum/EIPs/issues/20
// ------------------------------------------------------------------------
    function transfer(address to, uint tokens) public returns (bool success) {
        balances[msg.sender] = balances[msg.sender].sub(tokens);
        balances[to] = balances[to].add(tokens);
        emit Transfer(msg.sender, to, tokens);
        return true;
    }


// ------------------------------------------------------------------------
// Token owner can approve for `spender` to transferFrom `tokens`
// from the token owner's account.
//   @param spender, The address which will spend the funds.
//   @param tokens, The amount of tokens to be spent.
// ------------------------------------------------------------------------
    function approve(address spender, uint tokens) public returns (bool success) {
        allowed[msg.sender][spender] = tokens;
        emit Approval(msg.sender, spender, tokens);
        return true;
    }


// ------------------------------------------------------------------------
// Transfer `tokens` from the `from` account to the `to` account.
// The calling account must already have sufficient tokens approve
// for spending from the `from` account.
//   - From account must have sufficient balance to transfer
//   - Spender must have sufficient allowance to transfer
//   - 0 value transfers are allowed
// ------------------------------------------------------------------------
    function transferFrom(address from, address to, uint tokens) public returns (bool success) {
        balances[from] = balances[from].sub(tokens);
        allowed[from][msg.sender] = allowed[from][msg.sender].sub(tokens);
        balances[to] = balances[to].add(tokens);
        emit Transfer(from, to, tokens);
        return true;
    }


// ------------------------------------------------------------------------
// @dev Function to check the amount of tokens that an owner allowed to a spender.
//   @param tokenOwner. The address which owns the funds.
//   @param spender. The address which will spend the funds.
//   @param remaining, specifying the amount of tokens still available for the spender.
// ------------------------------------------------------------------------
    function allowance(address tokenOwner, address spender) public view returns (uint remaining) {
        return allowed[tokenOwner][spender];
    }

// ------------------------------------------------------------------------
// Don't accept ETH.
// ------------------------------------------------------------------------
    function () external payable {
        revert();
    }

// ------------------------------------------------------------------------
// Owner can transfer out any accidentally sent ERC20 tokens
// ------------------------------------------------------------------------
    function transferAnyERC20Token(address tokenAddress, uint tokens) public onlyOwner returns (bool success) {
        return ERC20Interface(tokenAddress).transfer(owner, tokens);
    }

}
// ----------------------------------------------------------------------------
// Basic version of ERC20 Standard
// @dev see https://github.com/ethereum/EIPs/issues/20
// ----------------------------------------------------------------------------
function allowance(address tokenOwner, address spender) public view returns (uint remaining) {
        return allowed[tokenOwner][spender];
    }
// ------------------------------------------------------------------------
// @dev Function to check the amount of tokens that an owner allowed to a spender.
//   @param tokenOwner. The address which owns the funds.
//   @param spender. The address which will spend the funds.
//   @param remaining, specifying the amount of tokens still available for the spender.
// ------------------------------------------------------------------------