ZAttributeCalculatorTransformUniversalMappingByParam
This calculation class calculates the value of an attribute using a mapping file based on another attribute value. The attribute value transformation can be applied to both process and object attributes.
You can control the behavior of the calculation class by specifying the following parameters:
Parameter |
Description |
Example value |
attrname |
Source system attributes whose values are converted |
AT_PLZ |
mappingfile |
File that contains the mapping information (key-value pairs) Specify the directory containing the mapping file relative to the data_ppm\bin directory. The directory is located under <PPM installation directory>\ppmmashzone\server\bin\work\. |
..\custom\<ppmclient>\xml\ |
defaultcopy |
Specifies the behavior if no mapping is found for the attribute value. |
FALSE |
Note that a default value specified in the calculation rule (defaultvalue XML element) is used regardless of the defaultcopy parameter. If a default value is specified, it takes priority.
Example
In the example below, the values of the AT_PLZ process attribute are converted into the AT_ORT process attribute. The conversion is specified in the file PLZ_Ort.mappings. If the postal code does not relate to any city, the AT_ORT attribute is assigned the value Not specified.
Extract from the measure configuration
...
<calcattr name="AT_ORT" type="PROCESS">
<defaultvalue>Not specified</defaultvalue>
<calcclass name="com.idsscheer.ppm.server.
keyindicator.attributecalculator
ZAttributeCalculatorTransformUniversalMappingByParam">
<calcparam key="attrname" value="AT_PLZ"/>
<calcparam key="mappingfile" value="PLZ_Ort.mappings"/>
</calcclass>
</calcattr>
...
Content of the mapping file PLZ_Ort.mappings:
66115 = Saarbruecken
10117 = Berlin Center
14612 = Falkensee
Please make sure that the mapping files you are using are regular Java property files. If they contain umlauts or other special characters, they must be converted with native2ascii. Further information on converting files with native content to ASCII files is available on the help pages on the Sun Microsystems, Inc. Web page.
ObjectCounterByEpcEnv
The ObjectCounterByEpcEnv calculation class calculates the number of functions preceding or following the current function, ignoring any events and connectors. The current function is the function for which the calculation rule is being executed.
You can control the behavior of the calculation class by specifying the following parameters:
Parameter |
Description |
Example value |
DIRECTION |
Direction of search for predecessor or successor functions starting from the current function |
FORWARD (successor functions) or |
ENVTYPE |
Search for functions in the immediate vicinity of the function or in the entire process instance |
DIRECT (only immediately adjacent functions) INDIRECT (all functions in the specified search direction) |
OBJECTNAMEFILTER |
Limits the search to particular internal function names, with use of the placeholders * and ? as required. Several name patterns are specified using key as follows: OBJECTNAMEFILTER.0 |
*AUFT*,????AUFT* FCT_AUFT1, FCT_AUFT_2 *AUFT?? |
Warning
Note that the name (key) of each parameter is written in upper case.
Example (extract from measure configuration)
...
<calcattr name="AT_KI_COUNTFUNC_ENV" type="OT_FUNC"
objectname="FCT_CREATE_ORD">
<calcclass name="com.idsscheer.ppm.server.
keyindicator.attributecalculator.
ZAttributeCalculatorObjectCounterByEpcEnv">
<calcparam key="DIRECTION" value="FORWARD"/>
<calcparam key="ENVTYPE" value="DIRECT"/>
<calcparam key="OBJECTNAMEFILTER.0"
value="FCT_CREATE_*"/>
<calcparam key="OBJECTNAMEFILTER.1"
value="FCT_ORDER_*">
</calcclass>
</calcattr>
...
The configured search retrieves all successor functions directly adjacent to the current function. The set of functions retrieved is further limited by the specified filter expressions FCT_CREATE_* and FCT_ORDER_*. The number of objects in the set of functions retrieved is calculated and is saved in the calculated AT_KI_COUNTFUNC_ENV attribute type.
AttributeCopierByEpcEnv
Use this calculation class to define dependencies between several attribute calculations (<depends attrname="..." type="..."/>). For example, it can be useful to only execute a particular attribute calculation when certain attribute type values have already been copied to selected functions using the AttributeCopierByEpcEnv calculation class.
In the actual calculation, a configurable search starting from the current function is used to retrieve particular adjacent functions.
Particular attribute type values for a function are then copied to one or more functions in line with the specified parameters. A distinction is made between the following two cases:
1. case
The current function will be the destination of the copying operation<calcparam key="COPYROLE" value="DESTINATION"/>).
If several adjacent functions are retrieved, a function needs to be selected from the set of functions retrieved to be the source of the copying operation. In this case, the COPYTYPE parameter must have the value 1-TO-1.
2. case
The current function will be the source for the copying operation (<calcparam key="COPYROLE" value="SOURCE"/>).
The specified attribute type values are to be copied from the starting function to another specified function. The COPYTYPE parameter must have the value 1-TO-1 as the search can retrieve several adjacent functions. The SORTATTRIBUTE and SORTTYPE parameters are used to select a destination function from the set retrieved.
If the specified attribute type values are to be copied from the starting function to all adjacent functions, the COPYTYPE parameter must have the value 1-TO-N. In this case, it is not necessary to specify the SORTATTRIBUTE and SORTTYPE sorting parameters as there is no need to make any further distinction between the functions found.
Identify the source for copying
To establish the source and target for the copying operation the SORTATTRIBUTE and SORTTYPE parameters are used to determine the function that is in first position based on the specified sort direction.
Attribute type values to be copied
The list of attribute type values to be copied is specified with consecutive numbering using the SOURCEATTRIBUTE.<x> or DESTINATIONATTRIBUTE.<x> parameters, with <x> being an integer. If no destination attribute type is specified, the source attribute type is created as the destination attribute type with corresponding values for the specified functions.
You can control the behavior of the AttributeCopierByEpcEnv calculation class by specifying the following parameters:
Parameter |
Description |
Example value |
DIRECTION |
Direction of search for predecessor or successor functions starting from the current function |
FORWARD (successor functions) or |
ENVTYPE |
Search for functions in the specified direction in the immediate vicinity of the function or in the entire process instance |
DIRECT (only immediately adjacent functions) INDIRECT (all functions in the specified search direction) |
OBJECTNAMEFILTER |
Limits the search to particular internal function names, with use of the placeholders * and ? as required. Several name patterns are specified using key as follows: OBJECTNAMEFILTER.0 |
*AUFT*,????AUFT* FCT_AUFT1, FCT_AUFT_2 *AUFT?? |
COPYROLE |
Role of the current function in the copying process. The adjacent functions identified by the search each take opposing roles. |
SOURCE (copying source) DESTINATION (copying destination) |
COPYTYPE |
If multiple functions are identified as the copying destination, this parameter specifies whether the value is to be copied to all of them or just to one function. |
1-TO-1 (value is copied to 1-TO-N (value is copied to |
SORTATTRIBUTE |
Attribute used as sorting criterion if multiple functions are retrieved |
Existing |
SORTTYPE |
Sorting direction for the selected sorting criterion |
ASC (default value: DESC (descending) |
SORTNULLVALUES |
Specifies whether objects whose sort attribute has not been entered are to be sorted by maximum or minimum value, or if an error message is to be output. |
MIN, MAX, DEFAULT (default value) |
SOURCEATTRIBUTE.<x> |
The source attribute type whose value is to be copied. <x> is an integer and corresponds to destinationattribute.<x> |
An existing |
DESTINATION |
The destination attribute type to which the value is to be copied. <x> is an integer and corresponds to sourceattribute.<x> |
Existing |
Example
The configured search retrieves all predecessor functions directly adjacent to the current function, which is to be used as the source for the copying operation. If multiple predecessor functions are retrieved, the set of functions identified is sorted in descending order using the sorting criterion AT_START_TIME. The value of the AT_START_TIME attribute type is copied from the latest function to the AT_END_TIME attribute type for the destination function.
Extract from the measure configuration
...
<calcattr name="AT_END_TIME" type="OT_FUNC" objectname="...">
<calcclass name="com.idsscheer.ppm.server.
keyindicator.attributecalculator.
ZAttributeCalculatorAttributeCopierByEpcEnv">
<calcparam key="DIRECTION" value="BACKWARD"/>
<calcparam key="ENVTYPE" value="DIRECT"/>
<calcparam key="COPYROLE" value="SOURCE"/>
<calcparam key="COPYTYPE" value="1-TO-1"/>
<calcparam key="SORTATTRIBUTE" value="AT_START_TIME"/>
<calcparam key="SORTTYPE" value="DESC"/>
<calcparam key="SOURCEATTRIBUTE.0"
value="AT_START_TIME"/>
<calcparam key="DESTINATIONATTRIBUTE.0"
value="AT_END_TIME"/>
</calcclass>
</calcattr>
...
AttributeAggregatorByEpcEnv
The AttributeAggregatorByEpcEnv calculation class adds up the specified numerical attribute type for all adjacent functions. The result is saved in the specified attribute type.
You can control the behavior of the AttributeAggregatorByEpcEnv calculation class by specifying the following parameters:
Parameter |
Description |
Example value |
DIRECTION |
Direction of search for predecessor or successor functions starting from the current function |
FORWARD (successor functions) or |
ENVTYPE |
Search for functions in the specified direction in the immediate vicinity of the function or in the entire process instance |
DIRECT (only immediately adjacent functions) INDIRECT (all functions in the specified search direction) |
OBJECTNAMEFILTER |
Limits the search to particular internal function names, with use of the placeholders * and ? as required. Several name patterns are specified using key as follows: OBJECTNAMEFILTER.0 |
*AUFT*,????AUFT* FCT_AUFT1, FCT_AUFT_2 *AUFT?? |
AGGREGATION_ |
Attribute type to be aggregated |
Existing PPM attribute type |
Example
In the example below, all successor functions are retrieved for the current function in the process instance, whose internal name begins with the string FCT_ORDER_ or FCT_INVOICING_ followed by any four characters. The AT_ORDER_VOL attribute type is aggregated for the set of functions retrieved and saved in the AT_KI_ORDER_VOL_AGG attribute type.
Extract from the measure configuration
...
<calcattr name="AT_KI_ORDER_VOL_AGG" type="OT_FUNC"
objectname="ORDER*">
<calcclass name="com.idsscheer.ppm.server.
keyindicator.attributecalculator.
ZAttributeCalculatorAttributeAggregatorByEpcEnv">
<calcparam key="DIRECTION" value="FORWARD"/>
<calcparam key="ENVTYPE" value="INDIRECT"/>
<calcparam key="OBJECTNAMEFILTER.0"
value="FCT_ORDER_*"/>
<calcparam key="OBJECTNAMEFILTER.1"
value="FCT_INVOICING_????"/>
<calcparam key="AGGREGATION_ATTRIBUTE"
value="AT_ORDER_VOL"/>
</calcclass>
</calcattr>
...