Advanced Visual Modeler Concepts

Properties Overview

A Visual Modeler property is an attribute of a product model, option class, or option item used to write rules that affect configuration of a product or to customize the presentation of a product model to the customer.

Where you create a property in the model hierarchy determines what objects can use the property. In general, a property is available to objects in the model group and model hierarchy below the point at which you create the property.

You can use properties as variables and write rules that reason on the properties' values using functions such as value and expand.

Define a Property

  1. Navigate to and select the location in the model group hierarchy at which to create the property.
Where you create the property determines the objects in the hierarchy that can use the property.
  1. Click the Properties tab.
  2. If you are working in a model, click the Define tab.
  3. Enter a name for the property.
  4. Do not begin a property name with "UI:" or "CONFIG". Do not include a period (.) in a property name.

  5. Select a property type from the drop-down list.
Number: a property whose value is numeric. For example, the weight of an item in grams expressed as a real number (including decimals).
String: a property expressed as a word or phrase. For example, use a string-valued property to indicate the color of an option item.
Selecting this type enables the Localize field. Check the Localize field's box to enter values for this property in any of the supported locales. For example, if you enter the original value in English, you can change the system locale to German and then modify the property's value in German. The German value appears for those users whose locale is German; the English value appears for those users whose locale is English.
List: a property whose value must be selected from a list, such as days of the week. You can define a list called "Weekdays" whose values are Sunday, Monday, Tuesday, and so on.
  1. Optionally, define a default value for this property. You can override this value when you apply the property to an item or class.
If the property type is "List", the Value field displays a drop-down list of the available lists. Select a list for the default list value.
  1. Click Add.
The new property appears in the boxes below the fields.
  1. Click Save All Changes.

Attach a Property

You define a property at the model group or model level. You attach a property to a model, an option class, or an option item.

  1. Click Configuration Models in the Product and Catalog Administration panel on the home page.
  2. In the Navigation frame, navigate to the object to which you want to attach the property.
  3. Click the Properties tab.
Two sets of fields display:
Unattached Properties: select properties and define values for them
Attached Properties: show the properties that are currently attached

The Properties tab for a model contains two tabs: Attach and Define. Use the Define tab to define properties.

  1. Select a property from the Unattached Properties drop-down list.
The property displays its default value if it has one.
  1. Enter a value for the property. You can set the value of a property by entering its value in the text field or by using a property editor window to set a value.
  2. Click Attach.
The property appears among the Attached Properties.
  1. Click Save All Changes.
  2. You must perform this last step to ensure that the property is attached.

Use the Property Editor Window

Use the Numeric Property Editor window and the String Property Editor window to edit property values.

  1. Invoke the property window editor by clicking the Edit button next to any property.
The Property Editor window displays.
  1. Specify a value for a property or specify a formula to calculate a value at runtime. To create a formula, enter "=" as the first character of the text area. The expansion fields activate to help you define the formula. The syntax of a formula depends on whether you are editing a numeric or a string property.
To define a formula on a numeric property:
Function: select a defined function from the drop-down list.
Property: specify the property whose values should be used to calculate the function.
Location: specify where to locate the named property (or properties). You can select an option item or select one of the following values for the location:
unspecified: use the named property anywhere it is defined in the model.
relative: use the named property at the current location.
To specify a formula on a string property, choose among gather, match, and expand:
gather: Assign actions to a string property. Gather finds all occurrences of the specified property in the property pool and creates a semicolon-separated string with the values of the occurrences.
match: Write rule fragments. Match provides a mechanism to compare a string to the value of a property.
expand: use the expand function.

Modify or Remove the Value of an Attached Property

You modify the value of an attached property at the local level to which it is attached.

  1. Click Configuration Models in the Product and Catalog Administration panel on the home page.
  2. In the Model Groups frame, navigate to the element to which the property is attached.
If the property is attached to a model:
In the Model Groups frame, click the model group that contains the model.
In the Models and Groups frame, click the model to which the property is attached.
Click Edit in the toolbar.
If the property is attached to an option class or option item:
In the Model Groups frame, click the model group that contains either the model or group with the option class or option item.
In the Models and Groups frame, click the model or group.
Click Edit in the toolbar.
In the Navigation frame, find and click the option class or option item.
  1. Click the Properties tab.
This tab displays two sets of fields:
Unattached Properties: select properties and define values for them.
Attached Properties: show the properties that are currently attached.

If the property is attached to a model, you will see two tabs within the Properties tab: Attach and Define. The Attach tab diisplays automatically.

  1. Find the property you want to modify or remove.
  2. Modify or remove the attached property:
If necessary, change the value of a property.
Note that this only changes the value locally, at the level at which it is attached.
To remove an attached property, click Remove.
  1. Click Save All Changes.

Modify or Delete a Property Definition

  1. Click Configuration Models in the Product and Catalog Administration panel on the Sterling Multi-Channel Selling Solution home page.
  2. Navigate to and select the location in the model group hierarchy where the property is defined.
