Blockwell

dKargo

ERC20

This contract is an ERC20 token.

Name dKargo
Symbol DKA
Decimals 18
Total Supply 5,000,000,000 DKA

About link

dKargo (DKA) is a cryptocurrency and operates on the Ethereum platform. dKargo has a current supply of 5,000,000,000 with 1,116,241,666 in circulation. The last known price of dKargo is 0.09094162 USD and is down -6.43 over the last 24 hours. It is currently trading on 11 active market(s) with $12,699,101.08 traded over the last 24 hours. More information can be found at https://dkargo.io/main_en.html.

Stats

Public Functions 23
Event Types 5
Code Size 24,923 bytes

Events (5) keyboard_arrow_up

AddressChainLinked Event

Parameters help
node
address help

AddressChainUnlinked Event

Parameters help
node
address help

Approval Event

Parameters help
owner
address help
spender
address help
value
uint256 help

OwnershipTransferred Event

Parameters help
old
address help
expected
address help

Transfer Event

Parameters help
from
address help
to
address help
value
uint256 help

_name Variable

string help
Internal Variable

_symbol Variable

string help
Internal Variable

_owner Variable

address help
Internal Variable

_supply Variable

uint256 help
Internal Variable

_balances Variable

mapping(address => uint256) help
Internal Variable

_allowances Variable

mapping(address => mapping(address => uint256)) help
Internal Variable

_slist Variable

NodeList help
Internal Variable

_infcs Variable

mapping(bytes4 => bool) help
Internal Variable

_dkargoPrefix Variable

string help
Internal Variable

Functions Expand All Collapse All

getDkargoPrefix keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function getDkargoPrefix() public view returns (string memory) {
  return _dkargoPrefix;
}

supportsInterface keyboard_arrow_up

Parameters help

Name Type
infcid
bytes4 help

Properties

Visibility help public
Mutability help view
Source Code
function supportsInterface(bytes4 infcid) external view returns (bool) {
  return _infcs[infcid];
}

count keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function count() public view returns (uint256) {
  return _slist.count;
}

head keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function head() public view returns (address) {
  return _slist.head;
}

tail keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function tail() public view returns (address) {
  return _slist.tail;
}

nextOf keyboard_arrow_up

Parameters help

Name Type
node
address help

Properties

Visibility help public
Mutability help view
Source Code
function nextOf(address node) public view returns (address) {
  return _slist.map[node].next;
}

prevOf keyboard_arrow_up

Parameters help

Name Type
node
address help

Properties

Visibility help public
Mutability help view
Source Code
function prevOf(address node) public view returns (address) {
  return _slist.map[node].prev;
}

isLinked keyboard_arrow_up

Parameters help

Name Type
node
address help

Properties

Visibility help public
Mutability help view
Source Code
function isLinked(address node) public view returns (bool) {
  if (_slist.count == 1 && _slist.head == node && _slist.tail == node) {
    return true;
  } else {
    return
      (_slist.map[node].prev == address(0) &&
        _slist.map[node].next == address(0))
        ? (false)
        : (true);
  }
}

Parameters help

