Package org.apache.xerces.xs

Examples of org.apache.xerces.xs.XSImplementation


      String name = "xml/xerces-bug.xsd";
      URL xsdUrl = Thread.currentThread().getContextClassLoader().getResource(name);

      MultiClassSchemaResolver resolver = new MultiClassSchemaResolver();
      resolver.setBaseURI(xsdUrl.toString());
      XSImplementation impl = getXSImplementation();
      XSLoader schemaLoader = impl.createXSLoader(null);
      setResourceResolver(schemaLoader, resolver);
      setDOMErrorHandler(schemaLoader);
      XSModel model = schemaLoader.loadURI(xsdUrl.toString());

      XSNamedMap types = model.getComponents(XSConstants.TYPE_DEFINITION);
View Full Code Here


         // Try the 2.7.0 version
         String name = "org.apache.xerces.dom.DOMXSImplementationSourceImpl";
         System.setProperty(DOMImplementationRegistry.PROPERTY, name);
      }

      XSImplementation impl;
      try
      {
         DOMImplementationRegistry registry = DOMImplementationRegistry.newInstance();
         impl = (XSImplementation)registry.getDOMImplementation("XS-Loader");
      }
View Full Code Here

         log.trace("loading xsd from InputStream");
      }

      LSInputAdaptor input = new LSInputAdaptor(is, encoding);

      XSImplementation impl = getXSImplementation();
      XSLoader schemaLoader = impl.createXSLoader(null);
      setDOMErrorHandler(schemaLoader);
      if(schemaResolver != null)
      {
         setResourceResolver(schemaLoader, schemaResolver);
      }
View Full Code Here

         log.trace("loading xsd from Reader");
      }

      LSInputAdaptor input = new LSInputAdaptor(reader, encoding);

      XSImplementation impl = getXSImplementation();
      XSLoader schemaLoader = impl.createXSLoader(null);
      setDOMErrorHandler(schemaLoader);
      if(schemaResolver != null)
      {
         setResourceResolver(schemaLoader, schemaResolver);
      }
View Full Code Here

         log.trace("loading xsd from string");
      }

      LSInputAdaptor input = new LSInputAdaptor(data, encoding);

      XSImplementation impl = getXSImplementation();
      XSLoader schemaLoader = impl.createXSLoader(null);
      setDOMErrorHandler(schemaLoader);
      return schemaLoader.load(input);
   }
View Full Code Here

               // Try the 2.7.0 version
               String name = "org.apache.xerces.dom.DOMXSImplementationSourceImpl";
               System.setProperty(DOMImplementationRegistry.PROPERTY, name);
            }

            XSImplementation impl;
            try
            {
               DOMImplementationRegistry registry = DOMImplementationRegistry.newInstance();
               impl = (XSImplementation)registry.getDOMImplementation("XS-Loader");
            }
View Full Code Here

         log.trace("loading xsd from InputStream");
      }

      LSInputAdaptor input = new LSInputAdaptor(is, encoding);

      XSImplementation impl = getXSImplementation();
      XSLoader schemaLoader = impl.createXSLoader(null);
      setDOMErrorHandler(schemaLoader);
      if(schemaResolver != null)
      {
         setResourceResolver(schemaLoader, schemaResolver);
      }
View Full Code Here

         log.trace("loading xsd from Reader");
      }

      LSInputAdaptor input = new LSInputAdaptor(reader, encoding);

      XSImplementation impl = getXSImplementation();
      XSLoader schemaLoader = impl.createXSLoader(null);
      setDOMErrorHandler(schemaLoader);
      if(schemaResolver != null)
      {
         setResourceResolver(schemaLoader, schemaResolver);
      }
View Full Code Here

         log.trace("loading xsd from string");
      }

      LSInputAdaptor input = new LSInputAdaptor(data, encoding);

      XSImplementation impl = getXSImplementation();
      XSLoader schemaLoader = impl.createXSLoader(null);
      setDOMErrorHandler(schemaLoader);
      return schemaLoader.load(input);
   }
View Full Code Here

               // Try the 2.7.0 version
               String name = "org.apache.xerces.dom.DOMXSImplementationSourceImpl";
               System.setProperty(DOMImplementationRegistry.PROPERTY, name);
            }

            XSImplementation impl;
            try
            {
               DOMImplementationRegistry registry = DOMImplementationRegistry.newInstance();
               impl = (XSImplementation)registry.getDOMImplementation("XS-Loader");
            }
View Full Code Here

TOP

Related Classes of org.apache.xerces.xs.XSImplementation

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.