org.eclipse.emf.cdo.server.db.mapping
Interface IListMapping

All Known Subinterfaces:
IListMapping2

public interface IListMapping

Interface for mapping features with isMany() == true.

Since:
2.0

Method Summary
 Collection<IDBTable> getDBTables()
          Returns all DB tables which are used by this feature.
 EStructuralFeature getFeature()
          Return the mapped feature.
 void objectDetached(IDBStoreAccessor accessor, CDOID id, long revised)
          Hook with which a list mapping is notified that a containing object has been revised.
 boolean queryXRefs(IDBStoreAccessor accessor, String mainTableName, String mainTableWhere, IStoreAccessor.QueryXRefsContext context, String idString)
          Retrieve cross-references from DB.
 void readChunks(IDBStoreChunkReader dbStoreChunkReader, List<IStoreChunkReader.Chunk> chunks, String where)
          Used to load-on-demand chunks of a list.
 void readValues(IDBStoreAccessor accessor, InternalCDORevision revision, int listChunk)
          Read the list size and the complete list or the first part of it.
 void writeValues(IDBStoreAccessor accessor, InternalCDORevision revision)
          Write a complete list of values to the database.
 

Method Detail

getFeature

EStructuralFeature getFeature()
Return the mapped feature.

Returns:
the mapped feature.

getDBTables

Collection<IDBTable> getDBTables()
Returns all DB tables which are used by this feature.

Returns:
a collection of all tables of this feature.

writeValues

void writeValues(IDBStoreAccessor accessor,
                 InternalCDORevision revision)
Write a complete list of values to the database.

Parameters:
accessor - the accessor to use.
revision - the revision containing the list to be written.

readValues

void readValues(IDBStoreAccessor accessor,
                InternalCDORevision revision,
                int listChunk)
Read the list size and the complete list or the first part of it.

Parameters:
accessor - the accessor to use.
revision - the revision into which the list values should be read.
listChunk - indicating the lazy loading behavior: CDORevision.UNCHUNKED means that the whole list should be read. Else, if listChunk >= 0, the list is filled with InternalCDOList.UNINITIALIZED and only the first listChunk values are read.

readChunks

void readChunks(IDBStoreChunkReader dbStoreChunkReader,
                List<IStoreChunkReader.Chunk> chunks,
                String where)
Used to load-on-demand chunks of a list.

Parameters:
dbStoreChunkReader - the chunkReader to use
chunks - the chunks to read
where - the where-clause to use in order to read the chunks.

objectDetached

void objectDetached(IDBStoreAccessor accessor,
                    CDOID id,
                    long revised)
Hook with which a list mapping is notified that a containing object has been revised. Can be implemented in order to clean up lists of revised objects.

Parameters:
accessor - the accessor to use.
id - the ID of the object which has been revised.
revised - the timestamp at which the object was revised.
Since:
3.0

queryXRefs

boolean queryXRefs(IDBStoreAccessor accessor,
                   String mainTableName,
                   String mainTableWhere,
                   IStoreAccessor.QueryXRefsContext context,
                   String idString)
Retrieve cross-references from DB.

Since:
4.0
See Also:
IClassMapping.queryXRefs(IDBStoreAccessor, IStoreAccessor.QueryXRefsContext, String), IStoreAccessor.queryXRefs(IStoreAccessor.QueryXRefsContext)


Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) and others.