Package org.apache.tika.parser.microsoft
Class AbstractOfficeParser
java.lang.Object
org.apache.tika.parser.AbstractParser
org.apache.tika.parser.microsoft.AbstractOfficeParser
- All Implemented Interfaces:
Serializable,Parser
- Direct Known Subclasses:
OfficeParser,OOXMLParser,Word2006MLParser
Intermediate layer to set
OfficeParserConfig uniformly.- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidconfigure(ParseContext parseContext) Checks to see if the user has specified anOfficeParserConfig.booleanbooleanbooleanbooleanbooleanvoidsetByteArrayMaxOverride(int maxOverride) WARNING: this sets a static variable in POI.voidsetConcatenatePhoneticRuns(boolean concatenatePhoneticRuns) voidsetDateFormatOverride(String format) voidsetExtractAllAlternativesFromMSG(boolean extractAllAlternativesFromMSG) Some .msg files can contain body content in html, rtf and/or text.voidsetExtractMacros(boolean extractMacros) voidsetIncludeDeletedContent(boolean includeDeletedConent) voidsetIncludeMoveFromContent(boolean includeMoveFromContent) voidsetIncludeShapeBasedContent(boolean includeShapeBasedContent) voidsetUseSAXDocxExtractor(boolean useSAXDocxExtractor) voidsetUseSAXPptxExtractor(boolean useSAXPptxExtractor) Methods inherited from class org.apache.tika.parser.AbstractParser
parseMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.tika.parser.Parser
getSupportedTypes, parse
-
Constructor Details
-
AbstractOfficeParser
public AbstractOfficeParser()
-
-
Method Details
-
configure
Checks to see if the user has specified anOfficeParserConfig. If so, no changes are made; if not, one is added to the context.- Parameters:
parseContext-
-
getIncludeDeletedContent
public boolean getIncludeDeletedContent()- Returns:
- See Also:
-
getIncludeMoveFromContent
public boolean getIncludeMoveFromContent()- Returns:
- See Also:
-
getUseSAXDocxExtractor
public boolean getUseSAXDocxExtractor()- Returns:
- See Also:
-
getExtractMacros
public boolean getExtractMacros()- Returns:
- whether or not to extract macros
- See Also:
-
setIncludeDeletedContent
-
setIncludeMoveFromContent
-
setIncludeShapeBasedContent
-
setUseSAXDocxExtractor
-
setUseSAXPptxExtractor
-
setExtractMacros
-
setConcatenatePhoneticRuns
-
setExtractAllAlternativesFromMSG
Some .msg files can contain body content in html, rtf and/or text. The default behavior is to pick the first non-null value and include only that. If you'd like to extract all non-null body content, which is likely duplicative, set this value to true.- Parameters:
extractAllAlternativesFromMSG- whether or not to extract all alternative parts from msg files- Since:
- 1.17
-
getExtractAllAlternativesFromMSG
public boolean getExtractAllAlternativesFromMSG() -
setByteArrayMaxOverride
WARNING: this sets a static variable in POI. This allows users to override POI's protection of the allocation of overly large byte arrays. Use carefully; and please open up issues on POI's bugzilla to bump values for specific records.- Parameters:
maxOverride-
-
setDateFormatOverride
-