Java 8 EntityResolver2 - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Java 8 EntityResolver2 class.

This code example shows how to use the following methods:resolveEntity
                return null; 
            } 
             
            // Resolve using EntityResolver2 
            try { 
                InputSource inputSource = 
                    fEntityResolver.resolveEntity(name, pubId, baseURI, sysId);
                return (inputSource != null) ? createXMLInputSource(inputSource, baseURI) : null;
            } 
            // error resolving entity 
            catch (SAXException e) {
                Exception ex = e.getException();
                if (ex == null) {
                    ex = e;
                } 
                throw new XNIException(ex);
            }    
        } 
         
        // unable to resolve entity 
4
CodeRank
This code example shows how to use the following methods:resolveEntity
    } 
 
    @Override 
    public InputSource resolveEntity(String publicId, String systemId)
            throws SAXException, IOException {
        return entityResolver.resolveEntity(publicId, systemId);
    } 
 
    @Override 
    public InputSource resolveEntity(String name, String publicId,
            String baseURI, String systemId) throws SAXException, IOException {
        // TODO URLs returned by the Jar abstraction may be of the form jar:jar: 
        //      which is not a URL that can be resolved by the JRE. This should 
        //      use the JarFactory to construct and return a valid InputSource. 
        return entityResolver.resolveEntity(name, publicId, baseURI, systemId);
    } 
 
    /* 
     * Receives notification of the start of an element. 
     * 
2
CodeRank
See Code Examples for Java 8 EntityResolver2 Methods: