Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [henshin-dev] Forbid and Require

Hi Christian,

Thanks again for your quick response. 

What I'm really trying is to understand the Require and Forbid actions, for which cases it is recommended to use them. 
Is there any formal or informal documentation I can read to learn about them?

Also, where I can read about Paths and Units (LoopUnits, ConditionalUnits, etc)?

Cheers!
Javier
 


On Sun, Apr 20, 2014 at 8:24 AM, Christian Krause <henshin.ck@xxxxxxxxx> wrote:

Hi Javier,

You have two process nodes in your rules. In you forbid rule the preserve process is matched with the buyer process. it is analogous for your require rule.

If you want to have two rules: one for buyer processes and one for non buyer you can do it as follows.  Remove the forbid and require nodes. In the buyer rule add the "name=buyer" attribute to the preserve process node. In the other match the attribute witj a parameter and add an AttributeCondidition procName!="Buyer" using the tree based editor.

Cheers,
Christian

On Apr 20, 2014 1:44 AM, "Javier Scayola" <javier.scayola@xxxxxxxxx> wrote:
Hi!

I'm doing some tests with the Require and Forbid actions in collections. I created 2 test rules, one called requireRule and the second one forbidRule (attachment: requireAndForbid.png).

The source model contains 3 Process objects with names: Reseller, Buyer, Credit Entity.

The problem I have is that my common sense tells me that the forbidRule would forbid the match of the Buyer process, so the result would be the list of processes excluding Buyer. But, the result is actually the opposite, it returns only the process Buyer. (attachment: forbidRuleResult.png)

Then in the required rule, my common sense tells me that I would be restricting the matches to the one process called Buyer. But, again, the result is the opposite, it shows all processes but Buyer. (attachment: requireRuleResult.png)

Is this behaviour right?

Is there any document where I can read how all actions (preserve, create, forbid, etc) works? Same for paths and Units (LoopUnits, ConditionalUnits, etc)

Thanks in advance!

Regards,
Javier

_______________________________________________
henshin-dev mailing list
henshin-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/henshin-dev


_______________________________________________
henshin-dev mailing list
henshin-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/henshin-dev



Back to the top