Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [henshin-dev] Compare two node's attributes in rule?

Am 07.01.2013 um 18:18 schrieb Christian Krause:

> Hi Jens,
> 
> Am 1/7/2013 4:36 PM, schrieb Jens Bürger:
>> Hi,
>> 
>> In addition to my last question, it would be important for me to compare the attributes values of two nodes of the same type.
>> 
>> Say I have two nodes of the type critical.
>> Every node has the attribute "high". I want to create a rule which has a match if the values of the two "high"-attributes do differ.
> 
> For doing this, the rule should have two parameters, say x and y.

Nice, but it didn't help me with my application because there I have the aforementioned lists. So I made the (also in my other mail mentioned) workaround on a logical level.

[…]
>> Is there any documentation on how Henshin calculates values of the "Value"-property and what it's features are?
> 
> We don't have a manual I am afraid. In general, the interpreter does not offer any special syntax for attribute calculations. What happens is that we use a JavaScript engine to make these calculations.

... this information helped alot, especially because one can let the engine do primitive string-operations :)

Jens

Back to the top