SDM: Week 7 Lab / Exercise

Week 7 Lab / Exercise

In this open-ended lab you will work with a "proper" UML tool, i.e. with a tool that has an underlying metamodel conformant to UML, rather than with a "dumb" drawing tool. We will use Papyrus. If you want to install it on your own machine you can download it from https://www.eclipse.org/papyrus/. On Windows, I think the easiest way is to install the Eclipse Modeling Package using the Eclipse Installer, then add the Papyrus package using its Update Site as instructed. Alternatively you can use it in the labs on DICE (it is papyrus23, or find it on the Applications menu). There are many other UML tools and you may wish to explore.

In this lab, and for the rest of the course, detailed use of the tools is not examinable - the idea is to get the picture of the kind of thing that can be done and have a play with some tools to enrich your understanding of the state of the art. (NB this doesn't mean you can safely ignore the labs - there are various ways I can examine your high-level understanding, e.g., give you a fictional situation and ask you to suggest and justify what tools would be suitable...in any case, the tools can be fun :-) But a playful approach is more valuable than ever now.)

Start up Papyrus, creating a new workspace, and start playing. Create a new Papyrus project with some UML diagrams in it. You may find you need to set the Papyrus perspective manually - Window, Perspective, Open perspective, Other..., Papyrus. Details of just how to get started seem to vary a bit by platform and change frequently so rather than me giving click by click instructions, explore!

Here are some suggestions:

  • The metamodel diagram in Part C of the 2022-23 lab assessment was build with Papyrus. Can you reproduce it? In order to do so exactly, you will need not only to use the diagram elements you find in the palettes, which are reasonably intuitive, but also to explore the Properties views of the model elements - click on a diagram element, then explore the panel below - and the display options - right click, then look under the Filters submenu. Can you understand, and get rid of, the blobs that you'll get by default on the ends of associations?
  • The User Guide linked from Papyrus's Documentation tab has a section of Tutorials - section 7.4 is the most relevant. (Start here, click User Guide, Starter Guide) You will not have time to do all of these, but pick something and have a go. Maybe try building an activity diagram, or a sequence diagram. (To add a new diagram to an existing model, click the model in the Model Explorer and look at the New Diagram contextual menu.)
  • Now combine your Papyrus exploration with your learning about design patterns. Pick one of the patterns and model it in Papyrus.

Exercises (independent of the lab; not for hand-in; aiming to help you understand some key patterns):

License
All rights reserved The University of Edinburgh