Hello everybody,

Is it possible to activate a rule if only all facts of a given deftemplate match with it ?

I mean suppose that I have deftemplate :

(deftemplate my-template (slot my-slot))

(reset)

(assert (my-template (my-slot TRUE)))
(assert (my-template (my-slot TRUE)))
(assert (my-template (my-slot TRUE)))

;; And the following rule :

(defrule my-rule
 (ALL (my-template (my-slot TRUE)))
=>
 (printout t "All my-slot are TRUE !" crlf)
)

(run)

Thanks in advance,

Regards.

Nicolas

_________________________________________________________________
À faire rêver : des endroits célèbres à voir http://search.live.com/images/results.aspx?q=Endroits+c%C3%A9l%C3%A8bres++&mkt=fr-ca&FORM=SERNEP


--------------------------------------------------------------------
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]
--------------------------------------------------------------------

Reply via email to