Class IndexShiftDataExpander

java.lang.Object
com.illumon.iris.db.v2.utils.IndexShiftDataExpander
All Implemented Interfaces:
SafeCloseable, AutoCloseable

public class IndexShiftDataExpander extends Object implements SafeCloseable
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 Details

  • Constructor Details

    • IndexShiftDataExpander

      public IndexShiftDataExpander(ShiftAwareListener.Update update, Index sourceIndex)
      Generates the backwards compatible ARM from an ARMS update.
      Parameters:
      update - The usptream update.
  • Method Details

    • getAdded

      public Index getAdded()
      Fetch the resulting index of added values.
      Returns:
      added index
    • getRemoved

      public Index getRemoved()
      Fetch the resulting index of removed values.
      Returns:
      removed index
    • getModified

      public Index getModified()
      Fetch the resulting index of modified values.
      Returns:
      modified index
    • close

      public void close()
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface SafeCloseable
    • validate

      public void validate(Index sourceIndex)
      Perform backwards compatible validation checks.
      Parameters:
      sourceIndex - the underlying index that apply to added/removed/modified