Show / Hide Table of Contents

Class Waiter<Request, Response>

Provides a mechanism for waiting on some condition in either blocking or async manner.

Inheritance
object
Waiter<Request, Response>
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: Oci.Common.Waiters
Assembly: OCI.DotNetSDK.Common.dll
Syntax
public class Waiter<Request, Response>
Type Parameters
Name Description
Request

Request Type

Response

Response Type

Constructors

Waiter(WaiterConfiguration, WaiterAgent<Request, Response>)

Declaration
public Waiter(WaiterConfiguration configuration, WaiterAgent<Request, Response> agent)
Parameters
Type Name Description
WaiterConfiguration configuration
WaiterAgent<Request, Response> agent

Waiter(Func<Response>)

Declaration
public Waiter(Func<Response> invokableWaiterAgent)
Parameters
Type Name Description
Func<Response> invokableWaiterAgent

Methods

Execute()

Executes the waiter agent in a new thread and it is blocked until the condition is met or throws an exception.

Declaration
public Response Execute()
Returns
Type Description
Response

Response

ExecuteAsync()

Returns a TaskResponse which can be waited on and the result would contain response in the desired state or throws an exception if the condition is not met.

Declaration
public Task<Response> ExecuteAsync()
Returns
Type Description
Task<Response>

TaskResponse

In this article
Back to top