MDT/UML2/New and Noteworthy/Kepler
MDT UML2 New and Noteworthy items for the Kepler release.
This milestone was completed on February 4, 2013.
The UML exporter now supports references to existing UML models instead of redundantly exporting duplicate UML resources.
The "at most one return" constraint for operations is now evaluated by the UML validator.
The OccurrenceSpecification::covered upper bound constraint (which redefines the upper bound from InteractionFragment::covered) is now enforced by the UML validator.
A new 'XMI Identifiers' option has been added to the Ecore to UML converter. When enabled (by setting the option to "PROCESS") the converter will assign "consumable" XMI identifiers to the resulting UML elements.
The UML importer for EMF models now uses the mapped resource locator (provided by EMF) to more efficiently look up repeated pathmap references.
New addToContainmentList(Element, EObject) and removeFromContainmentList(Element, EObject) methods have been added to the StereotypeApplicationHelper base class.
The UML2 code generator has been enhanced to generate a "DerivedUnionAdapter" utility class which can be used to obtain notifications when a feature that affects the value of a derived union has changed. Such an adapter (UMLDerivedUnionAdapter) has been generated for UML and can be found in the org.eclipse.uml2.uml.util package.
This milestone was completed on March 18, 2013.
A new 'Foreign Definitions' profile definition option has been introduced to support "foreign definitions". When enabled (by setting the option to "PROCESS"), the resulting profile definition will reference the definitions of elements from any referenced profiles instead of redefining them anew. This option supports application of cross-referenced stereotypes to elements in different models, provided that both the referring and referenced models/profiles are loaded into the same resource set and modified/saved at the same time.
Of course, one must be careful with this option, as it allows creation of dependencies between different (versions of) profile metadata in different profiles. Particular care must be used when creating generalization relationships that span profiles and when defining and applying new versions of classes and stereotypes independently of models and/or profiles that may be referencing them.
The UML to Ecore converter has been enhanced with new options to support validation and invocation delegates, and the UML2 code generator has been modified to work with them.
When enabled (by setting the option to "PROCESS"), the 'Validation Delegates' option will result in generated code that uses an OCL validation delegate to evaluate OCL constraints. Note that this option only takes effect if/when the 'Invariant Constraints' option is also enabled. See http://wiki.eclipse.org/EMF/New_and_Noteworthy/Helios#Support_for_Validation_Delegates for more information on validation delegates.
When enabled (by setting the option to "PROCESS"), the 'Invocation Delegates' option will result in generated code that uses an OCL invocation delegate to implement OCL query operations. Note that this option only takes effect if/when the 'Operation Bodies' option is also enabled. See http://wiki.eclipse.org/EMF/New_and_Noteworthy/Helios#Support_for_Operation_Invocation_Delegates for more information on invocation delegates.
This milestone was completed on May 6, 2013.
The sample UML editor now qualifies edit labels with the objects' containing resource so that elements with the same qualified name (but from different resources) can more easily be distinguished.
The commands for copy, cut, and paste have been specialized in the context of the sample UML editor to handle cutting, copying, and/or pasting stereotype applications. Stereotype applications for the copied/cut elements are pasted to the target resource iff the same version of the associated profile is applied in the resulting context. This means that the specific version of the containing profile(s) must be applied either to a package in the hierarchy of the elements being copied/cut or to a package in the hierarchy of the target to which the elements are being pasted.
UML2 now preserves additional redefinition details (lower bound, upper bound, and type) when a UML model is converted to Ecore.
The UML2 code generator has been enhanced to leverage this information to provide better support for redefined types and multiplicities. More specific type constraints are now enforced in redefining classes and narrower multiplicities are now enforced via overrides in the generated validator.
Better code generation support for explicit redefinitions has also been provided and the eIsSet(int) method is now being correctly overridden to delegate to isSet*() methods for redefined features.
The sample UML editor now uses a qualified text provider for stereotype application edit labels so that it's easier to tell which stereotype application has which element as its base element when selecting a stereotype application as a value.
The control/uncontrol action has been customized in the sample UML editor (actually in its action bar contributor) so that stereotype applications are moved to/from "fragment" resources when their base elements are controlled/uncontrolled.