Attribute Availability

It is possible for a Processing Rule Set to be used for more than one Dynamic Evidence Type Versions. For example, the same Validation Rule Set can be used for many Versions of an Evidence Type. In such a case, the Validation Rule Set will have to factor the structural changes across different Versions into its logic.

For example, Version 1 of an Evidence Type might have "authorizedExpense" and "actualExpense" as two Attributes. In version 2, the "actualExpense" Attribute might have been replaced by a Child Evidence Type called "Expense". In this case, the total actual expense should be calculated by summing the expense value from all Child Records of Type "Expense". If there is a validation which checks the actual expense amount against the authorized expense amount, and the same Validation Rule set is being used for both Version 1 and 2, the validation logic should first check for the existence of the "actualExpense" Attribute. This is required because the generated Rule Set contains Rule Attributes corresponding to both versions 1 and 2..

The operation isAttributeAvailable() can be used to check if a particular Attribute is available in a particular Evidence record. So for this example, the Validation Rule Set can check if the "actualExpense" attribute is available in the record being validated. If not, the logic can calculate the actual expense by adding up the expense from "Expense" child records.