Please note : This help page is not for the latest version of Enterprise Architect. The latest help can be found here.

Define Rule Conditions

Model Rule Conditions in the Rule Conditions Section



See also


The Business Domain model defines the business terms (such as Customer) and their associated attributes; from the appropriate Class element in the Project Browser, drag and drop the required condition attribute (such as age) or operation (such as IsValidLicense()) onto the Rule Conditions column.

The Rule Condition field enables you to use intellisense to display a list of possible entries for the field; press ( Ctrl+Spacebar ) in the field to display the list of entries
If the Rule Condition is of type enum, the Allowable Values fields are automatically set with the enum literals; the procedure then ends here.




Determine a range of accepted values for the Rule Condition.




Right-click on the Allowable Values column and select the Edit Allowable Values context menu option; the Edit Allowable Values dialog displays.

Type each required value or range of values in the Value field, and click on the Save button to display the value in the Allowable Values list box
age could have the values:
>18 and <50
IsValidLicense() could return:




Click on the OK button to save the values and close the dialog; a new constraint AllowableValues is created for the attribute.

You can check this constraint by opening the Properties dialog for the attribute and selecting the Constraints tab
If the Rule Condition references an enumeration, the enum literals are not editable in the Edit Allowable Values dialog.




If the Rule Condition is an operation, you can pass parameters to it.

Right click on the Allowable Values field, and select the Edit Parameters context menu option; the Edit Parameters dialog displays.

Select the parameters and type their values into the Value text box; click on the OK button to cancel the dialog.

You can add an operation as a Rule Condition more than once, to allow calling the operation with different sets of parameters
To add another Rule Condition, right-click on the No column and select the Add Row context menu option; an empty row is added to the table.


To remove a Rule Condition from the table, right-click on the appropriate No field and select the Delete Row context menu option; this does not affect the original attribute or the new constraint in the model.

You can either re-use the attribute with its constraint, or use the attribute Properties dialog to remove the constraint.