getRelationTargets(refContent, contentClass, targetContent [, params])
Retrieves all potential target documents of a given relation
This method is useful to retrieve all target documents that a relation may point to for a given document. It utilizes a HQL query und the background to retrieve results.
This method may be used to retrieve potential relation options not only for existing documents but also for documents to be created. Therefor the refContent parameter may take the document that holds the relation, but also all parent document from which the document holding the relation may be created
For existing documents this method will also return the current target of the relation, even if it is no longer contained in the relation filter. Switch this off via the "params" argument if this is not desired.
The optional "params" Lookup table argument can be used to further refine the query executed. It takes the following lookup keys:
refContent (WGAPI object WGContent
The content document holding the relation, or a parent document from which the document holding the relation is to be created.
The content class for which the relation is defined. On updating a content this is always the content class of refContent.
The name of the relation to fetch targets for
params (Lookup table, optional):
Optional params to the retrieval query
A ResultSet of the documents being valid targets for the relation
|Allowed in script types||