Blockwell

Polybius Token

ERC20

This contract is an ERC20 token.

Name Polybius Token
Symbol PLBT
Decimals 6
Total Supply 3,969,565 PLBT

About link description

Polybius (PLBT) is a cryptocurrency and operates on the Ethereum platform. Polybius has a current supply of 3,969,564.998325 with 0 in circulation. The last known price of Polybius is 3.74782842 USD and is up 12.64 over the last 24 hours. It is currently trading on 5 active market(s) with $1,562.84 traded over the last 24 hours. More information can be found at https://polybius.io/.

Stats

Public Functions 34
Event Types 3
Code Size 20,376 bytes

Events (3) keyboard_arrow_up

Approval Event

Parameters help
from
address help
spender
address help
value
uint256 help

Transfer Event

Parameters help
from
address help
to
address help
value
uint256 help

UpgradeProposal Event

Parameters help
newVersion
address help

UPGRADE_FREEZE_TIME Constant

uint help
3 days

etoken2 Variable

address help

etoken2Symbol Variable

bytes32 help

name Variable

string help

symbol Variable

string help

latestVersion Variable

address help
Internal Variable

pendingVersion Variable

address help
Internal Variable

pendingVersionTimestamp Variable

uint help
Internal Variable

userOptOutVersion Variable

mapping(address => address) help
Internal Variable

Functions Expand All Collapse All

_forwardApprove keyboard_arrow_up

Parameters help

Name Type
_spender
address help
_value
uint help
_sender
address help

Properties

Visibility help public
Mutability help transaction

Modifiers help

onlyImplementationFor checks for the following:
Source Code
function _forwardApprove(
  address _spender,
  uint256 _value,
  address _sender
) onlyImplementationFor(_sender) returns (bool) {
  return etoken2.proxyApprove(_spender, _value, etoken2Symbol, _sender);
}

_forwardTransferFromWithReference keyboard_arrow_up

Parameters help

Name Type
_from
address help
_to
address help
_value
uint help
_reference
string help
_sender
address help

Properties

Visibility help public
Mutability help transaction

Modifiers help

onlyImplementationFor checks for the following:
Source Code
function _forwardTransferFromWithReference(
  address _from,
  address _to,
  uint256 _value,
  string _reference,
  address _sender
) onlyImplementationFor(_sender) returns (bool) {
  return
    etoken2.proxyTransferFromWithReference(
      _from,
      _to,
      _value,
      etoken2Symbol,
      _reference,
      _sender
    );
}

_forwardTransferFromToICAPWithReference keyboard_arrow_up

Parameters help

Name Type
_from
address help
_icap
bytes32 help
_value
uint help
_reference
string help
_sender
address help

Properties

Visibility help public
Mutability help transaction

Modifiers help

