com.overzealous.remark.convert
Class NodeRemover

java.lang.Object
  extended by com.overzealous.remark.convert.NodeRemover
All Implemented Interfaces:
NodeHandler

public class NodeRemover
extends Object
implements NodeHandler

Author:
Phil DeJarnett

Method Summary
static NodeRemover getInstance()
           
 void handleIgnoredHTMLElement(Element node, DocumentConverter converter)
          Handle an ignored HTMLElement.
 void handleNode(NodeHandler parent, Element node, DocumentConverter converter)
          Handles an HTML Element node.
 void handleTextNode(TextNode node, DocumentConverter converter)
          Handle a child text node.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static NodeRemover getInstance()

handleNode

public void handleNode(NodeHandler parent,
                       Element node,
                       DocumentConverter converter)
Description copied from interface: NodeHandler
Handles an HTML Element node. This is where most of the work is done. Which NodeHandler is used is based on the tagName of the element.

Specified by:
handleNode in interface NodeHandler
Parameters:
parent - The previous node walker, in case we just want to remove an element.
node - Node to handle
converter - Parent converter for this object.

handleTextNode

public void handleTextNode(TextNode node,
                           DocumentConverter converter)
Description copied from interface: NodeHandler
Handle a child text node.

Specified by:
handleTextNode in interface NodeHandler
Parameters:
node - Node to handle
converter - Parent converter for this object.

handleIgnoredHTMLElement

public void handleIgnoredHTMLElement(Element node,
                                     DocumentConverter converter)
Description copied from interface: NodeHandler
Handle an ignored HTMLElement.

Specified by:
handleIgnoredHTMLElement in interface NodeHandler
Parameters:
node - Node to handle
converter - Parent converter for this object.


© 2011 OverZealous Creations, LLC - BitBucket Repository