|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.pig.data.DefaultAbstractBag
org.apache.pig.data.InternalCachedBag
public class InternalCachedBag
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.apache.pig.data.DefaultAbstractBag |
---|
DefaultAbstractBag.BagDelimiterTuple, DefaultAbstractBag.EndBag, DefaultAbstractBag.StartBag |
Field Summary |
---|
Fields inherited from class org.apache.pig.data.DefaultAbstractBag |
---|
endBag, MAX_SPILL_FILES, mContents, mLastContentsSize, mMemSize, mSize, mSpillFiles, startBag |
Constructor Summary | |
---|---|
InternalCachedBag()
|
|
InternalCachedBag(int bagCount)
|
|
InternalCachedBag(int bagCount,
float percent)
|
Method Summary | |
---|---|
void |
add(Tuple t)
Add a tuple to the bag. |
void |
addAll(Collection<Tuple> c)
Add contents of a container to the bag. |
void |
addAll(DataBag b)
Add contents of a bag to the bag. |
void |
clear()
Clear out the contents of the bag, both on disk and in memory. |
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 |
spill()
Instructs an object to spill whatever it can to disk and release references to any data structures it spills. |
Methods inherited from class org.apache.pig.data.DefaultAbstractBag |
---|
compareTo, equals, getMemorySize, getSpillFile, hashCode, incSpillCount, incSpillCount, markStale, readFields, reportProgress, size, toString, warn, write |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public InternalCachedBag()
public InternalCachedBag(int bagCount)
public InternalCachedBag(int bagCount, float percent)
Method Detail |
---|
public void add(Tuple t)
DefaultAbstractBag
add
in interface DataBag
add
in class DefaultAbstractBag
t
- tuple to add.public void addAll(DataBag b)
DefaultAbstractBag
addAll
in interface DataBag
addAll
in class DefaultAbstractBag
b
- bag to add contents of.public void addAll(Collection<Tuple> c)
DefaultAbstractBag
addAll
in class DefaultAbstractBag
c
- Collection to add contents of.public void clear()
DefaultAbstractBag
clear
in interface DataBag
clear
in class DefaultAbstractBag
public boolean isDistinct()
DataBag
public boolean isSorted()
DataBag
public Iterator<Tuple> iterator()
DataBag
public long spill()
Spillable
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |