Previous Table of Contents Next


8.10 Aggregation Semantics

   As noted previously, the MOF Model provides two ways of relating MOF values; that is, Associations and Attributes. In both cases, a relation has a property known as aggregation that determines how strongly related values are tied together.

   The MOF Model currently supports three aggregation semantics; that is, “none,? “shared,? and “composite? in order of increasing strength.

   NOTE: In practice, the semantics of aggregation are mostly concerned with the life-cycles of related values. Since different mappings will use different strategies for managing the life-cycles of values, aggregation semantics are largely mapping specific.

8.10.1 Aggregation “none?

   An Attribute or Association with aggregation of “none? has the weakest form of relation between values. This will typically correspond to independent life-cycles for both parties and the use of shallow copy semantics in a mapping.

8.10.2 Aggregation “composite?

   An Attribute or Association with aggregation of “composite? has the strongest form of relation between values. A “composite? relation involving two types is asymmetric, with one “end? labeled as the “composition? type and the other end labelled the “component? type. An instance of the first type is “composed of? instances of the second type.

   An M1-level “composite? relation is defined to have information model semantics that can be loosely described as containment semantics:

    Other restrictions may apply to “composite? relations in some mappings (e.g., 8.11.2, “The Composition Closure Rule,? on page 155).

8.10.3 Aggregation “shared?

   An Attribute or Association with aggregation of “shared? corresponds to a relation between values that is between “none? and “shared.?

   NOTE: The semantics of “shared? aggregation should correspond to the semantics of an Aggregate in UML. Unfortunately, the OMG UML specification gives no clear guidance on what these semantics should be. As an interim measure, the use of “shared? aggregation in the MOF is discouraged.