public static <T extends RingPosition<T>> boolean noneStrictlyWrapsAround(Collection<AbstractBounds<T>> bounds) { for (AbstractBounds<T> b : bounds) { if (strictlyWrapsAround(b.left, b.right)) return false; } return true; }
public static <T extends RingPosition<T>> boolean noneStrictlyWrapsAround(Collection<AbstractBounds<T>> bounds) { for (AbstractBounds<T> b : bounds) { if (strictlyWrapsAround(b.left, b.right)) return false; } return true; }
public static <T extends RingPosition<T>> boolean noneStrictlyWrapsAround(Collection<AbstractBounds<T>> bounds) { for (AbstractBounds<T> b : bounds) { if (strictlyWrapsAround(b.left, b.right)) return false; } return true; }
public static <T extends RingPosition<T>> boolean noneStrictlyWrapsAround(Collection<AbstractBounds<T>> bounds) { for (AbstractBounds<T> b : bounds) { if (strictlyWrapsAround(b.left, b.right)) return false; } return true; }
/** * Returns the sstables that have any partition between {@code left} and {@code right}, when both bounds are taken inclusively. * The interval formed by {@code left} and {@code right} shouldn't wrap. */ public Iterable<SSTableReader> liveSSTablesInBounds(PartitionPosition left, PartitionPosition right) { assert !AbstractBounds.strictlyWrapsAround(left, right); if (intervalTree.isEmpty()) return Collections.emptyList(); PartitionPosition stopInTree = right.isMinimum() ? intervalTree.max() : right; return intervalTree.search(Interval.create(left, stopInTree)); }
public static List<SSTableReader> sstablesInBounds(PartitionPosition left, PartitionPosition right, SSTableIntervalTree intervalTree) { assert !AbstractBounds.strictlyWrapsAround(left, right); if (intervalTree.isEmpty()) return Collections.emptyList(); PartitionPosition stopInTree = right.isMinimum() ? intervalTree.max() : right; return intervalTree.search(Interval.create(left, stopInTree)); }
public static List<SSTableReader> sstablesInBounds(PartitionPosition left, PartitionPosition right, SSTableIntervalTree intervalTree) { assert !AbstractBounds.strictlyWrapsAround(left, right); if (intervalTree.isEmpty()) return Collections.emptyList(); PartitionPosition stopInTree = right.isMinimum() ? intervalTree.max() : right; return intervalTree.search(Interval.create(left, stopInTree)); }
/** * Returns the sstables that have any partition between {@code left} and {@code right}, when both bounds are taken inclusively. * The interval formed by {@code left} and {@code right} shouldn't wrap. */ public Iterable<SSTableReader> liveSSTablesInBounds(PartitionPosition left, PartitionPosition right) { assert !AbstractBounds.strictlyWrapsAround(left, right); if (intervalTree.isEmpty()) return Collections.emptyList(); PartitionPosition stopInTree = right.isMinimum() ? intervalTree.max() : right; return intervalTree.search(Interval.create(left, stopInTree)); }
public static List<SSTableReader> sstablesInBounds(PartitionPosition left, PartitionPosition right, SSTableIntervalTree intervalTree) { assert !AbstractBounds.strictlyWrapsAround(left, right); if (intervalTree.isEmpty()) return Collections.emptyList(); PartitionPosition stopInTree = right.isMinimum() ? intervalTree.max() : right; return intervalTree.search(Interval.create(left, stopInTree)); }
/** * Returns the sstables that have any partition between {@code left} and {@code right}, when both bounds are taken inclusively. * The interval formed by {@code left} and {@code right} shouldn't wrap. */ public Iterable<SSTableReader> liveSSTablesInBounds(PartitionPosition left, PartitionPosition right) { assert !AbstractBounds.strictlyWrapsAround(left, right); if (intervalTree.isEmpty()) return Collections.emptyList(); PartitionPosition stopInTree = right.isMinimum() ? intervalTree.max() : right; return intervalTree.search(Interval.create(left, stopInTree)); }