Chapter 4 Managing Profiles
Defining a stereotype as a metaclass
Stereotypes can be used to create sub-classifications within a selected metaclass. You can select the Use as Metaclass check box in the stereotype property page and turn the stereotype into a metaclass inside the current metaclass.
The metaclass stereotype feature can be useful when you need to:
- Use the same object for designing different concepts like business transactions and binary collaborations in a BPM for ebXML.
- Have objects with identical names but different stereotypes in the same namespace. A metaclass stereotype creates a sub-namespace in the current metaclass and allows you to have instances with identical names but different metaclass stereotypes in the same metaclass.
Sub-objects
When a stereotype is defined on a sub-object (like a table column or an entity attribute), you cannot turn it into a metaclass stereotype.
The new metaclass stereotype enjoys all the attributes of a standard metaclass:
- List in the Model menu. The list of the parent metaclass will no longer display objects with the new metaclass stereotype. These objects will be displayed in a new metaclass stereotype list, which appears in the Model menu below that of the parent metaclass.
Any new object created in this list has the stereotype defined by default, you can paste an object in this list provided it has the correct stereotype. If you change the stereotype of an object in the list, this object will be removed from the list the next time you open the list.
- Specific folder and command in the Browser: metaclass stereotypes appear in a separate folder in the Browser and there is a specific command in the New contextual menu.
- Specific property sheet title corresponding to the name of the metaclass stereotype.
To define a stereotype as a metaclass:
- Right-click a metaclass and select New→Stereotype in the contextual menu.
A new stereotype is created with a default name.
- Type a stereotype name, select a parent in the corresponding boxes.
- Select the Use as metaclass check box.
- Click Apply.
Copyright (C) 2005. Sybase Inc. All rights reserved.
|
|