Blockwell

CosmoCoin

ERC20

This contract is an ERC20 token.

Name CosmoCoin
Symbol COSM
Decimals 18
Total Supply 1,098,000,000 COSM

About link

Cosmo Coin (COSM) is a cryptocurrency token and operates on the Ethereum platform. Cosmo Coin has a current supply of 923,000,000 with 670,780,888.574 in circulation. The last known price of Cosmo Coin is $0.000846 USD and is up 5.68% over the last 24 hours. It is currently trading on 6 active market(s) with $365.26 traded over the last 24 hours. More information can be found at https://cosmochain.io/.

Stats

Public Functions 20
Event Types 11
Code Size 8,757 bytes

AddBlackListAddress Event

Parameters help
_address
address help

AddWhiteListAddress Event

Parameters help
_address
address help

Approval Event

Parameters help
owner
address help
spender
address help
value
uint256 help

Burn Event

Parameters help
from
address help
at
address help
value
uint256 help

Mint Event

Parameters help
to
address help
value
uint256 help

OwnershipTransferred Event

Parameters help
previousOwner
address help
newOwner
address help

Pause Event

Parameters help

RemoveBlackListAddress Event

Parameters help
_address
address help

RemoveWhiteListAddress Event

Parameters help
_address
address help

Transfer Event

Parameters help
from
address help
to
address help
value
uint256 help

Unpause Event

Parameters help

Functions Expand All Collapse All

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));
        newOwner = _newOwner;
    }

acceptOwnership keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
    function acceptOwnership() public onlyNewOwner returns(bool) {
        emit OwnershipTransferred(owner, newOwner);        
        owner = newOwner;
        newOwner = address(0);
    }

AddBlacklist keyboard_arrow_up

Parameters help

Name Type
account
address help

Properties

Visibility help public
Mutability help transaction
Source Code
    function AddBlacklist(address account) public onlyOwner returns(bool) {
        require(account != address(0));
        require(blacklist[account] == false);
        require(account != address(this));
        require(account != owner);

        blacklist[account] = true;
        emit AddBlackListAddress(account);
        return true;
    }

RemoveBlacklist keyboard_arrow_up

Parameters help

Name Type
account
address help

Properties

Visibility help public
Mutability help transaction
Source Code
    function RemoveBlacklist(address account) public onlyOwner returns(bool) {
        require(account != address(0));
        require(blacklist[account] == true);
        blacklist[account] = false;
        emit RemoveBlackListAddress(account);
        return true;
    }

AddWhitelist keyboard_arrow_up

Parameters help

Name Type
account
address help

Properties

Visibility help public
Mutability help transaction
Source Code
    function AddWhitelist(address account) public onlyOwner returns(bool) {
        require(account != address(0));
        require(whitelist[account] == false);
        require(account != address(this));
        whitelist[account] = true;
        emit AddWhiteListAddress(account);
        return true;
    }

RemoveWhiltelist keyboard_arrow_up

Parameters help

Name Type
account
address help

Properties

Visibility help public
Mutability help transaction
Source Code
    function RemoveWhiltelist(address account) public onlyOwner returns(bool) {
        require(account != address(0));
        require(whitelist[account] == true);
        require(account != owner);
        whitelist[account] = false;
        emit RemoveWhiteListAddress(account);
        return true;
    }

pause keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
    function pause() onlyOwner whenNotPaused public {
        paused = true;
        emit Pause();
    }

unpause keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help transaction
Source Code
    function unpause() onlyOwner whenPaused public {
        paused = false;
        emit Unpause();
    }

totalSupply keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

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

balanceOf keyboard_arrow_up

Parameters help

Name Type
_who
address help

Properties

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

allowance keyboard_arrow_up

Parameters help

Name Type
_owner
address help
_spender
address help

Properties

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

transfer keyboard_arrow_up

Parameters help

Name Type
_to
address help
_amount
uint256 help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
    function transfer(address _to, uint256 _amount) public whenNotPaused returns(bool) {
        require(_to != address(0));
        require(_to != address(this));
        require(_amount > 0);
        require(_amount <= balances[msg.sender]);
        require(blacklist[msg.sender] == false);
        require(blacklist[_to] == false);

        balances[msg.sender] = balances[msg.sender].sub(_amount);
        balances[_to] = balances[_to].add(_amount);
        emit Transfer(msg.sender, _to, _amount);
        return true;
    }

transferFrom keyboard_arrow_up

Parameters help

Name Type
_from
address help
_to
address help
_amount
uint256 help

Properties

Visibility help public
Mutability help transaction

Requirements help

Source Code
    function transferFrom(address _from, address _to, uint256 _amount) public whenNotPaused returns(bool) {
        require(_to != address(0));
        require(_to != address(this));
        require(_amount <= balances[_from]);
        require(_amount <= allowed[_from][msg.sender]);
        require(blacklist[_from] == false);
        require(blacklist[_to] == false);
        require(blacklist[msg.sender] == false);

        balances[_from] = balances[_from].sub(_amount);
        allowed[_from][msg.sender] = allowed[_from][msg.sender].sub(_amount);
        balances[_to] = balances[_to].add(_amount);
        emit Transfer(_from, _to, _amount);
        return true;
    }

approve keyboard_arrow_up

Parameters help

Name Type
_spender
address help
_amount
uint256 help

Properties

Visibility help public
Mutability help transaction

Requirements help

One or more of the following:
Source Code
    function approve(address _spender, uint256 _amount) public returns(bool) {
        // reduce spender's allowance to 0 then set desired value after to avoid race condition
        require((_amount == 0) || (allowed[msg.sender][_spender] == 0));
        allowed[msg.sender][_spender] = _amount;
        emit Approval(msg.sender, _spender, _amount);
        return true;
    }

name keyboard_arrow_up

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;
    }

symbol keyboard_arrow_up

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;
    }

decimals keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

Visibility help public
Mutability help view
Source Code
    function decimals() public view returns (uint8) {
        return _decimals;
    }

constructor keyboard_arrow_up

Parameters help

This function has no parameters.

Properties

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

burn keyboard_arrow_up

Parameters help

Name Type
_address
address help
_value
uint256 help

Properties

Visibility help public
Mutability help transaction
Source Code
    function burn(address _address, uint256 _value) external whenNotPaused {
        require(_value <= balances[_address]);
        require((whitelist[msg.sender] == true && _address == msg.sender) || (msg.sender == owner));
        balances[_address] = balances[_address].sub(_value);
        totalTokenSupply = totalTokenSupply.sub(_value);
        emit Burn(msg.sender, _address, _value);
        emit Transfer(_address, address(0), _value);
    }

mintTokens keyboard_arrow_up

Parameters help

Name Type
_beneficiary
address help
_value
uint256 help

Properties

Visibility help public
Mutability help transaction
Source Code
    function mintTokens(address _beneficiary, uint256 _value) external onlyOwner {
        require(_beneficiary != address(0));
        require(blacklist[_beneficiary] == false);
        require(_value > 0);
        balances[_beneficiary] = balances[_beneficiary].add(_value);
        totalTokenSupply = totalTokenSupply.add(_value);
        emit Mint(_beneficiary, _value);
        emit Transfer(address(0), _beneficiary, _value);
    }