I think Mark Egloff wrote: > > Sounds for me like a classic design of an observer pattern. > For this of course you have to implement your own collection class. But > is not so hard as you think, because it is only in this case a wrapper. > > So I think we must first define what would happen if a collection is > changing using add() or remove(). My understanding is that in this case > Only facts are going to be adding or removed. Or have the rules also > automatically be fired in this case? If yes, then you need the > possibility to create central observer objects where you can register > the rules for firing. After that the observer is going to be registered > in the objects which are notifying him if some events are occurring. (or > the other way round) So the wrappers have a link to the observer and > the observer has links to the specific rules. > > Am I completely wrong with this concept? If not then we could go forward > and discuss some specific issues.
Generally, you've got the idea. There's a specific protocol that has to be followed for Jess's Rete algorithm to work properly; it actually dovetails pretty well with the PropertyChangeEvent paradigm. This part is not a problem; for the most part, if we can get events sent to Jess, then Jess knows what to do. The idea of creating standard wrappers for various Collections is a reasonable one. It won't help people who will want to be able to use unwrapped Collection objects, too, but it's a reasonable approach. --------------------------------------------------------- Ernest Friedman-Hill Distributed Systems Research Phone: (925) 294-2154 Sandia National Labs FAX: (925) 294-2234 PO Box 969, MS 9012 [EMAIL PROTECTED] Livermore, CA 94550 http://herzberg.ca.sandia.gov -------------------------------------------------------------------- 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] --------------------------------------------------------------------
