Package lumis.util.parse
Class TikaParser
- java.lang.Object
-
- lumis.util.parse.TikaParser
-
- All Implemented Interfaces:
IFileParser
public class TikaParser extends Object implements IFileParser
Implementation forIFileParser
to deal withParser
for most content-types.- Since:
- 5.5.0
- Version:
- $Revision: 15901 $ $Date: 2013-10-04 11:16:36 -0300 (Fri, 04 Oct 2013) $
-
-
Constructor Summary
Constructors Constructor Description TikaParser()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
extract(File inputFile)
String
extract(File inputFile, Charset charset)
String
extract(InputStream inputStream)
Extract text from an input stream.String
extract(InputStream inputStream, Charset charset)
-
-
-
Method Detail
-
extract
public String extract(File inputFile) throws ParseException, FileNotFoundException
- Specified by:
extract
in interfaceIFileParser
- Throws:
ParseException
FileNotFoundException
-
extract
public String extract(File inputFile, Charset charset) throws ParseException, FileNotFoundException
- Specified by:
extract
in interfaceIFileParser
- Throws:
ParseException
FileNotFoundException
-
extract
public String extract(InputStream inputStream, Charset charset) throws ParseException
- Specified by:
extract
in interfaceIFileParser
- Throws:
ParseException
-
extract
public String extract(InputStream inputStream) throws ParseException, IOException
Description copied from interface:IFileParser
Extract text from an input stream.- Specified by:
extract
in interfaceIFileParser
- Parameters:
inputStream
- the input stream.- Returns:
- the text extracted.
- Throws:
ParseException
- if an error occurred while parsing stream content.IOException
- if an I/O error occurred.
-
-