OpenDOF Project
DOFOperation DOFObject_BeginSubscribe ( DOFObject  obj,
const DOFInterfaceProperty  property,
uint32  minPeriod,
DOFOperationControl  config,
uint32  timeout,
const DOFObjectSubscribeCallback  callback,
void *  context 
)

Register a requestor callback for watching the value of a property over time, and ask the provider of the submitted DOFObject and submitted DOFInterfaceProperty to notify us of such Property value changes.

For the duration of the DOFOperation, changes detected in the Property will be communicated to us through the callback, based on the given timing parameters. As with any DOFOperation, this operation can be extended or cancelled.

Resource Management:
This function allocates resources that must later be freed by calling DOFOperation_Destroy.
Note
The Property's current value is always returned when the subscription is started.
Intermediate changes that occur more frequently than minPeriod may be dropped to save bandwidth, but the most current value of the Property is always returned.
Parameters
objThe object on which to watch the Property. This should not be NULL.
propertyThe Property to watch. This should not be NULL.
minPeriodThe preferred minimum time period between change notifications, in milliseconds. This is used only as a guideline; updates may occur more (or less) frequently than indicated here.
configConfiguration options for the request operation (NULL for default configuration).
timeoutThe duration for the asynchronous operation, in milliseconds (specifies the duration of the subscription). The timeout begins after the operation has been processed and sent to appropriate connections.
callbackThe callback through which responses and the completion notification will be received. This may be null to ignore notification of the received values during the subscription. However, results are only reported to the callback.
contextApplication context data associated with the asynchronous operation.
Returns
A representation of the subscribe operation.
Exceptions
NULLis returned if
  • an invalid parameter is detected; or
  • insufficient resources exist to create the operation.
core-c-dof-oal Version 7.1.5 Build 0
2017-01-25