|
|
Create Units |
Rhapsody has the concept of a Unit – this is a model element which is stored as a separate file on the hard drive, but it only allows one element at time to be made into a unit. This helper provides an easy way to create units / remove the unit status from multiple elements.
|
Applicable To |
Eligible
Units (various) |
|
Menu
Entry |
Power
Pack Unit Tools Create Units Power
Pack Unit Tools Remove Unit Status |
|
Demonstration |
This helper may also be automatically invoked as a Triggered Helper.
Depending on the menu selected, the helper either applies unit status or removes unit status to all currently selected elements.
Can be used in conjunction with the Browse Potential Units custom browser.
Unit creation rules are optional but allow the creation of units to be prohibited using white or blacklist rules. Rules are defined in properties at project / package level:
RhapsodyPowerPack.CreateUnits.WhiteListRules
RhapsodyPowerPack.CreateUnits.BlackListRules
Both properties allow multiple rules to be defined (separated by semi colons)
Rules have the following format:
[UnitType] : [OwnerType]
· UnitType is either a base term or a new term (e.g. Object)
· OwnerType is a comma-separated list of allowed / disallowed types (depending on whether this is a blacklist or a whitelist)
For example:
· A whitelist of Object:Class would only allow objects under classes to be made into units, objects under packages would violate the rule.
· A blacklist of Block:Block would allow blocks to be created under packages, classes or objects but not under other blocks.
· A whitelist of Object:Class;Block:Package would define two rules, allowing objects under classes to be units and blocks under packages to be units.
A UnitType should only appear in one list but if it is in both the whitelist has priority.
The Model Checker has a custom check to check for rule violations.