Previous Table of Contents Next


6.2 Metadata Architectures

   The central theme of the MOF approach to metadata management is extensibility. The aim is to provide a framework that supports any kind of metadata, and that allows new kinds to be added as required. In order to achieve this, the MOF has a layered metadata architecture that is based on the classical four layer metamodeling architecture popular within standards communities such as ISO and CDIF. The key feature of both the classical and MOF metadata architectures is the meta-metamodeling layer that ties together the metamodels and models.

   The traditional four layer metadata architecture is briefly described below. This is followed by a more detailed description of how this maps onto the MOF metadata architecture.

6.2.1 Four Layer Metadata Architectures

   The classical framework for metamodeling is based on an architecture with four meta- layers. These layers are conventionally described as follows:

    The classical four layer meta-modeling framework is illustrated in Figure 6.1 on page 10. This example shows metadata for some simple records (i.e., “StockQuote? instances) along with the “RecordTypes? metamodel for describing and the hard-wired meta-metamodel that defines the metamodeling constructs (e.g., meta-Classes and meta-Attributes).

   While the example shows only one model and one metamodel, the main aim of having four meta-layers is to support multiple models and metamodels. Just as the “StockQuote? type describes many StockQuote instances at the information level, the “RecordTypes? metamodel can describe many record types at the model level. Similarly, the meta-metamodel level can describe many other metamodels at the metamodel that in turn represent other kinds of metadata describing other kinds of information.


   


meta-metamodel

   Hard-wired Meta-metamodel

   MetaModel ( “RecordTypes?, MetaClass ( “Record?,[ MetaAttr ( “name?, String),metamodel MetaAttr ( “fields?, List < “Field?> ) ] MetaClass ( “Field?, ... )

   Record ( “StockQuote?, [ Field ( “company?, String ) model Field ( “price?, FixedPoint ) ] )

   StockQuote (“Sunbeam Harvesters?, 98.77)StockQuote (“Ace Taxi Cab Ltd?, 12.32)

   information

   ...

   Figure 6.1 - Four Layer Metadata Architecture

   The classical four layer metadata architecture has a number of advantages over simple modeling approaches. If the framework is designed appropriately, it can:

6.2.2 The MOF Metadata Architecture

   The MOF metadata architecture1 , illustrated by the example in Figure 6.2, is based on the traditional four layer metadata architecture described above. This example shows a typical instantiation of the MOF metadata architecture with metamodels for representing UML diagrams and OMG IDL.

   1. One could argue that the term “architecture? is an inappropriate in this context. After all, the MOF metadata “architecture? is little more than a way of conceptualizing relationships between data and descriptions of data. Certainly, there is no intention the “architecture? be used as a benchmark for MOF conformance. However, the term has been used in MOF discussion for a long time, so the reader must forgive any perceived inaccuracy.


   Figure 6.2 - MOF Metadata Architecture

   The MOF metadata architecture has a few important features that distinguish it from earlier metamodeling architectures:

   The self-describing nature of the MOF Model has some important consequences:

6.2.3 MOF Metamodeling Terminology

   There is enormous scope for confusion if standard metamodeling terminology is used in the MOF specification. To avoid this and to make it easier to read, we have opted to simplify the terminology. Some particular points of confusion are as follows:

   To avoid some of this confusion, we generally try to avoid using the “meta-? prefix. In particular, while the core of the MOF is a meta-metamodel (assuming that there are 4 meta- layers), it is referred to as “the MOF Model.? Similarly, rather than using terms like Class, MetaClass, and MetaMetaClass, we use phraseology like “an M1-level instance of an M2level Class.?

   The meta-level numbering used in the remainder of this specification (for example, M2-level or M1-level) should be read as top down labels relative to the MOF Model at M3-level. We assume that the reader can mentally relabel the meta-levels to fit the context; for example, in contexts where the MOF Model is not at M3-level, or when applying the IDL mapping to the MOF Model itself.

   NOTE: Even the M1- / M2- terminology above has proved to be confusing to some readers. However, since changing the terminology again will take significant effort and cause considerable disruption, further work on this has been deferred until a clearly superior terminology is proposed.

   There are three cases where it is convenient to use the “meta-? prefix as part of MOF terminology:

   In each case, the term is used across all meta-levels and has a deliberately imprecise meaning.

   The core modeling concepts in the MOF use terms that are also used in UML with similar meanings. For example, a MOF Class corresponds to a UML Class, a MOF Attribute corresponds to a UML Attribute, and a MOF Association corresponds to a UML Association. However the correspondence is not always a direct match. For example, UML Associations may have many AssociationEnds, but MOF Associations must have precisely two.