org.pegdown
Class LinkRenderer

java.lang.Object
  extended by org.pegdown.LinkRenderer

public class LinkRenderer
extends java.lang.Object

A LinkRenderer is responsible for turning an AST node representing a link into a LinkRenderer.Rendering instance, which hold the actual properties of the link as it is going to be rendered. If you'd like to apply custom logic to link rendering (e.g. for selectively adding "nofollow" attributes) you should derive a custom LinkRenderer from this class and override the respective methods.


Nested Class Summary
static class LinkRenderer.Attribute
          Simple model class for an HTML tag attribute.
static class LinkRenderer.Rendering
          Simple model class for holding the `href`, link text as well as other tag attributes of an HTML link.
 
Constructor Summary
LinkRenderer()
           
 
Method Summary
 LinkRenderer.Rendering render(AutoLinkNode node)
           
 LinkRenderer.Rendering render(ExpLinkNode node, java.lang.String text)
           
 LinkRenderer.Rendering render(MailLinkNode node)
           
 LinkRenderer.Rendering render(RefLinkNode node, java.lang.String url, java.lang.String title, java.lang.String text)
           
 LinkRenderer.Rendering render(WikiLinkNode node)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LinkRenderer

public LinkRenderer()
Method Detail

render

public LinkRenderer.Rendering render(AutoLinkNode node)

render

public LinkRenderer.Rendering render(ExpLinkNode node,
                                     java.lang.String text)

render

public LinkRenderer.Rendering render(MailLinkNode node)

render

public LinkRenderer.Rendering render(RefLinkNode node,
                                     java.lang.String url,
                                     java.lang.String title,
                                     java.lang.String text)

render

public LinkRenderer.Rendering render(WikiLinkNode node)