Package org.apache.tika.parser
Interface Parser
- All Superinterfaces:
Serializable
- All Known Implementing Classes:
AbstractDBParser
,AbstractDWGParser
,AbstractEncodingDetectorParser
,AbstractExternalProcessParser
,AbstractImageParser
,AbstractMultipleParser
,AbstractOfficeParser
,AbstractParser
,AbstractXML2003Parser
,ActiveMimeParser
,AdobeFontMetricParser
,AgeRecogniser
,AmazonTranscribe
,AppleSingleFileParser
,AudioParser
,AutoDetectParser
,BPGParser
,ChmParser
,ClassParser
,CompositeExternalParser
,CompositeParser
,CompressorParser
,CryptoParser
,CTAKESParser
,DBFParser
,DcXMLParser
,DefaultParser
,DelegatingParser
,DGN8Parser
,DIFParser
,DigestingParser
,DirListParser
,DWGParser
,DWGReadParser
,EMFParser
,EmptyParser
,EncryptedPrescriptionParser
,EnviHeaderParser
,EpubContentParser
,EpubParser
,ErrorParser
,ExecutableParser
,ExternalParser
,ExternalParser
,FallbackParser
,FeedParser
,FictionBookParser
,FlatOpenDocumentParser
,FLVParser
,ForkParser
,GDALParser
,GeographicInformationParser
,GeoParser
,GeoPkgParser
,GribParser
,HDFParser
,HeifParser
,HttpParser
,HwpV5Parser
,ICNSParser
,IDMLParser
,ImageParser
,IptcAnpaParser
,ISArchiveParser
,IWork13PackageParser
,IWork18PackageParser
,IWorkPackageParser
,JackcessParser
,JournalParser
,JpegParser
,JSoupParser
,JXLParser
,LanguageDetectingParser
,Latin1StringsParser
,LibPstParser
,MatParser
,MboxParser
,MidiParser
,MIFParser
,Mp3Parser
,MP4Parser
,MSOwnerFileParser
,NamedEntityParser
,NetCDFParser
,NetworkParser
,ObjectRecognitionParser
,OfficeParser
,OldExcelParser
,OneNoteParser
,OOXMLParser
,OpenDocumentContentParser
,OpenDocumentMetaParser
,OpenDocumentParser
,OPFParser
,OutlookPSTParser
,PackageParser
,ParserDecorator
,ParserPostProcessor
,PDFParser
,PickBestTextEncodingParser
,Pkcs7Parser
,PListParser
,PooledTimeSeriesParser
,PrescriptionParser
,PRTParser
,PSDParser
,PSTMailItemParser
,QuattroProParser
,RarParser
,RecursiveParserWrapper
,RegexCaptureParser
,RFC822Parser
,RTFParser
,SAS7BDATParser
,SentimentAnalysisParser
,SourceCodeParser
,SpreadsheetMLParser
,SQLite3DBParser
,SQLite3Parser
,StatefulParser
,StringsParser
,SupplementingParser
,TensorflowImageRecParser
,TesseractOCRParser
,TextAndAttributeXMLParser
,TextAndCSVParser
,TiffParser
,TMXParser
,TNEFParser
,TrueTypeParser
,TSDParser
,TXTParser
,UnrarParser
,WACZParser
,WARCParser
,WebPParser
,WMFParser
,Word2006MLParser
,WordMLParser
,WordPerfectParser
,XLIFF12Parser
,XLZParser
,XMLParser
,XMLProfiler
Tika parser interface.
-
Method Summary
Modifier and TypeMethodDescriptiongetSupportedTypes
(ParseContext context) Returns the set of media types supported by this parser when used with the given parse context.void
parse
(InputStream stream, ContentHandler handler, Metadata metadata, ParseContext context) Parses a document stream into a sequence of XHTML SAX events.
-
Method Details
-
getSupportedTypes
Returns the set of media types supported by this parser when used with the given parse context.- Parameters:
context
- parse context- Returns:
- immutable set of media types
- Since:
- Apache Tika 0.7
-
parse
void parse(InputStream stream, ContentHandler handler, Metadata metadata, ParseContext context) throws IOException, SAXException, TikaException Parses a document stream into a sequence of XHTML SAX events. Fills in related document metadata in the given metadata object.The given document stream is consumed but not closed by this method. The responsibility to close the stream remains on the caller.
Information about the parsing context can be passed in the context parameter. See the parser implementations for the kinds of context information they expect.
- Parameters:
stream
- the document stream (input)handler
- handler for the XHTML SAX events (output)metadata
- document metadata (input and output)context
- parse context- Throws:
IOException
- if the document stream could not be readSAXException
- if the SAX events could not be processedTikaException
- if the document could not be parsed- Since:
- Apache Tika 0.5
-