public class io.dropwizard.servlets.assets.ResourceURL
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: io.dropwizard.servlets.assets.ResourceURL
super_class: java.lang.Object
{
private void <init>();
descriptor: ()V
flags: (0x0002) ACC_PRIVATE
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
invokespecial java.lang.Object.<init>:()V
return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lio/dropwizard/servlets/assets/ResourceURL;
public static boolean isDirectory(java.net.URL);
descriptor: (Ljava/net/URL;)Z
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=5, locals=9, args_size=1
start local 0 0: aload 0
invokevirtual java.net.URL.getProtocol:()Ljava/lang/String;
astore 1
start local 1 1: aload 1
dup
astore 2
invokevirtual java.lang.String.hashCode:()I
lookupswitch { // 2
104987: 2
3143036: 3
default: 18
}
StackMap locals: java.lang.String java.lang.String
StackMap stack:
2: aload 2
ldc "jar"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifne 4
goto 18
StackMap locals:
StackMap stack:
3: aload 2
ldc "file"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifne 17
goto 18
4: StackMap locals:
StackMap stack:
aload 0
invokevirtual java.net.URL.openConnection:()Ljava/net/URLConnection;
checkcast java.net.JarURLConnection
astore 3
start local 3 5: aload 3
invokevirtual java.net.JarURLConnection.getJarEntry:()Ljava/util/jar/JarEntry;
astore 4
start local 4 6: aload 4
invokevirtual java.util.jar.JarEntry.isDirectory:()Z
ifeq 8
7: iconst_1
ireturn
8: StackMap locals: java.net.JarURLConnection java.util.jar.JarEntry
StackMap stack:
aload 4
invokevirtual java.util.jar.JarEntry.getName:()Ljava/lang/String;
astore 5
start local 5 9: aload 3
invokevirtual java.net.JarURLConnection.getJarFile:()Ljava/util/jar/JarFile;
astore 6
start local 6 10: aload 6
aload 5
invokevirtual java.util.jar.JarFile.getEntry:(Ljava/lang/String;)Ljava/util/zip/ZipEntry;
astore 7
start local 7 11: aload 6
aload 7
invokevirtual java.util.jar.JarFile.getInputStream:(Ljava/util/zip/ZipEntry;)Ljava/io/InputStream;
astore 8
start local 8 12: aload 8
ifnonnull 13
iconst_1
ireturn
StackMap locals: java.net.URL java.lang.String java.lang.String java.net.JarURLConnection java.util.jar.JarEntry java.lang.String java.util.jar.JarFile java.util.zip.ZipEntry java.io.InputStream
StackMap stack:
13: iconst_0
14: ireturn
end local 8 end local 7 end local 6 end local 5 end local 4 end local 3 15: StackMap locals: java.net.URL java.lang.String java.lang.String
StackMap stack: java.io.IOException
astore 3
start local 3 16: new io.dropwizard.servlets.assets.ResourceNotFoundException
dup
aload 3
invokespecial io.dropwizard.servlets.assets.ResourceNotFoundException.<init>:(Ljava/lang/Throwable;)V
athrow
end local 3 17: StackMap locals:
StackMap stack:
new java.io.File
dup
aload 0
invokevirtual java.net.URL.toURI:()Ljava/net/URI;
invokespecial java.io.File.<init>:(Ljava/net/URI;)V
invokevirtual java.io.File.isDirectory:()Z
ireturn
18: StackMap locals:
StackMap stack:
new java.lang.IllegalArgumentException
dup
new java.lang.StringBuilder
dup
ldc "Unsupported protocol "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 0
invokevirtual java.net.URL.getProtocol:()Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
19: ldc " for resource "
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
aload 0
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/Object;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
20: invokespecial java.lang.IllegalArgumentException.<init>:(Ljava/lang/String;)V
athrow
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 21 0 resourceURL Ljava/net/URL;
1 21 1 protocol Ljava/lang/String;
5 15 3 jarConnection Ljava/net/JarURLConnection;
6 15 4 entry Ljava/util/jar/JarEntry;
9 15 5 relativeFilePath Ljava/lang/String;
10 15 6 jarFile Ljava/util/jar/JarFile;
11 15 7 zipEntry Ljava/util/zip/ZipEntry;
12 15 8 inputStream Ljava/io/InputStream;
16 17 3 e Ljava/io/IOException;
Exception table:
from to target type
4 7 15 Class java.io.IOException
8 14 15 Class java.io.IOException
Exceptions:
throws java.net.URISyntaxException
MethodParameters:
Name Flags
resourceURL
public static java.net.URL appendTrailingSlash(java.net.URL);
descriptor: (Ljava/net/URL;)Ljava/net/URL;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=8, locals=1, args_size=1
start local 0 0: aload 0
invokevirtual java.net.URL.getPath:()Ljava/lang/String;
ldc "/"
invokevirtual java.lang.String.endsWith:(Ljava/lang/String;)Z
ifeq 1
aload 0
goto 6
1: StackMap locals:
StackMap stack:
new java.net.URL
dup
aload 0
invokevirtual java.net.URL.getProtocol:()Ljava/lang/String;
2: aload 0
invokevirtual java.net.URL.getHost:()Ljava/lang/String;
3: aload 0
invokevirtual java.net.URL.getPort:()I
4: new java.lang.StringBuilder
dup
aload 0
invokevirtual java.net.URL.getFile:()Ljava/lang/String;
invokestatic java.lang.String.valueOf:(Ljava/lang/Object;)Ljava/lang/String;
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
bipush 47
invokevirtual java.lang.StringBuilder.append:(C)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
5: invokespecial java.net.URL.<init>:(Ljava/lang/String;Ljava/lang/String;ILjava/lang/String;)V
6: StackMap locals:
StackMap stack: java.net.URL
areturn
7: StackMap locals:
StackMap stack: java.net.MalformedURLException
pop
8: new java.lang.IllegalArgumentException
dup
new java.lang.StringBuilder
dup
ldc "Invalid resource URL: "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 0
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/Object;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokespecial java.lang.IllegalArgumentException.<init>:(Ljava/lang/String;)V
athrow
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 9 0 originalURL Ljava/net/URL;
Exception table:
from to target type
0 6 7 Class java.net.MalformedURLException
MethodParameters:
Name Flags
originalURL
public static long getLastModified(java.net.URL);
descriptor: (Ljava/net/URL;)J
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=5, locals=7, args_size=1
start local 0 0: aload 0
invokevirtual java.net.URL.getProtocol:()Ljava/lang/String;
astore 1
start local 1 1: aload 1
dup
astore 2
invokevirtual java.lang.String.hashCode:()I
lookupswitch { // 2
104987: 2
3143036: 3
default: 30
}
StackMap locals: java.lang.String java.lang.String
StackMap stack:
2: aload 2
ldc "jar"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifne 4
goto 30
StackMap locals:
StackMap stack:
3: aload 2
ldc "file"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifne 10
goto 30
4: StackMap locals:
StackMap stack:
aload 0
invokevirtual java.net.URL.openConnection:()Ljava/net/URLConnection;
checkcast java.net.JarURLConnection
astore 3
start local 3 5: aload 3
invokevirtual java.net.JarURLConnection.getJarEntry:()Ljava/util/jar/JarEntry;
astore 4
start local 4 6: aload 4
invokevirtual java.util.jar.JarEntry.getTime:()J
7: lreturn
end local 4 end local 3 8: StackMap locals:
StackMap stack: java.io.IOException
pop
9: lconst_0
lreturn
10: StackMap locals:
StackMap stack:
aconst_null
astore 3
start local 3 11: aload 0
invokevirtual java.net.URL.openConnection:()Ljava/net/URLConnection;
astore 3
12: aload 3
invokevirtual java.net.URLConnection.getLastModified:()J
lstore 5
13: aload 3
ifnull 17
14: aload 3
invokevirtual java.net.URLConnection.getInputStream:()Ljava/io/InputStream;
invokevirtual java.io.InputStream.close:()V
15: goto 17
StackMap locals: java.net.URL java.lang.String java.lang.String java.net.URLConnection top long
StackMap stack: java.io.IOException
16: pop
17: StackMap locals:
StackMap stack:
lload 5
lreturn
18: StackMap locals: java.net.URL java.lang.String java.lang.String java.net.URLConnection
StackMap stack: java.io.IOException
pop
19: aload 3
ifnull 23
20: aload 3
invokevirtual java.net.URLConnection.getInputStream:()Ljava/io/InputStream;
invokevirtual java.io.InputStream.close:()V
21: goto 23
StackMap locals:
StackMap stack: java.io.IOException
22: pop
23: StackMap locals:
StackMap stack:
lconst_0
lreturn
24: StackMap locals:
StackMap stack: java.lang.Throwable
astore 4
25: aload 3
ifnull 29
26: aload 3
invokevirtual java.net.URLConnection.getInputStream:()Ljava/io/InputStream;
invokevirtual java.io.InputStream.close:()V
27: goto 29
StackMap locals: java.net.URL java.lang.String java.lang.String java.net.URLConnection java.lang.Throwable
StackMap stack: java.io.IOException
28: pop
29: StackMap locals:
StackMap stack:
aload 4
athrow
end local 3 30: StackMap locals:
StackMap stack:
new java.lang.IllegalArgumentException
dup
new java.lang.StringBuilder
dup
ldc "Unsupported protocol "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 0
invokevirtual java.net.URL.getProtocol:()Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
ldc " for resource "
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
aload 0
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/Object;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokespecial java.lang.IllegalArgumentException.<init>:(Ljava/lang/String;)V
athrow
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 31 0 resourceURL Ljava/net/URL;
1 31 1 protocol Ljava/lang/String;
5 8 3 jarConnection Ljava/net/JarURLConnection;
6 8 4 entry Ljava/util/jar/JarEntry;
11 30 3 connection Ljava/net/URLConnection;
Exception table:
from to target type
4 7 8 Class java.io.IOException
14 15 16 Class java.io.IOException
11 13 18 Class java.io.IOException
20 21 22 Class java.io.IOException
11 13 24 any
18 19 24 any
26 27 28 Class java.io.IOException
MethodParameters:
Name Flags
resourceURL
}
SourceFile: "ResourceURL.java"