Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » BPMN Modeler » Changing the Activity name through a listener
Changing the Activity name through a listener [message #10798] Wed, 15 April 2009 21:53 Go to next message
Eclipse UserFriend
Originally posted by: klia0001.um.edu.mt

Hi,
I am using the plugin as part of my thesis, and so far it has been very
useful. I have created a custom annotation for the activities that
associates the Task to a WSDL Operation. This is done populating a
combobox.

I would like it so that when the user changes the selection in the
combobox, the actual name of the activity also changes from the default
"Task" to the name of the Operation. Is there a listener that I can use to
achieve this functionality?

I also want to programmatically retrieve the generated XML file so that I
can parse it while the program is running. Is there an easy way to do this?


Thanks,

Lia.
Re: Changing the Activity name through a listener [message #11231 is a reply to message #10798] Thu, 16 April 2009 13:34 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: atoulme.intalio.com

Lia wrote:
> Hi,
> I am using the plugin as part of my thesis, and so far it has been very
> useful. I have created a custom annotation for the activities that
> associates the Task to a WSDL Operation. This is done populating a
> combobox.
>
> I would like it so that when the user changes the selection in the
> combobox, the actual name of the activity also changes from the default
> "Task" to the name of the Operation. Is there a listener that I can use
> to achieve this functionality?
You can listen to model changes using EMF adapters. An EContentAdapter
placed on the BpmnDiagram object will listen to all the changes
occurring in there for example.
>
> I also want to programmatically retrieve the generated XML file so that
> I can parse it while the program is running. Is there an easy way to do
> this?
You can load the resource through a ResourceSet. This is documented in EMF.
>
>
> Thanks,
>
> Lia.
>
Re: Changing the Activity name through a listener [message #11299 is a reply to message #11231] Fri, 17 April 2009 13:37 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: klia0001.um.edu.mt

Thanks Antoine for the reply.

Can you please give me a quick overview of what I need to do to place an
EContentActivity on the BPMNDiagram object?


Thanks.
Re: Changing the Activity name through a listener [message #11335 is a reply to message #11299] Sat, 18 April 2009 20:23 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: atoulme.intalio.com

Lia wrote:
> Thanks Antoine for the reply.
> Can you please give me a quick overview of what I need to do to place an
> EContentActivity on the BPMNDiagram object?
You mean an EContentAdapter. You can google for it, EMF has plenty of
doc around it.
Re: Changing the Activity name through a listener [message #11592 is a reply to message #11335] Fri, 24 April 2009 12:12 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: klia0001.um.edu.mt

Hi Antoine,

Thanks for all your help, it was really useful.

I have one problem hovewer. I have put two Tasks in the diagram pool (Task
1 and Task 2). When I change the annotation of Task 1 it's ok.
When I change the annotation of Task 1 and then click on Task 2
immediately, the annotation of Task 1 changes to that of Task 2.

If however, I change the annotation on Task 1, then click on the pool, and
THEN click on Task 2, this does not happen.

I don't know whether I explained myself in a clear manner, but would
appreciate if you can point me in the right direction.


Thanks,
Lia
Re: Changing the Activity name through a listener [message #11628 is a reply to message #11592] Fri, 24 April 2009 13:25 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: atoulme.intalio.com

Not sure what's happening but it sure looks like a bug in your code.

Lia wrote:
> Hi Antoine,
>
> Thanks for all your help, it was really useful.
>
> I have one problem hovewer. I have put two Tasks in the diagram pool
> (Task 1 and Task 2). When I change the annotation of Task 1 it's ok.
> When I change the annotation of Task 1 and then click on Task 2
> immediately, the annotation of Task 1 changes to that of Task 2.
>
> If however, I change the annotation on Task 1, then click on the pool,
> and THEN click on Task 2, this does not happen.
>
> I don't know whether I explained myself in a clear manner, but would
> appreciate if you can point me in the right direction.
>
> Thanks,
> Lia
>
>
>
>
Re: Changing the Activity name through a listener [message #11664 is a reply to message #11628] Fri, 24 April 2009 14:43 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: klia0001.um.edu.mt

I just followed the same steps as in this tutorial:
http://wiki.eclipse.org/STP/BPMN_Component/STP_BPMN_Presenta tion_Hands_on_tutorial#Adding_a_property_tab_to_create_your_ annotation

I added "activity" as a global variable. It is still doing the same thing,
so I don't know what is happening.
Re: Changing the Activity name through a listener [message #11696 is a reply to message #11664] Sat, 25 April 2009 09:11 Go to previous message
Eclipse UserFriend
Originally posted by: atoulme.intalio.com

Lia,

it's because you change the selection: the activity changes and the
command applies to the wrong element.

I can't help you with your code ; samples are here to help you.

Thanks,


Antoine

Lia wrote:
> I just followed the same steps as in this tutorial:
> http://wiki.eclipse.org/STP/BPMN_Component/STP_BPMN_Presenta tion_Hands_on_tutorial#Adding_a_property_tab_to_create_your_ annotation
>
>
> I added "activity" as a global variable. It is still doing the same
> thing, so I don't know what is happening.
>
>
>
Previous Topic:Change Labels of PopupBar
Next Topic:visualize process data
Goto Forum:
  


Current Time: Sun Dec 21 18:14:32 GMT 2014

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

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