1 7 package org.jboss.xml.binding.parser; 8 9 import org.xml.sax.Attributes ; 10 import org.xml.sax.EntityResolver ; 11 import org.jboss.xml.binding.JBossXBException; 12 import org.apache.xerces.xs.XSTypeDefinition; 13 14 import java.io.Reader ; 15 import java.io.InputStream ; 16 17 21 public interface JBossXBParser 22 { 23 interface ContentHandler 24 { 25 void characters(char[] ch, int start, int length); 26 27 void endElement(String namespaceURI, String localName, String qName); 28 29 void startElement(String namespaceURI, String localName, String qName, Attributes atts, XSTypeDefinition type); 30 31 void startPrefixMapping(String prefix, String uri); 32 33 void endPrefixMapping(String prefix); 34 35 Object getRoot(); 36 } 37 38 void setEntityResolver(EntityResolver entityResolver) throws JBossXBException; 39 40 void setProperty(String name, Object value) throws JBossXBException; 41 42 void setFeature(String name, boolean value) throws JBossXBException; 43 44 void parse(String source, ContentHandler handler) throws JBossXBException; 45 46 void parse(InputStream is, ContentHandler handler) throws JBossXBException; 47 48 void parse(Reader reader, ContentHandler handler) throws JBossXBException; 49 } 50 | Popular Tags |