At the root model group level:
The Visual Modeler page automatically displays the root model group when you access Visual Modeler. If the root model group is not selected, click the root model group.
At the model group level, navigate to and click the model group in the Model Groups frame.
At the model level, navigate to and click the model group that contains the model, click the model, then click Edit Model in the toolbar.
The General Info tab displays for the group or model.
  1. Click the Properties tab.
At the model group level, the properties that are defined at the model group level display.
At the model level, two tabs display: Attach and Define. If the property is attached anywhere in the model group hierarchy, you cannot modify the property type. If the property is attached anywhere in the model group hierarchy, you cannot delete the property definition.
  1. To modify an unattached property, click the Define tab. Within the Define tab, find the property you want to modify or delete.
  2. To modify an attached property, click the Attach tab. Within the Attach tab, find the property you want to modify or remove.
  3. Modify or delete the property definition (property type or value).
  4. Click Save All Changes.

Name changes and value changes propagate to anywhere the property is attached. The value change is the default value for the property and does not override any values set for the attached property.

Worksheets Overview

Worksheets provide quick access to a group of properties, enabling you to maintain all the properties for a model properties in one place. A worksheet is a table that assigns property values to option items:

Rows represent option items
Columns represent properties

Each worksheet belongs to a model and can be used to set the values of properties of that model. You can still set the values for properties individually.

For example, suppose that a model of a computer has an option class for hard drives. Each hard drive option item has a number of properties such as capacity, RPM, latency, and buffer cache. You can create a worksheet to maintain the hard drive properties, similar to the following table:

Option Item
Capacity
RPM
Latency
Buffer Cache
WD Protege
160
5400
5.00
2
WD Caviar
250
7200
4.20
2
WD Caviar SE
250
7200
4.20
8
WD Essential
250
7200
4.20
2

You can modify worksheets at any time. Changes to property values are effective immediately, and are compiled with the other model details when you next compile the model.

You can export a worksheet in the form of a comma-separated values (CSV) file, then open the CSV file in your preferred spreadsheet program to manage the values. You import the modified spreadsheet to update the values in the worksheet.

Create a Worksheet

  1. Navigate to the model for which you want to create a worksheet.
  2. Click the Worksheets tab.
  3. Click New....
  4. In the New Worksheet window, enter a name for the worksheet, and click Create.
  5. Add the option items whose properties you want to maintain using this worksheet:
Click Add Row
Use the entity picker window to navigate to each option item
  1. Add the properties to the worksheet:
Click Add Column. The Add Column dialog box displays.
In the Add Column dialog box, select each property from the drop-down list of properties defined for this model.
To create a new property, click New Property, then enter the new property details in the Define New Property window.
  1. After you add the rows and columns for your worksheet, enter values for each option item and property.
  2. Click Save All Changes.

Modify a Worksheet

  1. Navigate to the model to which the worksheet belongs.
  2. Click the Worksheets tab.
  3. Select the name of the worksheet form the drop-down list.
  4. Click Select.
  5. In the worksheet, you can do the following:
Change the name of the worksheet: click the worksheet name and enter a new name for the worksheet.
Add a new row: click Add Row and select option items as required.
Move a row: click the link to the row, and select its new position from the drop-down list of rows.
Remove a row: click the link to the row, and click Delete.
Add a new column: click Add Column, and select the property from the drop-down list.
Move a column: click the column name, and select its new position form the drop-down list of columns.
Delete a column: click the column name and click Delete.

Export a Worksheet

  1. Navigate to the model to which the worksheet belongs.
  2. Click the Worksheets tab.
  3. Select the name of the worksheet from the drop-down list.
  4. Click Select.
  5. Click Export....
  6. In the File Download window, click Save.
  7. In the Save As window, navigate to the directory on your local machine to which you want to save the file, and then click Save.

Import a Worksheet

  1. Navigate to the model to which the worksheet belongs.
  2. Click the Worksheets tab.
  3. Click Import....
  4. In the Worksheet Import window, click the Browse... button.
  5. In the Choose File window, navigate to and select the spreadsheet that you want to import.
  6. Click Open.
  7. In the Worksheet Import window, click Import Now.

Properties as Variables

Use the following syntax to evaluate the value of a property in defining rules and properties:

${function(...)}

You can define a property as a function of another property, which is useful when you define display properties and mathematical formulas for rules. For example, you can use ${expand(property[,default[,format]])} to display properties of models.

For example, suppose that you have a numeric property, "Monitor Size", that expresses the screen size in inches. Suppose that you want to display monitor size in a table in the form "nn.00 inches". You can define a property called Display Monitor Size by "${expand("Monitor Size","n/a",0.00)} inches" and use the new property in the model display. Users viewing the details for, for example, a 17" display monitor see the monitor size expressed as "17.00 inches". Note that if the Monitor Size property is not defined, "n/a inches" displays.

 
.
 
 
 
""
 
 
 
 
 
 
 
