- Tech know how online

meta model

A metamodel is a model that models the concepts of a modeling technique, i.e., the model elements that can be used and their interrelationships. A metamodel thus provides a formalized description of models that reflects the structure of a domain. A metamodel is also the fundamental basis of a modeling language, which also consists of an abstract syntax, static semantics, and concrete syntax. In turn, a metamodel is described by a model - the so-called metametamodel.

A well-known example of a metamodel is the Unified Modelling Language (UML), whose metamodel in turn is the Meta Object Facility (MOF). Likewise, a class in the Javaprogramming language is a metamodel, which in turn is defined by the Java programming language as a metametamodel. Metamodels are an important prerequisite in the context of model-driven software development (MDSD), whereby executable software is generated from formal models using an automated process. In addition to UML as a modeling language for models of applications, the Object Management Group (OMG) has standardized the Common Warehouse Metamodel (CWM) for modeling data. For this purpose, four so-called meta-layers were defined by the OMG.

The term metamodel was derived from the Greek prefix meta, which can be translated as above, beside or behind. A model serves to abstract reality, for the creation and description of which a language is required. For this purpose, the rules as well as the grammar of this language must also be defined. Exactly these languages are defined in so-called meta-models, which in turn are themselves written in a meta-language.

Process of Model Building

The classical process of model building leads from one problem domain at a time to a model of the model domain. Metamodeling describes the modeling technique used in the model domain in a model. The concept of a modeling technique includes the model elements that can be used and their interrelationships. A metamodel is explicitly not a model of a model, but a model of a model domain, i.e. a set of similar models - especially models created according to the same technique.

If a metamodel is to define the elements and constructs of a modeling technique precisely, the elements and constructs of the metamodel must be specified just as precisely. This requires the metamodel of a metamodel - this is sufficiently called a higher metamodel or meta-metamodel. Insofar as one follows this idea, this form of definition leads to an infinite sequence of metamodels. Since this does not make sense, the OMG has standardized the Meta Object Facility (MOF) as a meta language and, as it were, the highest instance of meta modeling.

Structure of Models and Languages

Structure of Models and Languages

The figure shows the structure of models and languages from the OMG point of view. According to this, the metamodel does not have a superordinate metalanguage. The layer model defines the respective lower level as an instance of the higher level. Thus, the M2 level contains the instances of the constructs defined at the M3 level. In general, a metamodel defines itself, which means an identity with its meta-metamodel. Higher level metamodels are generally only needed when several, different model domains, each described separately in a metamodel, are to be represented by a common model.

M3 met amodel This top layer has the highest abstraction and defines the Meta Object Facility (MOF) according to the OMG specifications. The elements of MOF such as MOF Class, MOF Attributes, MOF Associations are used to define metamodels. Thus, the MOF layer specifies an abstract language to develop other modeling languages. Thus, all other modeling languages such as UML or CWM are instances of MOF.

M2 metamodel: This layer contains the metamodels that are described with the help of MOF constructs, each of which in turn specifies an abstract syntax and semantics. At this level, the OMG defines the two languages - UML and CWM - which are then used to model at the M1 level below. Often, however, the elements of the modeling languages, such as UML, are not sufficiently expressive for domain-specific modeling. This is then the approach for so-called UML profiles, which then extend the existing language scope of the UML in order to be able to adapt it to particular technical or business domains.

M1 model. This is where the models for representing the abstraction of a real system are stored.

MOF levels of metamodeling

MOF levels of metamodeling

As shown in the figure, the models are modeled using the UML - and any necessary profiles - or the CWM - here there is the OLAP profile. Thus, each model - for example, the UML model of a software application - is an instance of the metamodel.

M0 instance This layer represents the running system with its different states and real instance in memory. The objects at this layer represent instances of M1 objects and thus ultimately represent the real entities. The example of a book titled "UML" shown in the figure is an instance of the class Book modeled in the M1 layer. The properties of this book are then defined in the layer M1 above.

Informationen zum Artikel
Englisch: meta model
Updated at: 28.10.2013
#Words: 1522