How to Approach the Problem


Vertical mappings (see Abstracting Mappings in Chapter 5) can be classified in terms of the change in the level of abstraction that they bring about. A short-hop mapping doesn't have much effect on the level of abstraction between source model and target model. There's often a fairly clear, nearly one-to-one mapping between elements in the source and target models. For example, a mapping function that turns a class model into a corresponding set of implementation classes, operations to methods, and attributes to members represents a short hop. A long-hop mapping, on the other hand, does result in a significant change in abstraction level. An example is a mapping that takes the elements of a model and maps them directly to bits.

There are two ways to approach building an MDA process. One approach is to focus on finding models that exist at a single level of subject-matter abstraction. The other approach is to focus on the length of the mapping chain and find an optimal length for each hop in the chain. Unsurprisingly, you need to use a combination of both approaches.

It's generally the case that long-hop mappings lend themselves to partitioning into a mapping chain comprised of several short-hop mappings. The long-hop example above could be broken down so we map the source model to a specific model that knows about, say, local interfaces and remote interfaces, and then map that model to the source code. Not only does the multiple-hop approach simplify the mapping functions; it also exposes the intermediate model so the mapping functions can be reused. The trick is to find good trade-offs among the portability of the models you can create, the traceability and reusability of the mapping functions, and efficient notations for the things you have to specify for the platforms you're targeting.



MDA Distilled. Principles of Model-Driven Architecture
MDA Distilled. Principles of Model-Driven Architecture
ISBN: B00866PUN2
EAN: N/A
Year: 2003
Pages: 134

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net