public class ContentNormalizer extends java.lang.Object implements Normalizer
| Modifier and Type | Class and Description |
|---|---|
protected static class |
ContentNormalizer.ContentNormalizerState |
| Modifier | Constructor and Description |
|---|---|
|
ContentNormalizer(LayoutProcess layoutProcess) |
protected |
ContentNormalizer(LayoutProcess layoutProcess,
boolean init) |
| Modifier and Type | Method and Description |
|---|---|
void |
addText(java.lang.String text)
Adds text content to the current element.
|
protected ContentNormalizer.ContentNormalizerState |
createSaveState() |
void |
endDocument()
Ends the document.
|
void |
endElement()
Ends the current element.
|
protected void |
fillState(ContentNormalizer.ContentNormalizerState state) |
protected void |
generateAfterPseudoElements(LayoutElement element) |
protected boolean |
generateBeforePseudoElements(LayoutElement element) |
protected void |
generateContentAfter(LayoutElement element) |
protected boolean |
generateContentBefore(LayoutElement element) |
protected void |
generateStrings(LayoutElement element) |
Renderer |
getRenderer()
Returns the renderer.
|
StyleResolver |
getStyleResolver() |
void |
handlePageBreak(CSSValue pageName,
PseudoPage[] pseudoPages) |
protected void |
restore(ContentNormalizer.ContentNormalizerState state) |
State |
saveState() |
void |
startDocument()
Start document is the first call to the normalizer.
|
void |
startElement(java.lang.String namespace,
java.lang.String tag,
AttributeMap attributes)
Starts a new element.
|
protected void |
startElementInternal(java.lang.String namespace,
java.lang.String tag,
java.lang.String pseudo,
AttributeMap attributes) |
public ContentNormalizer(LayoutProcess layoutProcess)
protected ContentNormalizer(LayoutProcess layoutProcess, boolean init)
public void startDocument()
throws java.io.IOException,
NormalizationException
NormalizerstartDocument in interface Normalizerjava.io.IOExceptionNormalizationExceptionpublic void startElement(java.lang.String namespace,
java.lang.String tag,
AttributeMap attributes)
throws NormalizationException,
java.io.IOException
startElement in interface Normalizernamespace - tag - attributes - NormalizationExceptionjava.io.IOExceptionprotected void startElementInternal(java.lang.String namespace,
java.lang.String tag,
java.lang.String pseudo,
AttributeMap attributes)
throws NormalizationException,
java.io.IOException
NormalizationExceptionjava.io.IOExceptionprotected boolean generateBeforePseudoElements(LayoutElement element) throws java.io.IOException, NormalizationException
java.io.IOExceptionNormalizationExceptionprotected boolean generateContentBefore(LayoutElement element) throws java.io.IOException, NormalizationException
java.io.IOExceptionNormalizationExceptionprotected void generateContentAfter(LayoutElement element) throws java.io.IOException, NormalizationException
java.io.IOExceptionNormalizationExceptionprotected void generateStrings(LayoutElement element) throws java.io.IOException, NormalizationException
java.io.IOExceptionNormalizationExceptionprotected void generateAfterPseudoElements(LayoutElement element) throws java.io.IOException, NormalizationException
java.io.IOExceptionNormalizationExceptionpublic void addText(java.lang.String text)
throws NormalizationException,
java.io.IOException
addText in interface Normalizertext - NormalizationExceptionjava.io.IOExceptionpublic void endElement()
throws NormalizationException,
java.io.IOException
endElement in interface NormalizerNormalizationExceptionjava.io.IOExceptionpublic void endDocument()
throws java.io.IOException,
NormalizationException
NormalizerendDocument in interface Normalizerjava.io.IOExceptionNormalizationExceptionpublic void handlePageBreak(CSSValue pageName, PseudoPage[] pseudoPages)
handlePageBreak in interface Normalizerprotected ContentNormalizer.ContentNormalizerState createSaveState()
protected void fillState(ContentNormalizer.ContentNormalizerState state) throws StateException
StateExceptionpublic State saveState() throws StateException
saveState in interface StatefullComponentStateExceptionprotected void restore(ContentNormalizer.ContentNormalizerState state) throws StateException
StateExceptionpublic Renderer getRenderer()
getRenderer in interface Normalizerpublic StyleResolver getStyleResolver()