Name Type
spender
address help
amount
uint256 help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
function approve(address spender, uint256 amount) public returns (bool) {
  require(
    (amount == 0) || (allowance(msg.sender, spender) == 0),
    "ERC20Safe: approve from non-zero to non-zero allowance"
  );
  return super.approve(spender, amount);
}

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) public returns (bool) {
  bool ret = super.transfer(to, value);
  if (isLinked(msg.sender) && balanceOf(msg.sender) == 0) {
    _unlinkChain(msg.sender);
  }
  if (!isLinked(to) && balanceOf(to) > 0) {
    _linkChain(to);
  }
  return ret;
}

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
) public returns (bool) {
  bool ret = super.transferFrom(from, to, value);
  if (isLinked(from) && balanceOf(from) == 0) {
    _unlinkChain(from);
  }
  if (!isLinked(to) && balanceOf(to) > 0) {
    _linkChain(to);
  }
  return ret;
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function totalSupply() public view returns (uint256) {
  return _supply;
}

Parameters help

Name Type
account
address help

Properties

Visibility help public
Mutability help view
Source Code
function balanceOf(address account) public view returns (uint256) {
  return _balances[account];
}

Parameters help

Name Type
approver
address help
spender
address help

Properties

Visibility help public
Mutability help view
Source Code
function allowance(address approver, address spender)
  public
  view
  returns (uint256)
{
  return _allowances[approver][spender];
}

Parameters help

Name Type
spender
address help
addedValue
uint256 help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
function increaseAllowance(address spender, uint256 addedValue)
  public
  returns (bool)
{
  uint256 amount = allowance(msg.sender, spender).add(addedValue);
  return super.approve(spender, amount);
}

Parameters help

Name Type
spender
address help
subtractedValue
uint256 help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
function decreaseAllowance(address spender, uint256 subtractedValue)
  public
  returns (bool)
{
  uint256 amount = allowance(msg.sender, spender).sub(
    subtractedValue,
    "ERC20: decreased allowance below zero"
  );
  return super.approve(spender, amount);
}

transferOwnership keyboard_arrow_up

Parameters help

Name Type
expected
address help

Properties

Visibility help public
Mutability help transaction

Modifiers help

onlyOwner checks for the following:

Requirements help

Source Code
function transferOwnership(address expected) public onlyOwner {
  require(expected != address(0), "Ownership: new owner is the zero address");
  emit OwnershipTransferred(_owner, expected);
  _owner = expected;
}

owner keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function owner() public view returns (address) {
  return _owner;
}

isOwner keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function isOwner() public view returns (bool) {
  return msg.sender == _owner;
}

burn keyboard_arrow_up

Parameters help

Name Type
amount
uint256 help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
function burn(uint256 amount) external {
  _burn(msg.sender, amount);
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function name() public view returns (string memory) {
  return _name;
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function symbol() public view returns (string memory) {
  return _symbol;
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help pure
Source Code
function decimals() public pure returns (uint256) {
  return 18;
}

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 Ownership.constructor keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help internal
Mutability help transaction
Source Code
constructor() internal {
  emit OwnershipTransferred(_owner, msg.sender);
  _owner = msg.sender;
}

internal ERC20.constructor keyboard_arrow_up

Parameters help

Name Type
supply
uint256 help

Properties

Visibility help internal
Mutability help transaction

Requirements help

Source Code
constructor(uint256 supply) internal {
  uint256 pebs = supply;
  _mint(msg.sender, pebs);
}

internal ERC20._approve keyboard_arrow_up

Parameters help

Name Type
approver
address help
spender
address help
value
uint256 help

Properties

Visibility help internal
Mutability help transaction

Requirements help

Source Code
function _approve(
  address approver,
  address spender,
  uint256 value
) internal {
  require(approver != address(0), "ERC20: approve from the zero address");
  require(spender != address(0), "ERC20: approve to the zero address");
  _allowances[approver][spender] = value;
  emit Approval(approver, spender, value);
}

internal ERC20._transfer keyboard_arrow_up

Parameters help

Name Type
sender
address help
recipient
address help
amount
uint256 help

Properties

Visibility help internal
Mutability help transaction

Requirements help

Source Code
function _transfer(
  address sender,
  address recipient,
  uint256 amount
) internal {
  require(sender != address(0), "ERC20: transfer from the zero address");
  require(recipient != address(0), "ERC20: transfer to the zero address");
  _balances[sender] = _balances[sender].sub(
    amount,
    "ERC20: transfer amount exceeds balance"
  );
  _balances[recipient] = _balances[recipient].add(amount);
  emit Transfer(sender, recipient, amount);
}

internal ERC20._mint keyboard_arrow_up

Parameters help

Name Type
account
address help
amount
uint256 help

Properties

Visibility help internal
Mutability help transaction

Requirements help

Source Code
function _mint(address account, uint256 amount) internal {
  require(account != address(0), "ERC20: mint to the zero address");
  _supply = _supply.add(amount);
  _balances[account] = _balances[account].add(amount);
  emit Transfer(address(0), account, amount);
}

internal ERC20._burn keyboard_arrow_up

Parameters help

Name Type
account
address help
value
uint256 help

Properties

Visibility help internal
Mutability help transaction

Requirements help

Source Code
function _burn(address account, uint256 value) internal {
  require(account != address(0), "ERC20: burn from the zero address");
  _balances[account] = _balances[account].sub(
    value,
    "ERC20: burn amount exceeds balance"
  );
  _supply = _supply.sub(value);
  emit Transfer(account, address(0), value);
}

internal AddressChain._linkChain keyboard_arrow_up

Parameters help

Name Type
node
address help

Properties

Visibility help internal
Mutability help transaction
Source Code
function _linkChain(address node) internal {
  require(node != address(0), "AddressChain: try to link to the zero address");
  require(!isLinked(node), "AddressChain: the node is aleady linked");
  if (_slist.count == 0) {
    _slist.head = _slist.tail = node;
  } else {
    _slist.map[node].prev = _slist.tail;
    _slist.map[_slist.tail].next = node;
    _slist.tail = node;
  }
  _slist.count = _slist.count.add(1);
  emit AddressChainLinked(node);
}

internal AddressChain._unlinkChain keyboard_arrow_up

Parameters help

Name Type
node
address help

Properties

Visibility help internal
Mutability help transaction

Requirements help

Source Code
function _unlinkChain(address node) internal {
  require(
    node != address(0),
    "AddressChain: try to unlink to the zero address"
  );
  require(isLinked(node), "AddressChain: the node is aleady unlinked");
  address tempPrev = _slist.map[node].prev;
  address tempNext = _slist.map[node].next;
  if (_slist.head == node) {
    _slist.head = tempNext;
  }
  if (_slist.tail == node) {
    _slist.tail = tempPrev;
  }
  if (tempPrev != address(0)) {
    _slist.map[tempPrev].next = tempNext;
    _slist.map[node].prev = address(0);
  }
  if (tempNext != address(0)) {
    _slist.map[tempNext].prev = tempPrev;
    _slist.map[node].next = address(0);
  }
  _slist.count = _slist.count.sub(1);
  emit AddressChainUnlinked(node);
}

internal ERC165.constructor keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help internal
Mutability help transaction

Requirements help

0x01ffc9a7 must not be equal to 0xffffffff
Source Code
constructor() internal {
  _registerInterface(0x01ffc9a7); // supportsInterface()의 INTERFACE ID 등록
}

internal ERC165._registerInterface keyboard_arrow_up

Parameters help

Name Type
infcid
bytes4 help

Properties

Visibility help internal
Mutability help transaction

Requirements help

0x01ffc9a7 must not be equal to 0xffffffff
Source Code
function _registerInterface(bytes4 infcid) internal {
  require(infcid != 0xffffffff, "ERC165: invalid interface id");
  _infcs[infcid] = true;
}

internal DkargoPrefix._setDkargoPrefix keyboard_arrow_up

Parameters help

Name Type
prefix
string help

Properties

Visibility help internal
Mutability help transaction
Source Code
function _setDkargoPrefix(string memory prefix) internal {
  _dkargoPrefix = prefix;
}