Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » UML2 Tools » Missing edges in a exported use case diagram image (0.9.0)
Missing edges in a exported use case diagram image (0.9.0) [message #507981] Fri, 15 January 2010 07:20 Go to next message
Eclipse UserFriend
Originally posted by: r.zozmann.exxcellent.de

Hi,

we export (GMF) diagram images in a programmatic way via CopyToImageUtil
(org.eclipse.gmf.runtime.diagram.ui.render.util). As input i have a
Diagram (org.eclipse.gmf.runtime.notation) and i call
CopyToImageUtil.createDiagramEditPart(...) to get a DiagramEditPart for
further processing via CopyToImageUtil.copyToImage(...).
Looking into the DiagramEditPart instance i must realize, that there are
no connections (the edges collection is empty) and so the exported image
contains all shapes, but no lines (for edges). I have no rationale for
that behaviour, because:
- From technical aspect, i can't find any difference in loading/handling
between our way and the UMLDiagramEditor. We have also respect for the
diagram specific preferences (the right key for preferences hint).
- The problem occurs only for images of use case diagrams (all other
diagram types like class and activity diagrams are working good, the
exported image contains all edges). Also for GMF editors of other DSL's
our way to export images is working.

So the question is: Is there any magic/hidden functionality in the
editor for UseCase diagrams triggering the loading of edges in a more
specialized way than in other diagrams?

Thanks
Ralf
Re: Missing edges in a exported use case diagram image (0.9.0) [message #508005 is a reply to message #507981] Fri, 15 January 2010 14:31 Go to previous message
Eclipse UserFriend
Originally posted by: r.zozmann.exxcellent.de

After a litte bit more investigation, i could localize a more specific
scenario for the problem:
- The problem is not specific for use case diagrams only, but my
scenario affects only that.
- The edges are missed under the following conditions:
1. There exists a shortcut in diagram to a model element from another
model file located in another project in same workspace (very important!).
2. The association (in my case between the shortcut-actor and a normal
use case) was drawn from actor to use case, but is persisted in the
model file of actor (means: in the model file in the other project,
where the actor comes from). I believe this is related to #264509 and
i'm wondering about these persistence strategy, because the
AssociationEndConvention (org.eclipse.uml2.diagram.common.conventions)
has to prevent that.

Greetings
Ralf
Re: Missing edges in a exported use case diagram image (0.9.0) [message #508033 is a reply to message #507981] Fri, 15 January 2010 10:46 Go to previous message
Eclipse UserFriend
Originally posted by: r.zozmann.exxcellent.de

Ok finally i solve my problem by myself :-)
I have not fully debugged all aspects of problem, but it's caused by
something around URI handling in EMF/GMF. We have loaded diagram
resources (files) via file uri (URI.createFileURI(...)). This means we
have to handle with absolute paths. But all references in diagram/model
are platform resource uris. EMF/GMF seems to have problems to detect
file uri's as the same resource identificator as other platform resource
uri's. From that, referenced model files (from shortcut etc.) are loaded
more than once. And that brings me into trouble.
Now i try to work for all resources primary with platform resource uri's
and the problem vanished.

Greetings
Ralf
Previous Topic:Class and State Machine Diagrams
Next Topic:Missing edges in a exported use case diagram image (0.9.0)
Goto Forum:
  


Current Time: Thu Apr 25 16:45:57 GMT 2024

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

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

Back to the top