Package org.apache.openjpa.slice.jdbc
Class TargetFetchConfiguration
java.lang.Object
org.apache.openjpa.kernel.FetchConfigurationImpl
org.apache.openjpa.jdbc.kernel.JDBCFetchConfigurationImpl
org.apache.openjpa.slice.jdbc.TargetFetchConfiguration
- All Implemented Interfaces:
Serializable,Cloneable,EagerFetchModes,JDBCFetchConfiguration,LRSSizes,JoinSyntaxes,FetchConfiguration,LockLevels,LockScopes,QueryFlushModes
public class TargetFetchConfiguration
extends JDBCFetchConfigurationImpl
implements FetchConfiguration
A fetch configuration that is aware of special hint to narrow its operation on
subset of slices.
- Author:
- Pinaki Poddar
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.openjpa.jdbc.kernel.JDBCFetchConfigurationImpl
JDBCFetchConfigurationImpl.JDBCConfigurationStateNested classes/interfaces inherited from class org.apache.openjpa.kernel.FetchConfigurationImpl
FetchConfigurationImpl.ConfigurationState -
Field Summary
Fields inherited from class org.apache.openjpa.jdbc.kernel.JDBCFetchConfigurationImpl
_stateFields inherited from interface org.apache.openjpa.jdbc.kernel.EagerFetchModes
EAGER_JOIN, EAGER_NONE, EAGER_PARALLELFields inherited from interface org.apache.openjpa.kernel.FetchConfiguration
DEFAULT, FETCH_LOAD, FETCH_NONE, FETCH_REFFields inherited from interface org.apache.openjpa.jdbc.sql.JoinSyntaxes
SYNTAX_DATABASE, SYNTAX_SQL92, SYNTAX_TRADITIONALFields inherited from interface org.apache.openjpa.kernel.LockLevels
LOCK_NONE, LOCK_READ, LOCK_WRITEFields inherited from interface org.apache.openjpa.kernel.LockScopes
LOCKSCOPE_EXTENDED, LOCKSCOPE_NORMALFields inherited from interface org.apache.openjpa.jdbc.kernel.LRSSizes
SIZE_LAST, SIZE_QUERY, SIZE_UNKNOWNFields inherited from interface org.apache.openjpa.kernel.QueryFlushModes
FLUSH_FALSE, FLUSH_TRUE, FLUSH_WITH_CONNECTION -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedTargetFetchConfiguration(FetchConfigurationImpl.ConfigurationState state, JDBCFetchConfigurationImpl.JDBCConfigurationState jstate) -
Method Summary
Modifier and TypeMethodDescriptionbooleanAffirms if the target is set on this receiver explicitly (i.e. by the user).protected TargetFetchConfigurationReturn a new hollow instance.voidSetting hints on this configuration is treated specially if the given key is a target hint.voidSets the hint to the given value.voidsetTargets(String[] targets) Methods inherited from class org.apache.openjpa.jdbc.kernel.JDBCFetchConfigurationImpl
addFetchInnerJoin, addFetchInnerJoins, addJoin, addJoins, clearJoins, copy, getEagerFetchMode, getFetchDirection, getFetchInnerJoins, getIgnoreDfgForFkSelect, getIsolation, getJoins, getJoinSyntax, getLRSSize, getResultSetType, getSubclassFetchMode, getSubclassFetchMode, hasFetchInnerJoin, hasJoin, newResultList, removeJoin, removeJoins, setContext, setEagerFetchMode, setFetchDirection, setIgnoreDfgForFkSelect, setIsolation, setJoinSyntax, setLRSSize, setResultSetType, setSubclassFetchMode, traverseJDBCMethods inherited from class org.apache.openjpa.kernel.FetchConfigurationImpl
addFetchGroup, addFetchGroups, addField, addFields, clearFetchGroups, clearFields, clone, getCacheRetrieveMode, getCacheStoreMode, getContext, getExtendedPathLookup, getFetchBatchSize, getFetchGroups, getFields, getFlushBeforeQueries, getHint, getHints, getLockScope, getLockTimeout, getMaxFetchDepth, getQueryCacheEnabled, getQueryTimeout, getReadLockLevel, getRootClasses, getRootInstances, getSupportedHints, getWriteLockLevel, hasFetchGroup, hasFetchGroupAll, hasFetchGroupDefault, hasField, isDefaultPUFetchGroupConfigurationOnly, isFetchConfigurationSQLCacheAdmissible, isHintSet, lock, populateHintSetter, populateHintSetter, removeFetchGroup, removeFetchGroups, removeField, removeFields, removeHint, removeHint, requiresFetch, requiresLoad, resetFetchGroups, setCacheRetrieveMode, setCacheStoreMode, setExtendedPathLookup, setFetchBatchSize, setFlushBeforeQueries, setLockScope, setLockTimeout, setMaxFetchDepth, setQueryCacheEnabled, setQueryTimeout, setReadLockLevel, setRootClasses, setRootInstances, setWriteLockLevel, toString, toString, traverse, unlockMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.openjpa.kernel.FetchConfiguration
addFetchGroup, addFetchGroups, addField, addFields, clearFetchGroups, clearFields, clone, copy, getCacheRetrieveMode, getCacheStoreMode, getContext, getExtendedPathLookup, getFetchBatchSize, getFetchGroups, getFields, getFlushBeforeQueries, getHint, getHints, getLockScope, getLockTimeout, getMaxFetchDepth, getQueryCacheEnabled, getQueryTimeout, getReadLockLevel, getRootClasses, getRootInstances, getWriteLockLevel, hasFetchGroup, hasField, isDefaultPUFetchGroupConfigurationOnly, isFetchConfigurationSQLCacheAdmissible, isHintSet, lock, newResultList, removeFetchGroup, removeFetchGroups, removeField, removeFields, requiresFetch, requiresLoad, resetFetchGroups, setCacheRetrieveMode, setCacheStoreMode, setContext, setExtendedPathLookup, setFetchBatchSize, setFlushBeforeQueries, setLockScope, setLockTimeout, setMaxFetchDepth, setQueryCacheEnabled, setQueryTimeout, setReadLockLevel, setRootClasses, setRootInstances, setWriteLockLevel, traverse, unlock
-
Constructor Details
-
TargetFetchConfiguration
public TargetFetchConfiguration() -
TargetFetchConfiguration
protected TargetFetchConfiguration(FetchConfigurationImpl.ConfigurationState state, JDBCFetchConfigurationImpl.JDBCConfigurationState jstate)
-
-
Method Details
-
setHint
Setting hints on this configuration is treated specially if the given key is a target hint.- Specified by:
setHintin interfaceFetchConfiguration- Overrides:
setHintin classFetchConfigurationImpl- Parameters:
value- if the given key is target hint, then the value can be either null, a String or a non-zero sized String array. It can not be a zero-sized String array.- See Also:
-
setHint
Description copied from class:FetchConfigurationImplSets the hint to the given value. If the key corresponds to a known key, then that value is set via the setter method. Otherwise it is put into opaque hints map.
In either case, the original value is put in the hints map. So essential difference between setting a value directly by a setter and via a hint is the memory of this original value.
The other important difference is setting lock levels. Setting of lock level via setter method needs active transaction. But setting via hint does not.- Specified by:
setHintin interfaceFetchConfiguration- Overrides:
setHintin classFetchConfigurationImpl- Parameters:
key- a hint key. If it is one of the statically registered hint key then the setter is called.value- to be set. The given value type must match the argument type of the setter, if one exists.original- value as specified by the caller. This value is put in the hints map.
-
setTargets
-
isExplicitTarget
public boolean isExplicitTarget()Affirms if the target is set on this receiver explicitly (i.e. by the user). -
newInstance
Description copied from class:FetchConfigurationImplReturn a new hollow instance.- Overrides:
newInstancein classJDBCFetchConfigurationImpl
-