Blockwell

TE-FOOD

ERC20

This contract is an ERC20 token.

Name TE-FOOD
Symbol TFD
Decimals 18
Total Supply 567,917,833 TFD

About link description

TE-FOOD is a blockchain based farm-to-table food traceability solution. Its mission is to provide transparency in the food industry. TE-FOOD aims to enable customers to improve consumer trust and brand exposure, gain deeper supply chain insight to improve their operational efficiency, comply with export regulations, protect their brands against counterfeiting, and perform quicker product recalls. As an end-to-end solution, TE-FOOD offers many components for the complete supply chain to identify tracked items and batches, capture the data, store it on blockchain, process the data, and present it to the consumers. Launched in 2016, TE-FOOD reportedly serves over 6,000 business customers, and performs 400,000 business operations each day. The team claims food products tracked with TE-FOOD are available for more than 150 million consumers around the world. TE-FOOD's blockchain (the FoodChain) is a public permissioned blockchain, which enables both supply chain participants and the consumer community to maintain masternodes to decentralize traceability information. TFD is an ERC20 token and operates on the Ethereum platform which represents a tokenized software licence, enabling users of TE-FOOD's ecosystem to perform their activities. All individuals and organizations need to possess a certain number of TFD licence tokens to use TE-FOOD's ecosystem.

Stats

Public Functions 16
Event Types 4
Code Size 6,997 bytes

Approval Event

Parameters help
tokenOwner
address help
spender
address help
tokens
uint help

OwnershipTransferred Event

Parameters help
previousOwner
address help
newOwner
address help

Transfer Event

Parameters help
from
address help
to
address help
tokens
uint help

VestedTokensReleased Event

Parameters help
to
address help
amount
uint help

Functions Expand All Collapse All

approve keyboard_arrow_up

Parameters help

Name Type
_spender
address help
_value
uint256 help
_data
bytes help

Properties

Visibility help public
Mutability help transaction
Source Code
  function approve(address _spender, uint256 _value, bytes _data) public returns (bool) {
    super.approve(_spender, _value);
    require(_spender.call(_data));
    return true;
  }

transfer keyboard_arrow_up

Parameters help

Name Type
_to
address help
_value
uint256 help
_data
bytes help

Properties

Visibility help public
Mutability help transaction
Source Code
  function transfer(address _to, uint256 _value, bytes _data) public returns (bool) {
    super.transfer(_to, _value);
    require(_to.call(_data));
    return true;
  }

transferFrom keyboard_arrow_up

Parameters help

Name Type
_from
address help
_to
address help
_value
uint256 help
_data
bytes help

Properties

Visibility help public
Mutability help transaction
Source Code
  function transferFrom(address _from, address _to, uint256 _value, bytes _data) public returns (bool) {
    super.transferFrom(_from, _to, _value);
    require(_to.call(_data));
    return true;
  }

totalSupply keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

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

balanceOf keyboard_arrow_up

Parameters help

Name Type
tokenOwner
address help

Properties

Visibility help public
Mutability help constant
Source Code
  function balanceOf(address tokenOwner) public constant returns (uint balance) {
    return balances[tokenOwner];
  }

allowance keyboard_arrow_up

Parameters help

Name Type
tokenOwner
address help
spender
address help

Properties

Visibility help public
Mutability help constant
Source Code
  function allowance(address tokenOwner, address spender) public constant returns (uint remaining) {
    return allowed[tokenOwner][spender];
  }

transfer keyboard_arrow_up

Parameters help

Name Type
to
address help
tokens
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
  function transfer(address to, uint tokens) public returns (bool success) {
    require (now >= transferrableTime);
    require (to != address(this));
    require (balances[msg.sender] >= tokens);
    balances[msg.sender] = balances[msg.sender].sub(tokens);
    balances[to] = balances[to].add(tokens);
    Transfer(msg.sender, to, tokens);
    return true;
  }

approve keyboard_arrow_up

Parameters help

