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.

C#
protected internal virtual IAsyncResult BeginTryCommand(System.Runtime.DurableInstancing.InstancePersistenceContext context, System.Runtime.DurableInstancing.InstancePersistenceCommand command, TimeSpan timeout, AsyncCallback callback, object state);

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

Product Versions
.NET Framework 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1