Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Papyrus » Need clarification of Class Diagram tutorial
Need clarification of Class Diagram tutorial [message #1484901] Sun, 23 November 2014 21:58 Go to next message
David P is currently offline David PFriend
Messages: 2
Registered: November 2014
Junior Member
I'm looking forward to using Papyrus for sequence diagrams, but I'm having trouble getting started with a class diagram.

I'm using Luna 4.4.1 and Papyrus 1.0.1.v201409170932, and I'm trying to follow


  • .../TutorialOnPapyrusUSE_d20101001.pdf
  • .../PapyrusTutorial_OnSequenceDiagrams_v0.1_d2010100.pdf


What's unclear is:

  • How to get a typed attribute of a Class to display
  • How to get an operation to display
  • How to get an "implements" relation to display


Here's what I've done


  1. Create a UML project and import primitive types
  2. Drag a Class from palette and drop to model.di pane. Name it Zoo.
  3. Drag an Interface from palette and drop to model.di pane. Name it Animal.
  4. In Zoo, create a property called residents of type Animal, visibility=private, and multiplicity=0..*
  5. I expected this attribute to appear in the Zoo box, and that an aggregation link to Animal would appear, but neither did.
  6. In Animal, I would like to define a feedMe() operation, but only attributes are available.
  7. Drag a Class from palette and drop to model.di pane. Name it Tiger.
  8. Select edge type Abstraction in the palette, then click and hold in the center of Tiger, drag up to the center of Animal, and release. Label the edge "implements"
  9. I expected the "implements" label to remain visible, but it doesn't


Suggestions?

Cheers
David
Re: Need clarification of Class Diagram tutorial [message #1486055 is a reply to message #1484901] Mon, 24 November 2014 19:42 Go to previous messageGo to next message
Charles Rivet is currently offline Charles RivetFriend
Messages: 219
Registered: May 2014
Location: Canada
Senior Member

Hi David,

It would be useful to know what version of Papyrus you are using for your test. I am currently running off the nightly builds, so the behaviour I observe can be a little different.

For your step (5), "I expected this attribute to appear in the Zoo box, and that an aggregation link to Animal would appear, but neither did.". For the first part, this has happened to me in the past, but not lately. The easiest way to get it to appear is to right click on the "Zoo" class and select "Filters: > "Show/Hide Contents". You will then be able to pick what you want to show in the class' compartments. As for the aggregation, that is not the current behaviour of Papyrus, where the act of creating a property does not automatically create an aggregation. It is, however, often desirable to be able to graphically see that relationship, and it has already been reported as an issue (targeted at Mars I think).

For your step (9), "I expected the "implements" label to remain visible, but it doesn't", you will have to explicitly show if by right clicking on the abstraction and selecting "Filters" > "Manage Connectors Labels" to pick what you want displayed.

/Charles


/Charles Rivet
Re: Need clarification of Class Diagram tutorial [message #1486186 is a reply to message #1486055] Mon, 24 November 2014 22:15 Go to previous message
David P is currently offline David PFriend
Messages: 2
Registered: November 2014
Junior Member
Hi Charles,

Thanks for your note. In my query, I do indicate my versions of Papyrus and Eclipse.

When I select my class Zoo, and select Filters > "Show/Hide Contents", and select all checkboxes, there is no change in the display of the class. Re-doing the initial steps shows all checkboxes are not selected, contrary to expectation.

Having all these on is what most users would expect, I believe.

Cheers
David
Previous Topic:How to install Java code generator for Papyrus
Next Topic:state machine in-state reaction
Goto Forum:
  


Current Time: Wed Jul 08 11:53:54 GMT 2020

Powered by FUDForum. Page generated in 0.01542 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top