Package org.drools.core.common
Class ClassAwareObjectStore
- java.lang.Object
-
- org.drools.core.common.ClassAwareObjectStore
-
- All Implemented Interfaces:
Externalizable,Serializable,ObjectStore
public class ClassAwareObjectStore extends Object implements Externalizable, ObjectStore
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceClassAwareObjectStore.SingleClassStore
-
Constructor Summary
Constructors Constructor Description ClassAwareObjectStore()ClassAwareObjectStore(boolean isEqualityBehaviour, Lock lock)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddHandle(InternalFactHandle handle, Object object)voidclear()booleanclearClassStore(Class<?> clazz)static Class<?>getActualClass(Object object)InternalFactHandlegetHandleForObject(Object object)InternalFactHandlegetHandleForObjectIdentity(Object object)ObjectgetObjectForHandle(InternalFactHandle handle)ClassAwareObjectStore.SingleClassStoregetOrCreateClassStore(Class<?> clazz)FactHandleClassStoregetStoreForClass(Class<?> clazz)booleanisEmpty()Iterator<InternalFactHandle>iterateFactHandles()This class is not thread safe, changes to the working memory during iteration may give unexpected resultsIterator<InternalFactHandle>iterateFactHandles(org.kie.api.runtime.ObjectFilter filter)This class is not thread safe, changes to the working memory during iteration may give unexpected resultsIterator<InternalFactHandle>iterateNegFactHandles(org.kie.api.runtime.ObjectFilter filter)Iterator<Object>iterateNegObjects(org.kie.api.runtime.ObjectFilter filter)Iterator<Object>iterateObjects()This class is not thread safe, changes to the working memory during iteration may give unexpected resultsIterator<Object>iterateObjects(Class<?> clazz)Iterator<Object>iterateObjects(org.kie.api.runtime.ObjectFilter filter)This class is not thread safe, changes to the working memory during iteration may give unexpected resultsvoidreadExternal(ObjectInput in)InternalFactHandlereconnect(InternalFactHandle handle)voidremoveHandle(InternalFactHandle handle)intsize()voidupdateHandle(InternalFactHandle handle, Object object)voidwriteExternal(ObjectOutput out)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.drools.core.common.ObjectStore
iterateFactHandles
-
-
-
-
Constructor Detail
-
ClassAwareObjectStore
public ClassAwareObjectStore()
-
ClassAwareObjectStore
public ClassAwareObjectStore(boolean isEqualityBehaviour, Lock lock)
-
-
Method Detail
-
writeExternal
public void writeExternal(ObjectOutput out) throws IOException
- Specified by:
writeExternalin interfaceExternalizable- Throws:
IOException
-
readExternal
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
- Specified by:
readExternalin interfaceExternalizable- Throws:
IOExceptionClassNotFoundException
-
size
public int size()
- Specified by:
sizein interfaceObjectStore
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmptyin interfaceObjectStore
-
clear
public void clear()
- Specified by:
clearin interfaceObjectStore
-
getObjectForHandle
public Object getObjectForHandle(InternalFactHandle handle)
- Specified by:
getObjectForHandlein interfaceObjectStore
-
reconnect
public InternalFactHandle reconnect(InternalFactHandle handle)
- Specified by:
reconnectin interfaceObjectStore
-
getHandleForObject
public InternalFactHandle getHandleForObject(Object object)
- Specified by:
getHandleForObjectin interfaceObjectStore
-
getHandleForObjectIdentity
public InternalFactHandle getHandleForObjectIdentity(Object object)
- Specified by:
getHandleForObjectIdentityin interfaceObjectStore
-
updateHandle
public void updateHandle(InternalFactHandle handle, Object object)
- Specified by:
updateHandlein interfaceObjectStore
-
addHandle
public void addHandle(InternalFactHandle handle, Object object)
- Specified by:
addHandlein interfaceObjectStore
-
removeHandle
public void removeHandle(InternalFactHandle handle)
- Specified by:
removeHandlein interfaceObjectStore
-
iterateObjects
public Iterator<Object> iterateObjects()
Description copied from interface:ObjectStoreThis class is not thread safe, changes to the working memory during iteration may give unexpected results- Specified by:
iterateObjectsin interfaceObjectStore
-
iterateObjects
public Iterator<Object> iterateObjects(org.kie.api.runtime.ObjectFilter filter)
Description copied from interface:ObjectStoreThis class is not thread safe, changes to the working memory during iteration may give unexpected results- Specified by:
iterateObjectsin interfaceObjectStore
-
iterateFactHandles
public Iterator<InternalFactHandle> iterateFactHandles()
Description copied from interface:ObjectStoreThis class is not thread safe, changes to the working memory during iteration may give unexpected results- Specified by:
iterateFactHandlesin interfaceObjectStore
-
iterateFactHandles
public Iterator<InternalFactHandle> iterateFactHandles(org.kie.api.runtime.ObjectFilter filter)
Description copied from interface:ObjectStoreThis class is not thread safe, changes to the working memory during iteration may give unexpected results- Specified by:
iterateFactHandlesin interfaceObjectStore
-
iterateNegObjects
public Iterator<Object> iterateNegObjects(org.kie.api.runtime.ObjectFilter filter)
- Specified by:
iterateNegObjectsin interfaceObjectStore
-
iterateNegFactHandles
public Iterator<InternalFactHandle> iterateNegFactHandles(org.kie.api.runtime.ObjectFilter filter)
- Specified by:
iterateNegFactHandlesin interfaceObjectStore
-
getStoreForClass
public FactHandleClassStore getStoreForClass(Class<?> clazz)
- Specified by:
getStoreForClassin interfaceObjectStore
-
clearClassStore
public boolean clearClassStore(Class<?> clazz)
- Specified by:
clearClassStorein interfaceObjectStore
-
getOrCreateClassStore
public ClassAwareObjectStore.SingleClassStore getOrCreateClassStore(Class<?> clazz)
-
-