""""
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Built-In Properties

Property
Type
Comments
 
 
""""
CONFIG: FIRST FIRE
numeric
1 if this is the first time firing rules, 0 otherwise.
 
 
 
 
 
 
CONFIG: POOL SIZE
numeric
Number of copies of a model to keep in the model pool.
CONFIG: REPEAT FIRING
string
"yes" or "true" turns on looping in the rule engine, causing rules to fire as long as the current state keeps changing. Since rules are removed from the rule list whenever they fire, this is not an infinite loop.
CONFIG: SUBMODEL NAME
string
The encoded name of another model. Encoding replaces potentially unsafe file system characters with _XXXX where XXXX is the hex representation of their Unicode character code. For example, a space is represented by "_0020".
CONFIG: SUBMODEL RETURN
string
"yes" or "true": when we punch into a submodel specified by the previous property, return with that model's BOM as a child of this model.
_cacheKey
string
Use on a model node to contain the key used to store the model in the model cache.
_description
string
The description of an item.
_errorCount
numeric
Number of errors encountered during rule firing.
_fileSize
string
String representation of a Long value, size of the XML file for a model.
_lastModified
string
Last modified date for a model as a string (number of seconds since some important date).
_modelTabs
list
List of tab names for the model.
_name
string
The name of an option item, option class, or model.
_parent.<item names>
varies
Properties inherited by a submodel from the parent.
_pickItems
list
Used internally to keep track of picked items.
_pickmap.<itemKey>
string
Mapping of an item to an option class.
_picks
list
Used internally to keep track of picked items.
_quantity
integer
Quantity selected, if >0 the item is picked.
_sequence
numeric
Rule firing sequence. If 0, this is the first time through the loop, 1 is the second, and so on.
_tabMembers<#>
list
Where <#> is a tab number (0...N), these properties contains the names of the root level option classes that are part of the tab whose index is <#>.

Lists

Use lists when a single property can have multiple values, such as day of the week, wheels allowed for a road or racing bike, shirt size, and so on. You can write rules to test that the value of the property is defined in the list.

Define a List

  1. Navigate to the model group or model for which you want to define the list.
  2. Click the Lists tab.
This displays any lists already defined.
  1. Click New....
The New List tab displays.
  1. Enter a name and description for the list.
  2. Define the values for the list.
Enter a value in the New Value field.
Click Add Item.
  1. Repeat the last step for each value you want to add.
  2. Click Save to save the values and remain at the New List tab. Click Save and Return to save the values and return to the Lists tab.

Modify a List

  1. Navigate to the model which contains the list you want to modify.
  2. Click the Lists tab.
The lists already defined display.
  1. Click the name of the list you want to modify.
The Edit List tab displays.
  1. Modify the name or description.
  2. Delete values from the list.
Select one or more values in the list.
Click Delete.
  1. Add values to the list.
Type a value in the New Value field.
Click Add Item.
  1. Modify values in the list.
There is no way to modify a value in a single step. You must delete the old value and add the new one.
  1. Click Save to save the values and remain at the Edit List tab. Click Save and Return to save your changes and return to the Lists tab.

Delete a List

  1. Navigate to the model which contains the list you want to delete.
  2. Click the Lists tab.
The lists already defined display.
  1. Among the defined lists, find the list you want to delete.
  2. Click Delete on the same line as the list you want to delete.
The list disappears from among the defined lists.

This last step is important! If you click Delete, but do not click Save All Changes, the list is not deleted.

  1. Click Save All Changes.

Rules Overview

Rules determine which instances of a model are valid. Use rules to ensure that the options a customer chooses when configuring a product model are valid. Rules can be simple or complex. For example, a simple rule specifies that a particular option item must not weigh more than 100 grams. A more complex rule specifies that one option item must not weigh more than 100 grams OR another option item must not weigh more than 50 grams AND the material must be steel.

A rule consists of one or more fragments and an action. The action can be a message action (messages that display), an expansion action (items that are added), or an assignment action (properties that are assigned). Rules can determine whether or not additional selections appear for a customer when they make certain choices (expansion action).

You define and attach rules to specific points in your model hierarchy. The rules fire when a customer chooses an option item. You can create your own rule classifications. Rule priorities determine the order in which rules are fired: lowest numbers fire first. Use values between 0 and 100: 50 is the default value.

Each time a model is validated, the rules fire to determine whether each rule succeeds or fails. You can control the order in which rules fire by setting a priority for each rule. Rules with lower priority value fire before rules with a higher priority value. The default value is 50.

When you test a model, you can review the model firing behavior. You can also specify whether rules are fired just once or possibly multiple times.

Define a Rule

  1. Navigate to the detail page for the model group or model where you want to create the rule.
  2. Click the Rules tab.
If you are defining the rule at the model level, then the Rules tab displays two tabs: Attach and Define. Click the Define tab.
The model group level contains a single tab for defining the rule.
  1. Click New....
The New Rule tab displays.
  1. Select a classification for the rule and specify a priority.
  2. Enter a name and description for the rule. Also, select whether the rule is triggered when the rule's conditions are met (success) or not met (failure).
  3. Define the fragments of the rule.
  4. Define the rule actions.
You can define messages to display, a rule expansion formula, or you can assign properties and values.

No syntax checking is performed on rules. The configurator engine will fail to load a model if there is a syntax error in any of the assigned rules.

  1. Click Save.

Modify a Rule

  1. Navigate to the model group or model where the rule was created.
  2. Click the Rules tab.
