Class ContainerFieldStrategy
java.lang.Object
org.apache.openjpa.jdbc.meta.strats.AbstractStrategy
org.apache.openjpa.jdbc.meta.strats.AbstractFieldStrategy
org.apache.openjpa.jdbc.meta.strats.ContainerFieldStrategy
- All Implemented Interfaces:
Serializable,FieldStrategy,Strategy
- Direct Known Subclasses:
MapTableFieldStrategy,StoreCollectionFieldStrategy
An abstract container mapping that handles traversing the
join to examine the size of the relation.
- Author:
- Marc Prud'hommeaux
- See Also:
-
Field Summary
Fields inherited from class org.apache.openjpa.jdbc.meta.strats.AbstractFieldStrategy
field -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidappendIndex(SQLBuffer sql, Select sel, Joins joins) Append the ordered column alias to the given statement.voidappendIsEmpty(SQLBuffer sql, Select sel, Joins joins) Append a where clause to the given statement checking if this value is empty.voidappendIsNotEmpty(SQLBuffer sql, Select sel, Joins joins) Append a where clause to the given statement checking if this value is not empty.voidappendIsNotNull(SQLBuffer sql, Select sel, Joins joins) Append a where clause to the given statement checking if this value is not null.voidappendIsNull(SQLBuffer sql, Select sel, Joins joins) Append a where clause to the given statement checking if this value is null.protected static voidappendJoinCount(SQLBuffer sql, Select sel, Joins joins, DBDictionary dict, FieldMapping field, ForeignKey fk) voidappendSize(SQLBuffer sql, Select sel, Joins joins) Append a where clause to the given statement checking the size of the value.static voidappendUnaliasedJoin(SQLBuffer sql, Select sel, Joins joins, DBDictionary dict, FieldMapping field, ForeignKey fk) protected abstract ClassMapping[]getIndependentElementMappings(boolean traverse) Return all independent mappings to which this strategy must join in order to access collection elements, or empty array if none.abstract ForeignKeyMethods inherited from class org.apache.openjpa.jdbc.meta.strats.AbstractFieldStrategy
appendType, assertNotMappedBy, isEagerSelectToMany, isVersionable, join, joinKey, joinKeyRelation, joinRelation, load, load, loadEagerJoin, loadEagerParallel, loadKeyProjection, loadProjection, select, selectEagerJoin, selectEagerParallel, setFieldMapping, supportsSelect, toDataStoreValue, toKeyDataStoreValue, whereMethods inherited from class org.apache.openjpa.jdbc.meta.strats.AbstractStrategy
customDelete, customInsert, customUpdate, delete, getAlias, initialize, insert, isCustomDelete, isCustomInsert, isCustomUpdate, map, updateMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.openjpa.jdbc.meta.Strategy
customDelete, customInsert, customUpdate, delete, getAlias, initialize, insert, isCustomDelete, isCustomInsert, isCustomUpdate, map, update
-
Constructor Details
-
ContainerFieldStrategy
public ContainerFieldStrategy()
-
-
Method Details
-
getIndependentElementMappings
Return all independent mappings to which this strategy must join in order to access collection elements, or empty array if none.- Parameters:
traverse- whether we're traversing through to the related type- See Also:
-
appendIsEmpty
Description copied from interface:FieldStrategyAppend a where clause to the given statement checking if this value is empty. Appends impossible-to-satisfy SQL by default.- Specified by:
appendIsEmptyin interfaceFieldStrategy- Overrides:
appendIsEmptyin classAbstractFieldStrategy
-
appendIsNotEmpty
Description copied from interface:FieldStrategyAppend a where clause to the given statement checking if this value is not empty. Appends always-satisfied SQL by default.- Specified by:
appendIsNotEmptyin interfaceFieldStrategy- Overrides:
appendIsNotEmptyin classAbstractFieldStrategy
-
appendIsNull
Description copied from interface:FieldStrategyAppend a where clause to the given statement checking if this value is null.- Specified by:
appendIsNullin interfaceFieldStrategy- Overrides:
appendIsNullin classAbstractFieldStrategy
-
appendIsNotNull
Description copied from interface:FieldStrategyAppend a where clause to the given statement checking if this value is not null.- Specified by:
appendIsNotNullin interfaceFieldStrategy- Overrides:
appendIsNotNullin classAbstractFieldStrategy
-
getJoinForeignKey
-
appendSize
Description copied from interface:FieldStrategyAppend a where clause to the given statement checking the size of the value.- Specified by:
appendSizein interfaceFieldStrategy- Overrides:
appendSizein classAbstractFieldStrategy
-
appendIndex
Description copied from interface:FieldStrategyAppend the ordered column alias to the given statement.- Specified by:
appendIndexin interfaceFieldStrategy- Overrides:
appendIndexin classAbstractFieldStrategy
-
appendJoinCount
protected static void appendJoinCount(SQLBuffer sql, Select sel, Joins joins, DBDictionary dict, FieldMapping field, ForeignKey fk) -
appendUnaliasedJoin
public static void appendUnaliasedJoin(SQLBuffer sql, Select sel, Joins joins, DBDictionary dict, FieldMapping field, ForeignKey fk)
-