contract IExchange {
    /**
    @dev fired on allocationToken rate set
     */
    event AllocationTokenRateSet(uint256 rate);

    /**
    @dev fired on exchange state change
    */
    event StateChanged(uint256 state);

    /**
    @dev fired on exchange of tokenns
     */
    event TokensExchanged(
        uint256 _operationId,
        address userAddress,
        address erc20Token,
        address allocationToken,
        uint256 erc20Tokens,
        uint256 allocationTokens
    );

    /**
    @notice function exchanges chellecoin tokens to allocation tokens
    @param tokens the amount of chellecoin tokens to be exchanged for allocation tokens
     */
    function exchange(uint256 tokens) public returns (bool);

    /**
    @notice this function sets/changes state of this smart contract and only exchange manager/owner can call it
    @param state it can be either 0 (Inactive) or 1 (Active)
     */
    function setState(uint256 state) external;

    /**
    @dev it updates  update exchange rate of ERC-20 tokens to AT tokens
    @param  _allocationTokensPerErc20Token the exchange rate
    */
    function setExchangeRate(uint256 _allocationTokensPerErc20Token) external;

    /**
    @notice function to get the current state of the exchange contract
    @return current state
    */
    function getCurrentState() public view returns (uint256);

}
/**
 @title IExchange
 @dev This contract represents an Interface to Exchange contract
 */
function setState(uint256 state) external;

/**
 @notice this function sets/changes state of this smart contract and only exchange manager/owner can call it
 @param state it can be either 0 (Inactive) or 1 (Active)
 */