There's no special trick; you just need to identify the set of rules that need to be removed, then undefine them one at a time. If you want to later undefine all the rules defined in an arbitrary CLP file, you could use a JessEvent listener to watch for DEFRULE events, store the names of the rules in a list, and then remove the rules named in the list later.


On May 30, 2008, at 9:57 AM, John Chrysakis wrote:

Hello to all jess users,

I want to apply a set of rules in the Working Memory and later to delete them. But I didn't find a way to do this for a set of rules. I found useful the
unDefRule method but it can be used only for one rule.

The main problem is that when we have a lot of rules (which maybe in
different clp files) it is desirable to apply a set of rules and later in
different situations to apply a set of some other rules and delete the
first ones. The reset method don't give me the solution because the rules remain defined so when I tried it all rules were fired (old and new ones which have true LHS, but this is not my goal)

Any ideas?

Thanks in advance.

..John..



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

---------------------------------------------------------
Ernest Friedman-Hill
Informatics & Decision Sciences          Phone: (925) 294-2154
Sandia National Labs                FAX:   (925) 294-2234
PO Box 969, MS 9012                 [EMAIL PROTECTED]
Livermore, CA 94550                 http://www.jessrules.com




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