org.jboss.cache.pojo.memory
Class PersistentReference
java.lang.Object
org.jboss.cache.pojo.memory.PersistentReference
- Direct Known Subclasses:
- ArgumentPersistentReference, EmptyReference, FieldPersistentReference
public abstract class PersistentReference
- extends Object
Base class for persistent references.
Persistent reference is a Weak/Soft reference to a reflection object.
If the reflection object is garbage collected, the reference is then rebuilt using reflection operations.
- Author:
- csuconic
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
REFERENCE_SOFT
public static final int REFERENCE_SOFT
- See Also:
- Constant Field Values
PersistentReference
public PersistentReference(Class clazz,
Object referencedObject,
int referenceType)
- Parameters:
clazz
- The clazz being used on this object (where we will do reflection operations)referencedObject
- The reflection object being usedreferenceType
- if REFERENCE_WEAK will use a WeakReference, and if REFERENCE_SOFT will use a SoftReference for referencedObject
get
public Object get()
rebuildReference
protected abstract Object rebuildReference()
throws Exception
- Throws:
Exception
Copyright © 2008 JBoss, a division of Red Hat. All Rights Reserved.