The Rules tab for the Model level displays two tabs: Attach and Define. To modify the rule, click the Define tab. The model group level contains a single tab for defining the rule.
The Rules tab displays a table with the currently defined rules.
Click Where Used at the bottom of the tab to view the entities to which the rule is attached.
  1. Find the rule you want to modify, then click the Edit icon.
The Edit Rule tab displays.
  1. Modify the rule. You can modify the following rule attributes:
Name and Description
Comments
Whether the rule is triggered when the rule's conditions are met (success) or not met (failure)
Rule fragments in the Fragments table
Actions in the Actions area
  1. Define messages to display, a rule expansion formula, or assign properties and values.

Create a Rule Classification

  1. Navigate to the rule creation page.
  2. Click ... next to the Classification drop-down list.
  3. In the Rule Classification Window, enter a name for the classification, and click Add Item.
  4. Click Save and Return.

Attach a Rule

  1. Navigate to the level in the model hierarchy (model, option class or option item) where you want to attach the rule.
  2. Click the Rules tab.
At the model level, the Rules tab contains two tabs: Attach and Define. At the option class and option item levels, the Rules tab looks like the Attach tab.
The Attach tab displays a drop-down list of the unattached rules, as well as a table showing the rules that are currently attached.
  1. Select a rule from the drop-down list in the Unattached Rules table.
  2. Click Attach.
The rule is appended to the end of the current rules in the Attached Rules table.
  1. Define the start and end dates for the rule.
  2. To set this rule as a checkpoint, check the Stop Firing column box.
If any errors occur up to this point in the rule firing, processing stops and the errors display. If no errors occur, rule firing continues until all the rules are fired or the next checkpoint is hit.
  1. Determine the sequence.
The rules fire within the element to which they are attached in the order they appear in the list. You can modify the order using the up or down arrows to the right of the rule.
  1. Click Save All Changes.

View the Details of an Attached Rule

  1. Navigate to the level in the hierarchy (model, option class, or option item) where the rule is attached.
  2. Click the Rules tab.
At the model level, the Rules tab contains two tabs: Attach and Define. At the option class and option item levels, the Rules tab looks like the Attach tab.
The Attach tab displays a drop-down list of the unattached rules, as well as a table showing the rules that are currently attached.
  1. Find the rule among the list of attached rules in the lower part of the frame.
  2. Click the name of the rule.
The Rule Detail Viewer displays.

View Rule Attachments

  1. Navigate to the model group or model where the rule was created.
  2. Click the Rules tab.
The Rules tab for the Model level displays two tabs: Attach and Define. To modify the rule, click the Define tab. The model group level contains a single tab for defining the rule.
The Rules tab displays a table with the currently defined rules.
  1. Find the rule you want to modify, then click the Edit icon.
The Edit Rule tab displays.
  1. Click Where Used....
The Rule Usage window displays.

Unattach a Rule

  1. Navigate to the level in the model hierarchy (model, option class or option item) where the rule is attached.
  2. Click the Rules tab.
At the model level, the Rules tab contains two tabs: Attach and Define. At the option class and option item levels, the Rules tab only contains attachments.
The Rules tab displays a drop-down list of the unattached rules, as well as a table showing the rules that are currently attached.
  1. Find the rule in the Attached Rules table.
  2. Click the Delete symbol (X) at the end of the rule's row in the table.
The rule returns to the Unattached Rules table.
  1. Click Save All Changes.

Delete a Rule

You cannot delete a rule if the rule is currently attached to any node in the model hierarchy.

  1. Navigate to the model group or model where you created the rule.
  2. Click the Rules tab.
At the model level, the Rules tab contains two tabs: Attach and Define. At the model group level, you can only define. If the rule you want to delete was created at the model level, then click the Define tab.
  1. Find the rule you want to delete.
  2. Click the Delete icon next to the rule you want to delete.
  3. Click Save All Changes.

Move or Copy a Rule

Moving a rule means that the rule definition is deleted from its previous location. Copying a rule means that you create a copy of the rule without deleting its original definition.

  1. Navigate to the rule definition that you wish to move or copy.
  2. Click Copy Rule.
  3. Click Browse... to open the entity picker window.
  4. Navigate to the model group or group to which you want to move or copy the rule definition, select it, and click Done.
  5. If you want to, you can change the name of the rule definition.
  6. Click Move or Copy as appropriate.
An error message displays if a rule with the same name already exists in the target location. If a property referenced in the rule does not exist in the new location, it is created at the same time as the rule is.
  1. Click Close.

To Specify the Rule Firing Sequence

  1. Navigate to the model.
  2. Click the Rules tab.
  3. Click the Firing Sequence sub-tab.
  4. Enter a priority for each rule: this should be an integer between 0 and 100.
The higher the value of the priority, the lower is the priority: rules with lower priority value fire before rules with a higher priority value. The default value is 50.

To Review Rule Firing

  1. Navigate to the model whose rule firing you want to review.
  2. Click Test.
  3. In the Product Configurator window, click Show Trace Log.
  4. The secondary window displays a trace of the results of the rule firing. You can review this to determine if rules are firing as you expect.

