Class RecordingMap<C extends Map<K,V>,K,V>
java.lang.Object
com.blazebit.persistence.view.impl.collection.RecordingMap<C,K,V>
- All Implemented Interfaces:
RecordingContainer<C>,BasicDirtyTracker,DirtyTracker,Serializable,Map<K,V>
- Direct Known Subclasses:
RecordingSortedMap
public class RecordingMap<C extends Map<K,V>,K,V>
extends Object
implements RecordingContainer<C>, Map<K,V>, DirtyTracker, Serializable
- Since:
- 1.2.0
- Author:
- Christian Beikov
- See Also:
-
Nested Class Summary
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionRecordingMap(C delegate, boolean ordered, Set<Class<?>> allowedSubtypes, Set<Class<?>> parentRequiringUpdateSubtypes, Set<Class<?>> parentRequiringCreateSubtypes, boolean updatable, boolean optimize, boolean strictCascadingCheck) protectedRecordingMap(C delegate, Set<Class<?>> allowedSubtypes, Set<Class<?>> parentRequiringUpdateSubtypes, Set<Class<?>> parentRequiringCreateSubtypes, boolean updatable, boolean optimize, boolean hashBased, boolean ordered, boolean strictCascadingCheck) -
Method Summary
Modifier and TypeMethodDescription<T> boolean$$_copyDirty(T[] source, T[] target) long[]longbooleanbooleanboolean$$_isDirty(int attributeIndex) void$$_markDirty(int attributeIndex) void$$_replaceAttribute(Object oldObject, int attributeIndex, Object newObject) long[]void$$_setDirty(long[] dirty) void$$_setParent(BasicDirtyTracker parent, int parentIndex) voidvoidprotected final voidprotected voidprotected voidvoidclear()booleancontainsKey(Object key) booleancontainsValue(Object value) protected CentrySet()booleanbooleaninthashCode()voidinitiateActionsAgainstState(List<MapAction<C>> actions, C initialState) booleanisEmpty()booleankeySet()voidvoidreplaceActionElement(Object oldKey, Object oldValue, Object newKey, Object newValue) voidreplay(C map, UpdateContext context, MapViewToEntityMapper mapper, CollectionRemoveListener keyRemoveListener, CollectionRemoveListener valueRemoveListener) resetActions(UpdateContext context) voidvoidsetActions(RecordingMap<C, K, V> recordingMap, Map<Object, Object> objectMapping) voidsetActions(List<MapAction<C>> actions, Map<K, K> addedKeys, Map<K, K> removedKeys, Map<V, V> addedElements, Map<V, V> removedElements) intsize()Read-onlytoString()values()Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
Field Details
-
delegate
-
allowedSubtypes
-
parentRequiringUpdateSubtypes
-
parentRequiringCreateSubtypes
-
updatable
protected final boolean updatable
-
-
Constructor Details
-
RecordingMap
-
RecordingMap
-
-
Method Details
-
$$_isDirty
public boolean $$_isDirty()- Specified by:
$$_isDirtyin interfaceBasicDirtyTracker
-
$$_isDirty
public boolean $$_isDirty(int attributeIndex) - Specified by:
$$_isDirtyin interfaceDirtyTracker
-
$$_copyDirty
public <T> boolean $$_copyDirty(T[] source, T[] target) - Specified by:
$$_copyDirtyin interfaceDirtyTracker
-
$$_setDirty
public void $$_setDirty(long[] dirty) - Specified by:
$$_setDirtyin interfaceDirtyTracker
-
$$_resetDirty
public long[] $$_resetDirty()- Specified by:
$$_resetDirtyin interfaceDirtyTracker
-
$$_getDirty
public long[] $$_getDirty()- Specified by:
$$_getDirtyin interfaceDirtyTracker
-
$$_getSimpleDirty
public long $$_getSimpleDirty()- Specified by:
$$_getSimpleDirtyin interfaceDirtyTracker
-
$$_markDirty
public void $$_markDirty(int attributeIndex) - Specified by:
$$_markDirtyin interfaceBasicDirtyTracker
-
$$_unmarkDirty
public void $$_unmarkDirty()- Specified by:
$$_unmarkDirtyin interfaceBasicDirtyTracker
-
$$_setParent
- Specified by:
$$_setParentin interfaceBasicDirtyTracker
-
$$_hasParent
public boolean $$_hasParent()- Specified by:
$$_hasParentin interfaceBasicDirtyTracker
-
$$_getParent
-
$$_replaceAttribute
- Specified by:
$$_replaceAttributein interfaceDirtyTracker
-
$$_unsetParent
public void $$_unsetParent()- Specified by:
$$_unsetParentin interfaceBasicDirtyTracker
-
isHashBased
public boolean isHashBased() -
getCurrentIterator
-
recordingIterator
-
resetRecordingIterator
public void resetRecordingIterator() -
getDelegate
- Specified by:
getDelegatein interfaceRecordingContainer<C extends Map<K,V>>
-
hasActions
public boolean hasActions() -
setActions
-
setActions
-
copyDelegate
-
getInitialVersion
-
resetActions
-
initiateActionsAgainstState
-
getActions
-
getAddedKeys
-
getRemovedKeys
-
getAddedElements
-
getRemovedElements
-
replay
public void replay(C map, UpdateContext context, MapViewToEntityMapper mapper, CollectionRemoveListener keyRemoveListener, CollectionRemoveListener valueRemoveListener) -
replaceActionElement
-
checkType
-
checkType
-
addAction
-
put
-
remove
-
putAll
-
clear
public void clear() -
keySet
-
values
-
entrySet
-
size
public int size()Read-only -
isEmpty
public boolean isEmpty() -
containsKey
-
containsValue
-
get
-
hashCode
public int hashCode() -
equals
-
toString
-