contract AdminRole {
    using Roles for Roles.Role;

    event AdminAdded(address indexed account);
    event AdminRemoved(address indexed account);
    event OwnerAdded(address indexed account);
    event OwnerRemoved(address indexed account);

    Roles.Role private _admins;
    Roles.Role private _owners;

    constructor () internal {
        _addAdmin(msg.sender);
        _addOwner(msg.sender);
    }

    modifier onlyOwner() {
        require(isOwner(msg.sender));
        _;
    }

    modifier onlyAdmin() {
        require(isAdmin(msg.sender));
        _;
    }

    function isOwner(address account) public view returns (bool) {
        return _owners.has(account);
    }

    function isAdmin(address account) public view returns (bool) {
        return _admins.has(account);
    }

    //    function addOwner(address account) public onlyOwner {
    //        _addOwner(account);
    //    }

    function addAdmin(address account) public onlyOwner {
        _addAdmin(account);
    }

    function renounceAdmin() public {
        _removeAdmin(msg.sender);
    }

    //    function renounceOwner() public {
    //        _removeOwner(msg.sender);
    //    }

    function removeAdmin(address account) public onlyOwner {
        _removeAdmin(account);
    }

    function _addAdmin(address account) internal {
        _admins.add(account);
        emit AdminAdded(account);
    }

    function _addOwner(address account) internal {
        _owners.add(account);
        emit OwnerAdded(account);
    }

    function _removeAdmin(address account) internal {
        _admins.remove(account);
        emit AdminRemoved(account);
    }

    //    function _removeOwner(address account) internal {
    //        _owners.remove(account);
    //        emit OwnerRemoved(account);
    //    }
}
function removeAdmin(address account) public onlyOwner {
        _removeAdmin(account);
    }
//    function renounceOwner() public {
//        _removeOwner(msg.sender);
//    }