@PipeBitInfo(name="Files in Dir Tree Reader", description="Reads document texts from text files in a directory tree.", role=READER, products={DOCUMENT_ID,DOCUMENT_ID_PREFIX}) public final class FileTreeReader extends org.apache.uima.fit.component.JCasCollectionReader_ImplBase
Modifier and Type | Field and Description |
---|---|
static String |
PARAM_ENCODING
Name of configuration parameter that contains the character encoding used
by the input files.
|
static String |
PARAM_EXTENSIONS
Name of optional configuration parameter that specifies the extensions
of the files that the collection reader will read.
|
Constructor and Description |
---|
FileTreeReader() |
Modifier and Type | Method and Description |
---|---|
void |
close() |
static org.apache.uima.collection.CollectionReader |
createReader(String inputDirectory)
Convenience method to create a reader with an input directory
|
void |
getNext(org.apache.uima.jcas.JCas jcas) |
int |
getNumberOfDocuments()
Gets the total number of documents that will be returned by this
collection reader.
|
org.apache.uima.util.Progress[] |
getProgress() |
boolean |
hasNext() |
void |
initialize(org.apache.uima.UimaContext context) |
getLogger, getNext, initialize
destroy, getCasInitializer, getProcessingResourceMetaData, initialize, isConsuming, reconfigure, setCasInitializer, typeSystemInit
getConfigParameterValue, getConfigParameterValue, setConfigParameterValue, setConfigParameterValue
getCasManager, getMetaData, getResourceManager, getUimaContext, getUimaContextAdmin, setLogger, setMetaData
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public static final String PARAM_ENCODING
public static final String PARAM_EXTENSIONS
'.'
.public void initialize(org.apache.uima.UimaContext context) throws org.apache.uima.resource.ResourceInitializationException
initialize
in class org.apache.uima.fit.component.JCasCollectionReader_ImplBase
org.apache.uima.resource.ResourceInitializationException
public int getNumberOfDocuments()
public boolean hasNext()
public void getNext(org.apache.uima.jcas.JCas jcas) throws IOException, org.apache.uima.collection.CollectionException
getNext
in class org.apache.uima.fit.component.JCasCollectionReader_ImplBase
IOException
org.apache.uima.collection.CollectionException
public void close() throws IOException
close
in interface org.apache.uima.collection.base_cpm.BaseCollectionReader
close
in class org.apache.uima.fit.component.JCasCollectionReader_ImplBase
IOException
public org.apache.uima.util.Progress[] getProgress()
public static org.apache.uima.collection.CollectionReader createReader(String inputDirectory) throws org.apache.uima.resource.ResourceInitializationException
inputDirectory
- -org.apache.uima.resource.ResourceInitializationException
- -Copyright © 2012-2017 The Apache Software Foundation. All Rights Reserved.