To Control Rule Firing

When the Configurator validates a model and the current set of picks, it tests each rule in turn to evaluate for success or failure, and performs expansion and assignment actions as appropriate. The property CONFIG: REPEAT FIRING controls rule firing.

Rule firing can behave as follows:

Single-pass rule firing: each rule is tested only once during model validation. Single-pass rule firing is the default.
Multiple-pass rule firing: you can configure a model so that if any rules are fired, the fired rules are removed from the rules list and the remaining rules are tested again. This process continues until no more rules are fired.

To Set Multiple-Pass Rule Testing

  1. Navigate to the model whose rule firing you want to control.
  2. Click Properties.
  3. Select CONFIG: REPEAT FIRING from the Unattached Properties drop-down list.
  4. Set its value to ''true'' and click Attach.
  5. Click Save All Changes.

You can examine the trace log to verify that the rules fire only once. In the summary section of the trace log, you should see that there was one firing phase.

Rule Fragments and Actions Overview

A rule consists of one or more fragments and an action. Rule fragments perform the rule logic. Rule actions define what happens as a result of rule fragment evaluation.

Rule actions can be:

Message Actions: Displays a message when the rule is triggered.
Formula and Expansion Actions: Defines an expansion action based on a rule expansion formula.
Assignment Actions: Assigns the value calculated by the rule formula to one or more properties when the rule is triggered.

Click the arrow icon to toggle the visibility of sections of the Fragments area and to enable working with fragments. For example, click the arrow to display the foreach section:

The following buttons display in the Fragments area of the New Rule tab:

Button
Name

New Operator button

New Fragment button

Delete button

Edit button

Click the New Operator icon to create a nested level for creating fragments. The new level displays a new set of New Fragment and New Operator links. You use this New Fragment link to create the fragments at this nested level. If you click New Operator at this level, you create another nested level below the current level with its own set of New Fragment and New Operator links.

Click the New Fragment icon to create a fragment at the current level (in this case, the top level) in the rule structure. Click New Fragment again to create a second fragment at the current level. For example:

FragmentA AND FragmentB

Click Delete to delete the fragment.

Click Edit to modify the fragment.

Foreach Rule Modifier

The foreach rule modifier applies a rule to elements of a model that meet a specified condition. The rule specifies a condition and the action to take if the condition is met: for each element in the model that meets the condition, the Product Configurator takes the specified action. You can apply the foreach rule modifier to each element of the model whether or not the customer selects it, or only to elements that the customer selects.

The foreach rule modifier is basically a scope modifier for a rule condition. When there is no scope defined, the rule condition's scope is properties in the property pool. The rule first looks in the property pool at the properties attached to the node to which the rule is attached. To expand the scope of the rule condition, you click the condition expansion icon. Scope expansion operates by describing a property to search for and a temporary property to hold the current value each time the rule is fired. The UI presents:

foreach {propertyOne} as {propertyTwo}

Which means:

For every item in the model that has {propertyOne} attached

Use {propertyTwo} to hold the current value of {propertyOne}

==> evaluate the rest of the rule as if the rule were attached to the item that has {propertyOne} attached

The scope modifier can apply to properties in the property pool only (which contains only the properties of those option items selected by the user) or it can search over properties anywhere in the model regardless of whether the item is selected or not.

You set whether the foreach rule condition modifier traverses the entire model, or traverses only the properties of option classes or option items that the user selected and are in the property pool, by clicking the anywhere in the model checkbox.

For example, suppose that you want to define a rule to display appropriate food choices for a particular lifestyle. If the customer chooses "healthy", they see only healthy choices such as broccolli, brown rice, and granola. If the customer chooses "unhealthy", they see only unhealthy choices such as cheesy scalloped potatoes, donuts, and hot dogs.

You define several option classes: Lifestyle, Breakfast, Lunch, and Dinner. Within those option classes, you define the option items (choices): healthy or unhealthy for Lifestyle; granola, fruit, donuts, and crispy bacon for Breakfast; salad, tofu, chili-cheese fries, and hot dogs for Lunch, and so on. You define a property on the Lifestyle choices to indicate the customer's lifestyle choice: lifestyleChoice, which has the value healthy or unhealthy. To enable matching the customer's food choice with their lifestyle choice, you define a property on each of the food choices, foodType, which has the value healthy or unhealthy. The rule checks the lifestyleChoice property against the foodType property to determine whether or not to display a particular food choice.

You can attach the rule to each option item in the model to which the rule applies, but if you add option classes or option items, every time you add a new option class or option item, you must attach the rule to the new option class or option item. A simpler method is to attach the rule to one point in the model, and check the "anywhere in the model" checkbox. When you compile the model, the Product Configurator automatically applies the rule to each of the model's option items.

Example: To Create a Simple Level of Fragments

In this example, you create a rule consisting of two fragments joined by a single operator, with no nested levels: FragmentA AND FragmentB. When you access the tab, the New Rule tab displays.

  1. Select the boolean operator required for these fragments.
  2. Click the New Fragment icon
The New Fragment tab displays.
  1. Define the fragment.
