Save This Page
Home » apache-openjpa-1.1.0-source » org.apache.openjpa.jdbc » meta » strats » [javadoc | source]
org.apache.openjpa.jdbc.meta.strats
abstract public class: StoreCollectionFieldStrategy [javadoc | source]
java.lang.Object
   org.apache.openjpa.jdbc.meta.strats.AbstractStrategy
      org.apache.openjpa.jdbc.meta.strats.AbstractFieldStrategy
         org.apache.openjpa.jdbc.meta.strats.ContainerFieldStrategy
            org.apache.openjpa.jdbc.meta.strats.StoreCollectionFieldStrategy

All Implemented Interfaces:
    FieldStrategy, Strategy

Direct Known Subclasses:
    HandlerCollectionTableFieldStrategy, RelationMapTableFieldStrategy, RelationToManyInverseKeyFieldStrategy, RelationCollectionTableFieldStrategy, RelationCollectionInverseKeyFieldStrategy, RelationMapInverseKeyFieldStrategy, RelationToManyTableFieldStrategy

Base class for strategies that are stored as a collection, even if their field value is something else. Handles data loading and basic query functionality. Subclasses must implement abstract methods and insert/update/delete behavior as well as overriding FieldStrategy#toDataStoreValue , FieldStrategy#join , and FieldStrategy#joinRelation if necessary.
Fields inherited from org.apache.openjpa.jdbc.meta.strats.AbstractFieldStrategy:
field
Method from org.apache.openjpa.jdbc.meta.strats.StoreCollectionFieldStrategy Summary:
add,   getJoinForeignKey,   getJoinForeignKey,   isEagerSelectToMany,   join,   joinElementRelation,   load,   loadEagerJoin,   loadEagerParallel,   loadElement,   loadProjection,   newLRSProxy,   selectAll,   selectEagerJoin,   selectEagerParallel,   selectElement,   supportsSelect,   toCollection
Methods from org.apache.openjpa.jdbc.meta.strats.ContainerFieldStrategy:
appendIsEmpty,   appendIsNotEmpty,   appendIsNotNull,   appendIsNull,   appendJoinCount,   appendSize,   appendUnaliasedJoin,   getIndependentElementMappings,   getJoinForeignKey
Methods from org.apache.openjpa.jdbc.meta.strats.AbstractFieldStrategy:
appendIsEmpty,   appendIsNotEmpty,   appendIsNotNull,   appendIsNull,   appendSize,   assertNotMappedBy,   isEagerSelectToMany,   isVersionable,   join,   joinKey,   joinKeyRelation,   joinRelation,   load,   load,   loadEagerJoin,   loadEagerParallel,   loadKeyProjection,   loadProjection,   select,   selectEagerJoin,   selectEagerParallel,   setFieldMapping,   supportsSelect,   toDataStoreValue,   toKeyDataStoreValue,   where
Methods from org.apache.openjpa.jdbc.meta.strats.AbstractStrategy:
customDelete,   customInsert,   customUpdate,   delete,   getAlias,   initialize,   insert,   isCustomDelete,   isCustomInsert,   isCustomUpdate,   map,   update
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.openjpa.jdbc.meta.strats.StoreCollectionFieldStrategy Detail:
 protected  void add(JDBCStore store,
    Object coll,
    Object obj) 
    Add an item to the data structure representing a field value. By default, assumes the structure is a collection.
 protected ForeignKey getJoinForeignKey() 
 abstract protected ForeignKey getJoinForeignKey(ClassMapping elem)
 public boolean isEagerSelectToMany() 
 abstract protected Joins join(Joins joins,
    ClassMapping elem)
 abstract protected Joins joinElementRelation(Joins joins,
    ClassMapping elem)
 public  void load(OpenJPAStateManager sm,
    JDBCStore store,
    JDBCFetchConfiguration fetch) throws SQLException 
 public  void loadEagerJoin(OpenJPAStateManager sm,
    JDBCStore store,
    JDBCFetchConfiguration fetch,
    Result res) throws SQLException 
 public Object loadEagerParallel(OpenJPAStateManager sm,
    JDBCStore store,
    JDBCFetchConfiguration fetch,
    Object res) throws SQLException 
 abstract protected Object loadElement(OpenJPAStateManager sm,
    JDBCStore store,
    JDBCFetchConfiguration fetch,
    Result res,
    Joins joins) throws SQLException
    Load an element of the collection. The given state manager might be null if the load is for a projection or for processing eager parallel results.
 public Object loadProjection(JDBCStore store,
    JDBCFetchConfiguration fetch,
    Result res,
    Joins joins) throws SQLException 
 abstract protected Proxy newLRSProxy()
    Return a large result set proxy for this field.
 protected Joins selectAll(Select sel,
    ClassMapping elem,
    OpenJPAStateManager sm,
    JDBCStore store,
    JDBCFetchConfiguration fetch,
    int eagerMode) 
    Select data for loading, starting in field table.
 public  void selectEagerJoin(Select sel,
    OpenJPAStateManager sm,
    JDBCStore store,
    JDBCFetchConfiguration fetch,
    int eagerMode) 
 public  void selectEagerParallel(SelectExecutor sel,
    OpenJPAStateManager sm,
    JDBCStore store,
    JDBCFetchConfiguration fetch,
    int eagerMode) 
 abstract protected  void selectElement(Select sel,
    ClassMapping elem,
    JDBCStore store,
    JDBCFetchConfiguration fetch,
    int eagerMode,
    Joins joins)
 public int supportsSelect(Select sel,
    int type,
    OpenJPAStateManager sm,
    JDBCStore store,
    JDBCFetchConfiguration fetch) 
 protected Collection toCollection(Object val) 
    Convert the field value to a collection. Handles collections and arrays by default.