[jboss-jira] [JBoss JIRA] Closed: (JBRULES-756) Allow predicates and return values to use implicit bindings
Edson Tirelli (JIRA)
jira-events at lists.jboss.org
Wed Mar 28 08:59:27 EDT 2007
[ http://jira.jboss.com/jira/browse/JBRULES-756?page=all ]
Edson Tirelli closed JBRULES-756.
---------------------------------
Resolution: Done
Feature added, test cases added.
> Allow predicates and return values to use implicit bindings
> -----------------------------------------------------------
>
> Key: JBRULES-756
> URL: http://jira.jboss.com/jira/browse/JBRULES-756
> Project: JBoss Rules
> Issue Type: Feature Request
> Security Level: Public(Everyone can see)
> Components: Reteoo, Drl Parser/Builder
> Affects Versions: 3.1-m1
> Reporter: Edson Tirelli
> Assigned To: Edson Tirelli
> Fix For: 3.1-m2
>
>
> Allow for use of implicit declared/bound variables inside predicates and return value expressions. Ex:
> package org.drools;
> global java.util.List results;
> global java.lang.Double factor;
> rule "test implicit declarations"
> when
> // implicit binding
> Cheese( type == "stilton", ( price < 20*factor ) )
> // late declaration
> Cheese( price < ( price * factor ), ( price < price * factor ), price : price )
> then
> results.add( "Rule Fired" );
> end
> The "price" variable is implicit declared and bound to the "price" field to be used inside the predicates and return values. It also allows for late bindings.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list