|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.egothor.merger.Merge
public class Merge
A Merge object is an implementation of BarrelReader. When a Merge is constructed the object is supplied with an enumeration of BarrelReaders (an implementation of Barrel). The given Barrels are merged into a single BarrelReader represented by this class.
Constructor Summary | |
---|---|
Merge()
Constructor for the Merge object. |
Method Summary | |
---|---|
void |
add(BarrelReader bf)
Add another barrel reader into this class. |
void |
close()
Closes this Merger and all the inner structures. |
SequenceWithClose<DocumentData> |
getDocuments()
Return an enumeration of DocumentData
objects. |
SequenceWithClose<IListReader> |
getILists()
Return an enumeration of IListReader s. |
long |
length()
Return the length of the final product of this object. |
void |
rewind()
Restart operation is not supported. |
int |
size()
How many readers are merged? |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Merge()
BarrelReader
s.
Method Detail |
---|
public SequenceWithClose<DocumentData> getDocuments()
DocumentData
objects. The first element represents the metadata of document
number 0, and the last element has an index number equal to length()-1
.
The collection is generated without gaps
getDocuments
in interface BarrelReader
public SequenceWithClose<IListReader> getILists()
IListReader
s.
getILists
in interface BarrelReader
public int size()
public void add(BarrelReader bf)
bf
- BarrelReader passed to this Mergerpublic void close()
close
in interface BarrelReader
public long length()
length
in interface BarrelReader
public void rewind() throws java.lang.UnsupportedOperationException
rewind
in interface BarrelReader
java.lang.UnsupportedOperationException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |