public abstract class MathMLPostProcessor extends java.lang.Object implements DOMPostProcessor
DOMPostProcessors that might want to do interesting
things to MathML islands, leaving everything else unchanged.| 构造器和说明 |
|---|
MathMLPostProcessor() |
| 限定符和类型 | 方法和说明 |
|---|---|
protected abstract void |
handleMathMLIsland(org.w3c.dom.Element inputMathIsland,
org.w3c.dom.Document outputDocument,
org.w3c.dom.Node outputParentNode,
int mathmlCounter)
This method is called for each MathML
math element discovered, in document order. |
org.w3c.dom.Document |
postProcessDOM(org.w3c.dom.Document workDocument,
DOMOutputOptions options,
StylesheetManager stylesheetManager)
Implement this to post-process the raw DOM produced by SnuggleTeX.
|
public final org.w3c.dom.Document postProcessDOM(org.w3c.dom.Document workDocument,
DOMOutputOptions options,
StylesheetManager stylesheetManager)
DOMPostProcessor
You will be given an entire DOM Document to analyse, containing a root element
called root in the SnuggleConstants.SNUGGLETEX_NAMESPACE namespace.
You should create a new Document and return it. The children of the root element will end up being the Nodes added to the final DOM.
You MUST NOT modify the workDocument that is passed to you.
postProcessDOM 在接口中 DOMPostProcessorworkDocument - incoming DOM to be analysed for post-processingoptions - DOMOutputOptions specified by callerstylesheetManager - Instance of StylesheetManager that can be used to
load and manage XSLT stylesheets.protected abstract void handleMathMLIsland(org.w3c.dom.Element inputMathIsland,
org.w3c.dom.Document outputDocument,
org.w3c.dom.Node outputParentNode,
int mathmlCounter)
math element discovered, in document order.inputMathIsland - MathML math element discoveredoutputDocument - resulting Document being built upoutputParentNode - parent Node in the resulting Document that would
own this MathML element if left unchanged.mathmlCounter - counter for this MathML element, starting at 0 for the first
element in document order, 1 for the second, etc.