Retrieving reflection information on a schema
You can retrieve reflection information on a schema.
About this task
The following example shows how to obtain reflection information on a schema:
Procedure
To obtain reflection information on a schema:
Results
Here is the schema:
<?xml version="1.0"?>
<schema targetNamespace="http://www.ilog.com/jrules/training/truck">
<element name = "TruckModel">
<complexType>
<sequence>
<element name="name" type="string"/>
<element name="licenseClass" type="string"/>
<element name="capacity" type="float"/>
<element name="thresholdFull" type="float"/>
</sequence>
</complexType>
</element>
</schema>
And here is the rule:
rule Threshold
{
when {
?tm: TruckModel(capacity > 8000);
}
then {
modify ?tm {thresholdFull = 0.9;}
}
}