Conditional Affinity
TIBCO Product and Service Catalog 2.0.0 introduced Conditional Affinity modeling, which combines InLink and CrossLink affinities in a single affinity type and provides additional flexibility. Affinity grouping enables different plan items to be grouped together based on the evaluation of the XPATH expression defined at the product catalog.
The following attributes are available at the record level in the AFFINITY GROUP of product or at the
ProductHasProvidePlanFragment
,
ProductHasUpdatePlanFragment
,
ProductHasCeasePlanFragment
,
ProductHasCancelPlanFragment
, and
ProductHasCustomPlanFragment
relationships. The additional configuration fields and rules in conditional affinity are :
AffinityType | Determines the type of affinity implemented.
|
AffinityCondition | Valid for Conditional type only. A String field containing an XPATH expression that evaluates to true or false based on data is in the order:
The XPATH expression evaluates against the following data fields on the order:
The XPATH expression can also be defined against the following plan data fields:
|
AffinityCorrelation | Valid for Conditional type only. The XPATH is evaluated on the Plan data and the order data. A String field containing an xpath expression based on a data is in the following order:
The XPATH expression evaluates against the following order data fields:
The XPATH expression can also be defined against the following plan data fields:
|
AffinityParentGroup | Valid for Conditional type only. A boolean field containing the value true or false:
|
AffinityActionGroup | Valid for Conditional type only. A boolean field containing the value true or false:
|
AffinityActionValue | AffinityActionValue is considered for grouping when AffinityActionGroup is set to true. This is valid for Conditional type only. String field containing an XPATH expression that evaluates to a String based on data is in the following order: The XPATH expression must evaluate to one of the following:
If the XPATH expression evaluates to anything other than these actions, then AOPD fails and returns an exception.
The XPATH expression is able to evaluate against the following data fields on the order:
The XPATH expression can also be defined against the following plan data fields:
|
AffinityProvide | Provide plan fragment name for affinity grouped plan item. Only plan items with the Provide action and the same value in this field are grouped together |
AffinityUpdate | Update plan fragment name for affinity grouped plan item. Only plan items with the Update action and the same value in this field are grouped together |
AffinityCease | Cease plan fragment name for affinity grouped plan item. Only plan items with the Cease action and the same value in this field are grouped together |
AffinityCancel | Cancel plan fragment name for affinity grouped plan item. Only plan items with the Cancel action and the same value in this field are grouped together |
For more information, see TIBCO Product and Service Catalog Product Catalog Guide.
<Actual XPath> containing string $var/PlanItem
. For example, if you want to define the XPath for UDF name-value pair
MSISDN=123
, the XPath can be
$var/PlanItem[productID='GSMLine']/udfs[name='MSISDN']/value/text()
.
XPath evaluates data from the planItem. For more details, see Sample Plan Item XML.
2) If XPath is defined against the order data, the format must be
<Actual XPath> containing string $var/Order.
For more details, seeSample Order XML.
3) Default order data is considered for evaluation if XPATH does not contain
$var/PlanItem
.