Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 318722 - [All Diagrams] Abstract figures PapyrusNodeFigure and NodeNamedElementFigure can not be extended by a composite figure
Summary: [All Diagrams] Abstract figures PapyrusNodeFigure and NodeNamedElementFigure ...
Status: RESOLVED FIXED
Alias: None
Product: Papyrus
Classification: Modeling
Component: Core (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 major (vote)
Target Milestone: 0.7.0   Edit
Assignee: Vincent Hémery CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 318566
  Show dependency tree
 
Reported: 2010-07-02 09:55 EDT by Vincent Hémery CLA
Modified: 2010-07-02 10:25 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vincent Hémery CLA 2010-07-02 09:55:37 EDT
The classes
org.eclipse.papyrus.diagram.common.figure.node.NodeNamedElementFigure
and
org.eclipse.papyrus.diagram.common.figure.node.PapyrusNodeFigure
impose too many constraints. They can be extended only by a basic figure, since they create all content directly in the top figure and rely on this fact.

These figure must be parameterizable, in order to enable extending them in case of composite figures. (Instead of duplicating all their code to adapt it to the composite figure implementing the corresponding interface)
They should also allow children to separate labels and compartments in different figures.

For examples, the lifeline figure of sequence diagram should be able to extend NodeNamedElementFigure, and configure it in order the top rectangle only has the border and contains labels.

These modifications must of course not impact the current default behavior.
Comment 1 Vincent Hémery CLA 2010-07-02 10:25:47 EDT
Overrideable methods  have been added to make both classes a lot more parameterizable.
Default implementation does not ipact current behavior. The API has only been enriched.

An example of usage can be found in org.eclipse.papyrus.diagram.sequence.edit.parts.LifelineEditPart.LifelineFigure.