onlyImplementationFor checks for the following:
Source Code
function _forwardTransferFromToICAPWithReference(
  address _from,
  bytes32 _icap,
  uint256 _value,
  string _reference,
  address _sender
) onlyImplementationFor(_sender) returns (bool) {
  return
    etoken2.proxyTransferFromToICAPWithReference(
      _from,
      _icap,
      _value,
      _reference,
      _sender
    );
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help constant
Source Code
function totalSupply() constant returns (uint256) {
  return etoken2.totalSupply(etoken2Symbol);
}

Parameters help

Name Type
_owner
address help

Properties

Visibility help public
Mutability help constant
Source Code
function balanceOf(address _owner) constant returns (uint256) {
  return etoken2.balanceOf(_owner, etoken2Symbol);
}

Parameters help

Name Type
_to
address help
_value
uint256 help

Properties

Visibility help public
Mutability help transaction
Source Code
function transfer(address _to, uint256 _value) returns (bool success);

Parameters help

Name Type
_from
address help
_to
address help
_value
uint256 help

Properties

Visibility help public
Mutability help transaction
Source Code
function transferFrom(
  address _from,
  address _to,
  uint256 _value
) returns (bool success);

Parameters help

Name Type
_spender
address help
_value
uint256 help

Properties

Visibility help public
Mutability help transaction
Source Code
function approve(address _spender, uint256 _value) returns (bool success);

Parameters help

Name Type
_from
address help
_spender
address help

Properties

Visibility help public
Mutability help constant
Source Code
function allowance(address _from, address _spender) constant returns (uint256) {
  return etoken2.allowance(_from, _spender, etoken2Symbol);
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help constant
Source Code
function decimals() constant returns (uint8) {
  return etoken2.baseUnit(etoken2Symbol);
}

init keyboard_arrow_up

Parameters help

Name Type
_etoken2
EToken2 help
_symbol
string help
_name
string help

Properties

Visibility help public
Mutability help transaction
Source Code
function init(
  EToken2 _etoken2,
  string _symbol,
  string _name
) returns (bool) {
  if (address(etoken2) != 0x0) {
    return false;
  }
  etoken2 = _etoken2;
  etoken2Symbol = _bytes32(_symbol);
  name = _name;
  symbol = _symbol;
  return true;
}

recoverTokens keyboard_arrow_up

Parameters help

Name Type
_value
uint help

Properties

Visibility help public
Mutability help transaction

Modifiers help

onlyAssetOwner checks for the following:
Source Code
function recoverTokens(uint256 _value) onlyAssetOwner() returns (bool) {
  return this.transferWithReference(msg.sender, _value, "Tokens recovery");
}

Parameters help

Name Type
_to
address help
_value
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
function transfer(address _to, uint256 _value) returns (bool) {
  return transferWithReference(_to, _value, "");
}

transferWithReference keyboard_arrow_up

Parameters help

Name Type
_to
address help
_value
uint help
_reference
string help

Properties

Visibility help public
Mutability help transaction
Source Code
function transferWithReference(
  address _to,
  uint256 _value,
  string _reference
) returns (bool) {
  return
    _getAsset()._performTransferWithReference(
      _to,
      _value,
      _reference,
      msg.sender
    );
}

transferToICAP keyboard_arrow_up

Parameters help

Name Type
_icap
bytes32 help
_value
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
function transferToICAP(bytes32 _icap, uint256 _value) returns (bool) {
  return transferToICAPWithReference(_icap, _value, "");
}

transferToICAPWithReference keyboard_arrow_up

Parameters help

Name Type
_icap
bytes32 help
_value
uint help
_reference
string help

Properties

Visibility help public
Mutability help transaction
Source Code
function transferToICAPWithReference(
  bytes32 _icap,
  uint256 _value,
  string _reference
) returns (bool) {
  return
    _getAsset()._performTransferToICAPWithReference(
      _icap,
      _value,
      _reference,
      msg.sender
    );
}

Parameters help

Name Type
_from
address help
_to
address help
_value
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
function transferFrom(
  address _from,
  address _to,
  uint256 _value
) returns (bool) {
  return transferFromWithReference(_from, _to, _value, "");
}

transferFromWithReference keyboard_arrow_up

Parameters help

Name Type
_from
address help
_to
address help
_value
uint help
_reference
string help

Properties

Visibility help public
Mutability help transaction
Source Code
function transferFromWithReference(
  address _from,
  address _to,
  uint256 _value,
  string _reference
) returns (bool) {
  return
    _getAsset()._performTransferFromWithReference(
      _from,
      _to,
      _value,
      _reference,
      msg.sender
    );
}

transferFromToICAP keyboard_arrow_up

Parameters help

Name Type
_from
address help
_icap
bytes32 help
_value
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
function transferFromToICAP(
  address _from,
  bytes32 _icap,
  uint256 _value
) returns (bool) {
  return transferFromToICAPWithReference(_from, _icap, _value, "");
}

transferFromToICAPWithReference keyboard_arrow_up

Parameters help

Name Type
_from
address help
_icap
bytes32 help
_value
uint help
_reference
string help

Properties

Visibility help public
Mutability help transaction
Source Code
function transferFromToICAPWithReference(
  address _from,
  bytes32 _icap,
  uint256 _value,
  string _reference
) returns (bool) {
  return
    _getAsset()._performTransferFromToICAPWithReference(
      _from,
      _icap,
      _value,
      _reference,
      msg.sender
    );
}

Parameters help

Name Type
_spender
address help
_value
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
function approve(address _spender, uint256 _value) returns (bool) {
  return _getAsset()._performApprove(_spender, _value, msg.sender);
}

emitTransfer keyboard_arrow_up

Parameters help

Name Type
_from
address help
_to
address help
_value
uint help

Properties

Visibility help public
Mutability help transaction

Modifiers help

onlyEToken2 checks for the following:
Source Code
function emitTransfer(
  address _from,
  address _to,
  uint256 _value
) onlyEToken2() {
  Transfer(_from, _to, _value);
}

emitApprove keyboard_arrow_up

Parameters help

Name Type
_from
address help
_spender
address help
_value
uint help

Properties

Visibility help public
Mutability help transaction

Modifiers help

onlyEToken2 checks for the following:
Source Code
function emitApprove(
  address _from,
  address _spender,
  uint256 _value
) onlyEToken2() {
  Approval(_from, _spender, _value);
}

constructor keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help payable
Source Code
function() payable {
  bytes32 result = _getAsset()._performGeneric.value(msg.value)(
    msg.data,
    msg.sender
  );
  assembly {
    mstore(0, result)
    return(0, 32)
  }
}

getVersionFor keyboard_arrow_up

Parameters help

Name Type
_sender
address help

Properties

Visibility help public
Mutability help constant
Source Code
function getVersionFor(address _sender) constant returns (address) {
  return
    userOptOutVersion[_sender] == 0
      ? latestVersion
      : userOptOutVersion[_sender];
}

getLatestVersion keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help constant
Source Code
function getLatestVersion() constant returns (address) {
  return latestVersion;
}

getPendingVersion keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help constant
Source Code
function getPendingVersion() constant returns (address) {
  return pendingVersion;
}

getPendingVersionTimestamp keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help constant
Source Code
function getPendingVersionTimestamp() constant returns (uint256) {
  return pendingVersionTimestamp;
}

proposeUpgrade keyboard_arrow_up

Parameters help

Name Type
_newVersion
address help

Properties

Visibility help public
Mutability help transaction

Modifiers help

onlyAssetOwner checks for the following:
Source Code
function proposeUpgrade(address _newVersion) onlyAssetOwner() returns (bool) {
  // Should not already be in the upgrading process.
  if (pendingVersion != 0x0) {
    return false;
  }
  // New version address should be other than 0x0.
  if (_newVersion == 0x0) {
    return false;
  }
  // Don't apply freeze-time for the initial setup.
  if (latestVersion == 0x0) {
    latestVersion = _newVersion;
    return true;
  }
  pendingVersion = _newVersion;
  pendingVersionTimestamp = now;
  UpgradeProposal(_newVersion);
  return true;
}

purgeUpgrade keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction

Modifiers help

onlyAssetOwner checks for the following:
Source Code
function purgeUpgrade() onlyAssetOwner() returns (bool) {
  if (pendingVersion == 0x0) {
    return false;
  }
  delete pendingVersion;
  delete pendingVersionTimestamp;
  return true;
}

commitUpgrade keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
function commitUpgrade() returns (bool) {
  if (pendingVersion == 0x0) {
    return false;
  }
  if (pendingVersionTimestamp + UPGRADE_FREEZE_TIME > now) {
    return false;
  }
  latestVersion = pendingVersion;
  delete pendingVersion;
  delete pendingVersionTimestamp;
  return true;
}

optOut keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
function optOut() returns (bool) {
  if (userOptOutVersion[msg.sender] != 0x0) {
    return false;
  }
  userOptOutVersion[msg.sender] = latestVersion;
  return true;
}

optIn keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
function optIn() returns (bool) {
  delete userOptOutVersion[msg.sender];
  return true;
}

multiAsset keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help constant
Source Code
function multiAsset() constant returns (EToken2) {
  return etoken2;
}

Internal Functions Expand All Collapse All

Internal functions are parts of the contract that can't be used directly, but instead are used by the public functions listed above.

internal PolybiusToken._getAsset keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help internal
Mutability help transaction
Source Code
function _getAsset() internal returns (Asset) {
  return Asset(getVersionFor(msg.sender));
}

internal Bytes32._bytes32 keyboard_arrow_up

Parameters help

Name Type
_input
string help

Properties

Visibility help internal
Mutability help constant
Source Code
function _bytes32(string _input) internal constant returns (bytes32 result) {
  assembly {
    result := mload(add(_input, 32))
  }
}