Name Type
spender
address help
tokens
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
  function approve(address spender, uint tokens) public returns (bool success) {
    require (now >= transferrableTime);
    require (spender != address(this));
    allowed[msg.sender][spender] = tokens;
    Approval(msg.sender, spender, tokens);
    return true;
  }

transferFrom keyboard_arrow_up

Parameters help

Name Type
from
address help
to
address help
tokens
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
  function transferFrom(address from, address to, uint tokens) public returns (bool success) {
    require (now >= transferrableTime);
    require (to != address(this));
    require (allowed[from][msg.sender] >= tokens);
    balances[from] = balances[from].sub(tokens);
    allowed[from][msg.sender] = allowed[from][msg.sender].sub(tokens);
    balances[to] = balances[to].add(tokens);
    Transfer(from, to, tokens);
    return true;
  }

transferOwnership keyboard_arrow_up

Parameters help

Name Type
newOwner
address help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
  function transferOwnership(address newOwner) public onlyOwner {
    require(newOwner != address(0));
    OwnershipTransferred(owner, newOwner);
    owner = newOwner;
  }

allocateTokens keyboard_arrow_up

Parameters help

Name Type
addr
address help
amount
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
  function allocateTokens (address addr, uint amount) public onlyOwner returns (bool) {
    require (addr != 0x00);
    require (amount > 0);
    balances[0x00] = balances[0x00].sub(amount);
    balances[addr] = balances[addr].add(amount);
    _circulatingSupply = _circulatingSupply.add(amount);
    assert (_vestedSupply.add(_circulatingSupply).add(balances[0x00]) == _totalSupply);
    Transfer(0x00, addr, amount);
    return true;
  }

allocateVestedTokens keyboard_arrow_up

Parameters help

Name Type
addr
address help
amount
uint help
vestingPeriod
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
  function allocateVestedTokens (address addr, uint amount, uint vestingPeriod) public onlyOwner returns (bool) {
    require (addr != 0x00);
    require (amount > 0);
    require (vestingPeriod > 0);
    balances[0x00] = balances[0x00].sub(amount);
    vestingMap[vestingPeriod].push( vestedBalance (addr,amount) );
    _vestedSupply = _vestedSupply.add(amount);
    assert (_vestedSupply.add(_circulatingSupply).add(balances[0x00]) == _totalSupply);
    return true;
  }

releaseVestedTokens keyboard_arrow_up

Parameters help

Name Type
vestingPeriod
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
  function releaseVestedTokens (uint vestingPeriod) public {
    require (now >= transferrableTime.add(vestingPeriod));
    require (vestingMap[vestingPeriod].length > 0);
    require (vestingMap[vestingPeriod][0].balance > 0);
    var v = vestingMap[vestingPeriod];
    for (uint8 i = 0; i < v.length; i++) {
      balances[v[i].addr] = balances[v[i].addr].add(v[i].balance);
      _circulatingSupply = _circulatingSupply.add(v[i].balance);
      _vestedSupply = _vestedSupply.sub(v[i].balance);
      VestedTokensReleased(v[i].addr, v[i].balance);
      Transfer(0x00, v[i].addr, v[i].balance);
      v[i].balance = 0;
    }
  }

enableTransfers keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
  function enableTransfers () public onlyOwner returns (bool) {
    transferrableTime = now.add(86400);
    owner = 0x00;
    return true;
  }

constructor keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help payable
Source Code
  function () public payable {
    revert();
  }

vestedBalanceOf keyboard_arrow_up

Parameters help

Name Type
tokenOwner
address help
vestingPeriod
uint help

Properties

Visibility help public
Mutability help constant
Source Code
  function vestedBalanceOf(address tokenOwner, uint vestingPeriod) public constant returns (uint balance) {
    var v = vestingMap[vestingPeriod];
    for (uint8 i = 0; i < v.length; i++) {
      if (v[i].addr == tokenOwner) return v[i].balance;
    }
    return 0;
  }