Class RTFParser
- java.lang.Object
-
- org.apache.tika.parser.AbstractParser
-
- org.apache.tika.parser.microsoft.rtf.RTFParser
-
- All Implemented Interfaces:
Serializable,org.apache.tika.parser.Parser
public class RTFParser extends org.apache.tika.parser.AbstractParserRTF parser- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description RTFParser()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static intgetMaxBytesForEmbeddedObject()Deprecated.intgetMemoryLimitInKb()Set<org.apache.tika.mime.MediaType>getSupportedTypes(org.apache.tika.parser.ParseContext context)voidparse(InputStream stream, ContentHandler handler, org.apache.tika.metadata.Metadata metadata, org.apache.tika.parser.ParseContext context)static voidsetMaxBytesForEmbeddedObject(int max)Deprecated.usesetMemoryLimitInKb(int)insteadvoidsetMemoryLimitInKb(int memoryLimitInKb)
-
-
-
Method Detail
-
getMaxBytesForEmbeddedObject
@Deprecated public static int getMaxBytesForEmbeddedObject()
Deprecated.- Returns:
- maximum number of bytes allowed for an embedded object.
-
setMaxBytesForEmbeddedObject
@Deprecated public static void setMaxBytesForEmbeddedObject(int max)
Deprecated.usesetMemoryLimitInKb(int)insteadBytes for embedded objects are currently cached in memory. If something goes wrong during the parsing of an embedded object, it is possible that a read length may be crazily too long and cause a heap crash.- Parameters:
max- maximum number of bytes to allow for embedded objects. If the embedded object has more than this number of bytes, skip it.
-
getSupportedTypes
public Set<org.apache.tika.mime.MediaType> getSupportedTypes(org.apache.tika.parser.ParseContext context)
-
parse
public void parse(InputStream stream, ContentHandler handler, org.apache.tika.metadata.Metadata metadata, org.apache.tika.parser.ParseContext context) throws IOException, SAXException, org.apache.tika.exception.TikaException
- Throws:
IOExceptionSAXExceptionorg.apache.tika.exception.TikaException
-
getMemoryLimitInKb
public int getMemoryLimitInKb()
-
setMemoryLimitInKb
@Field public void setMemoryLimitInKb(int memoryLimitInKb)
-
-