[rules-users] New to Drools. Is it possible to test inverse conditions?
Manuel Ortiz
manuel.ortizramos at gmail.com
Thu Mar 10 07:12:22 EST 2011
Dear Mauricio:
Thank you very much for your quick response.
If I understood Drools rules documentation, not(Person(age > 30)) means
"There is no Person fact in working memory with age > 30". Isn't it?
I would like to write in DRL "Retrieve Person facts in working memory with
age not greater than 30", not as
Person (age <= 30), but using "age > 30" as this is the string that the user
will provide.
I think it should be some way to do this in DRL. If not, I will have to
implement some kind of "inverse condition translator", which converts
restrictions to their opposites, something like
invertContition("age > 30") returns "age <= 30". I would like not to write
this kind of translator.
Thank you again for your time.
Regards,
Manuel Ortiz
--
View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/New-to-Drools-Is-it-possible-to-test-inverse-conditions-tp2659708p2660170.html
Sent from the Drools - User mailing list archive at Nabble.com.
More information about the rules-users
mailing list