org.objectweb.jorm.api
Interface PGenClassAccessor
- PAccessor, PIndexedElemFactory
- PAccessorGenClass
public interface PGenClassAccessor
The PGenClassAccessor interface defines the Accessor for all
generic classes. These methods are the same for all generic classes, they
are defined by this unique interface that extends the PAccessor
interface. Notice that all accessor methods are also prefixed with "pa".
It is also a factory of PIndexedElem that defines the object used by the
bindings in order to store the generic class element, and that are
implemented by generic class MI.
- R. Basset, P. Dechamboux
void | paAdd(PIndexedElem elem, Object conn) - It passes one of the elements extracted from the data store to the
memory instance.
|
boolean | paDeltaSupported() - It tells if the generic class memory instance supports delta
modifications, which means that paadded, padeleted and pamodified are
supported.
|
int | paGetNbElem() - It retrieves the number of elements contained within the generic class
memory instance before storing it.
|
Iterator | paIterator() - It returns an Iterator over the elements of a generic class memory
instance.
|
void | paSetNbElem(int nbelem) - It passes the number of elements contained within the generic class DSI
to the memory instance.
|
paAdd
public void paAdd(PIndexedElem elem,
Object conn)
throws PException
It passes one of the elements extracted from the data store to the
memory instance.
elem
- the PIndexElenm to be added to the memory instance.conn
- the connection to the DS
paDeltaSupported
public boolean paDeltaSupported()
It tells if the generic class memory instance supports delta
modifications, which means that paadded, padeleted and pamodified are
supported.
- It return true is delta is supported by the memory instance.
paGetNbElem
public int paGetNbElem()
It retrieves the number of elements contained within the generic class
memory instance before storing it. This is the number of element that
should remain into the DSI after writing.
- The number of elements within the memory instance of this
generic class.
paIterator
public Iterator paIterator()
It returns an Iterator over the elements of a generic class memory
instance. It scans all elements of the MI, their modification flag be
ELEM_CREATED, ELEM_DELETED, ELEM_MODIFIED or ELEM_UNMODIFIED. The
PBinding can then store them into the related DSI.
- The Iterator over the memory instance elements.
paSetNbElem
public void paSetNbElem(int nbelem)
It passes the number of elements contained within the generic class DSI
to the memory instance. This is done just before lements are passed to
the memory instance using the paAdd method.
nbelem
- The number of elements within this generic class DSI.