OpenDOF Project
DOFObject DOFSystem_WaitProvider ( const DOFSystem  sys,
const DOFObjectID  objectID,
uint32  interfaceIDCount,
const DOFInterfaceID  interfaceIDs[],
uint32  timeout 
)

Wait for a provider providing at least the given set of interfaces to become available in the system, and return a new, valid DOFObject for it.

The Broadcast ID may be used as a wildcard (to return the first object found).

The matching logic uses the same logic as DOFObjectID_MatchesAtLeast, so additional attributes may be present on the resulting Object (e.g., an activate service may add a Provider attribute). If there are multiple matches, the first one found will be returned. This is a simplified form of DOFSystem_Query or DOFSystem_BeginQuery, followed by DOFSystem_CreateObject on the first match.

There is no request to the network to identify additional objects that may be available. The DOFObject returned may be limited by the Interest operations that exist (see DOFSystem_BeginInterest).

If the Object is not available within the timeout period, the function will return NULL.

Resource Management:
This function allocates resources that must later be freed by calling DOFObject_Destroy.
Parameters
sysThe System. This must not be NULL.
objectIDThe Object ID on which to wait. This should not be NULL, and should not represent a multicast Object ID. It may be the Broadcast ID to return the first object found.
interfaceIDCountThe number of Interfaces to wait for on the Object. This should be greater than 0.
interfaceIDsThe list of Interfaces to wait for on the Object. This should not be NULL, and should not contain a NULL or the Wildcard ID.
timeoutThe duration to wait for the Object and Interfaces to be available, in milliseconds.
Returns
A new DOFObject representing the desired Object.
Exceptions
NULLis returned if an invalid parameter was detected, or the Object was not available within the given timeout.
See Also
DOFSystem_BeginInterest
core-c-dof-oal Version 8.0.1 Build 0
2018-01-22