ILOG JRules User Guide > Customizing JRules > Tasks > Defining Common Model Extensions for Rule Studio and Rule Team Server > Defining Rule Model Extensions > Creating a Struct Property

You can create a Struct property to group properties of primitive type.

Warning
Do not use a reserved SQL keyword as the name of a property.

To create a Struct property:

  1. Create or open an extension model file.
  2. In the Rule Model Extension Editor, right-click the extension model entry, and click New Child > Struct.
  3. A new Struct item appears in the tree.
  4. Select the Struct item, and, in the Properties view, set the Name property to the name of the new Struct property.
  5. To add properties to the Struct property, right-click the Struct property, and click New Child > Property. Edit the properties as needed.
  6. Right-click the rule model element to which you want to attach the Struct property, and click New Child > Property.
  7. A new Property item appears in the tree.
  8. Select the Property item, and, in the Properties view, set the Name property to the name of the item as you want it to appear in the Properties view, and the Type property to the name of the Struct property.
  9. Save the extension model file.
  10. You have now created a Struct property and attached it to a rule model element.

In XML, you create a Struct property as follows:

<struct>
   <property name="status" type="Status"/>
   <property name="author" type="String"/>
</struct>

Related Concepts

Rule Model

Related Tasks

Defining Rule Model Extensions
Creating a New Rule Model Class
Hiding a Rule Model Class
Creating an Enumeration Property
Creating a Hierarchical Property
Associating a Custom Editor to a Property

Related Reference

Rule Model Extension Editor

Related Samples and Tutorials

Rule Studio Business Rule Management Extensions
Rule Team Server Business Rule Management Extensions