public class FormattingUtils
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
FormattingUtils.Tag |
| Modifier and Type | Method and Description |
|---|---|
static void |
closeStyleTags(XHTMLContentHandler xhtml,
java.util.Deque<FormattingUtils.Tag> formattingState)
Closes all formatting tags.
|
static void |
ensureFormattingState(XHTMLContentHandler xhtml,
java.util.EnumSet<FormattingUtils.Tag> desired,
java.util.Deque<FormattingUtils.Tag> currentState)
Closes all tags until
currentState contains only tags from desired set,
then open all required tags to reach desired state. |
static java.util.EnumSet<FormattingUtils.Tag> |
toTags(org.apache.poi.wp.usermodel.CharacterRun run) |
public static void ensureFormattingState(XHTMLContentHandler xhtml, java.util.EnumSet<FormattingUtils.Tag> desired, java.util.Deque<FormattingUtils.Tag> currentState) throws org.xml.sax.SAXException
currentState contains only tags from desired set,
then open all required tags to reach desired state.xhtml - handlerdesired - desired formatting statecurrentState - current formatting state (stack of open formatting tags)org.xml.sax.SAXException - pass underlying handler exceptionpublic static void closeStyleTags(XHTMLContentHandler xhtml, java.util.Deque<FormattingUtils.Tag> formattingState) throws org.xml.sax.SAXException
xhtml - handlerformattingState - current formatting state (stack of open formatting tags)org.xml.sax.SAXException - pass underlying handler exceptionpublic static java.util.EnumSet<FormattingUtils.Tag> toTags(org.apache.poi.wp.usermodel.CharacterRun run)
Copyright © 2010 - 2023 Adobe. All Rights Reserved