public class io.undertow.util.DateUtils
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: io.undertow.util.DateUtils
super_class: java.lang.Object
{
private static final java.util.Locale LOCALE_US;
descriptor: Ljava/util/Locale;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
private static final java.util.TimeZone GMT_ZONE;
descriptor: Ljava/util/TimeZone;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
private static final java.lang.String RFC1123_PATTERN;
descriptor: Ljava/lang/String;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: "EEE, dd MMM yyyy HH:mm:ss z"
private static final java.util.concurrent.atomic.AtomicReference<java.lang.String> cachedDateString;
descriptor: Ljava/util/concurrent/atomic/AtomicReference;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
Signature: Ljava/util/concurrent/atomic/AtomicReference<Ljava/lang/String;>;
private static final java.lang.ThreadLocal<java.text.SimpleDateFormat> RFC1123_PATTERN_FORMAT;
descriptor: Ljava/lang/ThreadLocal;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
Signature: Ljava/lang/ThreadLocal<Ljava/text/SimpleDateFormat;>;
private static final java.lang.Runnable INVALIDATE_TASK;
descriptor: Ljava/lang/Runnable;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
private static final java.lang.String RFC1036_PATTERN;
descriptor: Ljava/lang/String;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: "EEEEEEEEE, dd-MMM-yy HH:mm:ss z"
private static final java.lang.String ASCITIME_PATTERN;
descriptor: Ljava/lang/String;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: "EEE MMM d HH:mm:ss yyyyy"
private static final java.lang.String OLD_COOKIE_PATTERN;
descriptor: Ljava/lang/String;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: "EEE, dd-MMM-yyyy HH:mm:ss z"
private static final java.lang.String COMMON_LOG_PATTERN;
descriptor: Ljava/lang/String;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: "[dd/MMM/yyyy:HH:mm:ss Z]"
private static final java.lang.ThreadLocal<java.text.SimpleDateFormat> COMMON_LOG_PATTERN_FORMAT;
descriptor: Ljava/lang/ThreadLocal;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
Signature: Ljava/lang/ThreadLocal<Ljava/text/SimpleDateFormat;>;
private static final java.lang.ThreadLocal<java.text.SimpleDateFormat> OLD_COOKIE_FORMAT;
descriptor: Ljava/lang/ThreadLocal;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
Signature: Ljava/lang/ThreadLocal<Ljava/text/SimpleDateFormat;>;
static void <clinit>();
descriptor: ()V
flags: (0x0008) ACC_STATIC
Code:
stack=2, locals=0, args_size=0
0: getstatic java.util.Locale.US:Ljava/util/Locale;
putstatic io.undertow.util.DateUtils.LOCALE_US:Ljava/util/Locale;
1: ldc "GMT"
invokestatic java.util.TimeZone.getTimeZone:(Ljava/lang/String;)Ljava/util/TimeZone;
putstatic io.undertow.util.DateUtils.GMT_ZONE:Ljava/util/TimeZone;
2: new java.util.concurrent.atomic.AtomicReference
dup
invokespecial java.util.concurrent.atomic.AtomicReference.<init>:()V
putstatic io.undertow.util.DateUtils.cachedDateString:Ljava/util/concurrent/atomic/AtomicReference;
3: new io.undertow.util.DateUtils$1
dup
invokespecial io.undertow.util.DateUtils$1.<init>:()V
putstatic io.undertow.util.DateUtils.RFC1123_PATTERN_FORMAT:Ljava/lang/ThreadLocal;
4: new io.undertow.util.DateUtils$2
dup
invokespecial io.undertow.util.DateUtils$2.<init>:()V
putstatic io.undertow.util.DateUtils.INVALIDATE_TASK:Ljava/lang/Runnable;
5: new io.undertow.util.DateUtils$3
dup
invokespecial io.undertow.util.DateUtils$3.<init>:()V
putstatic io.undertow.util.DateUtils.COMMON_LOG_PATTERN_FORMAT:Ljava/lang/ThreadLocal;
6: new io.undertow.util.DateUtils$4
dup
invokespecial io.undertow.util.DateUtils$4.<init>:()V
putstatic io.undertow.util.DateUtils.OLD_COOKIE_FORMAT:Ljava/lang/ThreadLocal;
7: return
LocalVariableTable:
Start End Slot Name Signature
public static java.lang.String toDateString(java.util.Date);
descriptor: (Ljava/util/Date;)Ljava/lang/String;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=2, locals=2, args_size=1
start local 0 0: getstatic io.undertow.util.DateUtils.RFC1123_PATTERN_FORMAT:Ljava/lang/ThreadLocal;
invokevirtual java.lang.ThreadLocal.get:()Ljava/lang/Object;
checkcast java.text.SimpleDateFormat
astore 1
start local 1 1: aload 1
getstatic io.undertow.util.DateUtils.GMT_ZONE:Ljava/util/TimeZone;
invokevirtual java.text.SimpleDateFormat.setTimeZone:(Ljava/util/TimeZone;)V
2: aload 1
aload 0
invokevirtual java.text.SimpleDateFormat.format:(Ljava/util/Date;)Ljava/lang/String;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 date Ljava/util/Date;
1 3 1 df Ljava/text/SimpleDateFormat;
MethodParameters:
Name Flags
date final
public static java.lang.String toOldCookieDateString(java.util.Date);
descriptor: (Ljava/util/Date;)Ljava/lang/String;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: getstatic io.undertow.util.DateUtils.OLD_COOKIE_FORMAT:Ljava/lang/ThreadLocal;
invokevirtual java.lang.ThreadLocal.get:()Ljava/lang/Object;
checkcast java.text.SimpleDateFormat
aload 0
invokevirtual java.text.SimpleDateFormat.format:(Ljava/util/Date;)Ljava/lang/String;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 date Ljava/util/Date;
MethodParameters:
Name Flags
date final
public static java.lang.String toCommonLogFormat(java.util.Date);
descriptor: (Ljava/util/Date;)Ljava/lang/String;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: getstatic io.undertow.util.DateUtils.COMMON_LOG_PATTERN_FORMAT:Ljava/lang/ThreadLocal;
invokevirtual java.lang.ThreadLocal.get:()Ljava/lang/Object;
checkcast java.text.SimpleDateFormat
aload 0
invokevirtual java.text.SimpleDateFormat.format:(Ljava/util/Date;)Ljava/lang/String;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 date Ljava/util/Date;
MethodParameters:
Name Flags
date final
public static java.util.Date parseDate(java.lang.String);
descriptor: (Ljava/lang/String;)Ljava/util/Date;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=4, locals=6, args_size=1
start local 0 0: aload 0
bipush 59
invokevirtual java.lang.String.indexOf:(I)I
istore 1
start local 1 1: iload 1
iflt 2
aload 0
iconst_0
iload 1
invokevirtual java.lang.String.substring:(II)Ljava/lang/String;
goto 3
StackMap locals: int
StackMap stack:
2: aload 0
StackMap locals:
StackMap stack: java.lang.String
3: astore 2
start local 2 4: new java.text.ParsePosition
dup
iconst_0
invokespecial java.text.ParsePosition.<init>:(I)V
astore 3
start local 3 5: getstatic io.undertow.util.DateUtils.RFC1123_PATTERN_FORMAT:Ljava/lang/ThreadLocal;
invokevirtual java.lang.ThreadLocal.get:()Ljava/lang/Object;
checkcast java.text.SimpleDateFormat
astore 4
start local 4 6: aload 4
getstatic io.undertow.util.DateUtils.GMT_ZONE:Ljava/util/TimeZone;
invokevirtual java.text.SimpleDateFormat.setTimeZone:(Ljava/util/TimeZone;)V
7: aload 4
aload 2
aload 3
invokevirtual java.text.SimpleDateFormat.parse:(Ljava/lang/String;Ljava/text/ParsePosition;)Ljava/util/Date;
astore 5
start local 5 8: aload 5
ifnull 10
aload 3
invokevirtual java.text.ParsePosition.getIndex:()I
aload 2
invokevirtual java.lang.String.length:()I
if_icmpne 10
9: aload 5
areturn
10: StackMap locals: java.lang.String int java.lang.String java.text.ParsePosition java.text.SimpleDateFormat java.util.Date
StackMap stack:
new java.text.ParsePosition
dup
iconst_0
invokespecial java.text.ParsePosition.<init>:(I)V
astore 3
11: new java.text.SimpleDateFormat
dup
ldc "EEEEEEEEE, dd-MMM-yy HH:mm:ss z"
getstatic io.undertow.util.DateUtils.LOCALE_US:Ljava/util/Locale;
invokespecial java.text.SimpleDateFormat.<init>:(Ljava/lang/String;Ljava/util/Locale;)V
astore 4
12: aload 4
getstatic io.undertow.util.DateUtils.GMT_ZONE:Ljava/util/TimeZone;
invokevirtual java.text.SimpleDateFormat.setTimeZone:(Ljava/util/TimeZone;)V
13: aload 4
aload 2
aload 3
invokevirtual java.text.SimpleDateFormat.parse:(Ljava/lang/String;Ljava/text/ParsePosition;)Ljava/util/Date;
astore 5
14: aload 5
ifnull 16
aload 3
invokevirtual java.text.ParsePosition.getIndex:()I
aload 2
invokevirtual java.lang.String.length:()I
if_icmpne 16
15: aload 5
areturn
16: StackMap locals:
StackMap stack:
new java.text.ParsePosition
dup
iconst_0
invokespecial java.text.ParsePosition.<init>:(I)V
astore 3
17: new java.text.SimpleDateFormat
dup
ldc "EEE MMM d HH:mm:ss yyyyy"
getstatic io.undertow.util.DateUtils.LOCALE_US:Ljava/util/Locale;
invokespecial java.text.SimpleDateFormat.<init>:(Ljava/lang/String;Ljava/util/Locale;)V
astore 4
18: aload 4
getstatic io.undertow.util.DateUtils.GMT_ZONE:Ljava/util/TimeZone;
invokevirtual java.text.SimpleDateFormat.setTimeZone:(Ljava/util/TimeZone;)V
19: aload 4
aload 2
aload 3
invokevirtual java.text.SimpleDateFormat.parse:(Ljava/lang/String;Ljava/text/ParsePosition;)Ljava/util/Date;
astore 5
20: aload 5
ifnull 22
aload 3
invokevirtual java.text.ParsePosition.getIndex:()I
aload 2
invokevirtual java.lang.String.length:()I
if_icmpne 22
21: aload 5
areturn
22: StackMap locals:
StackMap stack:
new java.text.ParsePosition
dup
iconst_0
invokespecial java.text.ParsePosition.<init>:(I)V
astore 3
23: new java.text.SimpleDateFormat
dup
ldc "EEE, dd-MMM-yyyy HH:mm:ss z"
getstatic io.undertow.util.DateUtils.LOCALE_US:Ljava/util/Locale;
invokespecial java.text.SimpleDateFormat.<init>:(Ljava/lang/String;Ljava/util/Locale;)V
astore 4
24: aload 4
getstatic io.undertow.util.DateUtils.GMT_ZONE:Ljava/util/TimeZone;
invokevirtual java.text.SimpleDateFormat.setTimeZone:(Ljava/util/TimeZone;)V
25: aload 4
aload 2
aload 3
invokevirtual java.text.SimpleDateFormat.parse:(Ljava/lang/String;Ljava/text/ParsePosition;)Ljava/util/Date;
astore 5
26: aload 5
ifnull 28
aload 3
invokevirtual java.text.ParsePosition.getIndex:()I
aload 2
invokevirtual java.lang.String.length:()I
if_icmpne 28
27: aload 5
areturn
28: StackMap locals:
StackMap stack:
aconst_null
areturn
end local 5 end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 29 0 date Ljava/lang/String;
1 29 1 semicolonIndex I
4 29 2 trimmedDate Ljava/lang/String;
5 29 3 pp Ljava/text/ParsePosition;
6 29 4 dateFormat Ljava/text/SimpleDateFormat;
8 29 5 val Ljava/util/Date;
MethodParameters:
Name Flags
date final
public static boolean handleIfModifiedSince(io.undertow.server.HttpServerExchange, java.util.Date);
descriptor: (Lio/undertow/server/HttpServerExchange;Ljava/util/Date;)Z
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
invokevirtual io.undertow.server.HttpServerExchange.getRequestHeaders:()Lio/undertow/util/HeaderMap;
getstatic io.undertow.util.Headers.IF_MODIFIED_SINCE:Lio/undertow/util/HttpString;
invokevirtual io.undertow.util.HeaderMap.getFirst:(Lio/undertow/util/HttpString;)Ljava/lang/String;
aload 1
invokestatic io.undertow.util.DateUtils.handleIfModifiedSince:(Ljava/lang/String;Ljava/util/Date;)Z
ireturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 exchange Lio/undertow/server/HttpServerExchange;
0 1 1 lastModified Ljava/util/Date;
MethodParameters:
Name Flags
exchange final
lastModified final
public static boolean handleIfModifiedSince(java.lang.String, java.util.Date);
descriptor: (Ljava/lang/String;Ljava/util/Date;)Z
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=6, locals=3, args_size=2
start local 0 start local 1 0: aload 1
ifnonnull 2
1: iconst_1
ireturn
2: StackMap locals:
StackMap stack:
aload 0
ifnonnull 4
3: iconst_1
ireturn
4: StackMap locals:
StackMap stack:
aload 0
invokestatic io.undertow.util.DateUtils.parseDate:(Ljava/lang/String;)Ljava/util/Date;
astore 2
start local 2 5: aload 2
ifnonnull 7
6: iconst_1
ireturn
7: StackMap locals: java.util.Date
StackMap stack:
aload 1
invokevirtual java.util.Date.getTime:()J
aload 2
invokevirtual java.util.Date.getTime:()J
ldc 999
ladd
lcmp
ifle 8
iconst_1
ireturn
StackMap locals:
StackMap stack:
8: iconst_0
ireturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 9 0 modifiedSince Ljava/lang/String;
0 9 1 lastModified Ljava/util/Date;
5 9 2 modDate Ljava/util/Date;
MethodParameters:
Name Flags
modifiedSince final
lastModified final
public static boolean handleIfUnmodifiedSince(io.undertow.server.HttpServerExchange, java.util.Date);
descriptor: (Lio/undertow/server/HttpServerExchange;Ljava/util/Date;)Z
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
invokevirtual io.undertow.server.HttpServerExchange.getRequestHeaders:()Lio/undertow/util/HeaderMap;
getstatic io.undertow.util.Headers.IF_UNMODIFIED_SINCE:Lio/undertow/util/HttpString;
invokevirtual io.undertow.util.HeaderMap.getFirst:(Lio/undertow/util/HttpString;)Ljava/lang/String;
aload 1
invokestatic io.undertow.util.DateUtils.handleIfUnmodifiedSince:(Ljava/lang/String;Ljava/util/Date;)Z
ireturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 exchange Lio/undertow/server/HttpServerExchange;
0 1 1 lastModified Ljava/util/Date;
MethodParameters:
Name Flags
exchange final
lastModified final
public static boolean handleIfUnmodifiedSince(java.lang.String, java.util.Date);
descriptor: (Ljava/lang/String;Ljava/util/Date;)Z
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=6, locals=3, args_size=2
start local 0 start local 1 0: aload 1
ifnonnull 2
1: iconst_1
ireturn
2: StackMap locals:
StackMap stack:
aload 0
ifnonnull 4
3: iconst_1
ireturn
4: StackMap locals:
StackMap stack:
aload 0
invokestatic io.undertow.util.DateUtils.parseDate:(Ljava/lang/String;)Ljava/util/Date;
astore 2
start local 2 5: aload 2
ifnonnull 7
6: iconst_1
ireturn
7: StackMap locals: java.util.Date
StackMap stack:
aload 1
invokevirtual java.util.Date.getTime:()J
aload 2
invokevirtual java.util.Date.getTime:()J
ldc 999
ladd
lcmp
ifge 8
iconst_1
ireturn
StackMap locals:
StackMap stack:
8: iconst_0
ireturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 9 0 modifiedSince Ljava/lang/String;
0 9 1 lastModified Ljava/util/Date;
5 9 2 modDate Ljava/util/Date;
MethodParameters:
Name Flags
modifiedSince final
lastModified final
public static void (io.undertow.server.HttpServerExchange);
descriptor: (Lio/undertow/server/HttpServerExchange;)V
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=3, locals=3, args_size=1
start local 0 0: aload 0
invokevirtual io.undertow.server.HttpServerExchange.getResponseHeaders:()Lio/undertow/util/HeaderMap;
astore 1
start local 1 1: aload 0
invokevirtual io.undertow.server.HttpServerExchange.getConnection:()Lio/undertow/server/ServerConnection;
invokevirtual io.undertow.server.ServerConnection.getUndertowOptions:()Lorg/xnio/OptionMap;
getstatic io.undertow.UndertowOptions.ALWAYS_SET_DATE:Lorg/xnio/Option;
iconst_1
invokevirtual org.xnio.OptionMap.get:(Lorg/xnio/Option;Z)Z
ifeq 4
aload 1
getstatic io.undertow.util.Headers.DATE:Lio/undertow/util/HttpString;
invokevirtual io.undertow.util.HeaderMap.contains:(Lio/undertow/util/HttpString;)Z
ifne 4
2: aload 0
invokestatic io.undertow.util.DateUtils.getCurrentDateTime:(Lio/undertow/server/HttpServerExchange;)Ljava/lang/String;
astore 2
start local 2 3: aload 1
getstatic io.undertow.util.Headers.DATE:Lio/undertow/util/HttpString;
aload 2
invokevirtual io.undertow.util.HeaderMap.put:(Lio/undertow/util/HttpString;Ljava/lang/String;)Lio/undertow/util/HeaderMap;
pop
end local 2 4: StackMap locals: io.undertow.util.HeaderMap
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 exchange Lio/undertow/server/HttpServerExchange;
1 5 1 responseHeaders Lio/undertow/util/HeaderMap;
3 4 2 dateString Ljava/lang/String;
MethodParameters:
Name Flags
exchange
public static java.lang.String getCurrentDateTime(io.undertow.server.HttpServerExchange);
descriptor: (Lio/undertow/server/HttpServerExchange;)Ljava/lang/String;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=5, locals=8, args_size=1
start local 0 0: getstatic io.undertow.util.DateUtils.cachedDateString:Ljava/util/concurrent/atomic/AtomicReference;
invokevirtual java.util.concurrent.atomic.AtomicReference.get:()Ljava/lang/Object;
checkcast java.lang.String
astore 1
start local 1 1: aload 1
ifnonnull 8
2: invokestatic java.lang.System.currentTimeMillis:()J
lstore 2
start local 2 3: lload 2
ldc 1000
lrem
lstore 4
start local 4 4: ldc 1000
lload 4
lsub
lstore 6
start local 6 5: new java.util.Date
dup
lload 2
invokespecial java.util.Date.<init>:(J)V
invokestatic io.undertow.util.DateUtils.toDateString:(Ljava/util/Date;)Ljava/lang/String;
astore 1
6: getstatic io.undertow.util.DateUtils.cachedDateString:Ljava/util/concurrent/atomic/AtomicReference;
aconst_null
aload 1
invokevirtual java.util.concurrent.atomic.AtomicReference.compareAndSet:(Ljava/lang/Object;Ljava/lang/Object;)Z
ifeq 8
7: aload 0
invokevirtual io.undertow.server.HttpServerExchange.getIoThread:()Lorg/xnio/XnioIoThread;
getstatic io.undertow.util.DateUtils.INVALIDATE_TASK:Ljava/lang/Runnable;
lload 6
getstatic java.util.concurrent.TimeUnit.MILLISECONDS:Ljava/util/concurrent/TimeUnit;
invokestatic io.undertow.util.WorkerUtils.executeAfter:(Lorg/xnio/XnioIoThread;Ljava/lang/Runnable;JLjava/util/concurrent/TimeUnit;)Lorg/xnio/XnioExecutor$Key;
pop
end local 6 end local 4 end local 2 8: StackMap locals: java.lang.String
StackMap stack:
aload 1
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 9 0 exchange Lio/undertow/server/HttpServerExchange;
1 9 1 dateString Ljava/lang/String;
3 8 2 realTime J
4 8 4 mod J
5 8 6 toGo J
MethodParameters:
Name Flags
exchange
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
1: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lio/undertow/util/DateUtils;
}
SourceFile: "DateUtils.java"
NestMembers:
io.undertow.util.DateUtils$1 io.undertow.util.DateUtils$2 io.undertow.util.DateUtils$3 io.undertow.util.DateUtils$4
InnerClasses:
io.undertow.util.DateUtils$1
io.undertow.util.DateUtils$2
io.undertow.util.DateUtils$3
io.undertow.util.DateUtils$4
public abstract Key = org.xnio.XnioExecutor$Key of org.xnio.XnioExecutor