Enumerated Constants          

Java and .NET vary in their support of enumerated constants. Java does not provide native support for them and .NET does. The Oracle Determinations Engine API for Java supports enumerated constants through static instances of a class that represents the particular enumeration.

Oracle Determinations Engine API for Java

Constants in the Expert API are represented as final static instances of a class describing the type of constant. For example, the Expert API exposes a class called SexType, that provides four static members to represent the possible sex types, Neuter, Male, Female, and Generic. Therefore, to set the sex of an attribute instance, the following is required:

personAttr.setSex(SexType.Female);

Oracle Determinations Engine API for .NET

Oracle Determinations Engine API for .NET exposes a collection of enumerated types. These types include constants for each of the acceptable values, for example:

personAttr.SetSex(SexType.Female);