Previous Table of Contents Next


6.4 Metamodels and Mappings

   The previous sub clauses outlined the overall metadata architecture for the MOF, and the metamodeling constructs provided by the MOF Model. This sub clause describes the Mapping approach that is used to instantiate MOF metamodels and metadata in the context of a given implementation technology.

   This sub clause is organized as follows. The first sub clause outlines the purpose and structure of MOF Mappings. The next two sub clauses give high-level overviews of the OMG MOF technology mappings defined to date. The final sub clause explains how the standard mappings are applied to the MOF Model to produce the OMG IDL for the MOF Model server and an XML DTD for metamodel interchange.

6.4.1 Abstract and Concrete Mappings

    MOF Mappings relate an M2-level metamodel specification to other M2 and M1-level artifacts, as depicted in Figure 6.6.


   Figure 6.6 - The function of MOF Technology Mappings

    Figure 6.6 depicts the Mapping derived relationships for an application metamodel as follows:

   The Abstract Mapping has two roles: 1) it serves to define the “meaning? of a metamodel, and 2) it provides a point of alignment for current and future MOF technology Mappings.

   Since the IDL and XML Mappings are both aligned with the Abstract Mapping there is a precise one-to-one correspondence between abstract metadata and metadata expressed as XMI documents or CORBA metaobjects. This correspondence holds for all metamodels. More significantly, it should also hold for any future metamodel Mappings (e.g., to Java or DCOM technology) that are aligned with the Abstract Mapping.

6.4.2 The MOF Metamodel to IDL Mapping

   The MOF IDL Mapping produces a specification for a CORBA metadata service from a MOF metamodel specification. The OMG IDL interfaces and associated behavioral semantics are specified in the “MOF to IDL Mapping? clause and “The Reflective Module? clause. These interfaces support creating, updating, and accessing metadata in the form of CORBA objects, either using “specific? interfaces that are tailored to the metamodel or “generic? interfaces that are metamodel independent.

   The MOF IDL Mapping places some additional restrictions in MOF metamodels beyond those set out in the “MOF Model and Interfaces? clause. See 9.5, “Preconditions for IDL Generation,? on page 192 for details.

6.4.3 The MOF Metamodel to XML Mappings

   Interchange of MOF-based metadata is defined in a separate OMG specification. The XMI (XML-based metadata Interchange) specification leverages the W3C’s XML (eXtensible Markup Language) technology to support the interchange of metadata and metamodels between MOF-based and other metadata repositories.

   The XMI 1.1 specification (formal/2000-11-02) has two main parts:

6.4.4 Mappings of the MOF Model

   The MOF IDL mapping has been applied to the MOF Model to produce the normative CORBA IDL for a metamodel repository. The XMI specification has been applied to the MOF Model to produce the normative XMI DTD for metamodel interchange, and a normative rendering of the MOF Model in the interchange format. These and other electronic renderings of the MOF metamodel are described in 4, “List of Documents,? on page 2 .