public interface NodeRendererContext extends LinkResolverContext
| Modifier and Type | Method and Description |
|---|---|
void |
delegateRender()
pass node rendering to previously registered handler
|
void |
doNotRenderLinks()
Increment the do not render links in this context.
|
void |
doNotRenderLinks(boolean doNotRenderLinks)
Increment/Decrement the do not render links in this context.
|
void |
doRenderLinks()
Decrement the do not render links in this context.
|
com.vladsch.flexmark.util.html.Attributes |
extendRenderingNodeAttributes(AttributablePart part,
com.vladsch.flexmark.util.html.Attributes attributes)
Extend the attributes by extensions for the node being currently rendered.
|
com.vladsch.flexmark.util.html.Attributes |
extendRenderingNodeAttributes(com.vladsch.flexmark.ast.Node node,
AttributablePart part,
com.vladsch.flexmark.util.html.Attributes attributes)
Extend the attributes by extensions for the node being currently rendered.
|
NodeRendererContext |
getDelegatedSubContext(Appendable out,
boolean inheritIndent)
Creates a child rendering context that can be used to collect rendered html text of the previously registered node renderer.
|
HtmlRendererOptions |
getHtmlOptions() |
HtmlWriter |
getHtmlWriter() |
String |
getNodeId(com.vladsch.flexmark.ast.Node node)
Get the id attribute for the given node.
|
RenderingPhase |
getRenderingPhase() |
NodeRendererContext |
getSubContext(Appendable out,
boolean inheritIndent)
Creates a child rendering context that can be used to collect rendered html text.
|
boolean |
isDoNotRenderLinks()
Whether the current rendering context has link rendering disabled.
|
encodeUrl, getCurrentNode, getDocument, getOptions, render, renderChildren, resolveLink, resolveLinkcom.vladsch.flexmark.util.html.Attributes extendRenderingNodeAttributes(AttributablePart part, com.vladsch.flexmark.util.html.Attributes attributes)
part - the tag of the node being rendered, some nodes render multiple tags with attributesattributes - the attributes that were calculated by the renderer or null, these may be modified. To preserve originals pass a copy.com.vladsch.flexmark.util.html.Attributes extendRenderingNodeAttributes(com.vladsch.flexmark.ast.Node node,
AttributablePart part,
com.vladsch.flexmark.util.html.Attributes attributes)
node - node for which to get attributespart - the tag of the node being rendered, some nodes render multiple tags with attributesattributes - the attributes that were calculated by the renderer or null, these may be modified. To preserve originals pass a copy.HtmlWriter getHtmlWriter()
NodeRendererContext getSubContext(Appendable out, boolean inheritIndent)
out - appendable to use for generated htmlinheritIndent - whether the html writer of the sub-context should inherit the current context's indentation level or start with 0 indentationNodeRendererContext getDelegatedSubContext(Appendable out, boolean inheritIndent)
out - appendable to use for generated htmlinheritIndent - whether the html writer of the sub-context should inherit the current context's indentation level or start with 0 indentationvoid delegateRender()
String getNodeId(com.vladsch.flexmark.ast.Node node)
node - node for which to get an id, depends on the HtmlIdGenerator assigned for the context. Default generator
only creates ids for Heading nodes or custom nodes that implement AnchorRefTarget interface.boolean isDoNotRenderLinks()
isDoNotRenderLinks(),
doNotRenderLinks(),
doRenderLinks(),
doNotRenderLinks(boolean)void doNotRenderLinks(boolean doNotRenderLinks)
doNotRenderLinks - if true then increment the doNotRenderLinks value, else decrement itisDoNotRenderLinks(),
doNotRenderLinks(),
doRenderLinks(),
doNotRenderLinks(boolean)void doNotRenderLinks()
void doRenderLinks()
IllegalStateException - if the current doNotRender links value is 0.isDoNotRenderLinks(),
doNotRenderLinks(),
doRenderLinks(),
doNotRenderLinks(boolean)RenderingPhase getRenderingPhase()
HtmlRendererOptions getHtmlOptions()
HtmlRendererOptions for the context.Copyright © 2018. All rights reserved.