Model transformation
Encyclopedia
A model transformation, in model-driven engineering
Model-driven engineering
Model-driven engineering is a software development methodology which focuses on creating and exploiting domain models , rather than on the computing concepts...

, is an automatable way of ensuring that a family of models is consistent, in a precise sense which the software engineer can define. The aim of using a model transformation is to save effort and reduce errors by automating the building and modification of models where possible.

Overview

Model transformations can be thought of as programs that take models as input. There is a wide variety of kinds of model transformation and uses of them, which differ in their inputs and outputs and also in the way they are expressed.

A model transformation usually specifies which models are acceptable as input, and if appropriate what models it may produce as output, by specifying the metamodel to which a model must conform.

Classification of model transformations

Model transformations and languages for them have been classified in many ways.
Some of the more common distinctions drawn are:

Number and type of inputs and outputs

In principle a model transformation may have many inputs and outputs of various types; the only absolute limitation is that a model transformation will take at least one model as input. However, a model transformation that did not produce any model as output would more commonly be called a model analysis or model query.

Endogenous versus exogenous

Endogenous transformations are transformations between models expressed in the same language. Exogenous transformations are transformations between models expressed using different languages. For example, in a process conforming to the OMG
OMG
OMG may refer to:*Oh My goodness, or Oh My Gosh, a common abbreviation used in SMS and Instant Messaging*omg!, a celebrity news and gossip Web site run by Yahoo.com...

 Model Driven Architecture, a platform-independent model
Platform-independent model
A Platform-Independent Model in software engineering is a model of a software system or business system, that is independent of the specific technological platform used to implement it...

 might be transformed into a platform-specific model
Platform-specific model
A platform-specific model is a model of a software or business system that is linked to a specific technological platform . Platform-specific models are indispensable for the actual implementation of a system.For example, a need to implement an online shop...

 by an exogenous model transformation.

Unidirectional versus bidirectional

A unidirectional model transformation has only one mode of execution: that is, it always takes the same type of input and produces the same type of output. Unidirectional model transformations are useful in compilation-like situations, where any output model is read-only. The relevant notion of consistency is then very simple: the input model is consistent with the model that the transformation would produce as output, only.

For a bidirectional model transformation, the same type of model can sometimes be input and other times be output. Bidirectional transformations are necessary in situations where people are working on more than one model and the models must be kept consistent. Then a change to either model might necessitate a change to the other, in order to maintain consistency between the models. Because each model can incorporate information which is not reflected in the other, there may be many models which are consistent with a given model. Important special cases are:
  • bijective transformations, in which there is exactly one model which is consistent with any given model; that is, the consistency relation is bijective. A pair of models is consistent if and only if it is related by the consistency bijection. Both models contain the same information, but presented differently.

  • view transformations, in which a concrete model determines a single view model, but the same view model might be produced from many different concrete models. The view model is an abstraction of the concrete model. If the view may be updated, a bidirectional transformation is needed. This situation is known in the database field as view-update
    View (database)
    In database theory, a view consists of a stored query accessible as a virtual table in a relational database or a set of documents in a document-oriented database composed of the result set of a query or map and reduce functions...

    . Any concrete model is consistent with its view.


It is particularly important that a bidirectional model transformation has appropriate properties to make it behave sensibly: for example, not making changes unnecessarily, or discarding deliberately made changes.

Languages for model transformations

A model transformation may be written in a general purpose programming language, but specialised model transformation languages are also available. Bidirectional transformations, in particular, are best written in a language that ensures the directions are appropriately related. The OMG
OMG
OMG may refer to:*Oh My goodness, or Oh My Gosh, a common abbreviation used in SMS and Instant Messaging*omg!, a celebrity news and gossip Web site run by Yahoo.com...

-standardised model transformation languages are collectively known as QVT
QVT
QVT is a standard set of languages for model transformation defined by the Object Management Group .- Overview :...

.

In some model transformation languages, for example the QVT
QVT
QVT is a standard set of languages for model transformation defined by the Object Management Group .- Overview :...

 languages, a model transformation is itself a model, that is, it conforms to a metamodel which is part of the model transformation language's definition. This facilitates the definition of Higher Order Transformations (HOTs), i.e. transformations which have other transformations as input and/or output.

See also

  • Model-driven engineering
    Model-driven engineering
    Model-driven engineering is a software development methodology which focuses on creating and exploiting domain models , rather than on the computing concepts...

     (MDE)
  • Model-driven architecture
    Model-driven architecture
    Model-driven architecture is a software design approach for the development of software systems. It provides a set of guidelines for the structuring of specifications, which are expressed as models. Model-driven architecture is a kind of domain engineering, and supports model-driven engineering of...

     (MDA)
  • Domain-specific language (DSL)
  • Model transformation language
    Model Transformation Language
    A model transformation language in systems and software engineering is a language for model transformation.- Overview :The notion of model transformation is of central importance to information technology. A software system may be seen as a set of information transformations...

  • Refinement
    Refinement
    In formal methods, program refinement is the verifiable transformation of an abstract formal specification into a concrete executable program. Stepwise refinement allows this process to be done in stages...

  • Transformation (disambiguation)
  • Program transformation
    Program transformation
    A program transformation is any operation that takes a computer program and generates another program. In many cases the transformed program is required to be semantically equivalent to the original, relative to a particular formal semantics and in fewer cases the transformations result in programs...

  • Data transformation
    Data transformation
    In metadata and data warehouse, a data transformation converts data from a source data format into destination data.Data transformation can be divided into two steps:...

  • Graph transformation
The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK