Blockwell

Swipe

ERC20

This contract is an ERC20 token.

Name Swipe
Symbol SXP
Decimals 18
Total Supply 299,754,135 SXP

About link description

Swipe (SXP) is a cryptocurrency and operates on the Ethereum platform. Swipe has a current supply of 289,612,084 with 106,981,302 in circulation. The last known price of Swipe is 1.70770427 USD and is down -1.08 over the last 24 hours. It is currently trading on 99 active market(s) with $107,471,887.10 traded over the last 24 hours. More information can be found at https://swipe.io/.

Stats

Public Functions 16
Event Types 7
Code Size 12,490 bytes

Library Use

Uses SafeMath for uint.

Events (7) keyboard_arrow_up

Approval Event

Parameters help
tokenOwner
address help
spender
address help
tokens
uint help

Freezed Event

Parameters help

LockUser Event

Parameters help
who
address help

OwnershipTransferred Event

Parameters help
_from
address help
_to
address help

Transfer Event

Parameters help
from
address help
to
address help
tokens
uint help

UnFreezed Event

Parameters help

UnlockUser Event

Parameters help
who
address help

symbol Variable

string help

name Variable

string help

decimals Variable

uint8 help

owner Variable

address help

_totalSupply Variable

uint help
Internal Variable

balances Variable

mapping(address => uint) help
Internal Variable

allowed Variable

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

isLocked Variable

uint8 help
Internal Variable

blacklist Variable

mapping(address => bool) help
Internal Variable

Functions Expand All Collapse All

transferOwnership keyboard_arrow_up

Parameters help

Name Type
newOwner
address help

Properties

Visibility help public
Mutability help transaction
Source Code
function transferOwnership(address newOwner) public onlyOwner {
  owner = newOwner;
  emit OwnershipTransferred(owner, newOwner);
}

lockUser keyboard_arrow_up

Parameters help

Name Type
who
address help

Properties

Visibility help public
Mutability help transaction
Source Code
function lockUser(address who) public onlyOwner {
  blacklist[who] = true;

  emit LockUser(who);
}

unlockUser keyboard_arrow_up

Parameters help

Name Type
who
address help

Properties

Visibility help public
Mutability help transaction
Source Code
function unlockUser(address who) public onlyOwner {
  blacklist[who] = false;

  emit UnlockUser(who);
}

freeze keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
function freeze() public onlyOwner {
  isLocked = 1;

  emit Freezed();
}

unfreeze keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
function unfreeze() public onlyOwner {
  isLocked = 0;

  emit UnFreezed();
}

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
function totalSupply() public view returns (uint256) {
  return _totalSupply.sub(balances[address(0)]);
}

Parameters help

Name Type
tokenOwner
address help

Properties

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

Parameters help

Name Type
tokenOwner
address help
spender
address help

Properties

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

Parameters help

Name Type
to
address help
tokens
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
function transfer(address to, uint256 tokens)
  public
  validLock
  permissionCheck
  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;
}

Parameters help

Name Type
spender
address help
tokens
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
function approve(address spender, uint256 tokens)
  public
  validLock
  permissionCheck
  returns (bool success)
{
  allowed[msg.sender][spender] = tokens;

  emit Approval(msg.sender, spender, tokens);

  return true;
}

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,
  uint256 tokens
) public validLock permissionCheck 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;
}

burn keyboard_arrow_up

Parameters help

Name Type
value
uint256 help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
function burn(uint256 value)
  public
  validLock
  permissionCheck
  returns (bool success)
{
  require(msg.sender != address(0), "ERC20: burn from the zero address");

  _totalSupply = _totalSupply.sub(value);
  balances[msg.sender] = balances[msg.sender].sub(value);
  emit Transfer(msg.sender, address(0), value);
  return true;
}

approveAndCall keyboard_arrow_up

Parameters help

Name Type
spender
address help
tokens
uint help
data
bytes help

Properties

Visibility help public
Mutability help transaction
Source Code
function approveAndCall(
  address spender,
  uint256 tokens,
  bytes memory data
) public validLock permissionCheck returns (bool success) {
  allowed[msg.sender][spender] = tokens;

  emit Approval(msg.sender, spender, tokens);

  ApproveAndCallFallBack(spender).receiveApproval(
    msg.sender,
    tokens,
    address(this),
    data
  );

  return true;
}

burnForAllowance keyboard_arrow_up

Parameters help

Name Type
account
address help
feeAccount
address help
amount
uint256 help

Properties

Visibility help public
Mutability help transaction
Source Code
function burnForAllowance(
  address account,
  address feeAccount,
  uint256 amount
) public onlyOwner returns (bool success) {
  require(account != address(0), "burn from the zero address");
  require(balanceOf(account) >= amount, "insufficient balance");

  uint256 feeAmount = amount.mul(2).div(10);
  uint256 burnAmount = amount.sub(feeAmount);

  _totalSupply = _totalSupply.sub(burnAmount);
  balances[account] = balances[account].sub(amount);
  balances[feeAccount] = balances[feeAccount].add(feeAmount);
  emit Transfer(account, address(0), burnAmount);
  emit Transfer(account, msg.sender, feeAmount);
  return true;
}

constructor keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

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

transferAnyERC20Token keyboard_arrow_up

Parameters help

Name Type
tokenAddress
address help
tokens
uint help

Properties

Visibility help public
Mutability help transaction
Source Code
function transferAnyERC20Token(address tokenAddress, uint256 tokens)
  public
  onlyOwner
  returns (bool success)
{
  return ERC20Interface(tokenAddress).transfer(owner, tokens);
}

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.