public class InternalSortedBag extends SortedSpillBag
SelfSpillBag.MemoryLimitsDefaultAbstractBag.BagDelimiterTuple, DefaultAbstractBag.EndBag, DefaultAbstractBag.StartBagmemLimitendBag, MAX_SPILL_FILES, mContents, mSize, mSpillFiles, startBag| Constructor and Description |
|---|
InternalSortedBag() |
InternalSortedBag(Comparator<Tuple> comp) |
InternalSortedBag(int bagCount,
Comparator<Tuple> comp) |
InternalSortedBag(int bagCount,
float percent,
Comparator<Tuple> comp) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(Tuple t)
Add a tuple to the bag.
|
boolean |
isDistinct()
Find out if the bag is distinct.
|
boolean |
isSorted()
Find out if the bag is sorted.
|
Iterator<Tuple> |
iterator()
Get an iterator to the bag.
|
long |
proactive_spill(Comparator<Tuple> comp)
Sort contents of mContents and write them to disk
|
long |
spill()
Instructs an object to spill whatever it can to disk and release
references to any data structures it spills.
|
addAll, addAll, addAll, clear, compareTo, equals, getMemorySize, getSpillFile, hashCode, incSpillCount, incSpillCount, markSpillableIfNecessary, markStale, readFields, reportProgress, sampleContents, size, toString, warn, writeclone, finalize, getClass, notify, notifyAll, wait, wait, waitforEach, spliteratorpublic InternalSortedBag()
public InternalSortedBag(Comparator<Tuple> comp)
public InternalSortedBag(int bagCount,
Comparator<Tuple> comp)
public InternalSortedBag(int bagCount,
float percent,
Comparator<Tuple> comp)
public void add(Tuple t)
DefaultAbstractBagadd in interface DataBagadd in class DefaultAbstractBagt - tuple to add.public boolean isSorted()
DataBagpublic boolean isDistinct()
DataBagpublic Iterator<Tuple> iterator()
DataBagpublic long spill()
Spillablepublic long proactive_spill(Comparator<Tuple> comp)
SortedSpillBagproactive_spill in class SortedSpillBagcomp - Comparator to sort contents of mContentsCopyright © 2007-2017 The Apache Software Foundation