You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tika.apache.org by ju...@apache.org on 2010/08/05 16:19:18 UTC
svn commit: r982632 [2/3] - in /tika/site: publish/ publish/0.5/
publish/0.6/ publish/0.7/ src/site/apt/ src/site/apt/0.5/ src/site/apt/0.6/
src/site/apt/0.7/
Modified: tika/site/publish/0.7/formats.html
URL: http://svn.apache.org/viewvc/tika/site/publish/0.7/formats.html?rev=982632&r1=982631&r2=982632&view=diff
==============================================================================
--- tika/site/publish/0.7/formats.html (original)
+++ tika/site/publish/0.7/formats.html Thu Aug 5 14:19:17 2010
@@ -174,7 +174,7 @@
</div>
<div id="bodyColumn">
<div id="contentBox">
- <!-- Licensed to the Apache Software Foundation (ASF) under one or more --><!-- contributor license agreements. See the NOTICE file distributed with --><!-- this work for additional information regarding copyright ownership. --><!-- The ASF licenses this file to You under the Apache License, Version 2.0 --><!-- (the "License"); you may not use this file except in compliance with --><!-- the License. You may obtain a copy of the License at --><!-- --><!-- http://www.apache.org/licenses/LICENSE-2.0 --><!-- --><!-- Unless required by applicable law or agreed to in writing, software --><!-- distributed under the License is distributed on an "AS IS" BASIS, --><!-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --><!-- See the License for the specific language governing permissions and --><!-- limitations under the License. --><div class="section"><h2>Supported Document Formats<a name="Supported_Document_Formats"></a></h2><p>This page lists al
l the document formats supported by Apache Tika 0.6. Follow the links to the various parser class javadocs for more detailed information about each document format and how it is parsed by Tika.</p><ul><li><a href="#Supported_Document_Formats">Supported Document Formats</a><ul><li><a href="#HyperText_Markup_Language">HyperText Markup Language</a></li><li><a href="#XML_and_derived_formats">XML and derived formats</a></li><li><a href="#Microsoft_Office_document_formats">Microsoft Office document formats</a></li><li><a href="#OpenDocument_Format">OpenDocument Format</a></li><li><a href="#Portable_Document_Format">Portable Document Format</a></li><li><a href="#Electronic_Publication_Format">Electronic Publication Format</a></li><li><a href="#Rich_Text_Format">Rich Text Format</a></li><li><a href="#Compression_and_packaging_formats">Compression and packaging formats</a></li><li><a href="#Text_formats">Text formats</a></li><li><a href="#Audio_formats">Audio formats</a></li><li><a h
ref="#Image_formats">Image formats</a></li><li><a href="#Video_formats">Video formats</a></li><li><a href="#Java_class_files_and_archives">Java class files and archives</a></li><li><a href="#The_mbox_format">The mbox format</a></li></ul></li></ul><div class="section"><h3><a name="HyperText_Markup_Language">HyperText Markup Language</a><a name="HyperText_Markup_Language"></a></h3><p>The HyperText Markup Language (HTML) is the lingua franca of the web. Tika uses the <a class="externalLink" href="http://home.ccil.org/~cowan/XML/tagsoup/">TagSoup</a> library to support virtually any kind of HTML found on the web. The output from the <a href="#apiorgapachetikaparserhtmlHtmlParser.html">HtmlParser</a> class is guaranteed to be well-formed and valid XHTML, and various heuristics are used to prevent things like inline scripts from cluttering the extracted text content.</p></div><div class="section"><h3><a name="XML_and_derived_formats">XML and derived formats</a><a name="XML_and_der
ived_formats"></a></h3><p>The Extensible Markup Language (XML) format is a generic format that can be used for all kinds of content. Tika has custom parsers for some widely used XML vocabularies like XHTML, OOXML and ODF, but the default <a href="#apiorgapachetikaparserxmlDcXMLParser.html">DcXMLParser</a> class simply extracts the text content of the document and ignores any XML structure. The only exception to this rule are Dublin Core metadata elements that are used for the document metadata.</p></div><div class="section"><h3><a name="Microsoft_Office_document_formats">Microsoft Office document formats</a><a name="Microsoft_Office_document_formats"></a></h3><p>Microsoft Office and some related applications produce documents in the generic OLE 2 Compound Document and Office Open XML (OOXML) formats. The older OLE 2 format was introduced in Microsoft Office version 97 and was the default format until Office version 2007 and the new XML-based OOXML format. The <a href="#apior
gapachetikaparsermicrosoftOfficeParser.html">OfficeParser</a> and <a href="#apiorgapachetikaparsermicrosoftooxmlOOXMLParser.html">OOXMLParser</a> classes use <a class="externalLink" href="http://poi.apache.org/">Apache POI</a> libraries to support text and metadata extraction from both OLE2 and OOXML documents.</p></div><div class="section"><h3><a name="OpenDocument_Format">OpenDocument Format</a><a name="OpenDocument_Format"></a></h3><p>The OpenDocument format (ODF) is used most notably as the default format of the OpenOffice.org office suite. The <a href="#apiorgapachetikaparserodfOpenDocumentParser.html">OpenDocumentParser</a> class supports this format and the earlier OpenOffice 1.0 format on which ODF is based.</p></div><div class="section"><h3><a name="Portable_Document_Format">Portable Document Format</a><a name="Portable_Document_Format"></a></h3><p>The <a href="#apiorgapachetikaparserpdfPDFParser.html">PDFParser</a> class parsers Portable Document Format (PDF) docum
ents using the <a class="externalLink" href="http://pdfbox.apache.org/">Apache PDFBox</a> library.</p></div><div class="section"><h3><a name="Electronic_Publication_Format">Electronic Publication Format</a><a name="Electronic_Publication_Format"></a></h3><p>The <a href="#apiorgapachetikaparserepubEpubParser.html">EpubParser</a> class supports the Electronic Publication Format (EPUB) used for many digital books.</p></div><div class="section"><h3><a name="Rich_Text_Format">Rich Text Format</a><a name="Rich_Text_Format"></a></h3><p>The <a href="#apiorgapachetikaparserrtfRTFParser.html">RTFParser</a> class uses the standard javax.swing.text.rtf feature to extract text content from Rich Text Format (RTF) documents.</p></div><div class="section"><h3><a name="Compression_and_packaging_formats">Compression and packaging formats</a><a name="Compression_and_packaging_formats"></a></h3><p>Tika uses the <a class="externalLink" href="http://commons.apache.org/compress/">Commons Compress<
/a> library to support various compression and packaging formats. The <a href="#apiorgapachetikaparserpkgPackageParser.html">PackageParser</a> class and its subclasses first parse the top level compression or packaging format and then pass the unpacked document streams to a second parsing stage using the parser instance specified in the parse context.</p></div><div class="section"><h3><a name="Text_formats">Text formats</a><a name="Text_formats"></a></h3><p>Extracting text content from plain text files seems like a simple task until you start thinking of all the possible character encodings. The <a href="#apiorgapachetikaparsertxtTXTParser.html">TXTParser</a> class uses encoding detection code from the <a class="externalLink" href="http://site.icu-project.org/">ICU</a> project to automatically detect the character encoding of a text document.</p></div><div class="section"><h3><a name="Audio_formats">Audio formats</a><a name="Audio_formats"></a></h3><p>Tika can detect several
common audio formats and extract metadata from them. Even text extraction is supported for some audio files that contain lyrics or other textual content. The <a href="#apiorgapachetikaparseraudioAudioParser.html">AudioParser</a> and <a href="#apiorgapachetikaparseraudioMidiParser.html">MidiParser</a> classes use standard javax.sound features to process simple audio formats, and the <a href="#apiorgapachetikaparsermp3Mp3Parser.html">Mp3Parser</a> class adds support for the widely used MP3 format.</p></div><div class="section"><h3><a name="Image_formats">Image formats</a><a name="Image_formats"></a></h3><p>The <a href="#apiorgapachetikaparserimageImageParser.html">ImageParser</a> class uses the standard javax.imageio feature to extract simple metadata from image formats supported by the Java platform. More complex image metadata is available through the <a href="#apiorgapachetikaparserjpegJpegParser.html">JpegParser</a> class that uses the metadata-extractor library to suppor
ts Exif metadata extraction from Jpeg images.</p></div><div class="section"><h3><a name="Video_formats">Video formats</a><a name="Video_formats"></a></h3><p>Currently Tika only supports the Flash video format using a simple parsing algorithm implemented in the <a href="#apiorgapachetikaparserflvFLVParser">FLVParser</a> class.</p></div><div class="section"><h3><a name="Java_class_files_and_archives">Java class files and archives</a><a name="Java_class_files_and_archives"></a></h3><p>The <a href="#apiorgapachetikaparserasmClassParser">ClassParser</a> class extracts class names and method signatures from Java class files, and the <a href="#apiorgapachetikaparserpkgZipParser.html">ZipParser</a> class supports also jar archives.</p></div><div class="section"><h3><a name="The_mbox_format">The mbox format</a><a name="The_mbox_format"></a></h3><p>The <a href="#apiorgapachetikaparsermboxMboxParser.html">MboxParser</a> can extract email messages from the mbox format used by many email
archives and Unix-style mailboxes.</p></div></div>
+ <!-- Licensed to the Apache Software Foundation (ASF) under one or more --><!-- contributor license agreements. See the NOTICE file distributed with --><!-- this work for additional information regarding copyright ownership. --><!-- The ASF licenses this file to You under the Apache License, Version 2.0 --><!-- (the "License"); you may not use this file except in compliance with --><!-- the License. You may obtain a copy of the License at --><!-- --><!-- http://www.apache.org/licenses/LICENSE-2.0 --><!-- --><!-- Unless required by applicable law or agreed to in writing, software --><!-- distributed under the License is distributed on an "AS IS" BASIS, --><!-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --><!-- See the License for the specific language governing permissions and --><!-- limitations under the License. --><div class="section"><h2>Supported Document Formats<a name="Supported_Document_Formats"></a></h2><p>This page lists al
l the document formats supported by Apache Tika 0.6. Follow the links to the various parser class javadocs for more detailed information about each document format and how it is parsed by Tika.</p><ul><li><a href="#Supported_Document_Formats">Supported Document Formats</a><ul><li><a href="#HyperText_Markup_Language">HyperText Markup Language</a></li><li><a href="#XML_and_derived_formats">XML and derived formats</a></li><li><a href="#Microsoft_Office_document_formats">Microsoft Office document formats</a></li><li><a href="#OpenDocument_Format">OpenDocument Format</a></li><li><a href="#Portable_Document_Format">Portable Document Format</a></li><li><a href="#Electronic_Publication_Format">Electronic Publication Format</a></li><li><a href="#Rich_Text_Format">Rich Text Format</a></li><li><a href="#Compression_and_packaging_formats">Compression and packaging formats</a></li><li><a href="#Text_formats">Text formats</a></li><li><a href="#Audio_formats">Audio formats</a></li><li><a h
ref="#Image_formats">Image formats</a></li><li><a href="#Video_formats">Video formats</a></li><li><a href="#Java_class_files_and_archives">Java class files and archives</a></li><li><a href="#The_mbox_format">The mbox format</a></li></ul></li></ul><div class="section"><h3><a name="HyperText_Markup_Language">HyperText Markup Language</a><a name="HyperText_Markup_Language"></a></h3><p>The HyperText Markup Language (HTML) is the lingua franca of the web. Tika uses the <a class="externalLink" href="http://home.ccil.org/~cowan/XML/tagsoup/">TagSoup</a> library to support virtually any kind of HTML found on the web. The output from the <a href="./api/org/apache/tika/parser/html/HtmlParser.html">HtmlParser</a> class is guaranteed to be well-formed and valid XHTML, and various heuristics are used to prevent things like inline scripts from cluttering the extracted text content.</p></div><div class="section"><h3><a name="XML_and_derived_formats">XML and derived formats</a><a name="XML_
and_derived_formats"></a></h3><p>The Extensible Markup Language (XML) format is a generic format that can be used for all kinds of content. Tika has custom parsers for some widely used XML vocabularies like XHTML, OOXML and ODF, but the default <a href="./api/org/apache/tika/parser/xml/DcXMLParser.html">DcXMLParser</a> class simply extracts the text content of the document and ignores any XML structure. The only exception to this rule are Dublin Core metadata elements that are used for the document metadata.</p></div><div class="section"><h3><a name="Microsoft_Office_document_formats">Microsoft Office document formats</a><a name="Microsoft_Office_document_formats"></a></h3><p>Microsoft Office and some related applications produce documents in the generic OLE 2 Compound Document and Office Open XML (OOXML) formats. The older OLE 2 format was introduced in Microsoft Office version 97 and was the default format until Office version 2007 and the new XML-based OOXML format. The <
a href="./api/org/apache/tika/parser/microsoft/OfficeParser.html">OfficeParser</a> and <a href="./api/org/apache/tika/parser/microsoft/ooxml/OOXMLParser.html">OOXMLParser</a> classes use <a class="externalLink" href="http://poi.apache.org/">Apache POI</a> libraries to support text and metadata extraction from both OLE2 and OOXML documents.</p></div><div class="section"><h3><a name="OpenDocument_Format">OpenDocument Format</a><a name="OpenDocument_Format"></a></h3><p>The OpenDocument format (ODF) is used most notably as the default format of the OpenOffice.org office suite. The <a href="./api/org/apache/tika/parser/odf/OpenDocumentParser.html">OpenDocumentParser</a> class supports this format and the earlier OpenOffice 1.0 format on which ODF is based.</p></div><div class="section"><h3><a name="Portable_Document_Format">Portable Document Format</a><a name="Portable_Document_Format"></a></h3><p>The <a href="./api/org/apache/tika/parser/pdf/PDFParser.html">PDFParser</a> class p
arsers Portable Document Format (PDF) documents using the <a class="externalLink" href="http://pdfbox.apache.org/">Apache PDFBox</a> library.</p></div><div class="section"><h3><a name="Electronic_Publication_Format">Electronic Publication Format</a><a name="Electronic_Publication_Format"></a></h3><p>The <a href="./api/org/apache/tika/parser/epub/EpubParser.html">EpubParser</a> class supports the Electronic Publication Format (EPUB) used for many digital books.</p></div><div class="section"><h3><a name="Rich_Text_Format">Rich Text Format</a><a name="Rich_Text_Format"></a></h3><p>The <a href="./api/org/apache/tika/parser/rtf/RTFParser.html">RTFParser</a> class uses the standard javax.swing.text.rtf feature to extract text content from Rich Text Format (RTF) documents.</p></div><div class="section"><h3><a name="Compression_and_packaging_formats">Compression and packaging formats</a><a name="Compression_and_packaging_formats"></a></h3><p>Tika uses the <a class="externalLink" hre
f="http://commons.apache.org/compress/">Commons Compress</a> library to support various compression and packaging formats. The <a href="./api/org/apache/tika/parser/pkg/PackageParser.html">PackageParser</a> class and its subclasses first parse the top level compression or packaging format and then pass the unpacked document streams to a second parsing stage using the parser instance specified in the parse context.</p></div><div class="section"><h3><a name="Text_formats">Text formats</a><a name="Text_formats"></a></h3><p>Extracting text content from plain text files seems like a simple task until you start thinking of all the possible character encodings. The <a href="./api/org/apache/tika/parser/txt/TXTParser.html">TXTParser</a> class uses encoding detection code from the <a class="externalLink" href="http://site.icu-project.org/">ICU</a> project to automatically detect the character encoding of a text document.</p></div><div class="section"><h3><a name="Audio_formats">Audio
formats</a><a name="Audio_formats"></a></h3><p>Tika can detect several common audio formats and extract metadata from them. Even text extraction is supported for some audio files that contain lyrics or other textual content. The <a href="./api/org/apache/tika/parser/audio/AudioParser.html">AudioParser</a> and <a href="./api/org/apache/tika/parser/audio/MidiParser.html">MidiParser</a> classes use standard javax.sound features to process simple audio formats, and the <a href="./api/org/apache/tika/parser/mp3/Mp3Parser.html">Mp3Parser</a> class adds support for the widely used MP3 format.</p></div><div class="section"><h3><a name="Image_formats">Image formats</a><a name="Image_formats"></a></h3><p>The <a href="./api/org/apache/tika/parser/image/ImageParser.html">ImageParser</a> class uses the standard javax.imageio feature to extract simple metadata from image formats supported by the Java platform. More complex image metadata is available through the <a href="./api/org/apache
/tika/parser/jpeg/JpegParser.html">JpegParser</a> class that uses the metadata-extractor library to supports Exif metadata extraction from Jpeg images.</p></div><div class="section"><h3><a name="Video_formats">Video formats</a><a name="Video_formats"></a></h3><p>Currently Tika only supports the Flash video format using a simple parsing algorithm implemented in the <a href="./api/org/apache/tika/parser/flv/FLVParser">FLVParser</a> class.</p></div><div class="section"><h3><a name="Java_class_files_and_archives">Java class files and archives</a><a name="Java_class_files_and_archives"></a></h3><p>The <a href="./api/org/apache/tika/parser/asm/ClassParser">ClassParser</a> class extracts class names and method signatures from Java class files, and the <a href="./api/org/apache/tika/parser/pkg/ZipParser.html">ZipParser</a> class supports also jar archives.</p></div><div class="section"><h3><a name="The_mbox_format">The mbox format</a><a name="The_mbox_format"></a></h3><p>The <a href
="./api/org/apache/tika/parser/mbox/MboxParser.html">MboxParser</a> can extract email messages from the mbox format used by many email archives and Unix-style mailboxes.</p></div></div>
</div>
</div>
<div class="clear">
Modified: tika/site/publish/0.7/parser.html
URL: http://svn.apache.org/viewvc/tika/site/publish/0.7/parser.html?rev=982632&r1=982631&r2=982632&view=diff
==============================================================================
--- tika/site/publish/0.7/parser.html (original)
+++ tika/site/publish/0.7/parser.html Thu Aug 5 14:19:17 2010
@@ -174,9 +174,9 @@
</div>
<div id="bodyColumn">
<div id="contentBox">
- <!-- Licensed to the Apache Software Foundation (ASF) under one or more --><!-- contributor license agreements. See the NOTICE file distributed with --><!-- this work for additional information regarding copyright ownership. --><!-- The ASF licenses this file to You under the Apache License, Version 2.0 --><!-- (the "License"); you may not use this file except in compliance with --><!-- the License. You may obtain a copy of the License at --><!-- --><!-- http://www.apache.org/licenses/LICENSE-2.0 --><!-- --><!-- Unless required by applicable law or agreed to in writing, software --><!-- distributed under the License is distributed on an "AS IS" BASIS, --><!-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --><!-- See the License for the specific language governing permissions and --><!-- limitations under the License. --><div class="section"><h2>The Parser interface<a name="The_Parser_interface"></a></h2><p>The <a href="#apiorgapachetika
parserParser.html">org.apache.tika.parser.Parser</a> interface is the key concept of Apache Tika. It hides the complexity of different file formats and parsing libraries while providing a simple and powerful mechanism for client applications to extract structured text content and metadata from all sorts of documents. All this is achieved with a single method:</p><div><pre>void parse(
+ <!-- Licensed to the Apache Software Foundation (ASF) under one or more --><!-- contributor license agreements. See the NOTICE file distributed with --><!-- this work for additional information regarding copyright ownership. --><!-- The ASF licenses this file to You under the Apache License, Version 2.0 --><!-- (the "License"); you may not use this file except in compliance with --><!-- the License. You may obtain a copy of the License at --><!-- --><!-- http://www.apache.org/licenses/LICENSE-2.0 --><!-- --><!-- Unless required by applicable law or agreed to in writing, software --><!-- distributed under the License is distributed on an "AS IS" BASIS, --><!-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --><!-- See the License for the specific language governing permissions and --><!-- limitations under the License. --><div class="section"><h2>The Parser interface<a name="The_Parser_interface"></a></h2><p>The <a href="./api/org/apache/
tika/parser/Parser.html">org.apache.tika.parser.Parser</a> interface is the key concept of Apache Tika. It hides the complexity of different file formats and parsing libraries while providing a simple and powerful mechanism for client applications to extract structured text content and metadata from all sorts of documents. All this is achieved with a single method:</p><div><pre>void parse(
InputStream stream, ContentHandler handler, Metadata metadata,
- ParseContext context) throws IOException, SAXException, TikaException;</pre></div><p>The <tt>parse</tt> method takes the document to be parsed and related metadata as input and outputs the results as XHTML SAX events and extra metadata. The parse context argument is used to specify context information (like the current local) that is not related to any individual document. The main criteria that lead to this design were:</p><dl><dt>Streamed parsing</dt><dd>The interface should require neither the client application nor the parser implementation to keep the full document content in memory or spooled to disk. This allows even huge documents to be parsed without excessive resource requirements.</dd><dt>Structured content</dt><dd>A parser implementation should be able to include structural information (headings, links, etc.) in the extracted content. A client application can use this information for example to better judge the relevance of different parts of the parsed docum
ent.</dd><dt>Input metadata</dt><dd>A client application should be able to include metadata like the file name or declared content type with the document to be parsed. The parser implementation can use this information to better guide the parsing process.</dd><dt>Output metadata</dt><dd>A parser implementation should be able to return document metadata in addition to document content. Many document formats contain metadata like the name of the author that may be useful to client applications.</dd><dt>Context sensitivity</dt><dd>While the default settings and behaviour of Tika parsers should work well for most use cases, there are still situations where more fine-grained control over the parsing process is desirable. It should be easy to inject such context-specific information to the parsing process without breaking the layers of abstraction.</dd></dl><p>These criteria are reflected in the arguments of the <tt>parse</tt> method.</p><div class="section"><h3>Document input str
eam<a name="Document_input_stream"></a></h3><p>The first argument is an <a class="externalLink" href="http://java.sun.com/j2se/1.5.0/docs/api/java/io/InputStream.html">InputStream</a> for reading the document to be parsed.</p><p>If this document stream can not be read, then parsing stops and the thrown <a class="externalLink" href="http://java.sun.com/j2se/1.5.0/docs/api/java/io/IOException.html">IOException</a> is passed up to the client application. If the stream can be read but not parsed (for example if the document is corrupted), then the parser throws a <a href="#apiorgapachetikaexceptionTikaException.html">TikaException</a>.</p><p>The parser implementation will consume this stream but <i>will not close it</i>. Closing the stream is the responsibility of the client application that opened it in the first place. The recommended pattern for using streams with the <tt>parse</tt> method is:</p><div><pre>InputStream stream = ...; // open the stream
+ ParseContext context) throws IOException, SAXException, TikaException;</pre></div><p>The <tt>parse</tt> method takes the document to be parsed and related metadata as input and outputs the results as XHTML SAX events and extra metadata. The parse context argument is used to specify context information (like the current local) that is not related to any individual document. The main criteria that lead to this design were:</p><dl><dt>Streamed parsing</dt><dd>The interface should require neither the client application nor the parser implementation to keep the full document content in memory or spooled to disk. This allows even huge documents to be parsed without excessive resource requirements.</dd><dt>Structured content</dt><dd>A parser implementation should be able to include structural information (headings, links, etc.) in the extracted content. A client application can use this information for example to better judge the relevance of different parts of the parsed docum
ent.</dd><dt>Input metadata</dt><dd>A client application should be able to include metadata like the file name or declared content type with the document to be parsed. The parser implementation can use this information to better guide the parsing process.</dd><dt>Output metadata</dt><dd>A parser implementation should be able to return document metadata in addition to document content. Many document formats contain metadata like the name of the author that may be useful to client applications.</dd><dt>Context sensitivity</dt><dd>While the default settings and behaviour of Tika parsers should work well for most use cases, there are still situations where more fine-grained control over the parsing process is desirable. It should be easy to inject such context-specific information to the parsing process without breaking the layers of abstraction.</dd></dl><p>These criteria are reflected in the arguments of the <tt>parse</tt> method.</p><div class="section"><h3>Document input str
eam<a name="Document_input_stream"></a></h3><p>The first argument is an <a class="externalLink" href="http://java.sun.com/j2se/1.5.0/docs/api/java/io/InputStream.html">InputStream</a> for reading the document to be parsed.</p><p>If this document stream can not be read, then parsing stops and the thrown <a class="externalLink" href="http://java.sun.com/j2se/1.5.0/docs/api/java/io/IOException.html">IOException</a> is passed up to the client application. If the stream can be read but not parsed (for example if the document is corrupted), then the parser throws a <a href="./api/org/apache/tika/exception/TikaException.html">TikaException</a>.</p><p>The parser implementation will consume this stream but <i>will not close it</i>. Closing the stream is the responsibility of the client application that opened it in the first place. The recommended pattern for using streams with the <tt>parse</tt> method is:</p><div><pre>InputStream stream = ...; // open the stream
try {
parser.parse(stream, ...); // parse the stream
} finally {
@@ -188,14 +188,14 @@ try {
<body>
...
</body>
-</html></pre></div><p>Parser implementations typically use the <a href="#apidocsorgapachetikasaxXHTMLContentHandler.html">XHTMLContentHandler</a> utility class to generate the XHTML output.</p><p>Dealing with the raw SAX events can be a bit complex, so Apache Tika comes with a number of utility classes that can be used to process and convert the event stream to other representations.</p><p>For example, the <a href="#apiorgapachetikasaxBodyContentHandler.html">BodyContentHandler</a> class can be used to extract just the body part of the XHTML output and feed it either as SAX events to another content handler or as characters to an output stream, a writer, or simply a string. The following code snippet parses a document from the standard input stream and outputs the extracted text content to standard output:</p><div><pre>ContentHandler handler = new BodyContentHandler(System.out);
-parser.parse(System.in, handler, ...);</pre></div><p>Another useful class is <a href="#apiorgapachetikaparserParsingReader.html">ParsingReader</a> that uses a background thread to parse the document and returns the extracted text content as a character stream:</p><div><pre>InputStream stream = ...; // the document to be parsed
+</html></pre></div><p>Parser implementations typically use the <a href="./api/org/apache/tika/sax/XHTMLContentHandler.html">XHTMLContentHandler</a> utility class to generate the XHTML output.</p><p>Dealing with the raw SAX events can be a bit complex, so Apache Tika comes with a number of utility classes that can be used to process and convert the event stream to other representations.</p><p>For example, the <a href="./api/org/apache/tika/sax/BodyContentHandler.html">BodyContentHandler</a> class can be used to extract just the body part of the XHTML output and feed it either as SAX events to another content handler or as characters to an output stream, a writer, or simply a string. The following code snippet parses a document from the standard input stream and outputs the extracted text content to standard output:</p><div><pre>ContentHandler handler = new BodyContentHandler(System.out);
+parser.parse(System.in, handler, ...);</pre></div><p>Another useful class is <a href="./api/org/apache/tika/parser/ParsingReader.html">ParsingReader</a> that uses a background thread to parse the document and returns the extracted text content as a character stream:</p><div><pre>InputStream stream = ...; // the document to be parsed
Reader reader = new ParsingReader(parser, stream, ...);
try {
...; // read the document text using the reader
} finally {
reader.close(); // the document stream is closed automatically
-}</pre></div></div><div class="section"><h3>Document metadata<a name="Document_metadata"></a></h3><p>The third argument to the <tt>parse</tt> method is used to pass document metadata both in and out of the parser. Document metadata is expressed as an <a href="#apiorgapachetikametadataMetadata.html">Metadata</a> object.</p><p>The following are some of the more interesting metadata properties:</p><dl><dt>Metadata.RESOURCE_NAME_KEY</dt><dd>The name of the file or resource that contains the document.<p>A client application can set this property to allow the parser to use file name heuristics to determine the format of the document.</p><p>The parser implementation may set this property if the file format contains the canonical name of the file (for example the Gzip format has a slot for the file name).</p></dd><dt>Metadata.CONTENT_TYPE</dt><dd>The declared content type of the document.<p>A client application can set this property based on for example a HTTP Content-Type header. T
he declared content type may help the parser to correctly interpret the document.</p><p>The parser implementation sets this property to the content type according to which the document was parsed.</p></dd><dt>Metadata.TITLE</dt><dd>The title of the document.<p>The parser implementation sets this property if the document format contains an explicit title field.</p></dd><dt>Metadata.AUTHOR</dt><dd>The name of the author of the document.<p>The parser implementation sets this property if the document format contains an explicit author field.</p></dd></dl><p>Note that metadata handling is still being discussed by the Tika development team, and it is likely that there will be some (backwards incompatible) changes in metadata handling before Tika 1.0.</p></div><div class="section"><h3>Parse context<a name="Parse_context"></a></h3><p>The final argument to the <tt>parse</tt> method is used to inject context-specific information to the parsing process. This is useful for example when
dealing with locale-specific date and number formats in Microsoft Excel spreadsheets. Another important use of the parse context is passing in the delegate parser instance to be used by two-phase parsers like the <a href="#apiorgapacheparserpkgPackageParser.html">PackageParser</a> subclasses. Some parser classes allow customization of the parsing process through strategy objects in the parse context.</p></div><div class="section"><h3>Parser implementations<a name="Parser_implementations"></a></h3><p>Apache Tika comes with a number of parser classes for parsing <a href="#formats.html">various document formats</a>. You can also extend Tika with your own parsers, and of course any contributions to Tika are warmly welcome.</p><p>The goal of Tika is to reuse existing parser libraries like <a class="externalLink" href="http://www.pdfbox.org/">PDFBox</a> or <a class="externalLink" href="http://poi.apache.org/">Apache POI</a> as much as possible, and so most of the parser classes in
Tika are adapters to such external libraries.</p><p>Tika also contains some general purpose parser implementations that are not targeted at any specific document formats. The most notable of these is the <a href="#apidocsorgapachetikaparserAutoDetectParser.html">AutoDetectParser</a> class that encapsulates all Tika functionality into a single parser that can handle any types of documents. This parser will automatically determine the type of the incoming document based on various heuristics and will then parse the document accordingly.</p></div></div>
+}</pre></div></div><div class="section"><h3>Document metadata<a name="Document_metadata"></a></h3><p>The third argument to the <tt>parse</tt> method is used to pass document metadata both in and out of the parser. Document metadata is expressed as an <a href="./api/org/apache/tika/metadata/Metadata.html">Metadata</a> object.</p><p>The following are some of the more interesting metadata properties:</p><dl><dt>Metadata.RESOURCE_NAME_KEY</dt><dd>The name of the file or resource that contains the document.<p>A client application can set this property to allow the parser to use file name heuristics to determine the format of the document.</p><p>The parser implementation may set this property if the file format contains the canonical name of the file (for example the Gzip format has a slot for the file name).</p></dd><dt>Metadata.CONTENT_TYPE</dt><dd>The declared content type of the document.<p>A client application can set this property based on for example a HTTP Content-Type hea
der. The declared content type may help the parser to correctly interpret the document.</p><p>The parser implementation sets this property to the content type according to which the document was parsed.</p></dd><dt>Metadata.TITLE</dt><dd>The title of the document.<p>The parser implementation sets this property if the document format contains an explicit title field.</p></dd><dt>Metadata.AUTHOR</dt><dd>The name of the author of the document.<p>The parser implementation sets this property if the document format contains an explicit author field.</p></dd></dl><p>Note that metadata handling is still being discussed by the Tika development team, and it is likely that there will be some (backwards incompatible) changes in metadata handling before Tika 1.0.</p></div><div class="section"><h3>Parse context<a name="Parse_context"></a></h3><p>The final argument to the <tt>parse</tt> method is used to inject context-specific information to the parsing process. This is useful for example
when dealing with locale-specific date and number formats in Microsoft Excel spreadsheets. Another important use of the parse context is passing in the delegate parser instance to be used by two-phase parsers like the <a href="./api/org/apache/parser/pkg/PackageParser.html">PackageParser</a> subclasses. Some parser classes allow customization of the parsing process through strategy objects in the parse context.</p></div><div class="section"><h3>Parser implementations<a name="Parser_implementations"></a></h3><p>Apache Tika comes with a number of parser classes for parsing <a href="./formats.html">various document formats</a>. You can also extend Tika with your own parsers, and of course any contributions to Tika are warmly welcome.</p><p>The goal of Tika is to reuse existing parser libraries like <a class="externalLink" href="http://www.pdfbox.org/">PDFBox</a> or <a class="externalLink" href="http://poi.apache.org/">Apache POI</a> as much as possible, and so most of the pars
er classes in Tika are adapters to such external libraries.</p><p>Tika also contains some general purpose parser implementations that are not targeted at any specific document formats. The most notable of these is the <a href="./api/org/apache/tika/parser/AutoDetectParser.html">AutoDetectParser</a> class that encapsulates all Tika functionality into a single parser that can handle any types of documents. This parser will automatically determine the type of the incoming document based on various heuristics and will then parse the document accordingly.</p></div></div>
</div>
</div>
<div class="clear">
Modified: tika/site/publish/0.7/parser_guide.html
URL: http://svn.apache.org/viewvc/tika/site/publish/0.7/parser_guide.html?rev=982632&r1=982631&r2=982632&view=diff
==============================================================================
--- tika/site/publish/0.7/parser_guide.html (original)
+++ tika/site/publish/0.7/parser_guide.html Thu Aug 5 14:19:17 2010
@@ -174,7 +174,7 @@
</div>
<div id="bodyColumn">
<div id="contentBox">
- <!-- Licensed to the Apache Software Foundation (ASF) under one or more --><!-- contributor license agreements. See the NOTICE file distributed with --><!-- this work for additional information regarding copyright ownership. --><!-- The ASF licenses this file to You under the Apache License, Version 2.0 --><!-- (the "License"); you may not use this file except in compliance with --><!-- the License. You may obtain a copy of the License at --><!-- --><!-- http://www.apache.org/licenses/LICENSE-2.0 --><!-- --><!-- Unless required by applicable law or agreed to in writing, software --><!-- distributed under the License is distributed on an "AS IS" BASIS, --><!-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --><!-- See the License for the specific language governing permissions and --><!-- limitations under the License. --><div class="section"><h2>Get Tika parsing up and running in 5 minutes<a name="Get_Tika_parsing_up_and_running_in_5_min
utes"></a></h2><p>This page is a quick start guide showing how to add a new parser to Apache Tika. Following the simple steps listed below your new parser can be running in only 5 minutes.</p><ul><li><a href="#Get_Tika_parsing_up_and_running_in_5_minutes">Get Tika parsing up and running in 5 minutes</a><ul><li><a href="#Getting_Started">Getting Started</a></li><li><a href="#Add_your_MIME-Type">Add your MIME-Type</a></li><li><a href="#Create_your_Parser_class">Create your Parser class</a></li><li><a href="#List_the_new_parser">List the new parser</a></li></ul></li></ul><div class="section"><h3><a name="Getting_Started">Getting Started</a><a name="Getting_Started"></a></h3><p>The <a href="#gettingstarted.html">Getting Started</a> document describes how to build Apache Tika from sources and how to start using Tika in an application. Pay close attention and follow the instructions in the "Getting and building the sources" section.</p></div><div class="section"><h3><a n
ame="Add_your_MIME-Type">Add your MIME-Type</a><a name="Add_your_MIME-Type"></a></h3><p>You first need to modify <a class="externalLink" href="http://svn.apache.org/repos/asf/tika/trunk/tika-core/src/main/resources/org/apache/tika/mime/tika-mimetypes.xml">tika-core/src/main/resources/org/apache/tika/mime/tika-mimetypes.xml</a> in order to Tika can map the file extension with its MIME-Type. You should add something like this:</p><div><pre> <mime-type type="application/hello">
+ <!-- Licensed to the Apache Software Foundation (ASF) under one or more --><!-- contributor license agreements. See the NOTICE file distributed with --><!-- this work for additional information regarding copyright ownership. --><!-- The ASF licenses this file to You under the Apache License, Version 2.0 --><!-- (the "License"); you may not use this file except in compliance with --><!-- the License. You may obtain a copy of the License at --><!-- --><!-- http://www.apache.org/licenses/LICENSE-2.0 --><!-- --><!-- Unless required by applicable law or agreed to in writing, software --><!-- distributed under the License is distributed on an "AS IS" BASIS, --><!-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --><!-- See the License for the specific language governing permissions and --><!-- limitations under the License. --><div class="section"><h2>Get Tika parsing up and running in 5 minutes<a name="Get_Tika_parsing_up_and_running_in_5_min
utes"></a></h2><p>This page is a quick start guide showing how to add a new parser to Apache Tika. Following the simple steps listed below your new parser can be running in only 5 minutes.</p><ul><li><a href="#Get_Tika_parsing_up_and_running_in_5_minutes">Get Tika parsing up and running in 5 minutes</a><ul><li><a href="#Getting_Started">Getting Started</a></li><li><a href="#Add_your_MIME-Type">Add your MIME-Type</a></li><li><a href="#Create_your_Parser_class">Create your Parser class</a></li><li><a href="#List_the_new_parser">List the new parser</a></li></ul></li></ul><div class="section"><h3><a name="Getting_Started">Getting Started</a><a name="Getting_Started"></a></h3><p>The <a href="./gettingstarted.html">Getting Started</a> document describes how to build Apache Tika from sources and how to start using Tika in an application. Pay close attention and follow the instructions in the "Getting and building the sources" section.</p></div><div class="section"><h3><a
name="Add_your_MIME-Type">Add your MIME-Type</a><a name="Add_your_MIME-Type"></a></h3><p>You first need to modify <a class="externalLink" href="http://svn.apache.org/repos/asf/tika/trunk/tika-core/src/main/resources/org/apache/tika/mime/tika-mimetypes.xml">tika-core/src/main/resources/org/apache/tika/mime/tika-mimetypes.xml</a> in order to Tika can map the file extension with its MIME-Type. You should add something like this:</p><div><pre> <mime-type type="application/hello">
<glob pattern="*.hi"/>
</mime-type></pre></div></div><div class="section"><h3><a name="Create_your_Parser_class">Create your Parser class</a><a name="Create_your_Parser_class"></a></h3><p>Now, you need to create your new parser. This is a class that must implement the Parser interface offered by Tika. A very simple Tika Parser looks like this:</p><div><pre>/*
* Licensed to the Apache Software Foundation (ASF) under one or more
Modified: tika/site/publish/index.html
URL: http://svn.apache.org/viewvc/tika/site/publish/index.html?rev=982632&r1=982631&r2=982632&view=diff
==============================================================================
--- tika/site/publish/index.html (original)
+++ tika/site/publish/index.html Thu Aug 5 14:19:17 2010
@@ -196,7 +196,7 @@
</div>
<div id="bodyColumn">
<div id="contentBox">
- <!-- Licensed to the Apache Software Foundation (ASF) under one or more --><!-- contributor license agreements. See the NOTICE file distributed with --><!-- this work for additional information regarding copyright ownership. --><!-- The ASF licenses this file to You under the Apache License, Version 2.0 --><!-- (the "License"); you may not use this file except in compliance with --><!-- the License. You may obtain a copy of the License at --><!-- --><!-- http://www.apache.org/licenses/LICENSE-2.0 --><!-- --><!-- Unless required by applicable law or agreed to in writing, software --><!-- distributed under the License is distributed on an "AS IS" BASIS, --><!-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --><!-- See the License for the specific language governing permissions and --><!-- limitations under the License. --><div class="section"><h2>Tika - Content Analysis Toolkit<a name="Tika_-_Content_Analysis_Toolkit"></a></h2><p>Apache T
ika is a toolkit for detecting and extracting metadata and structured text content from various documents using existing parser libraries. You can find the latest release on the <a href="#download.html">download page</a>. See the <a href="#a0.7gettingstarted.html">Getting Started</a> guide for instructions on how to start using Tika.</p><p>Tika was formerly a subproject of <a class="externalLink" href="http://lucene.apache.org/">Apache Lucene</a>. Lucene is a project of the <a class="externalLink" href="http://www.apache.org/">Apache Software Foundation</a>.</p></div><div class="section"><h2>Latest News<a name="Latest_News"></a></h2><dl><dt>April 2010: Tika Graduates to TLP</dt><dd> Apache Tika was voted into TLP status by a resolution submitted to the Apache Board. We are in the process of updating the site and moving things around. If you notice anything out of place, let us know.</dd><dt>April 2010: Apache Tika Release</dt><dd> Apache Tika 0.7 has been released. Please se
e the download page for more details.</dd><dt>January 2010: Apache Tika Release</dt><dd> Apache Tika 0.6 has been released. Please see the download page for more details.</dd><dt>November 2009: Apache Tika Release</dt><dd> Apache Tika 0.5 has been released. Please see the download page for more details.</dd><dt>14 August 2009 - Lucene at US ApacheCon</dt><dd> ApacheCon US is once again in the Bay Area and Lucene is coming along for the ride! The Lucene community has planned two full days of talks, plus a meetup and the usual bevy of training. With a well-balanced mix of first time and veteran ApacheCon speakers, the <a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/schedule#lucene">Lucene track</a> at ApacheCon US promises to have something for everyone. Be sure not to miss:<p>Training:</p><ul><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/437">Lucene Boot Camp</a> - A two day training session, Nov. 2nd & 3rd</li><li>
<a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/375">Solr Day</a> - A one day training session, Nov. 2nd</li></ul><p>Thursday, Nov. 5th:</p><ul><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/428">Introduction to the Lucene Ecosystem</a> - Grant Ingersoll @ 9:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/461">Lucene Basics and New Features</a> - Michael Busch @ 10:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/331">Apache Solr: Out of the Box</a> - Chris Hostetter @ 14:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/427">Introduction to Nutch</a> - Andrzej Bialecki @ 15:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/430">Lucene and Solr Performance Tuning</a> - Mark Miller @ 16:30</li></ul><p>Friday, Nov. 6th:</p><ul><li><a class="externalLink" hr
ef="http://www.us.apachecon.com/c/acus2009/sessions/332">Implementing an Information Retrieval Framework for an Organizational Repository</a> - Sithu D Sudarsan @ 9:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/333">Apache Mahout - Going from raw data to Information</a> - Isabel Drost @ 10:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/334">MIME Magic with Apache Tika</a> - Jukka Zitting @ 11:30</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/335">Building Intelligent Search Applications with the Lucene Ecosystem</a> - Ted Dunning @ 14:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/462">Realtime Search</a> - Jason Rutherglen @ 15:00</li></ul></dd><dt>July 2009: Apache Tika Release</dt><dd> Apache Tika 0.4 has been released. Please see the download page for more details.</dd><dt>March 2009: Apache Tika Release</dt
><dd> Apache Tika 0.3 has been released. Please see the download page for more details.</dd><dt>February 2009: Lucene at ApacheCon Europe 2009 in Amsterdam</dt><dd> Lucene will be extremely well represented at <a class="externalLink" href="http://www.eu.apachecon.com/c/aceu2009/">ApacheCon EU 2009</a> in Amsterdam, Netherlands this March 23-27, 2009:<ul><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/197">Lucene Boot Camp</a> - A two day training session, March 23 & 24th</li><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/201">Solr Boot Camp</a> - A one day training session, March 24th</li><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/136">Introducing Apache Mahout</a> - Grant Ingersoll. March 25th @ 10:30</li><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/137">Lucene/Solr Case Studies</a> - Erik Hatcher. March 25th @ 11:30</li><li><a class="external
Link" href="http://eu.apachecon.com/c/aceu2009/sessions/138">Advanced Indexing Techniques with Apache Lucene</a> - Michael Busch. March 25th @ 14:00</li><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/251">Apache Solr - A Case Study</a> - Uri Boness. March 26th @ 17:30</li><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/250">Best of breed - httpd, forrest, solr and droids</a> - Thorsten Scherler. March 27th @ 17:30</li><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/165">Apache Droids - an intelligent standalone robot framework</a> - Thorsten Scherler. March 26th @ 15:00</li></ul></dd><dt>December 2008: Apache Tika Release</dt><dd> Apache Tika 0.2 has been released. Please see the download page for more details.</dd><dt>November 2008: User mailing list created</dt><dd> A new mailing list, tika-user@lucene.apache.org, has been created for discussion about the use of the Tika toolkit. You
can subscribe this mailing list by sending a message to tika-user-subscribe@lucene.apache.org.</dd><dt>October 2008: Tika graduates to a Lucene subproject</dt><dd> Tika has graduated form the Incubator to become a subproject of Apache Lucene. The project infrastructure will be migrated from incubator.apache.org to lucene.apache.org.</dd><dt>October 2008: Apache Tika status report</dt><dd> Dave Meikle was just voted in as a new committer.<p>Paolo Mottadelli will present Tika at ApacheCon US.</p><p>Tika 0.2 should be released soon.</p><p>Usage documentation has been added to the website.</p></dd><dt>July 2008: Apache Tika status report</dt><dd> Tika community remains relatively small, with just a handful of active members<p>Work towards Tika 0.2 continues, Chris Mattman has volunteered to be the release manager</p></dd><dt>April 2008: Apache Tika status report</dt><dd> Niall Pemberton joined the project as a committer and PPMC member<p>The number of issues reported by externa
l contributors is growing gradually.</p><p>There was a Fast Feather Talk on Tika in ApacheCon EU 2008</p><p>We have good contacts especially with Apache POI and PDFBox</p><p>We are working towards Tika 0.2</p><p>Metadata handling improvements are being discussed</p></dd><dt>January 2008: Apache Tika status report</dt><dd> No new committers since the last report, activity has been moderate but steady, leading to the 0.1 release.<p>Tika 0.1 (incubating) has just been released.</p><p>Chris Mattmann intends to use that release in Nutch, That's good progress towards Tika's goal of providing data extraction functionality to other projects.</p><p>A new Tika logo was created by Google Highly Open Participation student, hasn't been integrated yet.</p></dd><dt>December 27th, 2007: Tika 0.1-incubating Released!</dt><dd> Tika has made its first official release, titled 0.1-incubating. See the <a class="externalLink" href="http://www.apache.org/dist/incubator/tika/CHANGES-0.1-incubating.
txt">CHANGES.txt</a> file for more information on the list of updates in this initial release. Thanks to all who contributed! You can download the official source tarball <a class="externalLink" href="http://www.apache.org/dyn/closer.cgi/incubator/tika">here</a>.</dd><dt>October 8th, 2007: Welcome Keith Bennett!</dt><dd> The Tika PPMC has <a class="externalLink" href="http://www.nabble.com/Please-welcome-Keith-Bennett-as-a-Tika-committer%21-tf4586151.html#a13107428">elected</a> Keith Bennett as our new committer. Welcome!</dd><dt>March 22nd, 2007: Apache Tika project started</dt><dd> The Apache Tika project was formally started when the <a class="externalLink" href="http://wiki.apache.org/incubator/TikaProposal">Tika proposal</a> was <a class="externalLink" href="http://mail-archives.apache.org/mod_mbox/incubator-general/200703.mbox/%3c510143ac0703221130p4341aa78vd6608c13ffc95a82@mail.gmail.com%3e">accepted</a> by the <a class="externalLink" href="http://incubator.apache.org
/">Apache Incubator PMC</a>. </dd></dl></div>
+ <!-- Licensed to the Apache Software Foundation (ASF) under one or more --><!-- contributor license agreements. See the NOTICE file distributed with --><!-- this work for additional information regarding copyright ownership. --><!-- The ASF licenses this file to You under the Apache License, Version 2.0 --><!-- (the "License"); you may not use this file except in compliance with --><!-- the License. You may obtain a copy of the License at --><!-- --><!-- http://www.apache.org/licenses/LICENSE-2.0 --><!-- --><!-- Unless required by applicable law or agreed to in writing, software --><!-- distributed under the License is distributed on an "AS IS" BASIS, --><!-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --><!-- See the License for the specific language governing permissions and --><!-- limitations under the License. --><div class="section"><h2>Tika - Content Analysis Toolkit<a name="Tika_-_Content_Analysis_Toolkit"></a></h2><p>Apache T
ika is a toolkit for detecting and extracting metadata and structured text content from various documents using existing parser libraries. You can find the latest release on the <a href="./download.html">download page</a>. See the <a href="./0.7/gettingstarted.html">Getting Started</a> guide for instructions on how to start using Tika.</p><p>Tika was formerly a subproject of <a class="externalLink" href="http://lucene.apache.org/">Apache Lucene</a>. Lucene is a project of the <a class="externalLink" href="http://www.apache.org/">Apache Software Foundation</a>.</p></div><div class="section"><h2>Latest News<a name="Latest_News"></a></h2><dl><dt>April 2010: Tika Graduates to TLP</dt><dd> Apache Tika was voted into TLP status by a resolution submitted to the Apache Board. We are in the process of updating the site and moving things around. If you notice anything out of place, let us know.</dd><dt>April 2010: Apache Tika Release</dt><dd> Apache Tika 0.7 has been released. Please
see the download page for more details.</dd><dt>January 2010: Apache Tika Release</dt><dd> Apache Tika 0.6 has been released. Please see the download page for more details.</dd><dt>November 2009: Apache Tika Release</dt><dd> Apache Tika 0.5 has been released. Please see the download page for more details.</dd><dt>14 August 2009 - Lucene at US ApacheCon</dt><dd> ApacheCon US is once again in the Bay Area and Lucene is coming along for the ride! The Lucene community has planned two full days of talks, plus a meetup and the usual bevy of training. With a well-balanced mix of first time and veteran ApacheCon speakers, the <a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/schedule#lucene">Lucene track</a> at ApacheCon US promises to have something for everyone. Be sure not to miss:<p>Training:</p><ul><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/437">Lucene Boot Camp</a> - A two day training session, Nov. 2nd & 3rd</li><l
i><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/375">Solr Day</a> - A one day training session, Nov. 2nd</li></ul><p>Thursday, Nov. 5th:</p><ul><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/428">Introduction to the Lucene Ecosystem</a> - Grant Ingersoll @ 9:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/461">Lucene Basics and New Features</a> - Michael Busch @ 10:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/331">Apache Solr: Out of the Box</a> - Chris Hostetter @ 14:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/427">Introduction to Nutch</a> - Andrzej Bialecki @ 15:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/430">Lucene and Solr Performance Tuning</a> - Mark Miller @ 16:30</li></ul><p>Friday, Nov. 6th:</p><ul><li><a class="externalLink"
href="http://www.us.apachecon.com/c/acus2009/sessions/332">Implementing an Information Retrieval Framework for an Organizational Repository</a> - Sithu D Sudarsan @ 9:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/333">Apache Mahout - Going from raw data to Information</a> - Isabel Drost @ 10:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/334">MIME Magic with Apache Tika</a> - Jukka Zitting @ 11:30</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/335">Building Intelligent Search Applications with the Lucene Ecosystem</a> - Ted Dunning @ 14:00</li><li><a class="externalLink" href="http://www.us.apachecon.com/c/acus2009/sessions/462">Realtime Search</a> - Jason Rutherglen @ 15:00</li></ul></dd><dt>July 2009: Apache Tika Release</dt><dd> Apache Tika 0.4 has been released. Please see the download page for more details.</dd><dt>March 2009: Apache Tika Release</
dt><dd> Apache Tika 0.3 has been released. Please see the download page for more details.</dd><dt>February 2009: Lucene at ApacheCon Europe 2009 in Amsterdam</dt><dd> Lucene will be extremely well represented at <a class="externalLink" href="http://www.eu.apachecon.com/c/aceu2009/">ApacheCon EU 2009</a> in Amsterdam, Netherlands this March 23-27, 2009:<ul><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/197">Lucene Boot Camp</a> - A two day training session, March 23 & 24th</li><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/201">Solr Boot Camp</a> - A one day training session, March 24th</li><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/136">Introducing Apache Mahout</a> - Grant Ingersoll. March 25th @ 10:30</li><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/137">Lucene/Solr Case Studies</a> - Erik Hatcher. March 25th @ 11:30</li><li><a class="extern
alLink" href="http://eu.apachecon.com/c/aceu2009/sessions/138">Advanced Indexing Techniques with Apache Lucene</a> - Michael Busch. March 25th @ 14:00</li><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/251">Apache Solr - A Case Study</a> - Uri Boness. March 26th @ 17:30</li><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/250">Best of breed - httpd, forrest, solr and droids</a> - Thorsten Scherler. March 27th @ 17:30</li><li><a class="externalLink" href="http://eu.apachecon.com/c/aceu2009/sessions/165">Apache Droids - an intelligent standalone robot framework</a> - Thorsten Scherler. March 26th @ 15:00</li></ul></dd><dt>December 2008: Apache Tika Release</dt><dd> Apache Tika 0.2 has been released. Please see the download page for more details.</dd><dt>November 2008: User mailing list created</dt><dd> A new mailing list, tika-user@lucene.apache.org, has been created for discussion about the use of the Tika toolkit. Y
ou can subscribe this mailing list by sending a message to tika-user-subscribe@lucene.apache.org.</dd><dt>October 2008: Tika graduates to a Lucene subproject</dt><dd> Tika has graduated form the Incubator to become a subproject of Apache Lucene. The project infrastructure will be migrated from incubator.apache.org to lucene.apache.org.</dd><dt>October 2008: Apache Tika status report</dt><dd> Dave Meikle was just voted in as a new committer.<p>Paolo Mottadelli will present Tika at ApacheCon US.</p><p>Tika 0.2 should be released soon.</p><p>Usage documentation has been added to the website.</p></dd><dt>July 2008: Apache Tika status report</dt><dd> Tika community remains relatively small, with just a handful of active members<p>Work towards Tika 0.2 continues, Chris Mattman has volunteered to be the release manager</p></dd><dt>April 2008: Apache Tika status report</dt><dd> Niall Pemberton joined the project as a committer and PPMC member<p>The number of issues reported by exter
nal contributors is growing gradually.</p><p>There was a Fast Feather Talk on Tika in ApacheCon EU 2008</p><p>We have good contacts especially with Apache POI and PDFBox</p><p>We are working towards Tika 0.2</p><p>Metadata handling improvements are being discussed</p></dd><dt>January 2008: Apache Tika status report</dt><dd> No new committers since the last report, activity has been moderate but steady, leading to the 0.1 release.<p>Tika 0.1 (incubating) has just been released.</p><p>Chris Mattmann intends to use that release in Nutch, That's good progress towards Tika's goal of providing data extraction functionality to other projects.</p><p>A new Tika logo was created by Google Highly Open Participation student, hasn't been integrated yet.</p></dd><dt>December 27th, 2007: Tika 0.1-incubating Released!</dt><dd> Tika has made its first official release, titled 0.1-incubating. See the <a class="externalLink" href="http://www.apache.org/dist/incubator/tika/CHANGES-0.1-incubatin
g.txt">CHANGES.txt</a> file for more information on the list of updates in this initial release. Thanks to all who contributed! You can download the official source tarball <a class="externalLink" href="http://www.apache.org/dyn/closer.cgi/incubator/tika">here</a>.</dd><dt>October 8th, 2007: Welcome Keith Bennett!</dt><dd> The Tika PPMC has <a class="externalLink" href="http://www.nabble.com/Please-welcome-Keith-Bennett-as-a-Tika-committer%21-tf4586151.html#a13107428">elected</a> Keith Bennett as our new committer. Welcome!</dd><dt>March 22nd, 2007: Apache Tika project started</dt><dd> The Apache Tika project was formally started when the <a class="externalLink" href="http://wiki.apache.org/incubator/TikaProposal">Tika proposal</a> was <a class="externalLink" href="http://mail-archives.apache.org/mod_mbox/incubator-general/200703.mbox/%3c510143ac0703221130p4341aa78vd6608c13ffc95a82@mail.gmail.com%3e">accepted</a> by the <a class="externalLink" href="http://incubator.apache.o
rg/">Apache Incubator PMC</a>. </dd></dl></div>
</div>
</div>
<div class="clear">
Modified: tika/site/src/site/apt/0.5/documentation.apt
URL: http://svn.apache.org/viewvc/tika/site/src/site/apt/0.5/documentation.apt?rev=982632&r1=982631&r2=982632&view=diff
==============================================================================
--- tika/site/src/site/apt/0.5/documentation.apt (original)
+++ tika/site/src/site/apt/0.5/documentation.apt Thu Aug 5 14:19:17 2010
@@ -23,7 +23,7 @@ Apache Tika Documentation
The Parser interface
- The {{{apidocs/org/apache/tika/parser/Parser.html}org.apache.tika.parser.Parser}}
+ The {{{./api/org/apache/tika/parser/Parser.html}org.apache.tika.parser.Parser}}
interface is the key concept of Apache Tika. It hides the complexity of
different file formats and parsing libraries while providing a simple and
powerful mechanism for client applications to extract structured text
@@ -73,7 +73,7 @@ Document input stream
{{{http://java.sun.com/j2se/1.5.0/docs/api/java/io/IOException.html}IOException}}
is passed up to the client application. If the stream can be read but
not parsed (for example if the document is corrupted), then the parser
- throws a {{{apidocs/org/apache/tika/exception/TikaException.html}TikaException}}.
+ throws a {{{./api/org/apache/tika/exception/TikaException.html}TikaException}}.
The parser implementation will consume this stream but <will not close it>.
Closing the stream is the responsibility of the client application that
@@ -128,7 +128,7 @@ XHTML SAX events
---
Parser implementations typically use the
- {{{apidocs/org/apache/tika/sax/XHTMLContentHandler.html}XHTMLContentHandler}}
+ {{{./api/org/apache/tika/sax/XHTMLContentHandler.html}XHTMLContentHandler}}
utility class to generate the XHTML output.
Dealing with the raw SAX events can be a bit complex, so Apache Tika (since
@@ -136,7 +136,7 @@ XHTML SAX events
process and convert the event stream to other representations.
For example, the
- {{{apidocs/org/apache/tika/sax/BodyContentHandler.html}BodyContentHandler}}
+ {{{./api/org/apache/tika/sax/BodyContentHandler.html}BodyContentHandler}}
class can be used to extract just the body part of the XHTML output and
feed it either as SAX events to another content handler or as characters
to an output stream, a writer, or simply a string. The following code
@@ -149,7 +149,7 @@ parser.parse(System.in, handler, ...);
---
Another useful class is
- {{{apidocs/org/apache/tika/parser/ParsingReader.html}ParsingReader}} that
+ {{{./api/org/apache/tika/parser/ParsingReader.html}ParsingReader}} that
uses a background thread to parse the document and returns the extracted
text content as a character stream:
@@ -167,7 +167,7 @@ Document metadata
The final argument to the <<<parse>>> method is used to pass document
metadata both in and out of the parser. Document metadata is expressed
- as an {{{apidocs/org/apache/tika/metadata/Metadata.html}Metadata}} object.
+ as an {{{./api/org/apache/tika/metadata/Metadata.html}Metadata}} object.
The following are some of the more interesting metadata properties:
@@ -209,7 +209,7 @@ Document metadata
Parser implementations
Apache Tika comes with a number of parser classes for parsing
- {{{formats.html}various document formats}}. You can also extend Tika
+ {{{./formats.html}various document formats}}. You can also extend Tika
with your own parsers, and of course any contributions to Tika are
warmly welcome.
@@ -220,7 +220,7 @@ Parser implementations
Tika also contains some general purpose parser implementations that are
not targeted at any specific document formats. The most notable of these
- is the {{{apidocs/org/apache/tika/parser/AutoDetectParser.html}AutoDetectParser}}
+ is the {{{./api/org/apache/tika/parser/AutoDetectParser.html}AutoDetectParser}}
class that encapsulates all Tika functionality into a single parser that
can handle any types of documents. This parser will automatically determine
the type of the incoming document based on various heuristics and will then
Modified: tika/site/src/site/apt/0.5/formats.apt
URL: http://svn.apache.org/viewvc/tika/site/src/site/apt/0.5/formats.apt?rev=982632&r1=982631&r2=982632&view=diff
==============================================================================
--- tika/site/src/site/apt/0.5/formats.apt (original)
+++ tika/site/src/site/apt/0.5/formats.apt Thu Aug 5 14:19:17 2010
@@ -101,9 +101,6 @@ Supported Document Formats
{{{https://issues.apache.org/jira/browse/TIKA-103}TIKA-103}} for the
respective issues.
- See the {{{xref-test/org/apache/tika/parser/microsoft/ExcelParserTest.html}ExcelParserTest}}
- test case for an example of parsing Microsoft Excel files.
-
[Microsoft Word (application/msword)]
Word document support is available in all versions of Tika and is based
on the {{{http://poi.apache.org/hwpf/}HWPF library}} from POI.
@@ -112,9 +109,6 @@ Supported Document Formats
{{{http://poi.apache.org/apidocs/org/apache/poi/hwpf/extractor/WordExtractor.html}WordExtractor}}
class from HWPF to extract document content as a sequence of paragraphs.
- See the {{{xref-test/org/apache/tika/parser/microsoft/WordParserTest.html}WordParserTest}}
- test case for an example of parsing Microsoft Word files.
-
[Microsoft PowerPoint (application/vnd.ms-powerpoint)]
PowerPoint presentation support is available in all versions of Tika and
is based on the {{{http://poi.apache.org/hslf/}HSLF library}} from POI.
@@ -123,9 +117,6 @@ Supported Document Formats
{{{http://poi.apache.org/apidocs/org/apache/poi/hslf/extractor/PowerPointExtractor.html}PowerPointExtractor}}
class from HSLF to extract spreadsheet content as a single paragraph.
- See the {{{xref-test/org/apache/tika/parser/microsoft/PowerPointParserTest.html}PowerPointParserTest}}
- test case for an example of parsing Microsoft PowerPoint files.
-
[Microsoft Visio (application/vnd.visio)]
Visio diagram support was added in Tika version 0.2 and is based on the
{{{http://poi.apache.org/hdgf/}HDGF library}} from POI.
Modified: tika/site/src/site/apt/0.6/formats.apt
URL: http://svn.apache.org/viewvc/tika/site/src/site/apt/0.6/formats.apt?rev=982632&r1=982631&r2=982632&view=diff
==============================================================================
--- tika/site/src/site/apt/0.6/formats.apt (original)
+++ tika/site/src/site/apt/0.6/formats.apt Thu Aug 5 14:19:17 2010
@@ -31,7 +31,7 @@ Supported Document Formats
Tika uses the {{{http://home.ccil.org/~cowan/XML/tagsoup/}TagSoup}}
library to support virtually any kind of HTML found on the web.
The output from the
- {{{api/org/apache/tika/parser/html/HtmlParser.html}HtmlParser}} class
+ {{{./api/org/apache/tika/parser/html/HtmlParser.html}HtmlParser}} class
is guaranteed to be well-formed and valid XHTML, and various heuristics
are used to prevent things like inline scripts from cluttering the
extracted text content.
@@ -41,7 +41,7 @@ Supported Document Formats
The Extensible Markup Language (XML) format is a generic format that can
be used for all kinds of content. Tika has custom parsers for some widely
used XML vocabularies like XHTML, OOXML and ODF, but the default
- {{{api/org/apache/tika/parser/xml/DcXMLParser.html}DcXMLParser}}
+ {{{./api/org/apache/tika/parser/xml/DcXMLParser.html}DcXMLParser}}
class simply extracts the text content of the document and ignores any XML
structure. The only exception to this rule are Dublin Core metadata
elements that are used for the document metadata.
@@ -53,9 +53,9 @@ Supported Document Formats
older OLE 2 format was introduced in Microsoft Office version 97 and was
the default format until Office version 2007 and the new XML-based
OOXML format. The
- {{{api/org/apache/tika/parser/microsoft/OfficeParser.html}OfficeParser}}
+ {{{./api/org/apache/tika/parser/microsoft/OfficeParser.html}OfficeParser}}
and
- {{{api/org/apache/tika/parser/microsoft/ooxml/OOXMLParser.html}OOXMLParser}}
+ {{{./api/org/apache/tika/parser/microsoft/ooxml/OOXMLParser.html}OOXMLParser}}
classes use {{{http://poi.apache.org/}Apache POI}} libraries to support
text and metadata extraction from both OLE2 and OOXML documents.
@@ -63,25 +63,25 @@ Supported Document Formats
The OpenDocument format (ODF) is used most notably as the default format
of the OpenOffice.org office suite. The
- {{{api/org/apache/tika/parser/odf/OpenDocumentParser.html}OpenDocumentParser}}
+ {{{./api/org/apache/tika/parser/odf/OpenDocumentParser.html}OpenDocumentParser}}
class supports this format and the earlier OpenOffice 1.0 format on which
ODF is based.
* {Portable Document Format}
- The {{{api/org/apache/tika/parser/pdf/PDFParser.html}PDFParser}} class
+ The {{{./api/org/apache/tika/parser/pdf/PDFParser.html}PDFParser}} class
parsers Portable Document Format (PDF) documents using the
{{{http://pdfbox.apache.org/}Apache PDFBox}} library.
* {Electronic Publication Format}
- The {{{api/org/apache/tika/parser/epub/EpubParser.html}EpubParser}} class
+ The {{{./api/org/apache/tika/parser/epub/EpubParser.html}EpubParser}} class
supports the Electronic Publication Format (EPUB) used for many digital
books.
* {Rich Text Format}
- The {{{api/org/apache/tika/parser/rtf/RTFParser.html}RTFParser}} class
+ The {{{./api/org/apache/tika/parser/rtf/RTFParser.html}RTFParser}} class
uses the standard javax.swing.text.rtf feature to extract text content
from Rich Text Format (RTF) documents.
@@ -89,7 +89,7 @@ Supported Document Formats
Tika uses the {{{http://commons.apache.org/compress/}Commons Compress}}
library to support various compression and packaging formats. The
- {{{api/org/apache/tika/parser/pkg/PackageParser.html}PackageParser}}
+ {{{./api/org/apache/tika/parser/pkg/PackageParser.html}PackageParser}}
class and its subclasses first parse the top level compression or
packaging format and then pass the unpacked document streams to a
second parsing stage using the parser instance specified in the
@@ -99,7 +99,7 @@ Supported Document Formats
Extracting text content from plain text files seems like a simple task
until you start thinking of all the possible character encodings. The
- {{{api/org/apache/tika/parser/txt/TXTParser.html}TXTParser}} class uses
+ {{{./api/org/apache/tika/parser/txt/TXTParser.html}TXTParser}} class uses
encoding detection code from the {{{http://site.icu-project.org/}ICU}}
project to automatically detect the character encoding of a text document.
@@ -108,20 +108,20 @@ Supported Document Formats
Tika can detect several common audio formats and extract metadata
from them. Even text extraction is supported for some audio files that
contain lyrics or other textual content. The
- {{{api/org/apache/tika/parser/audio/AudioParser.html}AudioParser}}
- and {{{api/org/apache/tika/parser/audio/MidiParser.html}MidiParser}}
+ {{{./api/org/apache/tika/parser/audio/AudioParser.html}AudioParser}}
+ and {{{./api/org/apache/tika/parser/audio/MidiParser.html}MidiParser}}
classes use standard javax.sound features to process simple audio
formats, and the
- {{{api/org/apache/tika/parser/mp3/Mp3Parser.html}Mp3Parser}} class
+ {{{./api/org/apache/tika/parser/mp3/Mp3Parser.html}Mp3Parser}} class
adds support for the widely used MP3 format.
* {Image formats}
- The {{{api/org/apache/tika/parser/image/ImageParser.html}ImageParser}}
+ The {{{./api/org/apache/tika/parser/image/ImageParser.html}ImageParser}}
class uses the standard javax.imageio feature to extract simple metadata
from image formats supported by the Java platform. More complex image
metadata is available through the
- {{{api/org/apache/tika/parser/jpeg/JpegParser.html}JpegParser}} class
+ {{{./api/org/apache/tika/parser/jpeg/JpegParser.html}JpegParser}} class
that uses the metadata-extractor library to supports Exif metadata
extraction from Jpeg images.
@@ -129,17 +129,17 @@ Supported Document Formats
Currently Tika only supports the Flash video format using a simple
parsing algorithm implemented in the
- {{{api/org/apache/tika/parser/flv/FLVParser}FLVParser}} class.
+ {{{./api/org/apache/tika/parser/flv/FLVParser}FLVParser}} class.
* {Java class files and archives}
- The {{{api/org/apache/tika/parser/asm/ClassParser}ClassParser}} class
+ The {{{./api/org/apache/tika/parser/asm/ClassParser}ClassParser}} class
extracts class names and method signatures from Java class files, and
- the {{{api/org/apache/tika/parser/pkg/ZipParser.html}ZipParser}} class
+ the {{{./api/org/apache/tika/parser/pkg/ZipParser.html}ZipParser}} class
supports also jar archives.
* {The mbox format}
- The {{{api/org/apache/tika/parser/mbox/MboxParser.html}MboxParser}} can
+ The {{{./api/org/apache/tika/parser/mbox/MboxParser.html}MboxParser}} can
extract email messages from the mbox format used by many email archives
and Unix-style mailboxes.
Modified: tika/site/src/site/apt/0.6/parser.apt
URL: http://svn.apache.org/viewvc/tika/site/src/site/apt/0.6/parser.apt?rev=982632&r1=982631&r2=982632&view=diff
==============================================================================
--- tika/site/src/site/apt/0.6/parser.apt (original)
+++ tika/site/src/site/apt/0.6/parser.apt Thu Aug 5 14:19:17 2010
@@ -20,7 +20,7 @@
The Parser interface
The
- {{{api/org/apache/tika/parser/Parser.html}org.apache.tika.parser.Parser}}
+ {{{./api/org/apache/tika/parser/Parser.html}org.apache.tika.parser.Parser}}
interface is the key concept of Apache Tika. It hides the complexity of
different file formats and parsing libraries while providing a simple and
powerful mechanism for client applications to extract structured text
@@ -79,7 +79,7 @@ void parse(
{{{http://java.sun.com/j2se/1.5.0/docs/api/java/io/IOException.html}IOException}}
is passed up to the client application. If the stream can be read but
not parsed (for example if the document is corrupted), then the parser
- throws a {{{api/org/apache/tika/exception/TikaException.html}TikaException}}.
+ throws a {{{./api/org/apache/tika/exception/TikaException.html}TikaException}}.
The parser implementation will consume this stream but <will not close it>.
Closing the stream is the responsibility of the client application that
@@ -134,7 +134,7 @@ try {
---
Parser implementations typically use the
- {{{apidocs/org/apache/tika/sax/XHTMLContentHandler.html}XHTMLContentHandler}}
+ {{{./api/org/apache/tika/sax/XHTMLContentHandler.html}XHTMLContentHandler}}
utility class to generate the XHTML output.
Dealing with the raw SAX events can be a bit complex, so Apache Tika
@@ -142,7 +142,7 @@ try {
convert the event stream to other representations.
For example, the
- {{{api/org/apache/tika/sax/BodyContentHandler.html}BodyContentHandler}}
+ {{{./api/org/apache/tika/sax/BodyContentHandler.html}BodyContentHandler}}
class can be used to extract just the body part of the XHTML output and
feed it either as SAX events to another content handler or as characters
to an output stream, a writer, or simply a string. The following code
@@ -155,7 +155,7 @@ parser.parse(System.in, handler, ...);
---
Another useful class is
- {{{api/org/apache/tika/parser/ParsingReader.html}ParsingReader}} that
+ {{{./api/org/apache/tika/parser/ParsingReader.html}ParsingReader}} that
uses a background thread to parse the document and returns the extracted
text content as a character stream:
@@ -173,7 +173,7 @@ try {
The third argument to the <<<parse>>> method is used to pass document
metadata both in and out of the parser. Document metadata is expressed
- as an {{{api/org/apache/tika/metadata/Metadata.html}Metadata}} object.
+ as an {{{./api/org/apache/tika/metadata/Metadata.html}Metadata}} object.
The following are some of the more interesting metadata properties:
@@ -220,14 +220,14 @@ try {
in Microsoft Excel spreadsheets. Another important use of the parse
context is passing in the delegate parser instance to be used by
two-phase parsers like the
- {{{api/org/apache/parser/pkg/PackageParser.html}PackageParser}} subclasses.
+ {{{./api/org/apache/parser/pkg/PackageParser.html}PackageParser}} subclasses.
Some parser classes allow customization of the parsing process through
strategy objects in the parse context.
* Parser implementations
Apache Tika comes with a number of parser classes for parsing
- {{{formats.html}various document formats}}. You can also extend Tika
+ {{{./formats.html}various document formats}}. You can also extend Tika
with your own parsers, and of course any contributions to Tika are
warmly welcome.
@@ -238,7 +238,7 @@ try {
Tika also contains some general purpose parser implementations that are
not targeted at any specific document formats. The most notable of these
- is the {{{apidocs/org/apache/tika/parser/AutoDetectParser.html}AutoDetectParser}}
+ is the {{{./api/org/apache/tika/parser/AutoDetectParser.html}AutoDetectParser}}
class that encapsulates all Tika functionality into a single parser that
can handle any types of documents. This parser will automatically determine
the type of the incoming document based on various heuristics and will then
Modified: tika/site/src/site/apt/0.7/formats.apt
URL: http://svn.apache.org/viewvc/tika/site/src/site/apt/0.7/formats.apt?rev=982632&r1=982631&r2=982632&view=diff
==============================================================================
--- tika/site/src/site/apt/0.7/formats.apt (original)
+++ tika/site/src/site/apt/0.7/formats.apt Thu Aug 5 14:19:17 2010
@@ -31,7 +31,7 @@ Supported Document Formats
Tika uses the {{{http://home.ccil.org/~cowan/XML/tagsoup/}TagSoup}}
library to support virtually any kind of HTML found on the web.
The output from the
- {{{api/org/apache/tika/parser/html/HtmlParser.html}HtmlParser}} class
+ {{{./api/org/apache/tika/parser/html/HtmlParser.html}HtmlParser}} class
is guaranteed to be well-formed and valid XHTML, and various heuristics
are used to prevent things like inline scripts from cluttering the
extracted text content.
@@ -41,7 +41,7 @@ Supported Document Formats
The Extensible Markup Language (XML) format is a generic format that can
be used for all kinds of content. Tika has custom parsers for some widely
used XML vocabularies like XHTML, OOXML and ODF, but the default
- {{{api/org/apache/tika/parser/xml/DcXMLParser.html}DcXMLParser}}
+ {{{./api/org/apache/tika/parser/xml/DcXMLParser.html}DcXMLParser}}
class simply extracts the text content of the document and ignores any XML
structure. The only exception to this rule are Dublin Core metadata
elements that are used for the document metadata.
@@ -53,9 +53,9 @@ Supported Document Formats
older OLE 2 format was introduced in Microsoft Office version 97 and was
the default format until Office version 2007 and the new XML-based
OOXML format. The
- {{{api/org/apache/tika/parser/microsoft/OfficeParser.html}OfficeParser}}
+ {{{./api/org/apache/tika/parser/microsoft/OfficeParser.html}OfficeParser}}
and
- {{{api/org/apache/tika/parser/microsoft/ooxml/OOXMLParser.html}OOXMLParser}}
+ {{{./api/org/apache/tika/parser/microsoft/ooxml/OOXMLParser.html}OOXMLParser}}
classes use {{{http://poi.apache.org/}Apache POI}} libraries to support
text and metadata extraction from both OLE2 and OOXML documents.
@@ -63,25 +63,25 @@ Supported Document Formats
The OpenDocument format (ODF) is used most notably as the default format
of the OpenOffice.org office suite. The
- {{{api/org/apache/tika/parser/odf/OpenDocumentParser.html}OpenDocumentParser}}
+ {{{./api/org/apache/tika/parser/odf/OpenDocumentParser.html}OpenDocumentParser}}
class supports this format and the earlier OpenOffice 1.0 format on which
ODF is based.
* {Portable Document Format}
- The {{{api/org/apache/tika/parser/pdf/PDFParser.html}PDFParser}} class
+ The {{{./api/org/apache/tika/parser/pdf/PDFParser.html}PDFParser}} class
parsers Portable Document Format (PDF) documents using the
{{{http://pdfbox.apache.org/}Apache PDFBox}} library.
* {Electronic Publication Format}
- The {{{api/org/apache/tika/parser/epub/EpubParser.html}EpubParser}} class
+ The {{{./api/org/apache/tika/parser/epub/EpubParser.html}EpubParser}} class
supports the Electronic Publication Format (EPUB) used for many digital
books.
* {Rich Text Format}
- The {{{api/org/apache/tika/parser/rtf/RTFParser.html}RTFParser}} class
+ The {{{./api/org/apache/tika/parser/rtf/RTFParser.html}RTFParser}} class
uses the standard javax.swing.text.rtf feature to extract text content
from Rich Text Format (RTF) documents.
@@ -89,7 +89,7 @@ Supported Document Formats
Tika uses the {{{http://commons.apache.org/compress/}Commons Compress}}
library to support various compression and packaging formats. The
- {{{api/org/apache/tika/parser/pkg/PackageParser.html}PackageParser}}
+ {{{./api/org/apache/tika/parser/pkg/PackageParser.html}PackageParser}}
class and its subclasses first parse the top level compression or
packaging format and then pass the unpacked document streams to a
second parsing stage using the parser instance specified in the
@@ -99,7 +99,7 @@ Supported Document Formats
Extracting text content from plain text files seems like a simple task
until you start thinking of all the possible character encodings. The
- {{{api/org/apache/tika/parser/txt/TXTParser.html}TXTParser}} class uses
+ {{{./api/org/apache/tika/parser/txt/TXTParser.html}TXTParser}} class uses
encoding detection code from the {{{http://site.icu-project.org/}ICU}}
project to automatically detect the character encoding of a text document.
@@ -108,20 +108,20 @@ Supported Document Formats
Tika can detect several common audio formats and extract metadata
from them. Even text extraction is supported for some audio files that
contain lyrics or other textual content. The
- {{{api/org/apache/tika/parser/audio/AudioParser.html}AudioParser}}
- and {{{api/org/apache/tika/parser/audio/MidiParser.html}MidiParser}}
+ {{{./api/org/apache/tika/parser/audio/AudioParser.html}AudioParser}}
+ and {{{./api/org/apache/tika/parser/audio/MidiParser.html}MidiParser}}
classes use standard javax.sound features to process simple audio
formats, and the
- {{{api/org/apache/tika/parser/mp3/Mp3Parser.html}Mp3Parser}} class
+ {{{./api/org/apache/tika/parser/mp3/Mp3Parser.html}Mp3Parser}} class
adds support for the widely used MP3 format.
* {Image formats}
- The {{{api/org/apache/tika/parser/image/ImageParser.html}ImageParser}}
+ The {{{./api/org/apache/tika/parser/image/ImageParser.html}ImageParser}}
class uses the standard javax.imageio feature to extract simple metadata
from image formats supported by the Java platform. More complex image
metadata is available through the
- {{{api/org/apache/tika/parser/jpeg/JpegParser.html}JpegParser}} class
+ {{{./api/org/apache/tika/parser/jpeg/JpegParser.html}JpegParser}} class
that uses the metadata-extractor library to supports Exif metadata
extraction from Jpeg images.
@@ -129,17 +129,17 @@ Supported Document Formats
Currently Tika only supports the Flash video format using a simple
parsing algorithm implemented in the
- {{{api/org/apache/tika/parser/flv/FLVParser}FLVParser}} class.
+ {{{./api/org/apache/tika/parser/flv/FLVParser}FLVParser}} class.
* {Java class files and archives}
- The {{{api/org/apache/tika/parser/asm/ClassParser}ClassParser}} class
+ The {{{./api/org/apache/tika/parser/asm/ClassParser}ClassParser}} class
extracts class names and method signatures from Java class files, and
- the {{{api/org/apache/tika/parser/pkg/ZipParser.html}ZipParser}} class
+ the {{{./api/org/apache/tika/parser/pkg/ZipParser.html}ZipParser}} class
supports also jar archives.
* {The mbox format}
- The {{{api/org/apache/tika/parser/mbox/MboxParser.html}MboxParser}} can
+ The {{{./api/org/apache/tika/parser/mbox/MboxParser.html}MboxParser}} can
extract email messages from the mbox format used by many email archives
and Unix-style mailboxes.