Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » loading and accessing the state machine diagram in uml format
loading and accessing the state machine diagram in uml format [message #416885] Tue, 19 February 2008 16:44 Go to next message
hemant is currently offline hemantFriend
Messages: 4
Registered: July 2009
Junior Member
Hello
I want ot load some state machines designed in different eclipse based
modeling tools like topcased and eclipseUML in my java programme and then
i want to access all the informations in the state diagram like state IDs
, state names, stereotypes ect.
Can anyone kindly guide me how can i do that. Kindly post an exaple source
code for loading a state digram in UML format in the application and then
access its information.
Thanks a lot in advance.
Hemant Kumar
Re: loading and accessing the state machine diagram in uml format [message #416891 is a reply to message #416885] Tue, 19 February 2008 17:24 Go to previous messageGo to next message
Marcelo Paternostro is currently offline Marcelo PaternostroFriend
Messages: 602
Registered: July 2009
Senior Member
Hi Hemant,

Please don't take this the wrong way, but asking the same question
multiple times is not the best approach to get the help you need in open
source communities. Also, a generic question like the one below shows
that you didn't do an initial investigation given that some of the
information you need is available at EMF's documentation page (like the
tutorial I've pointed you before). This may not be your case but that
is how it is perceived.

Btw, you may find all the information you need to do your work by
looking at what is available on the UML2 site
(http://www.eclipse.org/modeling/mdt/?project=uml2) and newsgroup.

Cheers,
Marcelo

hemant wrote:
> Hello
> I want ot load some state machines designed in different eclipse based
> modeling tools like topcased and eclipseUML in my java programme and
> then i want to access all the informations in the state diagram like
> state IDs , state names, stereotypes ect.
> Can anyone kindly guide me how can i do that. Kindly post an exaple
> source code for loading a state digram in UML format in the application
> and then access its information.
> Thanks a lot in advance.
> Hemant Kumar
>
Re: loading and accessing the state machine diagram in uml format [message #416914 is a reply to message #416891] Wed, 20 February 2008 09:14 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: hemant.kumar.811.gmail.com

Hello Mercelo,
I know this might be little teasing but i am very new to EMF paradigm. I
went through the tutorial referance u gave to me but as far as i
understood from that, it shows that EMF supports the UML constructs in
ECORE format only for class diagram ( slides 33, 34, 35) and there is no
supprt for state machine or activity diagrams. Thats why I again posted my
question making it little more clear that i want to work with activity
diagrams and State diagrams and not class diagrams.
I have also Tried to convert my state diagrams into ecore format by using
UML plugin but it also gives the empty state machine class. THough it
works fine with class diagram in uml format.
It might be little stupid question but i am very new to this field so i
apologise if i made u feel annoyed.

Great work though
Thanks a lot
Hemant
Re: loading and accessing the state machine diagram in uml format [message #416924 is a reply to message #416914] Wed, 20 February 2008 15:02 Go to previous message
Marcelo Paternostro is currently offline Marcelo PaternostroFriend
Messages: 602
Registered: July 2009
Senior Member
Hi Hemant,

I was not really annoyed (perhaps just a little ;-) ). Another tip is
to keep the same discussion in one single thread. Rest assured that we
will not miss it ;-)

The pages you mention show to someone that understands UML what Ecore
is: in very simple terms, it is a model that can represent the things
you have in class diagrams.

That said, lets think about what is the UML2 project. From its page, it
is "an EMF-based implementation of the Unified Modeling Language (UMLTM)
2.x OMG metamodel". In the UML2 project, "things" like Class, Activity,
State, and others are EMF classes (hence the "EMF-based
implementation"). So, dealing with a bunch of instances of UML2 (like a
state machine defined in a resource/diagram) is the same as dealing with
any other "bunch of instances" from a EMF model, like the "Library"
model we use on our tutorials (again see our documentation page). In
other words, you can use a simpler model to understand EMF and then use
that knowledge to tackle more complicated models.

Anyway, I did a quick scan on the UML2 newsgroup
(eclipse.modeling.mdt.uml2). The following posts may help you (the
first one, in particular):

"State Machine - UML Editor & Programmatic" from 1/22/2007 7:03 PM
"Ecore for Sequence diagram" from 3/1/2007 4:35 PM
"how to find out the type of element in a package" from 2/10/2008 5:38 AM
"UML2 / Sequence diagram / MessageKind" from 12/2/2007 6:03 AM
"Programmetic Create Connetor between Port" from 2/26/2007 4:51 AM
"Sequence Diagrams" from 5/1/2007 2:57 PM

You could ask in the UML2 newsgroup if someone has a code that reads a
state machine. You may be lucky ;-)

Cheers,
Marcelo

Hemant wrote:
> Hello Mercelo,
> I know this might be little teasing but i am very new to EMF paradigm. I
> went through the tutorial referance u gave to me but as far as i
> understood from that, it shows that EMF supports the UML constructs in
> ECORE format only for class diagram ( slides 33, 34, 35) and there is no
> supprt for state machine or activity diagrams. Thats why I again posted
> my question making it little more clear that i want to work with
> activity diagrams and State diagrams and not class diagrams.
> I have also Tried to convert my state diagrams into ecore format by
> using UML plugin but it also gives the empty state machine class. THough
> it works fine with class diagram in uml format.
> It might be little stupid question but i am very new to this field so i
> apologise if i made u feel annoyed.
> Great work though
> Thanks a lot
> Hemant
>
Previous Topic:[Announcement] Applied Metamodelling Book
Next Topic:Best practices when changing a model object via a dialog
Goto Forum:
  


Current Time: Fri Apr 26 16:09:12 GMT 2024

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

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

Back to the top