[rules-users] Drools issue
djb
dbrownell83 at hotmail.com
Thu Jul 8 09:11:03 EDT 2010
In Drools, you can call any java code in the "when" block using eval(...),
however, it is not advised because it cannot be used as a node in the RETE
graph.
so,
rule "basic rule"
when
$a: Account( validAccount == true ) // condition
eval($a.isValidAccount("blah"))
then
System.out.println("Account is not valid"); // consequence
end
depends on your goal though -- if you are making a validation program, you
probably want to use rule templates. otherwise, you might as well just use
a HashMap and a 3 line java program.
--
View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/Drools-issue-tp951185p951614.html
Sent from the Drools - User mailing list archive at Nabble.com.
More information about the rules-users
mailing list