Package jade.domain.KBManagement
Class MemKB
- java.lang.Object
-
- jade.domain.KBManagement.KB
-
- jade.domain.KBManagement.MemKB
-
-
Field Summary
Fields Modifier and Type Field Description protected intcurrentRegprotected Mapfactsprotected LeaseManagerlmprotected static intMAX_REGISTER_WITHOUT_CLEANprotected SubscriptionRespondersrprotected Hashtablesubscriptions
-
Constructor Summary
Constructors Constructor Description MemKB(int maxResultLimit)
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract voidclean()EnumerationgetSubscriptionDfAgentDescriptions()EnumerationgetSubscriptions()EnumerationgetSubscriptions(int offset)protected Objectinsert(Object name, Object fact)KBIteratoriterator(Object template)Iterated search is only supported in a DB-based KB.protected abstract booleanmatch(Object template, Object fact)static booleanmatchAID(AID template, AID fact)protected Objectremove(Object name)Listsearch(Object template, int maxResults)voidsubscribe(Object dfd, SubscriptionResponder.Subscription s)voidunsubscribe(SubscriptionResponder.Subscription sub)-
Methods inherited from class jade.domain.KBManagement.KB
deregister, register, search, setLeaseManager, setSubscriptionResponder
-
-
-
-
Field Detail
-
facts
protected Map facts
-
subscriptions
protected Hashtable subscriptions
-
lm
protected LeaseManager lm
-
currentReg
protected int currentReg
-
sr
protected SubscriptionResponder sr
-
MAX_REGISTER_WITHOUT_CLEAN
protected static final int MAX_REGISTER_WITHOUT_CLEAN
- See Also:
- Constant Field Values
-
-
Method Detail
-
clean
protected abstract void clean()
-
iterator
public KBIterator iterator(Object template)
Iterated search is only supported in a DB-based KB. Throw a RuntimeException. The requester will get back a FAILURE
-
subscribe
public void subscribe(Object dfd, SubscriptionResponder.Subscription s) throws NotUnderstoodException
- Specified by:
subscribein classKB- Throws:
NotUnderstoodException
-
getSubscriptionDfAgentDescriptions
public Enumeration getSubscriptionDfAgentDescriptions()
-
getSubscriptions
public Enumeration getSubscriptions()
- Specified by:
getSubscriptionsin classKB
-
getSubscriptions
public Enumeration getSubscriptions(int offset)
-
unsubscribe
public void unsubscribe(SubscriptionResponder.Subscription sub)
- Specified by:
unsubscribein classKB
-
-