Inheritance in rules [SOLVED] [message #825499] |
Tue, 20 March 2012 18:59  |
Eclipse User |
|
|
|
After a few attempts to use inheritance in some ETL and EML rules I completely gave up because I got to many "weird" errors, specially when populating collections. I was in a bit of a hurry and didn't have the time to dig a bit deeper.
I know inheritance can be my friend and save me some time and headaches and I am willing to give it another try. However, in the Epsilon book there is no details regarding inheritance, except for the existence of the extends keyword. For starters I would assume that that a rule can only extend another rule that has the same type of elements in the source parameter. Beyond that I would like to know how does it actually work.
1. Regarding target parameters: do you get a sum of the base and the extended rule, or only the ones from the extended rule? What special considerations must be taken when naming target parameters?
2. Does the base rule always has to be abstract? Probably a clarification of the semantics of the extends operator would come in handy.
3. How does the body of the base rule and the extending rule execute? As before a detailed explanation of the extends semantics would be nice.
4. How all of the above works if you extend more than one rule?
Any other details would be appreciated, for example if in different languages some of the semantics change.
Regards,
Horacio
[Updated on: Tue, 17 April 2012 11:26] by Moderator
|
|
|
|
|
|
Re: Inheritance in rules [message #840035 is a reply to message #840007] |
Mon, 09 April 2012 11:37  |
Eclipse User |
|
|
|
Hi Horacio,
> 1. Will inheritance work, using your example, if A is of the same class as X?
Yes, it should work.
> 2. How does guards work? If rule X2Y has a guard, will rule A2B inherit the guard too?
I'd expect it too.
Cheers,
Dimitris
|
|
|
Powered by
FUDForum. Page generated in 0.22848 seconds