Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » Java WorkFlow Tooling (JWT) » Restricting nodes as children of the main Activity
Restricting nodes as children of the main Activity [message #498236] Mon, 16 November 2009 04:20
Sed Mising name is currently offline Sed Mising nameFriend
Messages: 22
Registered: July 2009
Junior Member
Hello again! Picking up from my last post (thanks again Marc!) I took a look at the EPC view sample and have successfully created my own view and have happily been extending the metamodel for some custom needs. I've hit an obstacle that I was hoping someone here might have a workaround for....

Quick background:
I created an extension plugin that defines my metamodel (extending off of jwt-we) and have some custom actions (extending from ActivityNode). There is some more subclassing I do from there. For example:

ActivityNode <--- TypeA_CustomNode

ActivityNode <--- TypeB_CustomNode

Similarly, I also extended the StructuredActivityNode:

StructuredActivityNode <--- CompositeNode


The desired functionality:
I would like to be able to create an Activity that I can add nodes of TypeA to, as well as my CompositeNode, but I would like to restrict nodes of TypeB from being drop directly to the main Activity, and constrain them only to the CompositeNode. (Type A can be placed anywhere)

Problem:
Running through the code it seems because ActivityNode is the superclass, the CreateChild Request is fulfilled by the ScopeLayoutEditPolicy, which, though no fault of its own, only cares about the ActivityNode being added to the Activity. I would love to be able to inject the logic to cancel the command if the ActivityNode is of TypeB, but I can't do that.

Is there any combination of EditPolicies or extension points that could realize this type of behavior?

At the recommendation of Mr. Dutoo, I will also be posting this to the jwt mailing list.

Thanks in advance for any help you can offer!!
Previous Topic:Possible to use the JWT editor but for a different model?
Next Topic:Starting RCP mode
Goto Forum:
  


Current Time: Fri Apr 26 10:31:53 GMT 2024

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

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

Back to the top