IOwnable
This contract is used to manage ownership
Functions
owner
Returns the owner address
function owner() external view returns (address _owner);
Returns
Name | Type | Description |
---|---|---|
_owner | address | The address of the owner |
pendingOwner
Returns the pending owner address
function pendingOwner() external view returns (address _pendingOwner);
Returns
Name | Type | Description |
---|---|---|
_pendingOwner | address | The address of the pending owner |
changeOwner
Propose a new owner for the contract
The new owner will need to accept the ownership before it is transferred
function changeOwner(address _pendingOwner) external;
Parameters
Name | Type | Description |
---|---|---|
_pendingOwner | address | The address of the new owner |
acceptOwner
Accepts the ownership of the contract
function acceptOwner() external;
Events
ChangeOwner
Emitted when the owner is proposed to change
event ChangeOwner(address indexed _pendingOwner);
Parameters
Name | Type | Description |
---|---|---|
_pendingOwner | address | The address that is being proposed |
AcceptOwner
Emitted when the owner is accepted
event AcceptOwner(address indexed _owner);
Parameters
Name | Type | Description |
---|---|---|
_owner | address | The address of the new owner |
Errors
Ownable_OnlyOwner
Thrown when the caller is not the owner
error Ownable_OnlyOwner();
Ownable_OnlyPendingOwner
Thrown when the caller is not the pending owner
error Ownable_OnlyPendingOwner();