Redigera

Dela via


InstanceStore.BeginTryCommand Method

Definition

A persistence provider implements this method, which determines whether a particular persistence command can be executed. If the command can be executed, executes the command asynchronously.

protected public:
 virtual IAsyncResult ^ BeginTryCommand(System::Runtime::DurableInstancing::InstancePersistenceContext ^ context, System::Runtime::DurableInstancing::InstancePersistenceCommand ^ command, TimeSpan timeout, AsyncCallback ^ callback, System::Object ^ state);
protected internal virtual IAsyncResult BeginTryCommand (System.Runtime.DurableInstancing.InstancePersistenceContext context, System.Runtime.DurableInstancing.InstancePersistenceCommand command, TimeSpan timeout, AsyncCallback callback, object state);
abstract member BeginTryCommand : System.Runtime.DurableInstancing.InstancePersistenceContext * System.Runtime.DurableInstancing.InstancePersistenceCommand * TimeSpan * AsyncCallback * obj -> IAsyncResult
override this.BeginTryCommand : System.Runtime.DurableInstancing.InstancePersistenceContext * System.Runtime.DurableInstancing.InstancePersistenceCommand * TimeSpan * AsyncCallback * obj -> IAsyncResult
Protected Friend Overridable Function BeginTryCommand (context As InstancePersistenceContext, command As InstancePersistenceCommand, timeout As TimeSpan, callback As AsyncCallback, state As Object) As IAsyncResult

Parameters

context
InstancePersistenceContext

The instance context.

command
InstancePersistenceCommand

The persistence command to be executed.

timeout
TimeSpan

The timeout value for the command execution.

callback
AsyncCallback

The asynchronous callback delegate that receives notification of the completion of the asynchronous operation.

state
Object

The state information.

Returns

The state of the asynchronous operation.

Remarks

If the command can be executed, the persistence provider calls relevant methods on the InstancePersistenceContext to provide the results of the command.

Warning

Even though this method is declared as virtual rather than abstract, there is no implementation. This method must be overridden in order to provide functionality.

Applies to