public class BasicCollectionPersister extends AbstractCollectionPersister
Collection persister for collections of values and many-to-many associations.
batchSize, elementColumnAliases, elementColumnIsInPrimaryKey, elementColumnIsSettable, elementColumnNames, elementColumnReaders, elementColumnReaderTemplates, elementColumnWriters, elementFormulas, elementFormulaTemplates, elementIsPureFormula, elementType, hasIdentifier, hasIndex, hasWhere, identifierColumnName, indexColumnAliases, indexColumnIsGettable, indexColumnIsSettable, indexColumnNames, indexContainsFormula, indexFormulas, indexFormulaTemplates, isInverse, keyColumnAliases, keyColumnNames, qualifiedTableName, recreateBatchKey, sqlExceptionHelper, sqlWhereString| Constructor and Description |
|---|
BasicCollectionPersister(Collection collectionBinding,
CollectionDataAccess cacheAccessStrategy,
PersisterCreationContext creationContext) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
consumesCollectionAlias()
Very, very, very ugly…
|
boolean |
consumesEntityAlias()
Very, very, very ugly…
|
protected CollectionInitializer |
createCollectionInitializer(LoadQueryInfluencers loadQueryInfluencers)
Create the <tt>CollectionLoader</tt>
|
protected CollectionInitializer |
createSubselectInitializer(SubselectFetch subselect,
SharedSessionContractImplementor session) |
protected void |
doProcessQueuedOps(PersistentCollection collection,
Serializable id,
SharedSessionContractImplementor session) |
protected int |
doUpdateRows(Serializable id,
PersistentCollection collection,
SharedSessionContractImplementor session) |
String |
fromJoinFragment(String alias,
boolean innerJoin,
boolean includeSubclasses)
Get the from clause part of any joins
(optional operation)
|
String |
fromJoinFragment(String alias,
boolean innerJoin,
boolean includeSubclasses,
Set<String> treatAsDeclarations)
Get the from clause part of any joins
(optional operation)
|
protected String |
generateDeleteRowString()
Generate the SQL DELETE that deletes a particular row
|
protected String |
generateDeleteString()
Generate the SQL DELETE that deletes all rows
|
protected String |
generateInsertRowString()
Generate the SQL INSERT that creates a new row
|
protected String |
generateUpdateRowString()
Generate the SQL UPDATE that updates a row
|
org.hibernate.internal.FilterAliasGenerator |
getFilterAliasGenerator(String rootAlias) |
boolean |
isCascadeDeleteEnabled()
Is cascade delete handled by the database-level
foreign key constraint definition?
|
boolean |
isManyToMany()
Is this a many-to-many association? Note that this is mainly
a convenience feature as the single persister does not
conatin all the information needed to handle a many-to-many
itself, as internally it is looked at as two many-to-ones.
|
boolean |
isOneToMany()
Is this a one-to-many association?
|
String |
selectFragment(Joinable rhs,
String rhsAlias,
String lhsAlias,
String entitySuffix,
String collectionSuffix,
boolean includeCollectionColumns)
All columns to select, when loading.
|
String |
whereJoinFragment(String alias,
boolean innerJoin,
boolean includeSubclasses)
Get the where clause part of any joins
(optional operation)
|
String |
whereJoinFragment(String alias,
boolean innerJoin,
boolean includeSubclasses,
Set<String> treatAsDeclarations)
Get the where clause part of any joins
(optional operation)
|
appendElementColumns, appendIdentifierColumns, appendIndexColumns, decrementIndexByBase, deleteRows, determineTableName, doProcessQueuedOps, elementExists, filterFragment, filterFragment, filterFragment, filterFragment, generateDetectRowByElementString, generateDetectRowByIndexString, generateSelectFragment, generateSelectRowByIndexString, generateSelectSizeString, getAppropriateInitializer, getBatchSize, getCacheAccessStrategy, getCacheEntryStructure, getCollectionMetadata, getCollectionPersister, getCollectionPropertyColumnAliases, getCollectionSpaces, getCollectionType, getDeleteAllCheckStyle, getDeleteCheckStyle, getDialect, getElementByIndex, getElementClass, getElementColumnAliases, getElementColumnNames, getElementColumnNames, getElementDefinition, getElementPersister, getElementType, getFactory, getFetchMode, getIdentifierColumnAlias, getIdentifierColumnName, getIdentifierGenerator, getIdentifierType, getIndexColumnAliases, getIndexColumnNames, getIndexColumnNames, getIndexDefinition, getIndexFormulas, getIndexType, getInitializer, getInsertCheckStyle, getKeyColumnAliases, getKeyColumnNames, getKeyType, getManyToManyFilterFragment, getManyToManyOrderByString, getMappedByProperty, getName, getNavigableRole, getOwnerEntityName, getOwnerEntityPersister, getRole, getSize, getSQLDeleteRowString, getSQLDeleteString, getSQLExceptionConverter, getSQLExceptionHelper, getSQLInsertRowString, getSQLOrderByString, getSQLUpdateRowString, getSQLWhereString, getTableName, getType, getUpdateCheckStyle, hasCache, hasIndex, hasManyToManyOrdering, hasOrdering, hasOrphanDelete, hasWhere, incrementIndexByBase, indexExists, initCollectionPropertyMap, initialize, insertRows, isAffectedByEnabledFilters, isArray, isCollection, isDeleteAllCallable, isDeleteCallable, isExtraLazy, isInsertCallable, isInverse, isLazy, isMutable, isPrimitiveArray, isRowDeleteEnabled, isRowInsertEnabled, isSubselectLoadable, isUpdateCallable, isVersioned, logStaticSQL, oneToManyFilterFragment, oneToManyFilterFragment, postInstantiate, processQueuedOps, readElement, readIdentifier, readIndex, readKey, recreate, remove, selectFragment, toColumns, toColumns, toString, toType, updateRows, writeElement, writeElementToWhere, writeIdentifier, writeIndex, writeIndexToWhere, writeKeypublic BasicCollectionPersister(Collection collectionBinding, CollectionDataAccess cacheAccessStrategy, PersisterCreationContext creationContext) throws MappingException, CacheException
MappingExceptionCacheExceptionpublic boolean isCascadeDeleteEnabled()
CollectionPersisterIs cascade delete handled by the database-level foreign key constraint definition?
protected String generateDeleteString()
Generate the SQL DELETE that deletes all rows
generateDeleteString in class AbstractCollectionPersisterprotected String generateInsertRowString()
Generate the SQL INSERT that creates a new row
generateInsertRowString in class AbstractCollectionPersisterprotected String generateUpdateRowString()
Generate the SQL UPDATE that updates a row
generateUpdateRowString in class AbstractCollectionPersisterprotected void doProcessQueuedOps(PersistentCollection collection, Serializable id, SharedSessionContractImplementor session)
doProcessQueuedOps in class AbstractCollectionPersisterprotected String generateDeleteRowString()
Generate the SQL DELETE that deletes a particular row
generateDeleteRowString in class AbstractCollectionPersisterpublic boolean consumesEntityAlias()
JoinableVery, very, very ugly…
public boolean consumesCollectionAlias()
JoinableVery, very, very ugly…
public boolean isOneToMany()
CollectionPersisterIs this a one-to-many association?
public boolean isManyToMany()
CollectionPersisterIs this a many-to-many association? Note that this is mainly a convenience feature as the single persister does not conatin all the information needed to handle a many-to-many itself, as internally it is looked at as two many-to-ones.
isManyToMany in interface CollectionPersisterisManyToMany in class AbstractCollectionPersisterprotected int doUpdateRows(Serializable id, PersistentCollection collection, SharedSessionContractImplementor session) throws HibernateException
doUpdateRows in class AbstractCollectionPersisterHibernateExceptionpublic String selectFragment(Joinable rhs, String rhsAlias, String lhsAlias, String entitySuffix, String collectionSuffix, boolean includeCollectionColumns)
JoinableAll columns to select, when loading.
protected CollectionInitializer createCollectionInitializer(LoadQueryInfluencers loadQueryInfluencers) throws MappingException
Create the <tt>CollectionLoader</tt>
createCollectionInitializer in class AbstractCollectionPersisterMappingExceptionBasicCollectionLoaderpublic String fromJoinFragment(String alias, boolean innerJoin, boolean includeSubclasses)
JoinableGet the from clause part of any joins (optional operation)
public String fromJoinFragment(String alias, boolean innerJoin, boolean includeSubclasses, Set<String> treatAsDeclarations)
JoinableGet the from clause part of any joins (optional operation)
public String whereJoinFragment(String alias, boolean innerJoin, boolean includeSubclasses)
JoinableGet the where clause part of any joins (optional operation)
public String whereJoinFragment(String alias, boolean innerJoin, boolean includeSubclasses, Set<String> treatAsDeclarations)
JoinableGet the where clause part of any joins (optional operation)
protected CollectionInitializer createSubselectInitializer(SubselectFetch subselect, SharedSessionContractImplementor session)
createSubselectInitializer in class AbstractCollectionPersisterpublic org.hibernate.internal.FilterAliasGenerator getFilterAliasGenerator(String rootAlias)
getFilterAliasGenerator in class AbstractCollectionPersisterCopyright © 2001-2018 Red Hat, Inc. All Rights Reserved.