DOF Technology uses Synchronous and Asynchronous Operations, but we’ve found there’s a bit of confusion about what the differences are between these two types of operations and their sequences. On this page we’ll describe an Asynchronous Operation.

Something to remember about both Synchronous and Asynchronous Operations:

  • The set of methods the OAL provides for use in interface operations
    • The requestor initiates the operation
    • The provider always executes the operation and responds

Asynchronous Operations are:

  • Callback Operations
  • Nonblocking
  • Multiple results can be received
  • Messages are sent in one form and can be delivered in another

An asynchronous operation can utilize one of the following sequences:

  • The provider immediately supplies results that complete the operation
  • Operations are immediately acknowledged by the provider with changes sent to the requestor over time
  • Operations are not complete until the requestor sends a separate call to cancel them

Single-transaction Asynchronous Operations

Single-transaction asynchronous operations are complete after the initial response and require three methods:

  • The requestor uses a DOFObject method call to initiate the operation
  • The provider uses its corresponding DOFObject.Provider method to respond to the operation
  • The requestor uses an operation listener’s results handling method to process the results

Ongoing Asynchronous Operations

Unlike a single-transaction, these operations continue until the requestor uses a cancel method of the DOFOperation interface to unsubscribe or unregister the operation. The sequence of an ongoing asynchronous operation is as follows:

  • The requestor uses a DOFObject method call to initiate the operation
  • The provider uses its corresponding DOFObject.Provider method to acknowledge the operation
  • In subscribe operations only, the provider uses its DOFObject.Provider get method to send the requestor the initial value of the property.
    • Register operations do not have a corresponding method
  • The provider uses a DOFObject method call to send additional results to the requestor over time
  • The requestor uses an operation listener’s results handling method to process all results
  • As mentioned earlier, when finished, the requestor should use the cancel method of the DOFOperation interface to unsubscribe or unregister

Please refer to the Glossary for more definitions and terms.

asynchronous get operation
Asynchronous Operation