< prev index next >

src/java.base/share/classes/java/net/JarURLConnection.java

Print this page
rev 13123 : 8132734: JDK 9 runtime changes to support multi-release jar files
Summary: JEP 238 Multi-Release JAR Files runtime support
Contributed-by: steve.drach@oracle.com
rev 10469 : 8054834: Modular Source Code
Reviewed-by: alanb, chegar, ihse, mduigou
Contributed-by: alan.bateman@oracle.com, alex.buckley@oracle.com, chris.hegarty@oracle.com, erik.joelsson@oracle.com, jonathan.gibbons@oracle.com, karen.kinnear@oracle.com, magnus.ihse.bursie@oracle.com, mandy.chung@oracle.com, mark.reinhold@oracle.com, paul.sandoz@oracle.com


 106  *
 107  * <dt>context: <b>jar:http://www.foo.com/bar/jar.jar!/</b>,
 108  * spec:<b>baz/entry.txt</b>
 109  *
 110  * <dd>url:<b>jar:http://www.foo.com/bar/jar.jar!/baz/entry.txt</b>
 111  *
 112  * <dt>context: <b>jar:http://www.foo.com/bar/jar.jar!/baz</b>,
 113  * spec:<b>entry.txt</b>
 114  *
 115  * <dd>url:<b>jar:http://www.foo.com/bar/jar.jar!/baz/entry.txt</b>
 116  *
 117  * <dt>context: <b>jar:http://www.foo.com/bar/jar.jar!/baz</b>,
 118  * spec:<b>/entry.txt</b>
 119  *
 120  * <dd>url:<b>jar:http://www.foo.com/bar/jar.jar!/entry.txt</b>
 121  *
 122  * </dl>
 123  *
 124  * </ul>
 125  *












 126  * @see java.net.URL
 127  * @see java.net.URLConnection
 128  *
 129  * @see java.util.jar.JarFile
 130  * @see java.util.jar.JarInputStream
 131  * @see java.util.jar.Manifest
 132  * @see java.util.zip.ZipEntry
 133  *
 134  * @author Benjamin Renaud
 135  * @since 1.2
 136  */
 137 public abstract class JarURLConnection extends URLConnection {
 138 
 139     private URL jarFileURL;
 140     private String entryName;
 141 
 142     /**
 143      * The connection to the JAR file URL, if the connection has been
 144      * initiated. This should be set by connect.
 145      */




 106  *
 107  * <dt>context: <b>jar:http://www.foo.com/bar/jar.jar!/</b>,
 108  * spec:<b>baz/entry.txt</b>
 109  *
 110  * <dd>url:<b>jar:http://www.foo.com/bar/jar.jar!/baz/entry.txt</b>
 111  *
 112  * <dt>context: <b>jar:http://www.foo.com/bar/jar.jar!/baz</b>,
 113  * spec:<b>entry.txt</b>
 114  *
 115  * <dd>url:<b>jar:http://www.foo.com/bar/jar.jar!/baz/entry.txt</b>
 116  *
 117  * <dt>context: <b>jar:http://www.foo.com/bar/jar.jar!/baz</b>,
 118  * spec:<b>/entry.txt</b>
 119  *
 120  * <dd>url:<b>jar:http://www.foo.com/bar/jar.jar!/entry.txt</b>
 121  *
 122  * </dl>
 123  *
 124  * </ul>
 125  *
 126  * <p>Subclasses of {@code JarURLConnection} that support multi-release JAR files
 127  * should support URLs that refer to JAR runtime versioned entries. Such a URL
 128  * is a URL referring to an entry modified to include the fragment
 129  * {@code runtime}.  Subclasses that do not support multi-release JAR files
 130  * should ignore the fragment and process such URLs as if the fragment were not
 131  * present.  For example:
 132  *
 133  * <p>{@code jar:http://www.foo.com/bar/jar.jar!/baz/entry#runtime}
 134  *
 135  * <p>For information about multi-release jar files, see the specification for
 136  * {@link JarFile}.
 137  *
 138  * @see java.net.URL
 139  * @see java.net.URLConnection
 140  *
 141  * @see java.util.jar.JarFile
 142  * @see java.util.jar.JarInputStream
 143  * @see java.util.jar.Manifest
 144  * @see java.util.zip.ZipEntry
 145  *
 146  * @author Benjamin Renaud
 147  * @since 1.2
 148  */
 149 public abstract class JarURLConnection extends URLConnection {
 150 
 151     private URL jarFileURL;
 152     private String entryName;
 153 
 154     /**
 155      * The connection to the JAR file URL, if the connection has been
 156      * initiated. This should be set by connect.
 157      */


< prev index next >