Check the Not check box to define the fragment as a negative: "NOT (sum(PropertyA <= 250))".
Select the first function from the Function1 drop-down list.
Select a property from the Property1 drop-down list.
Select the operator.
Select the second function from the Function2 drop-down list.
In the Property2 field, select a property from the drop-down list or enter a literal value in the field (if you selected "literal" as the function).
Select the value for the If Not Specified drop-down list.
  1. Click Save and Return.
The New Rule tab re-displays with the new fragment. Note the infix representation.
  1. Click the New Fragment icon to create the next fragment in the rule.
  2. Repeat step 3 to define the second fragment.
  3. Click Save to save the rule and continue defining the rule. Click Save and Return to return to the list of rules in the Define tab.Click Save and Return.

Example: To Create Nested Fragments

In this example, the modeler is creating the following rule with nested fragments:

(FragmentA AND FragmentB) OR (FragmentC AND FragmentD)
  1. Click New Operator icon.
A nested level appears in the New Rule tab. This level has its own drop-down boolean operators, as well as its own New Fragment, New Operator, and Delete Operator icons.
  1. Create two fragments.
Use the nested drop-down list to select the boolean operator for these fragments. The default is AND.
Use the nested New Fragment icon to create the fragments at this nested level.
After the two fragments are complete, the New Rule tab displays.

You can nest as many fragments as you want by clicking the nested New Operator icon. Each time, a new nested operator appears with a new set of nested icons. You use these nested icons to create the fragments for the nested level.

  1. Using the top-level list, select the boolean operator (in this example, OR) to join the two nested levels.
  2. Click the New Operator icon at the top level.
A new nested level appears in the fragments tab. This level has its own drop-down boolean operators, as well as its own New Fragment, New Operator, and Delete Operator icons.
  1. Create two fragments.
Use the nested drop-down list of boolean operators and the nested New Fragment icon for these fragments.
After you complete the two fragments, the New Rule tab displays.

To Modify a Fragment

  1. Find the fragment you want to modify, then click the Edit Fragment icon in the Actions column.
The Edit Fragment tab displays.
  1. Modify one or more elements of the fragment.
Check the Not check box if you want to define the fragment as a negative: ''NOT (sum(PropertyA <= 250))''.
Select the first function from the Function1 drop-down list.
Select a property from the Property1 drop-down list.
Select the operator.
Select the second function from the Function2 drop-down list.
In the Property2 field, select a property from the drop-down list or enter a literal value in the field (if you selected ''literal'' as the function).
Select the value for the If Not Specified drop-down list.
  1. Click Save And Return.

To Delete a Fragment

Find the fragment you want to delete in the Fragments table, then click the Delete icon in the Actions column on the same line as the fragment.

To Create a Message Action

Perform this task in the Message Actions area of the New Rule or Edit Rule tab when you create or modify a rule.

  1. Select the type of message action from the drop-down list: Error, Warning, Suggestion.
  2. Type the message.
  3. Click Add Item.
  4. Repeat these steps to enter additional messages.
  5. Click Save to save the message action and continue editing. Click Save and Return to save the message and return to the Define tab.

To Create an Expansion Action

Perform this task in the Expansion Actions area of the New Rule or Edit Rule tab when you create or modify a rule.

  1. Enter a formula.
The results of the formula are used to perform the expansion.
  1. Enter a minimum and a maximum amount for the formula result.
The minimum amount is the value the rule formula result must be greater than. The value can be negative or greater than, or equal to zero. The value must be less than the maximum value (Max). The maximum amount is the maximum value the rule formula result must match. This value must be greater than the minimum value (Min).

Min and Max work slightly differently: for a fragment to evaluate to true, the rule formula must evaluate to greater than the Min value, but less than or equal to the Max value.

  1. Enter the quantity of the expansion items (must be greater than zero). You can use the supported functions to calculate the quantity and so you can specify the quantity as a function of a property. For example:
2*value(Memory Cards)
  1. Enter the item that you want to expand.
