Package libcore.io

Class ClassPathURLStreamHandler

    • Method Detail

      • getEntryUrlOrNull

        public URL getEntryUrlOrNull​(String entryName)
        Returns a URL backed by this stream handler for the named resource, or null if the entry cannot be found under the exact name presented.
      • isEntryStored

        public boolean isEntryStored​(String entryName)
        Returns true if an entry with the specified name exists and is stored (not compressed), and false otherwise.
      • openConnection

        protected URLConnection openConnection​(URL url)
                                        throws IOException
        Description copied from class: JarHandler
        Returns a connection to the jar file pointed by this URL in the file system
        Overrides:
        openConnection in class JarHandler
        Parameters:
        url - java.net.URL The URL to which the connection is pointing to
        Returns:
        java.net.URLConnection A connection to the resource pointed by this url.
        Throws:
        IOException - thrown if an IO error occurs when this method tries to establish connection.
      • close

        public void close()
                   throws IOException
        Used from tests to indicate this stream handler is finished with.
        Throws:
        IOException