I try to do somethings like this : (defclass person Person) (bind ?p1 (new Person)) (bind ?p2 (new Person)) (bind ?p3 (new Person)) (definstance person ?p1 static) (definstance person ?p2 static) (definstance person ?p3 static)
(deffunction myFunction(?per) (.....use of the current instance of the person.......... return TRUE)) I wrote a rule like this : (deffrule myRule (person ?per) (test (myFunction ?per)) => (printout t "Fire" crlf)) This rule doesn't work. It seems that Jess cannot bind the current instance of person in the ?per variable. Why we can bind a member of person (like : (person (name ?n)) but not the instance itself (person ?per)) ? Do you have a solution to solve this problem ? Tanks for your answer Samuel Kentzel ---------------------------------------------------------------------- ---------------------------------------------------------------------- >> This email and any files transmitted with it are CONFIDENTIAL and intended solely for the use of the individual or entity to whom they are addressed. >> Any unauthorised copying, disclosure, or distribution of the material within this email is strictly forbidden. >> Any views or opinions presented within this e-mail are solely those of the author and do not necessarily represent those of Odyssey Asset Management Systems SA unless otherwise specifically stated. >> An electronic message is not binding on its sender. Any message referring to a binding engagement must be confirmed in writing and duly signed. >>If you have received this email in error, please notify the sender immediately and delete the original. -------------------------------------------------------------------- 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] --------------------------------------------------------------------
