info.magnolia.importexport.filters
Class SkipNodeFilter

java.lang.Object
  extended by org.xml.sax.helpers.XMLFilterImpl
      extended by info.magnolia.importexport.filters.SkipNodeFilter
All Implemented Interfaces:
ContentHandler, DTDHandler, EntityResolver, ErrorHandler, XMLFilter, XMLReader

public abstract class SkipNodeFilter
extends XMLFilterImpl

A simple filter that skips over import of child nodes.

Version:
$Revision: $ ($Author: $)
Author:
tmiyar

Constructor Summary
SkipNodeFilter(XMLReader parent)
           
 
Method Summary
 void characters(char[] ch, int start, int length)
           
 void endElement(String uri, String localName, String qName)
           
protected abstract  String getFilteredNodeName()
          Implement this method to specify the name of the node you want to filter.
 void ignorableWhitespace(char[] ch, int start, int length)
           
 void startElement(String uri, String localName, String qName, Attributes atts)
           
 
Methods inherited from class org.xml.sax.helpers.XMLFilterImpl
endDocument, endPrefixMapping, error, fatalError, getContentHandler, getDTDHandler, getEntityResolver, getErrorHandler, getFeature, getParent, getProperty, notationDecl, parse, parse, processingInstruction, resolveEntity, setContentHandler, setDocumentLocator, setDTDHandler, setEntityResolver, setErrorHandler, setFeature, setParent, setProperty, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SkipNodeFilter

public SkipNodeFilter(XMLReader parent)
Method Detail

ignorableWhitespace

public void ignorableWhitespace(char[] ch,
                                int start,
                                int length)
                         throws SAXException
Specified by:
ignorableWhitespace in interface ContentHandler
Overrides:
ignorableWhitespace in class XMLFilterImpl
Throws:
SAXException

characters

public void characters(char[] ch,
                       int start,
                       int length)
                throws SAXException
Specified by:
characters in interface ContentHandler
Overrides:
characters in class XMLFilterImpl
Throws:
SAXException

startElement

public void startElement(String uri,
                         String localName,
                         String qName,
                         Attributes atts)
                  throws SAXException
Specified by:
startElement in interface ContentHandler
Overrides:
startElement in class XMLFilterImpl
Throws:
SAXException

endElement

public void endElement(String uri,
                       String localName,
                       String qName)
                throws SAXException
Specified by:
endElement in interface ContentHandler
Overrides:
endElement in class XMLFilterImpl
Throws:
SAXException

getFilteredNodeName

protected abstract String getFilteredNodeName()
Implement this method to specify the name of the node you want to filter.

Returns:
filtered node name


Copyright © 2003-2011 Magnolia International Ltd.. All Rights Reserved.