1 21 package oracle.toplink.essentials.platform.xml; 23 24 import java.io.File ; 25 import java.io.InputStream ; 26 import java.io.Reader ; 27 import java.net.URL ; 28 import javax.xml.transform.Source ; 29 import org.w3c.dom.Document ; 30 import org.xml.sax.EntityResolver ; 31 import org.xml.sax.ErrorHandler ; 32 import org.xml.sax.InputSource ; 33 34 public interface XMLParser { 35 public static final int NONVALIDATING = 0; 36 public static final int DTD_VALIDATION = 2; 37 public static final int SCHEMA_VALIDATION = 3; 38 39 public void setNamespaceAware(boolean isNamespaceAware); 40 41 public void setWhitespacePreserving(boolean isWhitespacePreserving); 42 43 public int getValidationMode(); 44 45 public void setValidationMode(int validationMode); 46 47 public EntityResolver getEntityResolver(); 48 49 public void setEntityResolver(EntityResolver entityResolver); 50 51 public ErrorHandler getErrorHandler(); 52 53 public void setErrorHandler(ErrorHandler errorHandler); 54 55 public void setXMLSchema(URL url) throws XMLPlatformException; 56 57 public void setXMLSchemas(Object [] schemas) throws XMLPlatformException; 58 59 public Document parse(InputSource inputSource) throws XMLPlatformException; 60 61 public Document parse(File file) throws XMLPlatformException; 62 63 public Document parse(InputStream inputStream) throws XMLPlatformException; 64 65 public Document parse(Reader reader) throws XMLPlatformException; 66 67 public Document parse(Source source) throws XMLPlatformException; 68 69 public Document parse(URL url) throws XMLPlatformException; 70 } 71 | Popular Tags |