Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Graphiti » Accessing eRessource or Diagram(Is there an API to get the eResource or "Diagram" object of an open Diagram?)
Accessing eRessource or Diagram [message #780916] Thu, 19 January 2012 22:22 Go to next message
Bjoern Ickx is currently offline Bjoern IckxFriend
Messages: 17
Registered: June 2011
Junior Member
Hello together,

I need to access the business objects of an open diagram. When I do this with a selection listener and select an object within the graphiti editor it works nice. However, now I need to do this without selecting something.

I have a simple model with "Processes" and "Flows"

I want to iterate through all "Processes" I modeled with the Graphiti editor. I think I need the eRessource the diagram is using to do this -> resource.getAllContents()

So I simple need the "Diagram" object, or eResource of the open diagram, or at least the DiagramTypeProvider of the open diagram.

By using the Graphiti interface I could only access LayoutService, GaCreateService ... PeService. Non of them delivers the above mentioned objects (Diagram, DiagramTypeProvider, eResource).

Is there a Graphiti API to access them? Or another way to get access to the instantiated objects of my model the graphiti editor has created?

Thanks in advance.

Best regards

Bjoern

[Updated on: Thu, 19 January 2012 22:23]

Report message to a moderator

Re: Accessing eRessource or Diagram [message #781187 is a reply to message #780916] Fri, 20 January 2012 08:36 Go to previous messageGo to next message
Michael Wenz is currently offline Michael WenzFriend
Messages: 1931
Registered: July 2009
Location: Walldorf, Germany
Senior Member
Hello,

it's not really an API (we get one in Graphiti 0.9.0) but you can cast the
active editor to DiagramEditor and call
getDiagramTypeProvider().getDiagram().

Michael
Re: Accessing eRessource or Diagram [message #782346 is a reply to message #781187] Mon, 23 January 2012 15:26 Go to previous messageGo to next message
Bjoern Ickx is currently offline Bjoern IckxFriend
Messages: 17
Registered: June 2011
Junior Member
Thanks a lot Michael, that worked well. What about the roadmap of 0.9? When it is planned to be released? Next months, half a year or year?

Best Björn
Re: Accessing eRessource or Diagram [message #783209 is a reply to message #782346] Wed, 25 January 2012 09:41 Go to previous message
Michael Wenz is currently offline Michael WenzFriend
Messages: 1931
Registered: July 2009
Location: Walldorf, Germany
Senior Member
0.9 will be released as part of the Juno release train, so in June.

Michael
Previous Topic:resizing elements nested in rectangle
Next Topic:image creation without opening an editor possible?
Goto Forum:
  


Current Time: Thu Mar 28 15:44:25 GMT 2024

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

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

Back to the top