Package com.illumon.iris.db.v2.utils
Class IndexShiftDataExpander
java.lang.Object
com.illumon.iris.db.v2.utils.IndexShiftDataExpander
- All Implemented Interfaces:
SafeCloseable
,AutoCloseable
Expands
ShiftAwareListener.onUpdate(ShiftAwareListener.Update)
's Update into a backward compatible
ARM (added, removed, modified) by expanding keyspace shifts.
Using this is almost always less efficient than using the Update directly.-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic IndexShiftDataExpander
Immutable, re-usableIndexShiftDataExpander
for an empty set of changes. -
Constructor Summary
ConstructorsConstructorDescriptionIndexShiftDataExpander
(ShiftAwareListener.Update update, Index sourceIndex) Generates the backwards compatible ARM from an ARMS update. -
Method Summary
-
Field Details
-
EMPTY
Immutable, re-usableIndexShiftDataExpander
for an empty set of changes.
-
-
Constructor Details
-
IndexShiftDataExpander
Generates the backwards compatible ARM from an ARMS update.- Parameters:
update
- The usptream update.
-
-
Method Details
-
getAdded
Fetch the resulting index of added values.- Returns:
- added index
-
getRemoved
Fetch the resulting index of removed values.- Returns:
- removed index
-
getModified
Fetch the resulting index of modified values.- Returns:
- modified index
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceSafeCloseable
-
validate
Perform backwards compatible validation checks.- Parameters:
sourceIndex
- the underlying index that apply to added/removed/modified
-