This function allows you to find a hypertarget matching the specified set of keys that may exist anywhere in the whole generated documentation.
null
.
To know exactly which phase currently is, use the generator property: output.estimationPhase
Note: Be careful when using this function (especially, within enabling conditions of template components and filtering expressions)! Incorrect use may cause the following side effects:
targetKey
findHyperTarget (Array(targetKey))
targetKeys
Each hypertarget is identified by a set of keys, which may be objects of any type. The keys are generated automatically for each hypertarget during the estimation phase by the FlexQuery expressions specified for each key in the hypertarget definition (within the properties of a template component).
A hypertarget is matched to the specified keys by matching those keys to the hypertarget's keys.
Any two individual keys are matched simply by comparing them using the Java method:
Object.equals()
.
However, matching two sets of keys is not so simple. This is controlled by the next parameters.
keyMatching
The following table shows all possible values of this parameter, the meaning of each value and the sign how it is represented in the Template Designer's Document Hyperlink Dialog (where the hyperlink's keys have the same usage as in this function).
Value | Meaning | Sign |
"sube" |
The specified keys must be a subset of or equal to the hypertarget's keys.
That means that each of the specified
Note: This value is used by default when no |
⊆ |
"equiv" |
The specified keys must be equal to the hypertarget's keys.
This is the same as in case of |
≡ |
"supe" |
The specified keys must be a superset of or equal to the hypertarget's keys.
This condition is opposite to
Using |
⊇ |
requiredKeyCount
keyMatching == "supe"
.
It allows you to set which of the specified keys must be matched in any case.
Those will be the first 'requiredKeyCount'
elements of the
targetKeys
array.
The minimal possible value of this parameter is 1 (that is, the first key in the array must always be matched). This is also its default value. If the actual passed value is < 1, it will be replaced with 1.
The maximal possible value is the number of specified targetKeys
(i.e. the array size).
So the passed value will be corrected accordingly.
Note: In the case when keyMatching != "supe"
, this parameter is ignored.
GOMHyperTarget
object that describes the hypertarget or null
if no hypertarget can be found (as well as during the estimation phase).
If several hypertargets exist that equally match to the specified parameters, the returned one is selected according the following rules (listed in priority order):
keyMatching == "sube"
, it has the minimal number of keys.
In case of keyMatching == "supe"
, it has the maximal number of keys.
Array()
, GOMHyperTarget
type,
GOMOutputInfo.estimationPhase