java.lang.Object
org.litebridgedb.tracking.ChangedField
org.litebridgedb.tracking.ChangedCollectionField
List-specific type of ChangedField which holds a snapshot of the original underlying map.
This class is a final implementation that provides additional functionality
for handling changes to Map-type fields.
It inherits the common properties and behavior from the ChangedField class
and extends it by including a snapshot of the original map associated with the field.
It ensures that the map snapshot is immutable.
-
Field Summary
Fields inherited from class org.litebridgedb.tracking.ChangedField
name, value -
Constructor Summary
ConstructorsConstructorDescriptionChangedCollectionField(String fieldName, @Nullable Object value, @Nullable List<Integer> listSnapshot, @Nullable List<Integer> prevListSnapshot) Construct aChangedMapFieldinstance representing a change in a map field, including a snapshot of its original state as an immutable map. -
Method Summary
Methods inherited from class org.litebridgedb.tracking.ChangedField
cast, name, value
-
Constructor Details
-
ChangedCollectionField
public ChangedCollectionField(String fieldName, @Nullable Object value, @Nullable List<Integer> listSnapshot, @Nullable List<Integer> prevListSnapshot) Construct aChangedMapFieldinstance representing a change in a map field, including a snapshot of its original state as an immutable map.- Parameters:
fieldName- the name of the field being trackedvalue- the new value of the fieldlistSnapshot- the original state of the map field, stored as an immutable mapprevListSnapshot- the previous state of the list
-
-
Method Details
-
listSnapshot
-
prevListSnapshot
-
updatedIndices
-
updatedValues
-
equals
- Overrides:
equalsin classChangedField
-
hashCode
public int hashCode()- Overrides:
hashCodein classChangedField
-
toString
- Overrides:
toStringin classChangedField
-