1 16 package org.apache.cocoon.xml; 17 18 import org.xml.sax.ContentHandler ; 19 import org.xml.sax.Locator ; 20 import org.xml.sax.SAXException ; 21 import org.xml.sax.Attributes ; 22 import org.xml.sax.helpers.DefaultHandler ; 23 24 29 30 31 public final class DefaultHandlerWrapper extends DefaultHandler { 32 private final ContentHandler handler; 33 34 public DefaultHandlerWrapper( ContentHandler handler ) { 35 this.handler = handler; 36 } 37 38 public void setDocumentLocator(Locator locator) { 39 handler.setDocumentLocator(locator); 40 } 41 42 public void startDocument() throws SAXException { 43 handler.startDocument(); 44 } 45 46 public void endDocument() throws SAXException { 47 handler.endDocument(); 48 } 49 50 public void startPrefixMapping(String prefix, String uri) throws SAXException { 51 handler.startPrefixMapping(prefix,uri); 52 } 53 54 public void endPrefixMapping(String prefix) throws SAXException { 55 handler.endPrefixMapping(prefix); 56 } 57 58 public void startElement(String namespaceURI, String localName, String qName, Attributes atts) throws SAXException { 59 handler.startElement(namespaceURI,localName,qName,atts); 60 } 61 62 public void endElement(String namespaceURI, String localName, String qName) throws SAXException { 63 handler.endElement(namespaceURI,localName,qName); 64 } 65 66 public void characters(char ch[], int start, int length) throws SAXException { 67 handler.characters(ch,start,length); 68 } 69 70 public void ignorableWhitespace(char ch[], int start, int length) throws SAXException { 71 handler.ignorableWhitespace(ch,start, length); 72 } 73 74 public void processingInstruction(String target, String data) throws SAXException { 75 handler.processingInstruction(target,data); 76 } 77 78 public void skippedEntity(String name) throws SAXException { 79 handler.skippedEntity(name); 80 } 81 82 83 } 84 | Popular Tags |