contract VNETToken is Ownable, AbstractToken {
    event Donate(address indexed _from, uint256 _amount);


    /**
     * @dev Constructor
     */
    constructor() public {
        name = "VNET Token";
        symbol = "VNET";
        decimals = 6;
        value = "1 Token = 100 GByte client newtwork traffic flow";

        // 35 Billion Total
        cap = 35000000000 * (10 ** decimals);
    }

    /**
     * @dev Sending eth to this contract will be considered as a donation
     */
    function () public payable {
        emit Donate(msg.sender, msg.value);
    }

    /**
     * @dev Function to mint tokens
     * @param _to The address that will receive the minted tokens.
     * @param _amount The amount of tokens to mint.
     * @return A boolean that indicates if the operation was successful.
     */
    function mint(address _to, uint256 _amount) external returns (bool) {
        require(mintAgents[msg.sender] && totalSupply_.add(_amount) <= cap);

        totalSupply_ = totalSupply_.add(_amount);
        balances[_to] = balances[_to].add(_amount);
        emit Mint(_to, _amount);
        emit Transfer(address(0), _to, _amount);
        return true;
    }

    /**
     * @dev Function to mint tokens, and lock some of them with a release time
     * @param _to The address that will receive the minted tokens.
     * @param _amount The amount of tokens to mint.
     * @param _lockedAmount The amount of tokens to be locked.
     * @param _releaseTime The timestamp about to release, which could be set just once.
     * @return A boolean that indicates if the operation was successful.
     */
    function mintWithLock(address _to, uint256 _amount, uint256 _lockedAmount, uint256 _releaseTime) external returns (bool) {
        require(mintAgents[msg.sender] && totalSupply_.add(_amount) <= cap);
        require(_amount >= _lockedAmount);

        totalSupply_ = totalSupply_.add(_amount);
        balances[_to] = balances[_to].add(_amount);
        lockedBalanceMap[_to] = lockedBalanceMap[_to] > 0 ? lockedBalanceMap[_to].add(_lockedAmount) : _lockedAmount;
        releaseTimeMap[_to] = releaseTimeMap[_to] > 0 ? releaseTimeMap[_to] : _releaseTime;
        emit Mint(_to, _amount);
        emit Transfer(address(0), _to, _amount);
        emit BalanceLocked(_to, _lockedAmount);
        return true;
    }
}
/**
 * @dev VNET Token for Vision Network Project
 */
function mint(address _to, uint256 _amount) external returns (bool) {
        require(mintAgents[msg.sender] && totalSupply_.add(_amount) <= cap);

        totalSupply_ = totalSupply_.add(_amount);
        balances[_to] = balances[_to].add(_amount);
        emit Mint(_to, _amount);
        emit Transfer(address(0), _to, _amount);
        return true;
    }
/**
 * @dev Function to mint tokens
 * @param _to The address that will receive the minted tokens.
 * @param _amount The amount of tokens to mint.
 * @return A boolean that indicates if the operation was successful.
 */