uk.ac.man.documentparser.input
Class Directory
java.lang.Object
uk.ac.man.documentparser.input.Directory
- All Implemented Interfaces:
- java.lang.Iterable<Document>, java.util.Iterator<Document>, DocumentIterator
public class Directory
- extends java.lang.Object
- implements DocumentIterator
Constructor Summary |
Directory(java.io.File dir,
InputFactory factory,
java.lang.String acceptedSuffix,
boolean recursive)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
contents
private java.io.File[] contents
nextDocIndex
private int nextDocIndex
nextDocument
private Document nextDocument
acceptedSuffix
private java.lang.String acceptedSuffix
recursive
private boolean recursive
factory
private InputFactory factory
currentSubDirectory
private DocumentIterator currentSubDirectory
currentFileIterator
private DocumentIterator currentFileIterator
Directory
public Directory(java.io.File dir,
InputFactory factory,
java.lang.String acceptedSuffix,
boolean recursive)
fetchNext
private void fetchNext()
skip
public void skip()
- Specified by:
skip
in interface DocumentIterator
hasNext
public boolean hasNext()
- Specified by:
hasNext
in interface java.util.Iterator<Document>
next
public Document next()
- Specified by:
next
in interface java.util.Iterator<Document>
remove
public void remove()
- Specified by:
remove
in interface java.util.Iterator<Document>
iterator
public java.util.Iterator<Document> iterator()
- Specified by:
iterator
in interface java.lang.Iterable<Document>