R
- @InterfaceAudience.Private public class RegionSplitCalculator<R extends KeyRange> extends Object
Modifier and Type | Field and Description |
---|---|
static Comparator<byte[]> |
BYTES_COMPARATOR |
Constructor and Description |
---|
RegionSplitCalculator(Comparator<R> cmp) |
Modifier and Type | Method and Description |
---|---|
boolean |
add(R range)
Adds an edge to the split calculator
|
com.google.common.collect.Multimap<byte[],R> |
calcCoverage()
Generates a coverage multimap from split key to Regions that start with the
split key.
|
static <R extends KeyRange> |
findBigRanges(Collection<R> bigOverlap,
int count)
Find specified number of top ranges in a big overlap group.
|
TreeSet<byte[]> |
getSplits() |
com.google.common.collect.Multimap<byte[],R> |
getStarts() |
public static final Comparator<byte[]> BYTES_COMPARATOR
public RegionSplitCalculator(Comparator<R> cmp)
public boolean add(R range)
public com.google.common.collect.Multimap<byte[],R> calcCoverage()
public TreeSet<byte[]> getSplits()
public com.google.common.collect.Multimap<byte[],R> getStarts()
public static <R extends KeyRange> List<R> findBigRanges(Collection<R> bigOverlap, int count)
bigOverlap
- a list of ranges that overlap with each othercount
- the max number of ranges to findCopyright © 2007–2019 The Apache Software Foundation. All rights reserved.