Hi all,
as announced, I’d like to start with the
implementation of the new view mechanism during the next days. Since there still
seems to be some discussion related to the final requirements of the features that
should be supported in the end I’m going to start with a (hopefully) less
controversial part of the implementation that can be done mostly independent
from the rest of the views: The support for different positions in different
views.
This feature will be very important once we
have views like swimlanes which will give elements positions and dimensions
that cannot be shared with “conventional” views and therefore this
information cannot be shared between different views. Also, the user may want
to arrange elements in a more business oriented view in a different manner than
in a technical view (which often contains much more elements and may require
more space between the elements). Therefore, the model should be able to store one
position/dimension for each model element and each view.
The proposed implementation consists of:
- Removing Point and Dimension from the
View package
- Adding a ViewData element to the View
Package with attributes viewID, x, y, width, height
- Removing Location(Point) and
Size(Dimension) from the GraphicalElement
- Adding ViewData as 0..* relationship to the
GraphicalElement
- Adjusting the code, so the information in
the ViewData element that corresponds to the current view is used
- Sourcing out the storage of these
elements into a new file (e.g. *.workflowview) to prevent the core model file (*.workflow)
from being cluttered with view-specific information
- Other view specific information (like
References and ReferenceEdges) should also be put into this file
However, there are a few complications:
- This modification will cause
incompatibility with the old file format (as will do any modification of the
metamodel which makes it imcompatible with the previous one). We’ll need
to implement transformations that convert the old files to the new format (Florian
is already looking into this)
- If a view is used the first time, a
dialog should be displayed to let the user import the initial positions for the
elements from another view or use an automatic layouting algorithm
- It would probably also be nice if the
positions of elements can be synchronized between different views, so that if
the user moves an element in View1, it gets moved automatically to the same
position in View2 (basically an emulation of what we have now, which will be
still useful in some cases I guess)
As always, if someone has some suggestions
or objections to this proposal, please do not hesitate to answer.
Regards,
Christian