Package org.apache.xerces.dom

Examples of org.apache.xerces.dom.DOMInputImpl


    public static Map<URI, byte[]> captureSchema(URI systemURI, String schemaData,
                                                 XMLEntityResolver resolver) throws XsdException {
        if (__log.isDebugEnabled())
            __log.debug("captureSchema(URI,Text,...): systemURI=" + systemURI);

        DOMInputImpl input = new DOMInputImpl();
        input.setSystemId(systemURI.toString());
        input.setStringData(schemaData);

        Map<URI, byte[]> ret = captureSchema(input, resolver);
        // Let's not forget the root schema.
        try {
            // TODO don't assume UTF-8 - but which encoding is required?
View Full Code Here


        }
        // Ignore IOException. It cannot be thrown from this method.
        catch (IOException ex) {}
       
        if (resolvedId != null) {
            return new DOMInputImpl(publicId, resolvedId, baseURI);
       
        return null;
    }
View Full Code Here

        }
        // Ignore IOException. It cannot be thrown from this method.
        catch (IOException ex) {}
       
        if (resolvedId != null) {
            return new DOMInputImpl(publicId, resolvedId, baseURI);
       
        return null;
    }
View Full Code Here

                try {
                    XMLInputSource is = fEntityResolver.resolveEntity(
                        new XMLResourceIdentifierImpl(publicId,systemId,baseUri,null));
                    if(is==null)    return null;
                       
                    LSInput di = new DOMInputImpl();
                    di.setBaseURI(is.getBaseSystemId());
                    di.setByteStream(is.getByteStream());
                    di.setCharacterStream(is.getCharacterStream());
                    di.setEncoding(is.getEncoding());
                    di.setPublicId(is.getPublicId());
                    di.setSystemId(is.getSystemId());
                       
                    return di;
                } catch( IOException e ) {
                    // erors thrown by the callback is not supposed to be
                    // reported to users.
View Full Code Here

    public static Map<URI, byte[]> captureSchema(URI systemURI, byte[] schemaData,
                                                 XMLEntityResolver resolver, int localSchemaId) throws XsdException {
        if (__log.isDebugEnabled())
            __log.debug("captureSchema(URI,Text,...): systemURI=" + systemURI);

        DOMInputImpl input = new DOMInputImpl();
        input.setSystemId(systemURI.toString());
        input.setByteStream(new ByteArrayInputStream(schemaData));

        Map<URI, byte[]> ret = captureSchema(input, resolver);
       
        URI localURI = localSchemaId == 0 ? systemURI : URI.create(systemURI.toString() + '.' + localSchemaId);
        ret.put(localURI, schemaData);
View Full Code Here

            ++idx;
        }

        LSInputList list = new LSInputList() {
            public LSInput item(int index) {
                DOMInputImpl input = new DOMInputImpl();
                input.setSystemId(uris[index]);
                input.setByteStream(new ByteArrayInputStream(content[index]));
                return input;
            }

            public int getLength() {
                return uris.length;
View Full Code Here

        }

      }

      if (result == null) {
        result = new DOMInputImpl(publicId, systemId, baseURI);
      }
      if (elResult != null) {
        result.setStringData(Xml.getString(elResult));
      }
     }
View Full Code Here

    public static Map<URI, byte[]> captureSchema(URI systemURI, byte[] schemaData,
                                                 XMLEntityResolver resolver) throws XsdException {
        if (__log.isDebugEnabled())
            __log.debug("captureSchema(URI,Text,...): systemURI=" + systemURI);

        DOMInputImpl input = new DOMInputImpl();
        input.setSystemId(systemURI.toString());
        input.setStringData(new String(schemaData));

        Map<URI, byte[]> ret = captureSchema(input, resolver);
        ret.put(systemURI, schemaData);
        return ret;
    }
View Full Code Here

            ++idx;
        }

        LSInputList list = new LSInputList() {
            public LSInput item(int index) {
                DOMInputImpl input = new DOMInputImpl();
                input.setSystemId(uris[index]);
                input.setByteStream(new ByteArrayInputStream(content[index]));
                return input;
            }

            public int getLength() {
                return uris.length;
View Full Code Here

    public static Map<URI, byte[]> captureSchema(URI systemURI, byte[] schemaData,
                                                 XMLEntityResolver resolver) throws XsdException {
        if (__log.isDebugEnabled())
            __log.debug("captureSchema(URI,Text,...): systemURI=" + systemURI);

        DOMInputImpl input = new DOMInputImpl();
        input.setSystemId(systemURI.toString());
        input.setByteStream(new ByteArrayInputStream(schemaData));

        Map<URI, byte[]> ret = captureSchema(input, resolver);
        ret.put(systemURI, schemaData);
        return ret;
    }
View Full Code Here

TOP

Related Classes of org.apache.xerces.dom.DOMInputImpl

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.