Hello,
i'm currently evaluating Rule-Engines. I've started with JBossRules,
currently i do some tests with Jess.
I try to port my Testrules from JBRules to Jess and i can't get these two
rules work:
(
- Person is a JavaBean with getter/setter
- there are ~5000 Person-Objects in WorkingMemory
- behind 'data' is a getter-method which only returns string with all
attributes
)
(import com.PIAG.jess.Person)
(deftemplate Person (declare (from-class Person)))
(defrule datetest ""
(Person {gebdat == "12-Aug-1961"} (data ?data))
=>
(printout t "datetest: " ?data crlf)
)
no matches! how to deal with 'date' datatypes?
(defrule moditest ""
?p1 <- (Person {key == "002|003|2034"} (data ?data1) (naname ?naname1))
?p2 <- (Person {key == "UNST|002|3"} (data ?data2))
=>
(printout t "moditest: " ?data1 " - " ?data2 crlf)
(modify ?p2 (reference ?naname1))
)
no matches!
please point me in the right direction. currently i'm studing the manuals
but i did'nt found anything
about my problem.
regards
-klaus
--
Klaus Thiele - Personal & Informatik AG
mailto:[EMAIL PROTECTED]
"Ein wichtiger Charakterzug groÃartiger Programmierer ist konstruktive
Faulheit..."
Eric S. Raymond
--------------------------------------------------------------------
To unsubscribe, send the words 'unsubscribe jess-users [EMAIL PROTECTED]'
in the BODY of a message to [EMAIL PROTECTED], NOT to the list
(use your own address!) List problems? Notify [EMAIL PROTECTED]
--------------------------------------------------------------------