IWDTFTarget2::GetRelations method (wdtf.h)
Returns a collection of related targets.
Syntax
HRESULT GetRelations(
[in] BSTR RelationSDEL,
[in] BSTR MatchSDEL,
[out, retval] IWDTFTargets2 **ppRelations
);
Parameters
[in] RelationSDEL
An SDEL statement that contains one or more relation tokens that specify the desired targets.
[in] MatchSDEL
The SDEL statement that each returned target must match. If MatchSDEL is empty, all targets are returned.
[out, retval] ppRelations
The address of the variable that will receive the result of this method.
Return value
If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
Remarks
You use the GetRelations method to retrieve related instances of the IWDTFTarget2 interface. You specify the desired targets by a relation SDEL statement. Typically, an SDEL statement can contain attribute tokens, comparison operators, and value specifiers to perform matches. However, you do not need these items in the RelationSDEL parameter for the GetRelations method to work properly (the MatchSDEL parameter follows the rules for the IWDTFTarget2::Eval method).
The IWDTFTarget2:GetRelations method places every related target that GetRelations finds by the RelationSDEL statement into a new collection.
GetRelations returns only the subset of targets that satisfy the MatchSDEL parameter constraints. If the MatchSDEL parameter string is empty, GetRelations returns the entire collection of targets. This process filters out all of the targets that return VARIANT_FALSE when you provide MatchSDEL to the target's IWDTFTarget2::Eval method.
For more information about using the GetRelations method, see Simple Data Evaluation Language Overview.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP Professional |
Minimum supported server | Windows Server 2008 |
Target Platform | Desktop |
Header | wdtf.h |