[
http://jira.jboss.com/jira/browse/JBRULES-1064?page=comments#action_12371401 ]
Mark Proctor commented on JBRULES-1064:
---------------------------------------
-> is now deprecated, its not just needed now.
Person( girlAge : age, sex = "F" )
Person( boyAge : age -> ( girlAge.intValue() == boyAge.intValue() + 2 ), sex =
'M' )
is now, notice the boyAge does not need binding, as it will determine and bind
"age" as part of the autovivification process.
Person( girlAge : age, sex = "F" )
Person( eval( girlAge == age + 2 ), sex = 'M' )
You can ofcourse still still bind the boyAge, but generally its not preferred any more.
Basically predicates where where focused on a single field are no longer needed as we
determine the used and bound fields on the fly, we also now call then inline-eval.
Predicate, while the traditional name, was dropped, this is partly in preparation for when
we start to support backward chaining and will use the term predicate in the prolog
sense.
Person( boyAge : age, eval( girlAge.intValue() == boyAge.intValue() + 2 ), sex =
'M' ).
I'll close this one off in a day or so, if I don't hear any further feedback.
"->" notation for predicates missing in documentation
-----------------------------------------------------
Key: JBRULES-1064
URL:
http://jira.jboss.com/jira/browse/JBRULES-1064
Project: JBoss Rules
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: Documentation
Affects Versions: 4.0.0.GA
Reporter: Dr. Gernot Starke
Assigned To: Mark Proctor
Priority: Minor
the notation "->" for adressing complex terms is missing from 4.0.0
documentation.
It has been "return value operator" in 3.0.6:
<quoted from 3.0.6>
Example 3.13. Return Value operator
Person( girlAge : age, sex = "F" )
Person( boyAge : age -> ( girlAge.intValue() == boyAge.intValue() + 2 ), sex =
'M' )
</quoted>
--
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