class jdk.internal.net.http.ResponseContent$FixedLengthBodyParser implements jdk.internal.net.http.ResponseContent$BodyParser
minor version: 0
major version: 59
flags: flags: (0x0020) ACC_SUPER
this_class: jdk.internal.net.http.ResponseContent$FixedLengthBodyParser
super_class: java.lang.Object
{
final long contentLength;
descriptor: J
flags: (0x0010) ACC_FINAL
final java.util.function.Consumer<java.lang.Throwable> onComplete;
descriptor: Ljava/util/function/Consumer;
flags: (0x0010) ACC_FINAL
Signature: Ljava/util/function/Consumer<Ljava/lang/Throwable;>;
final jdk.internal.net.http.common.Logger debug;
descriptor: Ljdk/internal/net/http/common/Logger;
flags: (0x0010) ACC_FINAL
final java.lang.String dbgTag;
descriptor: Ljava/lang/String;
flags: (0x0010) ACC_FINAL
volatile long remaining;
descriptor: J
flags: (0x0040) ACC_VOLATILE
volatile java.lang.Throwable closedExceptionally;
descriptor: Ljava/lang/Throwable;
flags: (0x0040) ACC_VOLATILE
volatile jdk.internal.net.http.AbstractSubscription sub;
descriptor: Ljdk/internal/net/http/AbstractSubscription;
flags: (0x0040) ACC_VOLATILE
final jdk.internal.net.http.ResponseContent this$0;
descriptor: Ljdk/internal/net/http/ResponseContent;
flags: (0x1010) ACC_FINAL, ACC_SYNTHETIC
static final boolean $assertionsDisabled;
descriptor: Z
flags: (0x1018) ACC_STATIC, ACC_FINAL, ACC_SYNTHETIC
static void <clinit>();
descriptor: ()V
flags: (0x0008) ACC_STATIC
Code:
stack=1, locals=0, args_size=0
0: ldc Ljdk/internal/net/http/ResponseContent;
invokevirtual java.lang.Class.desiredAssertionStatus:()Z
ifne 1
iconst_1
goto 2
StackMap locals:
StackMap stack:
1: iconst_0
StackMap locals:
StackMap stack: int
2: putstatic jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.$assertionsDisabled:Z
return
LocalVariableTable:
Start End Slot Name Signature
void <init>(long, java.util.function.Consumer<java.lang.Throwable>);
descriptor: (Ljdk/internal/net/http/ResponseContent;JLjava/util/function/Consumer;)V
flags: (0x0000)
Code:
stack=6, locals=5, args_size=4
start local 0 start local 2 start local 4 0: aload 0
aload 1
putfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.this$0:Ljdk/internal/net/http/ResponseContent;
aload 0
invokespecial java.lang.Object.<init>:()V
1: aload 0
aload 0
invokedynamic get(Ljdk/internal/net/http/ResponseContent$FixedLengthBodyParser;)Ljava/util/function/Supplier;
Bootstrap: invokestatic java.lang.invoke.LambdaMetafactory.metafactory:(Ljava/lang/invoke/MethodHandles$Lookup;Ljava/lang/String;Ljava/lang/invoke/MethodType;Ljava/lang/invoke/MethodType;Ljava/lang/invoke/MethodHandle;Ljava/lang/invoke/MethodType;)Ljava/lang/invoke/CallSite;
Method arguments:
()Ljava/lang/Object;
jdk/internal/net/http/ResponseContent$FixedLengthBodyParser.dbgString()Ljava/lang/String; (5)
()Ljava/lang/String;
getstatic jdk.internal.net.http.common.Utils.DEBUG:Z
invokestatic jdk.internal.net.http.common.Utils.getDebugLogger:(Ljava/util/function/Supplier;Z)Ljdk/internal/net/http/common/Logger;
putfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.debug:Ljdk/internal/net/http/common/Logger;
2: aload 0
new java.lang.StringBuilder
dup
aload 1
getfield jdk.internal.net.http.ResponseContent.dbgTag:Ljava/lang/String;
invokestatic java.lang.String.valueOf:(Ljava/lang/Object;)Ljava/lang/String;
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
ldc "/FixedLengthBodyParser"
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
putfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.dbgTag:Ljava/lang/String;
3: aload 0
aload 0
lload 2
dup2_x1
putfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.remaining:J
putfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.contentLength:J
4: aload 0
aload 4
putfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.onComplete:Ljava/util/function/Consumer;
5: return
end local 4 end local 2 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 6 0 this Ljdk/internal/net/http/ResponseContent$FixedLengthBodyParser;
0 6 2 contentLength J
0 6 4 onComplete Ljava/util/function/Consumer<Ljava/lang/Throwable;>;
Signature: (JLjava/util/function/Consumer<Ljava/lang/Throwable;>;)V
MethodParameters:
Name Flags
this$0 final
contentLength
onComplete
java.lang.String dbgString();
descriptor: ()Ljava/lang/String;
flags: (0x0000)
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.dbgTag:Ljava/lang/String;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/net/http/ResponseContent$FixedLengthBodyParser;
public void onSubscribe(jdk.internal.net.http.AbstractSubscription);
descriptor: (Ljdk/internal/net/http/AbstractSubscription;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=4, locals=4, args_size=2
start local 0 start local 1 0: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.debug:Ljdk/internal/net/http/common/Logger;
invokeinterface jdk.internal.net.http.common.Logger.on:()Z
ifeq 4
1: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.debug:Ljdk/internal/net/http/common/Logger;
new java.lang.StringBuilder
dup
ldc "length="
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.contentLength:J
invokevirtual java.lang.StringBuilder.append:(J)Ljava/lang/StringBuilder;
ldc ", onSubscribe: "
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
2: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.this$0:Ljdk/internal/net/http/ResponseContent;
getfield jdk.internal.net.http.ResponseContent.pusher:Ljava/net/http/HttpResponse$BodySubscriber;
invokevirtual java.lang.Object.getClass:()Ljava/lang/Class;
invokevirtual java.lang.Class.getName:()Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
3: invokeinterface jdk.internal.net.http.common.Logger.log:(Ljava/lang/String;)V
4: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.this$0:Ljdk/internal/net/http/ResponseContent;
getfield jdk.internal.net.http.ResponseContent.pusher:Ljava/net/http/HttpResponse$BodySubscriber;
aload 0
aload 1
dup_x1
putfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.sub:Ljdk/internal/net/http/AbstractSubscription;
invokeinterface java.net.http.HttpResponse$BodySubscriber.onSubscribe:(Ljava/util/concurrent/Flow$Subscription;)V
5: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.contentLength:J
lconst_0
lcmp
ifne 18
6: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.this$0:Ljdk/internal/net/http/ResponseContent;
getfield jdk.internal.net.http.ResponseContent.onFinished:Ljava/lang/Runnable;
invokeinterface java.lang.Runnable.run:()V
7: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.this$0:Ljdk/internal/net/http/ResponseContent;
getfield jdk.internal.net.http.ResponseContent.pusher:Ljava/net/http/HttpResponse$BodySubscriber;
invokeinterface java.net.http.HttpResponse$BodySubscriber.onComplete:()V
8: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.onComplete:Ljava/util/function/Consumer;
aconst_null
invokeinterface java.util.function.Consumer.accept:(Ljava/lang/Object;)V
9: goto 18
StackMap locals:
StackMap stack: java.lang.Throwable
10: astore 2
start local 2 11: aload 0
aload 2
putfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.closedExceptionally:Ljava/lang/Throwable;
12: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.this$0:Ljdk/internal/net/http/ResponseContent;
getfield jdk.internal.net.http.ResponseContent.pusher:Ljava/net/http/HttpResponse$BodySubscriber;
aload 2
invokeinterface java.net.http.HttpResponse$BodySubscriber.onError:(Ljava/lang/Throwable;)V
13: goto 17
StackMap locals: jdk.internal.net.http.ResponseContent$FixedLengthBodyParser jdk.internal.net.http.AbstractSubscription java.lang.Throwable
StackMap stack: java.lang.Throwable
14: astore 3
15: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.onComplete:Ljava/util/function/Consumer;
aload 2
invokeinterface java.util.function.Consumer.accept:(Ljava/lang/Object;)V
16: aload 3
athrow
17: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.onComplete:Ljava/util/function/Consumer;
aload 2
invokeinterface java.util.function.Consumer.accept:(Ljava/lang/Object;)V
end local 2 18: StackMap locals:
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 19 0 this Ljdk/internal/net/http/ResponseContent$FixedLengthBodyParser;
0 19 1 sub Ljdk/internal/net/http/AbstractSubscription;
11 18 2 t Ljava/lang/Throwable;
Exception table:
from to target type
5 9 10 Class java.lang.Throwable
12 14 14 any
MethodParameters:
Name Flags
sub
public java.lang.String currentStateMessage();
descriptor: ()Ljava/lang/String;
flags: (0x0001) ACC_PUBLIC
Code:
stack=8, locals=1, args_size=1
start local 0 0: ldc "fixed content-length: %d, bytes received: %d"
iconst_2
anewarray java.lang.Object
dup
iconst_0
1: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.contentLength:J
invokestatic java.lang.Long.valueOf:(J)Ljava/lang/Long;
aastore
dup
iconst_1
aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.contentLength:J
aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.remaining:J
lsub
invokestatic java.lang.Long.valueOf:(J)Ljava/lang/Long;
aastore
2: invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Ljdk/internal/net/http/ResponseContent$FixedLengthBodyParser;
public void accept(java.nio.ByteBuffer);
descriptor: (Ljava/nio/ByteBuffer;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=7, locals=8, args_size=2
start local 0 start local 1 0: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.closedExceptionally:Ljava/lang/Throwable;
ifnull 4
1: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.debug:Ljdk/internal/net/http/common/Logger;
invokeinterface jdk.internal.net.http.common.Logger.on:()Z
ifeq 3
2: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.debug:Ljdk/internal/net/http/common/Logger;
new java.lang.StringBuilder
dup
ldc "already closed: "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.closedExceptionally:Ljava/lang/Throwable;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/Object;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokeinterface jdk.internal.net.http.common.Logger.log:(Ljava/lang/String;)V
3: StackMap locals:
StackMap stack:
return
4: StackMap locals:
StackMap stack:
iconst_0
istore 2
start local 2 5: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.remaining:J
lstore 3
start local 3 6: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.debug:Ljdk/internal/net/http/common/Logger;
invokeinterface jdk.internal.net.http.common.Logger.on:()Z
ifeq 10
7: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.debug:Ljdk/internal/net/http/common/Logger;
ldc "Parser got %d bytes (%d remaining / %d)"
iconst_3
anewarray java.lang.Object
dup
iconst_0
8: aload 1
invokevirtual java.nio.ByteBuffer.remaining:()I
invokestatic java.lang.Integer.valueOf:(I)Ljava/lang/Integer;
aastore
dup
iconst_1
lload 3
invokestatic java.lang.Long.valueOf:(J)Ljava/lang/Long;
aastore
dup
iconst_2
aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.contentLength:J
invokestatic java.lang.Long.valueOf:(J)Ljava/lang/Long;
aastore
9: invokeinterface jdk.internal.net.http.common.Logger.log:(Ljava/lang/String;[Ljava/lang/Object;)V
10: StackMap locals: int long
StackMap stack:
getstatic jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.$assertionsDisabled:Z
ifne 11
lload 3
lconst_0
lcmp
ifne 11
aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.contentLength:J
lconst_0
lcmp
ifeq 11
aload 1
invokevirtual java.nio.ByteBuffer.remaining:()I
ifeq 11
new java.lang.AssertionError
dup
invokespecial java.lang.AssertionError.<init>:()V
athrow
11: StackMap locals:
StackMap stack:
lload 3
lconst_0
lcmp
ifne 13
aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.contentLength:J
lconst_0
lcmp
ifle 13
12: return
13: StackMap locals:
StackMap stack:
aload 1
invokevirtual java.nio.ByteBuffer.hasRemaining:()Z
ifeq 20
lload 3
lconst_0
lcmp
ifle 20
14: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.sub:Ljdk/internal/net/http/AbstractSubscription;
invokevirtual jdk.internal.net.http.AbstractSubscription.demand:()Ljdk/internal/net/http/common/Demand;
invokevirtual jdk.internal.net.http.common.Demand.tryDecrement:()Z
istore 5
start local 5 15: getstatic jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.$assertionsDisabled:Z
ifne 16
iload 5
ifne 16
new java.lang.AssertionError
dup
invokespecial java.lang.AssertionError.<init>:()V
athrow
16: StackMap locals: int
StackMap stack:
aload 1
invokevirtual java.nio.ByteBuffer.remaining:()I
i2l
lload 3
invokestatic java.lang.Math.min:(JJ)J
l2i
istore 6
start local 6 17: aload 0
dup
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.remaining:J
iload 6
i2l
lsub
dup2_x1
putfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.remaining:J
lstore 3
18: aload 1
iload 6
invokestatic jdk.internal.net.http.common.Utils.sliceWithLimitedCapacity:(Ljava/nio/ByteBuffer;I)Ljava/nio/ByteBuffer;
astore 7
start local 7 19: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.this$0:Ljdk/internal/net/http/ResponseContent;
getfield jdk.internal.net.http.ResponseContent.pusher:Ljava/net/http/HttpResponse$BodySubscriber;
aload 7
invokevirtual java.nio.ByteBuffer.asReadOnlyBuffer:()Ljava/nio/ByteBuffer;
invokestatic java.util.List.of:(Ljava/lang/Object;)Ljava/util/List;
invokeinterface java.net.http.HttpResponse$BodySubscriber.onNext:(Ljava/lang/Object;)V
end local 7 end local 6 end local 5 20: StackMap locals:
StackMap stack:
lload 3
lconst_0
lcmp
ifne 29
21: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.debug:Ljdk/internal/net/http/common/Logger;
invokeinterface jdk.internal.net.http.common.Logger.on:()Z
ifeq 23
22: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.debug:Ljdk/internal/net/http/common/Logger;
ldc "Parser got all expected bytes: completing"
invokeinterface jdk.internal.net.http.common.Logger.log:(Ljava/lang/String;)V
23: StackMap locals:
StackMap stack:
getstatic jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.$assertionsDisabled:Z
ifne 24
aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.closedExceptionally:Ljava/lang/Throwable;
ifnull 24
new java.lang.AssertionError
dup
invokespecial java.lang.AssertionError.<init>:()V
athrow
24: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.this$0:Ljdk/internal/net/http/ResponseContent;
getfield jdk.internal.net.http.ResponseContent.onFinished:Ljava/lang/Runnable;
invokeinterface java.lang.Runnable.run:()V
25: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.this$0:Ljdk/internal/net/http/ResponseContent;
getfield jdk.internal.net.http.ResponseContent.pusher:Ljava/net/http/HttpResponse$BodySubscriber;
invokeinterface java.net.http.HttpResponse$BodySubscriber.onComplete:()V
26: iconst_1
istore 2
27: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.onComplete:Ljava/util/function/Consumer;
aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.closedExceptionally:Ljava/lang/Throwable;
invokeinterface java.util.function.Consumer.accept:(Ljava/lang/Object;)V
28: goto 35
29: StackMap locals:
StackMap stack:
getstatic jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.$assertionsDisabled:Z
ifne 35
aload 1
invokevirtual java.nio.ByteBuffer.remaining:()I
ifeq 35
new java.lang.AssertionError
dup
invokespecial java.lang.AssertionError.<init>:()V
athrow
end local 3 30: StackMap locals: jdk.internal.net.http.ResponseContent$FixedLengthBodyParser java.nio.ByteBuffer int
StackMap stack: java.lang.Throwable
astore 3
start local 3 31: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.debug:Ljdk/internal/net/http/common/Logger;
invokeinterface jdk.internal.net.http.common.Logger.on:()Z
ifeq 32
aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.debug:Ljdk/internal/net/http/common/Logger;
ldc "Unexpected exception"
aload 3
invokeinterface jdk.internal.net.http.common.Logger.log:(Ljava/lang/String;Ljava/lang/Throwable;)V
32: StackMap locals: java.lang.Throwable
StackMap stack:
aload 0
aload 3
putfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.closedExceptionally:Ljava/lang/Throwable;
33: iload 2
ifne 35
34: aload 0
getfield jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.onComplete:Ljava/util/function/Consumer;
aload 3
invokeinterface java.util.function.Consumer.accept:(Ljava/lang/Object;)V
end local 3 35: StackMap locals:
StackMap stack:
return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 36 0 this Ljdk/internal/net/http/ResponseContent$FixedLengthBodyParser;
0 36 1 b Ljava/nio/ByteBuffer;
5 36 2 completed Z
6 30 3 unfulfilled J
15 20 5 hasDemand Z
17 20 6 amount I
19 20 7 buffer Ljava/nio/ByteBuffer;
31 35 3 t Ljava/lang/Throwable;
Exception table:
from to target type
5 12 30 Class java.lang.Throwable
13 30 30 Class java.lang.Throwable
MethodParameters:
Name Flags
b
public void accept(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 java.nio.ByteBuffer
invokevirtual jdk.internal.net.http.ResponseContent$FixedLengthBodyParser.accept:(Ljava/nio/ByteBuffer;)V
return
LocalVariableTable:
Start End Slot Name Signature
}
SourceFile: "ResponseContent.java"
NestHost: jdk.internal.net.http.ResponseContent
InnerClasses:
public final Lookup = java.lang.invoke.MethodHandles$Lookup of java.lang.invoke.MethodHandles
public abstract BodySubscriber = java.net.http.HttpResponse$BodySubscriber of java.net.http.HttpResponse
public abstract Subscription = java.util.concurrent.Flow$Subscription of java.util.concurrent.Flow
abstract BodyParser = jdk.internal.net.http.ResponseContent$BodyParser of jdk.internal.net.http.ResponseContent
FixedLengthBodyParser = jdk.internal.net.http.ResponseContent$FixedLengthBodyParser of jdk.internal.net.http.ResponseContent