class WhitespaceStripper extends XMLFilterImpl
This filter works only when the event stream doesn't contain any mixed content.
Constructor and Description |
---|
WhitespaceStripper(ContentHandler handler,
ErrorHandler eh,
EntityResolver er) |
WhitespaceStripper(XMLReader reader) |
Modifier and Type | Method and Description |
---|---|
void |
characters(char[] ch,
int start,
int length) |
void |
endElement(String uri,
String localName,
String qName) |
void |
ignorableWhitespace(char[] ch,
int start,
int length) |
void |
startElement(String uri,
String localName,
String qName,
Attributes atts) |
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
public WhitespaceStripper(XMLReader reader)
public WhitespaceStripper(ContentHandler handler, ErrorHandler eh, EntityResolver er)
public void characters(char[] ch, int start, int length) throws SAXException
characters
in interface ContentHandler
characters
in class XMLFilterImpl
SAXException
public void startElement(String uri, String localName, String qName, Attributes atts) throws SAXException
startElement
in interface ContentHandler
startElement
in class XMLFilterImpl
SAXException
public void endElement(String uri, String localName, String qName) throws SAXException
endElement
in interface ContentHandler
endElement
in class XMLFilterImpl
SAXException
public void ignorableWhitespace(char[] ch, int start, int length) throws SAXException
ignorableWhitespace
in interface ContentHandler
ignorableWhitespace
in class XMLFilterImpl
SAXException
Copyright (c) 1997-2012 Oracle and/or its affiliates. All rights reserved.