IOVMClient
The IOVMClient contract interface.
Functions
cancelRequest
Cancels a request by its requestId. Emits a {RequestCancelled} event.
function cancelRequest(bytes32 requestId) external;
Parameters
Name | Type | Description |
---|---|---|
requestId | bytes32 | The ID of the request to be cancelled. |
setResponse
Sets the response data for a specific request. This function is called by the OVMGateway contract.
function setResponse(bytes32 requestId, bytes calldata data) external;
Parameters
Name | Type | Description |
---|---|---|
requestId | bytes32 | The ID of the request. |
data | bytes | The response data to be set. |
updateSpecification
Updates the specification of the OVM client.
function updateSpecification(Specification calldata newSpec) external;
Parameters
Name | Type | Description |
---|---|---|
newSpec | Specification | The new specification to update. |
withdraw
Withdraws the contract's balance to the contract owner.
function withdraw() external;
isPendingRequest
Checks if a request is pending.
function isPendingRequest(bytes32 requestId) external view returns (bool);
Parameters
Name | Type | Description |
---|---|---|
requestId | bytes32 | The ID of the request. |
Returns
Name | Type | Description |
---|---|---|
<none> | bool | isPending True if the request is pending, otherwise false. |
getSpecification
Returns the specification of the contract.
function getSpecification() external view returns (Specification memory);
Returns
Name | Type | Description |
---|---|---|
<none> | Specification | specification The specification of the contract. |
getOVMGatewayAddress
Get the address of the OVMGateway contract.
function getOVMGatewayAddress() external view returns (address);
Returns
Name | Type | Description |
---|---|---|
<none> | address | The address of the OVMGateway contract. |