Skip to content
Model centric tools for Spring development Community portal
Skyway PerspectivesModel driven delivery

Model reference

Reference Figure: The Skyway Metamodel

A one page view of the metamodel behind the editor: projects, packages, types and the elements that describe them.

Class diagram of the Skyway model repository with project, package, type and operation elements
Figure 5. The metamodel defines the vocabulary that recipes read during generation.

The metamodel is the vocabulary of the editor. It defines what a project is, how packages group types, and which elements a type may own. Generation recipes read this vocabulary rather than a particular file format, which is why the same model can feed more than one output style.

Core elements

  • Project. The top level container. It records the target package and the generation settings.
  • Package. A named group of types, usually aligned with an application layer.
  • Type. An entity, service, controller or flow. A stereotype decides how recipes treat it.
  • Attribute. A typed field with optional constraints such as required or unique.
  • Operation. A behaviour with input and output parameters, used by service and controller recipes.
  • Reference. A link between types, such as an association or a service dependency.

Why the model is explicit

An explicit model lets a recipe ask precise questions. Instead of parsing Java source, the recipe asks for every type with the entity stereotype and every attribute that is required. The answers are stable, so generated code is stable too. When a design change is made in the model, every layer sees it at the same time.

Reading the figure. Follow the arrows from Project down to Type, then across to Attribute, Operation and Reference. Each arrow is a containment or association rule that the editor enforces.

Use the metamodel view when a generator run skips an element. The view shows whether the element is attached to a type, whether it has the expected stereotype and whether it satisfies the minimum rules for its recipe.