public class io.vertx.ext.web.handler.impl.FaviconHandlerImpl implements io.vertx.ext.web.handler.FaviconHandler
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: io.vertx.ext.web.handler.impl.FaviconHandlerImpl
super_class: java.lang.Object
{
private static final io.vertx.core.impl.logging.Logger logger;
descriptor: Lio/vertx/core/impl/logging/Logger;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
private static final java.lang.String DEFAULT_VERTX_ICON;
descriptor: Ljava/lang/String;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: "META-INF/vertx/web/favicon.ico"
private final io.vertx.ext.web.handler.impl.FaviconHandlerImpl$Icon NULL_ICON;
descriptor: Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl$Icon;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
private final io.vertx.ext.web.handler.impl.FaviconHandlerImpl$Icon icon;
descriptor: Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl$Icon;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
private final long maxAgeSeconds;
descriptor: J
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
static void <clinit>();
descriptor: ()V
flags: (0x0008) ACC_STATIC
Code:
stack=1, locals=0, args_size=0
0: ldc Lio/vertx/ext/web/handler/FaviconHandler;
invokestatic io.vertx.core.impl.logging.LoggerFactory.getLogger:(Ljava/lang/Class;)Lio/vertx/core/impl/logging/Logger;
putstatic io.vertx.ext.web.handler.impl.FaviconHandlerImpl.logger:Lio/vertx/core/impl/logging/Logger;
1: return
LocalVariableTable:
Start End Slot Name Signature
public void <init>(io.vertx.core.Vertx, java.lang.String, long);
descriptor: (Lio/vertx/core/Vertx;Ljava/lang/String;J)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=7, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
invokespecial java.lang.Object.<init>:()V
1: aload 0
new io.vertx.ext.web.handler.impl.FaviconHandlerImpl$Icon
dup
aload 0
invokespecial io.vertx.ext.web.handler.impl.FaviconHandlerImpl$Icon.<init>:(Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl;)V
putfield io.vertx.ext.web.handler.impl.FaviconHandlerImpl.NULL_ICON:Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl$Icon;
2: aload 0
lload 3
putfield io.vertx.ext.web.handler.impl.FaviconHandlerImpl.maxAgeSeconds:J
3: lload 3
lconst_0
lcmp
ifge 5
4: new java.lang.IllegalArgumentException
dup
ldc "maxAgeSeconds must be > 0"
invokespecial java.lang.IllegalArgumentException.<init>:(Ljava/lang/String;)V
athrow
5: StackMap locals: io.vertx.ext.web.handler.impl.FaviconHandlerImpl io.vertx.core.Vertx java.lang.String long
StackMap stack:
aload 1
invokeinterface io.vertx.core.Vertx.fileSystem:()Lio/vertx/core/file/FileSystem;
astore 5
start local 5 6: aconst_null
astore 6
start local 6 7: aload 2
ifnonnull 15
8: aload 0
aload 5
ldc "favicon.ico"
invokevirtual io.vertx.ext.web.handler.impl.FaviconHandlerImpl.readFile:(Lio/vertx/core/file/FileSystem;Ljava/lang/String;)Lio/vertx/core/buffer/Buffer;
astore 6
9: goto 19
StackMap locals: io.vertx.ext.web.handler.impl.FaviconHandlerImpl io.vertx.core.Vertx java.lang.String long io.vertx.core.file.FileSystem io.vertx.core.buffer.Buffer
StackMap stack: java.lang.RuntimeException
10: pop
11: aload 5
ldc "META-INF/vertx/web/favicon.ico"
invokeinterface io.vertx.core.file.FileSystem.readFileBlocking:(Ljava/lang/String;)Lio/vertx/core/buffer/Buffer;
astore 6
12: goto 19
StackMap locals:
StackMap stack: java.lang.RuntimeException
13: pop
14: goto 19
15: StackMap locals:
StackMap stack:
aload 0
aload 5
aload 2
invokevirtual io.vertx.ext.web.handler.impl.FaviconHandlerImpl.readFile:(Lio/vertx/core/file/FileSystem;Ljava/lang/String;)Lio/vertx/core/buffer/Buffer;
astore 6
16: goto 19
StackMap locals:
StackMap stack: java.lang.RuntimeException
17: pop
18: getstatic io.vertx.ext.web.handler.impl.FaviconHandlerImpl.logger:Lio/vertx/core/impl/logging/Logger;
new java.lang.StringBuilder
dup
ldc "Could not load favicon "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 2
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokeinterface io.vertx.core.impl.logging.Logger.error:(Ljava/lang/Object;)V
19: StackMap locals:
StackMap stack:
aload 6
ifnull 22
20: aload 0
new io.vertx.ext.web.handler.impl.FaviconHandlerImpl$Icon
dup
aload 0
aload 6
invokespecial io.vertx.ext.web.handler.impl.FaviconHandlerImpl$Icon.<init>:(Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl;Lio/vertx/core/buffer/Buffer;)V
putfield io.vertx.ext.web.handler.impl.FaviconHandlerImpl.icon:Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl$Icon;
21: goto 23
22: StackMap locals:
StackMap stack:
aload 0
aload 0
getfield io.vertx.ext.web.handler.impl.FaviconHandlerImpl.NULL_ICON:Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl$Icon;
putfield io.vertx.ext.web.handler.impl.FaviconHandlerImpl.icon:Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl$Icon;
23: StackMap locals:
StackMap stack:
return
end local 6 end local 5 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 24 0 this Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl;
0 24 1 vertx Lio/vertx/core/Vertx;
0 24 2 path Ljava/lang/String;
0 24 3 maxAgeSeconds J
6 24 5 fs Lio/vertx/core/file/FileSystem;
7 24 6 buffer Lio/vertx/core/buffer/Buffer;
Exception table:
from to target type
8 9 10 Class java.lang.RuntimeException
11 12 13 Class java.lang.RuntimeException
15 16 17 Class java.lang.RuntimeException
MethodParameters:
Name Flags
vertx
path
maxAgeSeconds
public void <init>(io.vertx.core.Vertx, long);
descriptor: (Lio/vertx/core/Vertx;J)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=4, args_size=3
start local 0 start local 1 start local 2 0: aload 0
aload 1
aconst_null
lload 2
invokespecial io.vertx.ext.web.handler.impl.FaviconHandlerImpl.<init>:(Lio/vertx/core/Vertx;Ljava/lang/String;J)V
1: return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl;
0 2 1 vertx Lio/vertx/core/Vertx;
0 2 2 maxAgeSeconds J
MethodParameters:
Name Flags
vertx
maxAgeSeconds
public void <init>(io.vertx.core.Vertx, java.lang.String);
descriptor: (Lio/vertx/core/Vertx;Ljava/lang/String;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
aload 1
aload 2
ldc 86400
invokespecial io.vertx.ext.web.handler.impl.FaviconHandlerImpl.<init>:(Lio/vertx/core/Vertx;Ljava/lang/String;J)V
1: return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl;
0 2 1 vertx Lio/vertx/core/Vertx;
0 2 2 path Ljava/lang/String;
MethodParameters:
Name Flags
vertx
path
public void <init>(io.vertx.core.Vertx);
descriptor: (Lio/vertx/core/Vertx;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=2, args_size=2
start local 0 start local 1 0: aload 0
aload 1
aconst_null
invokespecial io.vertx.ext.web.handler.impl.FaviconHandlerImpl.<init>:(Lio/vertx/core/Vertx;Ljava/lang/String;)V
1: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl;
0 2 1 vertx Lio/vertx/core/Vertx;
MethodParameters:
Name Flags
vertx
private io.vertx.core.buffer.Buffer readFile(io.vertx.core.file.FileSystem, java.lang.String);
descriptor: (Lio/vertx/core/file/FileSystem;Ljava/lang/String;)Lio/vertx/core/buffer/Buffer;
flags: (0x0002) ACC_PRIVATE
Code:
stack=5, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 1
aload 2
invokeinterface io.vertx.core.file.FileSystem.existsBlocking:(Ljava/lang/String;)Z
ifeq 2
1: aload 1
aload 2
invokeinterface io.vertx.core.file.FileSystem.readFileBlocking:(Ljava/lang/String;)Lio/vertx/core/buffer/Buffer;
areturn
2: StackMap locals:
StackMap stack:
new java.lang.RuntimeException
dup
new java.lang.StringBuilder
dup
aload 2
invokestatic java.lang.String.valueOf:(Ljava/lang/Object;)Ljava/lang/String;
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
ldc " not found!"
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokespecial java.lang.RuntimeException.<init>:(Ljava/lang/String;)V
athrow
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl;
0 3 1 fs Lio/vertx/core/file/FileSystem;
0 3 2 path Ljava/lang/String;
MethodParameters:
Name Flags
fs
path
public void handle(io.vertx.ext.web.RoutingContext);
descriptor: (Lio/vertx/ext/web/RoutingContext;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=3, args_size=2
start local 0 start local 1 0: ldc "/favicon.ico"
aload 1
invokeinterface io.vertx.ext.web.RoutingContext.request:()Lio/vertx/core/http/HttpServerRequest;
invokeinterface io.vertx.core.http.HttpServerRequest.path:()Ljava/lang/String;
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifeq 8
1: aload 1
invokeinterface io.vertx.ext.web.RoutingContext.response:()Lio/vertx/core/http/HttpServerResponse;
astore 2
start local 2 2: aload 0
getfield io.vertx.ext.web.handler.impl.FaviconHandlerImpl.icon:Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl$Icon;
aload 0
getfield io.vertx.ext.web.handler.impl.FaviconHandlerImpl.NULL_ICON:Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl$Icon;
if_acmpne 5
3: aload 2
sipush 404
invokeinterface io.vertx.core.http.HttpServerResponse.setStatusCode:(I)Lio/vertx/core/http/HttpServerResponse;
invokeinterface io.vertx.core.http.HttpServerResponse.end:()Lio/vertx/core/Future;
pop
4: goto 9
5: StackMap locals: io.vertx.core.http.HttpServerResponse
StackMap stack:
aload 2
invokeinterface io.vertx.core.http.HttpServerResponse.headers:()Lio/vertx/core/MultiMap;
aload 0
getfield io.vertx.ext.web.handler.impl.FaviconHandlerImpl.icon:Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl$Icon;
getfield io.vertx.ext.web.handler.impl.FaviconHandlerImpl$Icon.headers:Lio/vertx/core/MultiMap;
invokeinterface io.vertx.core.MultiMap.addAll:(Lio/vertx/core/MultiMap;)Lio/vertx/core/MultiMap;
pop
6: aload 2
aload 0
getfield io.vertx.ext.web.handler.impl.FaviconHandlerImpl.icon:Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl$Icon;
getfield io.vertx.ext.web.handler.impl.FaviconHandlerImpl$Icon.body:Lio/vertx/core/buffer/Buffer;
invokeinterface io.vertx.core.http.HttpServerResponse.end:(Lio/vertx/core/buffer/Buffer;)Lio/vertx/core/Future;
pop
end local 2 7: goto 9
8: StackMap locals:
StackMap stack:
aload 1
invokeinterface io.vertx.ext.web.RoutingContext.next:()V
9: StackMap locals:
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 10 0 this Lio/vertx/ext/web/handler/impl/FaviconHandlerImpl;
0 10 1 ctx Lio/vertx/ext/web/RoutingContext;
2 7 2 resp Lio/vertx/core/http/HttpServerResponse;
MethodParameters:
Name Flags
ctx
public void handle(java.lang.Object);
descriptor: (Ljava/lang/Object;)V
flags: (0x1041) ACC_PUBLIC, ACC_BRIDGE, ACC_SYNTHETIC
Code:
stack=2, locals=2, args_size=2
0: aload 0
aload 1
checkcast io.vertx.ext.web.RoutingContext
invokevirtual io.vertx.ext.web.handler.impl.FaviconHandlerImpl.handle:(Lio/vertx/ext/web/RoutingContext;)V
return
LocalVariableTable:
Start End Slot Name Signature
}
SourceFile: "FaviconHandlerImpl.java"
NestMembers:
io.vertx.ext.web.handler.impl.FaviconHandlerImpl$Icon
InnerClasses:
private Icon = io.vertx.ext.web.handler.impl.FaviconHandlerImpl$Icon of io.vertx.ext.web.handler.impl.FaviconHandlerImpl