All Packages Class Hierarchy This Package Previous Next Index
Interface com.roguewave.vsj.RestoreContext
- public interface RestoreContext
RestoreContext is an interface that allows you to keep
track of objects so that you can resolve back-references
to objects that were already read. Thus a RestoreContext
table can be used to maintain the shape of a graph of objects,
including those that contain circular references.
-
addElement(Object)
- Add an object to the read table.
-
elementAt(int)
- Return an object from the read table.
-
endContext()
- End the current persistence context.
-
inContext()
- Return true if currently within a persistence
context.
-
newContext()
- Begin a new persistence context.
-
newContext(int)
- Begin a new persistence context with initial capacity
for the given number of objects.
newContext
public abstract void newContext()
- Begin a new persistence context. A persistence context
defines the scope of back-references used for isomorphic
persistence.
newContext
public abstract void newContext(int initCapacity)
- Begin a new persistence context with initial capacity
for the given number of objects. A persistence context
defines the scope of back references used for isomorphic
persistence.
inContext
public abstract boolean inContext()
- Return true if currently within a persistence
context. That is, return true if newContext() has been
called, but endContext() has not.
endContext
public abstract void endContext()
- End the current persistence context. A persistence context
defines the scope of back references used for isomorphic
persistence. Note that if you start a persistence context
and fail to end it, the
RestoreContext will have to maintain references to all of the
objects read so far, keeping them from ever being reclaimed by
the garbage collector.
addElement
public abstract void addElement(Object obj)
- Add an object to the read table.
elementAt
public abstract Object elementAt(int idx)
- Return an object from the read table. The index idx
is a back reference to a previously read object.
All Packages Class Hierarchy This Package Previous Next Index