Provide the full path to the expansion item within the current model.
You can use a rule in multiple models, which has implications for specifying the full path name. To facilitate the use of expansion rules across multiple models, you can use special symbols as follows:
Begin the path with a period (.), which means ''from the attachment point of the rule''. For example, ".Memory.64MB" means "an option item called 64MB in an option class called Memory in the current model".
Begin the path with an asterisk (*), which means from the root of the model group hierarchy.
If the name of a path component includes a quote character (' or "), you must escape the quote character or wrap the whole expression in quotes. For example, to get the gauge property from the Tubing.3" pipe.threading option item, use:
x = value(Tubing.3\"pipe.threading.gauge)
or:
x = value('Tubing.3"pipe.threading.gauge')
To retrieve Board.8'plank.thickness, use:
x = value(Board.8\'plank.thickness)
or:
x = value("Board.8'plank.thickness")
  1. Repeat these steps to enter additional items.
  2. Click Save All Changes.

The result of an expansion action picks a quantity selected on an option item. If the option item quantity is a drop-down list, ensure that the possible calculated values are consistent with the pickable values: otherwise, the drop-down list will not be able to display the calculated value.

To Create an Assignment Action

Perform this task in the Assignment Actions area at the bottom of the New Rule or Edit Rule tab when you create or modify a rule.

  1. Select a property from the drop-down list. The table below summarizes some of the special properties that can be assigned.
  2. Enter a value for the property. You can use the supported functions to calculate the value and so you can specify the value as a function of a property. For example:
2*value(Memory Cards)
When you assign a value to a property whose type is String, use the following syntax to refer to properties:
${function(arg1, arg2, ..., arg N}
For example, ${expand("Color", "Black", 0)}.
  1. Type the entity to which you want to assign the property and its value.
If you leave this field blank, the assignment defaults to the entity to which the rule is attached.
  1. Click Add Item.
  2. Repeat these steps to add additional items.
  3. Click Save All Changes.

The following table summarizes some of the available properties for assignment.

Property
Action
_constraintMessage
String: a message on an item because it is constrained
_constraintType
Integer: type of constraint; 0 is suggest, 1 is warn, and 2 is error
_description
String: an items description
_amEntitled
Integer: 0 false, 1 true
_isConstrained
Integer: 0 false, 1 true
_isSelected
Integer: 0 false, 1 true
_isViewable
Integer: 0 false, 1 true
_itemKey
Integer: database key of the item
_pickOverride
Integer: 0 false, 1 true; pick was overridden by a rule
_quantity
Integer: quantity; 0 quantities are not in the rule pool
_ratio
Numeric: ratio of this item to its children, computed if nested within another parent
_rawRatio
Numeric: raw ratio used in previous computation
_rulePick
Integer: 0 false, 1 true
_tabLevel
Integer: depth of this item

Example: Usage of the Expand Function

The syntax of the expand function is:

${expand(property[,defaultValue[,format[,lookup]]])}

For example, suppose that you want to display the name of the model as the name of the associated product together with the product description. At the model level, set the value of the UI: DISPLAY NAME property to:

${expand("UI: PRODUCT NAME")}

or:

${expand("UI: PRODUCT DESCRIPTION","Description not available")}

If the product name or description changes and you recompile the model, the name or description displays with the new version when users next configure the product.

Here are more examples of the expand function:

String-valued property:
${expand("color")}
${expand("color", "Black")}
Numeric-valued property:
${expand("weight")}
${expand("weight", 0.0)}
${expand("weight", 0.0, #.00)}

Option Constraints

Constraint tables enable you to limit a customer's choice of one or more option items based on the customer's choice of another option item. For example, the choice of an exterior color for a car limits the choice of interior colors.

You create an option constraint by creating a constraint table. You define constraint tables at the model level. After you create a table and the option classes that will provide the constraints, you define the constraints. Each row in the table represents a constraint.

Create a Constraint Table

  1. Navigate to the model where you want to create the constraint table.
  2. Click the Tables tab.
Two tabs display: General Info and Records. The General Info tab displays general information about the table displayed in the Table Name field.
  1. Click New....
The Create New Constraint Table tab displays.
  1. Enter a Table Name, a Description, and a date range (Start Date/End Date) for the table. (You can click the Calendar icon to select dates from the calendar.)
  2. Enter a message.
The message appears when the customer makes a selection that is incompatible with a constraint defined in the table.
Select the message type: error, warning, or suggestion.
Enter the message in the Message field.
  1. Click Save Changes.

The Tables tab re-displays with the new table in the Table Name field. Next, create the option constraints that are a part of the table using the Records tab.

Modify a Constraint Table

  1. Navigate to the model that contains the table you want to modify.
  2. Click the Tables tab.
  3. Select the table from the Table Names drop-down list.
  4. Modify the table. You can:
Define option constraints.
Modify option constraints.
Delete option constraints.
Modify the name, description, or effectivity dates in the General Info tab.
Modify the error/warning/suggestion message in the General Info tab.

Define Option Constraints

  1. Navigate to the model that contains the table for which you want to define the constraint.
  2. Click the Tables tab.
Two tabs display: General Info and Records. The General Info tab displays general information about the table displayed in the Table Name field. The Records tab is where you define the constraints.
  1. Select the table from the Table Names drop-down list.
  2. Click the Records tab.
The currently-defined option constraints display.
  1. Add columns to the constraint table.
Select an option class from the Table Column name drop-down list.
The drop-down list includes all the option classes that belong to the model, including any nested option classes and option classes that are part of option class groups attached to the model. The drop-down list displays the path to the option class relative to the model.
Click Add.
The column name is added to the table.
  1. Define an option constraint.
Click New Constraint to add a new row to the table.
Click Edit.
The option classes display as table columns, along with their option items.
The option items that display include any option items belonging to an any option item group attached to the option class.
Define compatibility ("Selected Values are all"). For example, will the selections you make in one column be valid or invalid with the selections in the other column(s)?
Select one or more option items in each column.
Click Save.

Modify an Option Constraint

  1. Navigate to the model that contains the table with the constraint you want to modify.
  2. Select the table from the Table Names drop-down list.
  3. Click the Records tab.
The currently-defined option constraints display.
  1. Find the constraint row you want to modify and click Edit.
The constraint information displays.
  1. Modify the constraint information.
Modify compatibility.
Will the selections you make in one column be valid/invalid with the selections in the other column(s)?
Modify the option items in each column.
Click Save.

Delete Option Constraints

  1. Navigate to the model that contains the table with the constraint you want to delete.
  2. Click the Tables tab.
  3. Select the table from the Table Names drop-down list.
  4. Click the Records tab.
The currently-defined option constraints display.
  1. Find the constraint row you want to delete.
  2. Click Delete (X).

Delete a Constraint Table

  1. Navigate to the model that contains the table with the constraint you want to delete.
  2. Click the Tables tab.
  3. Select the table from the Table Names drop-down list.
  4. Click Delete.

Import and Export Models

You can import model groups and models in the form of XML files. You can either import the entity relative to its original root model group, or you can designate a location into which to import. The model appears in the Navigation frames, and you can add to or modify the imported model.

To Import Model Groups and Models

  1. Navigate to the Visual Modeler page.
  2. To import to a selected point, navigate to the model group within which you want to import the file.
  3. Click Import in the toolbar.
The Visual Modeler Import window displays.
  1. Click Browse... to find the XML file you want to import.
When you select the file, the file displays in the field along with the complete path to the file.
  1. Select the import option.
Import with its original structure relative to its root model group
The Import process ignores any Destination Model Group indicated at the top of the window.
Import into the selected destination model group
  1. Click Import Now.

To Export a Model Group or Model

  1. Navigate to the model group or the model that you want to export.
  2. Click Export in the toolbar.

You can either open the XML file at its current location, choosing a desired text processing tool, or you can save the file to a desired location.

Using Dynamic Instantiation

Dynamic instantiation enables users to configure products on the fly and avoids having to create option items for each possible product configuration in your model. For example, consider a server rack. The user can decide on the number of slots they need and create dynamic instantiation controls for each type of component, such as servers and storage arrays that can fit into a slot, AC or DC power, and so on. As the modeler, you create the rack model, then create option classes for each of the rack's configurable features (such as servers and storage arrays) and set them as dynamic instantiation control classes. A user buying computer racks navigates to the rack product on your site and clicks the Configure button next to the servers and storage array choices. This adds a new option item to the model for that configurable feature. To configure each option item, the user clicks the Configure button that appears next to each added item. After the user adds and configures the entire rack and all the configurable features, the user clicks the Add button to add the rack to their cart.

  1. On the Model Group Navigation page, click New Model.
The New Model page displays.
  1. Enter a name for the model, then click Save and Edit.
The Model Navigation page for the new model displays.
  1. Click New Option Class.
The New Option Class page displays.
  1. Enter a name for the new option class, then click Save and Edit.
  2. Click the Display tab, then choose Dynamic Instantiation from the UI Control drop-down list.
Set other Display properties as appropriate, then click Save All Changes.
  1. Click the Properties tab, then set the following properties from the Unattached Properties drop-down list:
CONFIG: SUBMODEL NAME
Enter the name of an existing submodel for the property value, then click Attach.
CONFIG: SUBMODEL RETURN
Enter the name of an existing submodel to which the end-user should return after clicking the Add button, then click Attach.
  1. Click Save All Changes.
  2. Return to the new model's root node, then click the Compile and Test icon to test your dynamic instantiation option class.

Search

You can search for entities that contain properties and property values that you specify as parameters. You can search across the entire hierarchy, you can limit your search to model groups, models, option classes, option items, and rules, or you can limit your search even further to the currently selected model or group.

To Search for Entities

  1. Access the Visual Modeler page.
  2. To search within a specific model or group, navigate to and select the model or group.
  3. Click Search in the toolbar.
The Search window displays.
  1. Select the scope for the search from the Search drop-down list.
  2. Enter a property name or a property value or both.
Click Browse... to display a browser window to select a property from a list of all the properties in the Visual Modeler.
Use the drop-down list to select AND or OR. Select AND to produce search results that include both the Property Name and Property Value parameters you select. Select OR to produce search results that include either parameter.
When you enter a property value, the search results include property values that contain the property value you enter. For example, if you enter "75", the search results include any properties with the value "75" as well as property values such as "7550-1" or "MX-75-1".
  1. Click Search.

The search results display below the parameters. By default, the result is sorted in ascending order by property name. You can click one of the following columns to sort:

Property Name
Value
Location

When you click the column title the first time, the column is sorted in ascending order.

Reports

You can run a report on a model that you specify. You can select the types of information you want in the report:

Rule definitions
List definitions
Property definitions
Display Settings
Attached Properties
Attached Rules
Expand Groups

To Run a Report

  1. Access the Visual Modeler page.
  2. Click Report in the toolbar.
The Report Entry window displays.
  1. Enter the model you want to report on.
You can click Browse... to find and select the model in the model hierarchy.
  1. Select the locale in which you want to run the report.
  2. Select a date to report.
This produces a report for the models with effectivity dates within the specified date range.
  1. Select the information you want to include in the report.
  2. Click Run Report.

© 2011 IBM Corporation. All Rights Reserved