public class AlfrescoPoiPatchUtils extends Object
| Constructor and Description |
|---|
AlfrescoPoiPatchUtils() |
| Modifier and Type | Method and Description |
|---|---|
static List<org.openxmlformats.schemas.wordprocessingml.x2006.main.CTFtnEdn> |
getLimitedReadonlyList(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTFootnotes mutableFootnotes)
MNT-577: Alfresco is running 100% CPU for over 10 minutes while extracting metadata for Word office document
Converts mutable CTFootnotes to read-only limited list of CTFtnEdn |
static Iterable<PackageRelationship> |
getRelationships(POIXMLFactory factory,
PackagePart packagePart)
MNT-11823: Upload of PPTX causes very high memory usage leading to system instability
Returns filtered list of PackageRelationship relationships if properties extraction is enabled and parsing is going on for XSLF document or all relationships of the
document |
static void |
setContext(String context)
Sets the current POI context.
|
static void |
setPoiAllowableXslfRelationshipTypes(String context,
Set<String> poiAllowableXslfRelationshipTypes)
|
static void |
setPoiExtractPropertiesOnly(String context,
boolean poiExtractPropertiesOnly)
Sets the flag to determine whether the entire content of XSLF document must be parsed (
false) or not (true). |
static void |
setPoiFootnotesLimit(String context,
int poiFootnotesLimit)
Sets footnotes limit for XWPF documents parser.
|
public static void setPoiFootnotesLimit(String context, int poiFootnotesLimit)
DEFAULT_FOOTNOTES_LIMIT is set if this parameter is not set directly. Related to
MNT-577public static void setPoiExtractPropertiesOnly(String context, boolean poiExtractPropertiesOnly)
false) or not (true). Default value is false.
Related to MNT-11823public static void setPoiAllowableXslfRelationshipTypes(String context, Set<String> poiAllowableXslfRelationshipTypes)
public static void setContext(String context)
AlfrescoPoiPatchUtils will use POI properties for specified contextcontext - - String value which specifies current POI contextpublic static List<org.openxmlformats.schemas.wordprocessingml.x2006.main.CTFtnEdn> getLimitedReadonlyList(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTFootnotes mutableFootnotes)
CTFootnotes to read-only limited list of CTFtnEdnmutableFootnotes - - CTFootnotes instance which contains all currently loaded footnotesList<CTFtnEdn> listpublic static Iterable<PackageRelationship> getRelationships(POIXMLFactory factory, PackagePart packagePart) throws InvalidFormatException
PackageRelationship relationships if properties extraction is enabled and parsing is going on for XSLF document or all relationships of the
documentfactory - - POIXMLFactory instancepackagePart - - PackagePart instance which represents part of OOXML packageIterable<PackageRelationship> instance which contains list of allowable package relationshipsInvalidFormatExceptionCopyright © 2020. All rights reserved.