Class IndexedListAttributeFlusher<E,V extends List<?>>
java.lang.Object
com.blazebit.persistence.view.impl.update.flush.AttributeFetchGraphNode<X>
com.blazebit.persistence.view.impl.update.flush.AbstractPluralAttributeFlusher<CollectionAttributeFlusher<E,V>,CollectionAction<?>,RecordingCollection<?,?>,E,V>
com.blazebit.persistence.view.impl.update.flush.CollectionAttributeFlusher<E,V>
com.blazebit.persistence.view.impl.update.flush.IndexedListAttributeFlusher<E,V>
- All Implemented Interfaces:
DirtyChecker<V>,PluralDirtyChecker<V,,E> DirtyAttributeFlusher<CollectionAttributeFlusher<E,,V>, E, V> FetchGraphNode<CollectionAttributeFlusher<E,V>>
public class IndexedListAttributeFlusher<E,V extends List<?>>
extends CollectionAttributeFlusher<E,V>
- Since:
- 1.2.0
- Author:
- Christian Beikov
-
Nested Class Summary
Nested classes/interfaces inherited from class com.blazebit.persistence.view.impl.update.flush.AbstractPluralAttributeFlusher
AbstractPluralAttributeFlusher.DeepEqualityChecker, AbstractPluralAttributeFlusher.EntityIdWithViewIdEqualityChecker, AbstractPluralAttributeFlusher.EntityWithViewEqualityChecker, AbstractPluralAttributeFlusher.EntryState, AbstractPluralAttributeFlusher.EqualityChecker, AbstractPluralAttributeFlusher.EqualsEqualityChecker, AbstractPluralAttributeFlusher.IdentityEqualityChecker, AbstractPluralAttributeFlusher.PluralFlushOperationNested classes/interfaces inherited from interface com.blazebit.persistence.view.impl.change.DirtyChecker
DirtyChecker.DirtyKind -
Field Summary
Fields inherited from class com.blazebit.persistence.view.impl.update.flush.AbstractPluralAttributeFlusher
cascadeDeleteListener, collectionActions, collectionUpdatable, elementDescriptor, elementDirtyChecker, elementEqualityChecker, elementFlusher, elementFlushers, entityAttributeAccessor, flushOperation, flushStrategy, jpaProviderDeletesCollection, optimisticLockProtected, ownerEntityClass, ownerIdAttributeName, ownerIdBindFragments, ownerIdFlusher, ownerIdWhereFragment, ownerMapping, removeListener, replaceWithReferenceContents, supportsCollectionDml, viewAttributeAccessor, viewOnlyDeleteCascadedFields inherited from class com.blazebit.persistence.view.impl.update.flush.AttributeFetchGraphNode
attributeName, fetch, mapping -
Constructor Summary
ConstructorsConstructorDescriptionIndexedListAttributeFlusher(IndexedListAttributeFlusher<E, V> original, boolean fetch) IndexedListAttributeFlusher(IndexedListAttributeFlusher<E, V> original, boolean fetch, AbstractPluralAttributeFlusher.PluralFlushOperation flushOperation, List<? extends CollectionAction<?>> collectionActions, List<CollectionElementAttributeFlusher<E, V>> elementFlushers) IndexedListAttributeFlusher(String attributeName, String mapping, Class<?> ownerEntityClass, String ownerIdAttributeName, String ownerMapping, DirtyAttributeFlusher<?, ?, ?> ownerIdFlusher, DirtyAttributeFlusher<?, ?, ?> elementFlusher, boolean supportsCollectionDml, FlushStrategy flushStrategy, AttributeAccessor attributeMapper, InitialValueAttributeAccessor viewAttributeAccessor, boolean optimisticLockProtected, boolean collectionUpdatable, boolean viewOnlyDeleteCascaded, boolean jpaProviderDeletesCollection, CollectionRemoveListener cascadeDeleteListener, CollectionRemoveListener removeListener, CollectionInstantiatorImplementor<?, ?> collectionInstantiator, TypeDescriptor elementDescriptor, InverseFlusher<E> inverseFlusher, InverseRemoveStrategy inverseRemoveStrategy) -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddElements(UpdateContext context, Object ownerView, Object view, Collection<Object> removedAllObjects, boolean flushAtOnce, boolean removedAllWithoutCollectionActions, V value, List<Object> embeddablesToUpdate, FusedCollectionActions fusedCollectionActions, boolean initialKnown) protected voidaddFlatViewElementFlushActions(UpdateContext context, TypeDescriptor typeDescriptor, List<CollectionAction<?>> actions, V current) protected Collection<Object>appendRemoveSpecific(UpdateContext context, DeleteCriteriaBuilder<?> deleteCb, FusedCollectionActions fusedCollectionActions) protected booleanprotected booleancollectionEquals(V initial, V current) protected List<CollectionAction<Collection<?>>>determineCollectionActions(UpdateContext context, V initial, V current, AbstractPluralAttributeFlusher.EqualityChecker equalityChecker) protected List<CollectionAction<Collection<?>>>determineJpaCollectionActions(UpdateContext context, V jpaCollection, V value, AbstractPluralAttributeFlusher.EqualityChecker equalityChecker) getDirtyKind(V initial, V current) Returns the dirty kind of the objects.protected FusedCollectionActionsgetFusedOperations(List<? extends CollectionAction<?>> collectionActions) protected booleanprotected booleanmergeAndRequeue(UpdateContext context, RecordingCollection recordingCollection, Collection<Object> newCollection) protected CollectionAttributeFlusher<E,V> partialFlusher(boolean fetch, AbstractPluralAttributeFlusher.PluralFlushOperation operation, List<? extends CollectionAction<?>> collectionActions, List<CollectionElementAttributeFlusher<E, V>> elementFlushers) protected List<CollectionAction<Collection<?>>>replaceActions(V value) Methods inherited from class com.blazebit.persistence.view.impl.update.flush.CollectionAttributeFlusher
areActionsQueueable, cloneDeep, createCollection, createCollectionDeleter, createJpaCollection, createJpaCollection, createMergeFlusher, createPersistFlusher, createRecordingCollection, deleteElements, determineCollectionActionsForNonSubview, determineCollectionActionsForSubview, determineDirtyFlusherForNewCollection, executeActions, flushCollectionOperations, flushEntity, flushQuery, getActionUnrelatedDirtyObjectCount, getDirtyFlusher, getDirtyFlusherForRecordingCollection, getElementDirtyChecker, getElementFlushers, getEntityReferencesForCollectionOperation, getNestedCheckers, getNewInitialValue, invokeCollectionAction, isViewOnlyDeleteCascaded, mergeCollectionElements, mergeWith, remove, remove, removeByOwnerId, removeFromEntity, replaceCollection, replaceWithRecordingCollection, requiresDeferredFlush, requiresDeleteCascadeAfterRemove, requiresFlushAfterPersist, supportsQueryFlushMethods inherited from class com.blazebit.persistence.view.impl.update.flush.AbstractPluralAttributeFlusher
appendUpdateQueryFragment, determineElementFlushers, getElementIdAttributeName, getElementOnlyFlusher, getEntityAttributeAccessor, getEntityAttributeValue, getLockOwner, getMapping, getNestedGraphNode, getReplaceOrMergeAndElementFlusher, getReplaceOrMergeOnlyFlusher, getReplayAndElementFlusher, getReplayOnlyFlusher, getViewAttributeAccessor, getViewElement, identityContains, invokeFlushOperation, isOptimisticLockProtected, isPassThrough, loadForEntityFlush, persistIfNeeded, persistOrMerge, persistOrMergeMethods inherited from class com.blazebit.persistence.view.impl.update.flush.AttributeFetchGraphNode
appendFetchJoinQueryFragment, getAttributeNameMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.blazebit.persistence.view.impl.update.flush.DirtyAttributeFlusher
appendFetchJoinQueryFragment, appendUpdateQueryFragment, getElementIdAttributeName, getEntityAttributeAccessor, getLockOwner, getViewAttributeAccessor, isOptimisticLockProtected, isPassThrough, loadForEntityFlushMethods inherited from interface com.blazebit.persistence.view.impl.update.flush.FetchGraphNode
getAttributeName, getMapping
-
Constructor Details
-
IndexedListAttributeFlusher
public IndexedListAttributeFlusher(String attributeName, String mapping, Class<?> ownerEntityClass, String ownerIdAttributeName, String ownerMapping, DirtyAttributeFlusher<?, ?, ?> ownerIdFlusher, DirtyAttributeFlusher<?, ?, ?> elementFlusher, boolean supportsCollectionDml, FlushStrategy flushStrategy, AttributeAccessor attributeMapper, InitialValueAttributeAccessor viewAttributeAccessor, boolean optimisticLockProtected, boolean collectionUpdatable, boolean viewOnlyDeleteCascaded, boolean jpaProviderDeletesCollection, CollectionRemoveListener cascadeDeleteListener, CollectionRemoveListener removeListener, CollectionInstantiatorImplementor<?, ?> collectionInstantiator, TypeDescriptor elementDescriptor, InverseFlusher<E> inverseFlusher, InverseRemoveStrategy inverseRemoveStrategy) -
IndexedListAttributeFlusher
-
IndexedListAttributeFlusher
public IndexedListAttributeFlusher(IndexedListAttributeFlusher<E, V> original, boolean fetch, AbstractPluralAttributeFlusher.PluralFlushOperation flushOperation, List<? extends CollectionAction<?>> collectionActions, List<CollectionElementAttributeFlusher<E, V>> elementFlushers)
-
-
Method Details
-
collectionEquals
- Overrides:
collectionEqualsin classCollectionAttributeFlusher<E,V extends List<?>>
-
mergeAndRequeue
protected boolean mergeAndRequeue(UpdateContext context, RecordingCollection recordingCollection, Collection<Object> newCollection) - Overrides:
mergeAndRequeuein classCollectionAttributeFlusher<E,V extends List<?>>
-
partialFlusher
protected CollectionAttributeFlusher<E,V> partialFlusher(boolean fetch, AbstractPluralAttributeFlusher.PluralFlushOperation operation, List<? extends CollectionAction<?>> collectionActions, List<CollectionElementAttributeFlusher<E, V>> elementFlushers) - Overrides:
partialFlusherin classCollectionAttributeFlusher<E,V extends List<?>>
-
getDirtyKind
Description copied from interface:DirtyCheckerReturns the dirty kind of the objects.- Specified by:
getDirtyKindin interfaceDirtyChecker<E>- Overrides:
getDirtyKindin classCollectionAttributeFlusher<E,V extends List<?>> - Returns:
- The dirty kind
-
replaceActions
- Overrides:
replaceActionsin classCollectionAttributeFlusher<E,V extends List<?>>
-
appendRemoveSpecific
protected Collection<Object> appendRemoveSpecific(UpdateContext context, DeleteCriteriaBuilder<?> deleteCb, FusedCollectionActions fusedCollectionActions) - Overrides:
appendRemoveSpecificin classCollectionAttributeFlusher<E,V extends List<?>>
-
addElements
protected void addElements(UpdateContext context, Object ownerView, Object view, Collection<Object> removedAllObjects, boolean flushAtOnce, boolean removedAllWithoutCollectionActions, V value, List<Object> embeddablesToUpdate, FusedCollectionActions fusedCollectionActions, boolean initialKnown) - Overrides:
addElementsin classCollectionAttributeFlusher<E,V extends List<?>>
-
canFlushSeparateCollectionOperations
protected boolean canFlushSeparateCollectionOperations()- Overrides:
canFlushSeparateCollectionOperationsin classCollectionAttributeFlusher<E,V extends List<?>>
-
isIndexed
protected boolean isIndexed()- Overrides:
isIndexedin classCollectionAttributeFlusher<E,V extends List<?>>
-
addFlatViewElementFlushActions
protected void addFlatViewElementFlushActions(UpdateContext context, TypeDescriptor typeDescriptor, List<CollectionAction<?>> actions, V current) - Overrides:
addFlatViewElementFlushActionsin classCollectionAttributeFlusher<E,V extends List<?>>
-
getFusedOperations
protected FusedCollectionActions getFusedOperations(List<? extends CollectionAction<?>> collectionActions) - Overrides:
getFusedOperationsin classCollectionAttributeFlusher<E,V extends List<?>>
-
determineJpaCollectionActions
protected List<CollectionAction<Collection<?>>> determineJpaCollectionActions(UpdateContext context, V jpaCollection, V value, AbstractPluralAttributeFlusher.EqualityChecker equalityChecker) - Overrides:
determineJpaCollectionActionsin classCollectionAttributeFlusher<E,V extends List<?>>
-
determineCollectionActions
protected List<CollectionAction<Collection<?>>> determineCollectionActions(UpdateContext context, V initial, V current, AbstractPluralAttributeFlusher.EqualityChecker equalityChecker) - Overrides:
determineCollectionActionsin classCollectionAttributeFlusher<E,V extends List<?>>
-