public class jdk.internal.org.jline.utils.NonBlockingPumpReader extends jdk.internal.org.jline.utils.NonBlockingReader
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: jdk.internal.org.jline.utils.NonBlockingPumpReader
super_class: jdk.internal.org.jline.utils.NonBlockingReader
{
private static final int DEFAULT_BUFFER_SIZE;
descriptor: I
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: 4096
private final char[] buffer;
descriptor: [C
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
private int read;
descriptor: I
flags: (0x0002) ACC_PRIVATE
private int write;
descriptor: I
flags: (0x0002) ACC_PRIVATE
private int count;
descriptor: I
flags: (0x0002) ACC_PRIVATE
final java.util.concurrent.locks.ReentrantLock lock;
descriptor: Ljava/util/concurrent/locks/ReentrantLock;
flags: (0x0010) ACC_FINAL
private final java.util.concurrent.locks.Condition notEmpty;
descriptor: Ljava/util/concurrent/locks/Condition;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
private final java.util.concurrent.locks.Condition notFull;
descriptor: Ljava/util/concurrent/locks/Condition;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
private final java.io.Writer writer;
descriptor: Ljava/io/Writer;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
private boolean closed;
descriptor: Z
flags: (0x0002) ACC_PRIVATE
public void <init>();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
sipush 4096
invokespecial jdk.internal.org.jline.utils.NonBlockingPumpReader.<init>:(I)V
1: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Ljdk/internal/org/jline/utils/NonBlockingPumpReader;
public void <init>(int);
descriptor: (I)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=4, locals=2, args_size=2
start local 0 start local 1 0: aload 0
invokespecial jdk.internal.org.jline.utils.NonBlockingReader.<init>:()V
1: aload 0
iload 1
newarray 5
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.buffer:[C
2: aload 0
new jdk.internal.org.jline.utils.NonBlockingPumpReader$NbpWriter
dup
aload 0
invokespecial jdk.internal.org.jline.utils.NonBlockingPumpReader$NbpWriter.<init>:(Ljdk/internal/org/jline/utils/NonBlockingPumpReader;)V
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.writer:Ljava/io/Writer;
3: aload 0
new java.util.concurrent.locks.ReentrantLock
dup
invokespecial java.util.concurrent.locks.ReentrantLock.<init>:()V
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.lock:Ljava/util/concurrent/locks/ReentrantLock;
4: aload 0
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.lock:Ljava/util/concurrent/locks/ReentrantLock;
invokevirtual java.util.concurrent.locks.ReentrantLock.newCondition:()Ljava/util/concurrent/locks/Condition;
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.notEmpty:Ljava/util/concurrent/locks/Condition;
5: aload 0
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.lock:Ljava/util/concurrent/locks/ReentrantLock;
invokevirtual java.util.concurrent.locks.ReentrantLock.newCondition:()Ljava/util/concurrent/locks/Condition;
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.notFull:Ljava/util/concurrent/locks/Condition;
6: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 this Ljdk/internal/org/jline/utils/NonBlockingPumpReader;
0 7 1 bufferSize I
MethodParameters:
Name Flags
bufferSize
public java.io.Writer getWriter();
descriptor: ()Ljava/io/Writer;
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.writer:Ljava/io/Writer;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/org/jline/utils/NonBlockingPumpReader;
public boolean ready();
descriptor: ()Z
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
invokevirtual jdk.internal.org.jline.utils.NonBlockingPumpReader.available:()I
ifle 1
iconst_1
ireturn
StackMap locals:
StackMap stack:
1: iconst_0
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Ljdk/internal/org/jline/utils/NonBlockingPumpReader;
public int available();
descriptor: ()I
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=4, args_size=1
start local 0 0: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.lock:Ljava/util/concurrent/locks/ReentrantLock;
astore 1
start local 1 1: aload 1
invokevirtual java.util.concurrent.locks.ReentrantLock.lock:()V
2: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
istore 3
3: aload 1
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
4: iload 3
ireturn
5: StackMap locals: jdk.internal.org.jline.utils.NonBlockingPumpReader java.util.concurrent.locks.ReentrantLock
StackMap stack: java.lang.Throwable
astore 2
6: aload 1
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
7: aload 2
athrow
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 8 0 this Ljdk/internal/org/jline/utils/NonBlockingPumpReader;
1 8 1 lock Ljava/util/concurrent/locks/ReentrantLock;
Exception table:
from to target type
2 3 5 any
protected int read(long, boolean);
descriptor: (JZ)I
flags: (0x0004) ACC_PROTECTED
Code:
stack=4, locals=8, args_size=3
start local 0 start local 1 start local 3 0: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.lock:Ljava/util/concurrent/locks/ReentrantLock;
astore 4
start local 4 1: aload 4
invokevirtual java.util.concurrent.locks.ReentrantLock.lock:()V
2: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.closed:Z
ifne 7
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
ifne 7
3: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.notEmpty:Ljava/util/concurrent/locks/Condition;
lload 1
getstatic java.util.concurrent.TimeUnit.MILLISECONDS:Ljava/util/concurrent/TimeUnit;
invokeinterface java.util.concurrent.locks.Condition.await:(JLjava/util/concurrent/TimeUnit;)Z
pop
4: goto 7
StackMap locals: jdk.internal.org.jline.utils.NonBlockingPumpReader long int java.util.concurrent.locks.ReentrantLock
StackMap stack: java.lang.InterruptedException
5: astore 5
start local 5 6: new java.io.InterruptedIOException
dup
invokespecial java.io.InterruptedIOException.<init>:()V
aload 5
invokevirtual java.io.InterruptedIOException.initCause:(Ljava/lang/Throwable;)Ljava/lang/Throwable;
checkcast java.io.IOException
athrow
end local 5 7: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.closed:Z
ifeq 10
8: aload 4
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
9: iconst_m1
ireturn
10: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
ifne 13
11: aload 4
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
12: bipush -2
ireturn
13: StackMap locals:
StackMap stack:
iload 3
ifeq 17
14: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.buffer:[C
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.read:I
caload
istore 7
15: aload 4
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
16: iload 7
ireturn
17: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.buffer:[C
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.read:I
caload
istore 5
start local 5 18: aload 0
dup
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.read:I
iconst_1
iadd
dup_x1
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.read:I
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.buffer:[C
arraylength
if_icmpne 20
19: aload 0
iconst_0
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.read:I
20: StackMap locals: int
StackMap stack:
aload 0
dup
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
iconst_1
isub
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
21: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.notFull:Ljava/util/concurrent/locks/Condition;
invokeinterface java.util.concurrent.locks.Condition.signal:()V
22: iload 5
istore 7
23: aload 4
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
24: iload 7
ireturn
end local 5 25: StackMap locals: jdk.internal.org.jline.utils.NonBlockingPumpReader long int java.util.concurrent.locks.ReentrantLock
StackMap stack: java.lang.Throwable
astore 6
26: aload 4
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
27: aload 6
athrow
end local 4 end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 28 0 this Ljdk/internal/org/jline/utils/NonBlockingPumpReader;
0 28 1 timeout J
0 28 3 isPeek Z
1 28 4 lock Ljava/util/concurrent/locks/ReentrantLock;
6 7 5 e Ljava/lang/InterruptedException;
18 25 5 res I
Exception table:
from to target type
3 4 5 Class java.lang.InterruptedException
2 8 25 any
10 11 25 any
13 15 25 any
17 23 25 any
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
timeout
isPeek
public int readBuffered(char[]);
descriptor: ([C)I
flags: (0x0001) ACC_PUBLIC
Code:
stack=7, locals=7, args_size=2
start local 0 start local 1 0: aload 1
ifnonnull 2
1: new java.lang.NullPointerException
dup
invokespecial java.lang.NullPointerException.<init>:()V
athrow
2: StackMap locals:
StackMap stack:
aload 1
arraylength
ifne 4
3: iconst_0
ireturn
4: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.lock:Ljava/util/concurrent/locks/ReentrantLock;
astore 2
start local 2 5: aload 2
invokevirtual java.util.concurrent.locks.ReentrantLock.lock:()V
6: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.closed:Z
ifne 11
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
ifne 11
7: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.notEmpty:Ljava/util/concurrent/locks/Condition;
invokeinterface java.util.concurrent.locks.Condition.await:()V
8: goto 11
StackMap locals: jdk.internal.org.jline.utils.NonBlockingPumpReader char[] java.util.concurrent.locks.ReentrantLock
StackMap stack: java.lang.InterruptedException
9: astore 3
start local 3 10: new java.io.InterruptedIOException
dup
invokespecial java.io.InterruptedIOException.<init>:()V
aload 3
invokevirtual java.io.InterruptedIOException.initCause:(Ljava/lang/Throwable;)Ljava/lang/Throwable;
checkcast java.io.IOException
athrow
end local 3 11: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.closed:Z
ifeq 14
12: aload 2
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
13: iconst_m1
ireturn
14: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
ifne 17
15: aload 2
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
16: bipush -2
ireturn
17: StackMap locals:
StackMap stack:
aload 1
arraylength
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
invokestatic java.lang.Math.min:(II)I
istore 3
start local 3 18: iconst_0
istore 4
start local 4 19: goto 24
20: StackMap locals: int int
StackMap stack:
aload 1
iload 4
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.buffer:[C
aload 0
dup
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.read:I
dup_x1
iconst_1
iadd
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.read:I
caload
castore
21: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.read:I
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.buffer:[C
arraylength
if_icmpne 23
22: aload 0
iconst_0
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.read:I
23: StackMap locals:
StackMap stack:
iinc 4 1
StackMap locals:
StackMap stack:
24: iload 4
iload 3
if_icmplt 20
end local 4 25: aload 0
dup
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
iload 3
isub
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
26: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.notFull:Ljava/util/concurrent/locks/Condition;
invokeinterface java.util.concurrent.locks.Condition.signal:()V
27: iload 3
istore 6
28: aload 2
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
29: iload 6
ireturn
end local 3 30: StackMap locals: jdk.internal.org.jline.utils.NonBlockingPumpReader char[] java.util.concurrent.locks.ReentrantLock
StackMap stack: java.lang.Throwable
astore 5
31: aload 2
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
32: aload 5
athrow
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 33 0 this Ljdk/internal/org/jline/utils/NonBlockingPumpReader;
0 33 1 b [C
5 33 2 lock Ljava/util/concurrent/locks/ReentrantLock;
10 11 3 e Ljava/lang/InterruptedException;
18 30 3 r I
19 25 4 i I
Exception table:
from to target type
7 8 9 Class java.lang.InterruptedException
6 12 30 any
14 15 30 any
17 28 30 any
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
b
void write(char[], int, int);
descriptor: ([CII)V
flags: (0x0000)
Code:
stack=5, locals=7, args_size=4
start local 0 start local 1 start local 2 start local 3 0: iload 3
ifle 24
1: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.lock:Ljava/util/concurrent/locks/ReentrantLock;
astore 4
start local 4 2: aload 4
invokevirtual java.util.concurrent.locks.ReentrantLock.lock:()V
3: goto 18
4: StackMap locals: java.util.concurrent.locks.ReentrantLock
StackMap stack:
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.closed:Z
ifne 9
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.buffer:[C
arraylength
if_icmpne 9
5: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.notFull:Ljava/util/concurrent/locks/Condition;
invokeinterface java.util.concurrent.locks.Condition.await:()V
6: goto 9
StackMap locals:
StackMap stack: java.lang.InterruptedException
7: astore 5
start local 5 8: new java.io.InterruptedIOException
dup
invokespecial java.io.InterruptedIOException.<init>:()V
aload 5
invokevirtual java.io.InterruptedIOException.initCause:(Ljava/lang/Throwable;)Ljava/lang/Throwable;
checkcast java.io.IOException
athrow
end local 5 9: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.closed:Z
ifeq 16
10: new java.io.IOException
dup
ldc "Closed"
invokespecial java.io.IOException.<init>:(Ljava/lang/String;)V
athrow
11: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.buffer:[C
aload 0
dup
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.write:I
dup_x1
iconst_1
iadd
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.write:I
aload 1
iload 2
iinc 2 1
caload
castore
12: aload 0
dup
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
iconst_1
iadd
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
13: iinc 3 -1
14: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.write:I
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.buffer:[C
arraylength
if_icmpne 16
15: aload 0
iconst_0
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.write:I
16: StackMap locals:
StackMap stack:
iload 3
ifle 17
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.count:I
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.buffer:[C
arraylength
if_icmplt 11
17: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.notEmpty:Ljava/util/concurrent/locks/Condition;
invokeinterface java.util.concurrent.locks.Condition.signal:()V
18: StackMap locals:
StackMap stack:
iload 3
ifgt 4
19: goto 23
StackMap locals:
StackMap stack: java.lang.Throwable
20: astore 6
21: aload 4
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
22: aload 6
athrow
23: StackMap locals:
StackMap stack:
aload 4
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
end local 4 24: StackMap locals:
StackMap stack:
return
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 25 0 this Ljdk/internal/org/jline/utils/NonBlockingPumpReader;
0 25 1 cbuf [C
0 25 2 off I
0 25 3 len I
2 24 4 lock Ljava/util/concurrent/locks/ReentrantLock;
8 9 5 e Ljava/lang/InterruptedException;
Exception table:
from to target type
5 6 7 Class java.lang.InterruptedException
3 20 20 any
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
cbuf
off
len
public void close();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=3, args_size=1
start local 0 0: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.lock:Ljava/util/concurrent/locks/ReentrantLock;
astore 1
start local 1 1: aload 1
invokevirtual java.util.concurrent.locks.ReentrantLock.lock:()V
2: aload 0
iconst_1
putfield jdk.internal.org.jline.utils.NonBlockingPumpReader.closed:Z
3: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.notEmpty:Ljava/util/concurrent/locks/Condition;
invokeinterface java.util.concurrent.locks.Condition.signalAll:()V
4: aload 0
getfield jdk.internal.org.jline.utils.NonBlockingPumpReader.notFull:Ljava/util/concurrent/locks/Condition;
invokeinterface java.util.concurrent.locks.Condition.signalAll:()V
5: goto 9
StackMap locals: jdk.internal.org.jline.utils.NonBlockingPumpReader java.util.concurrent.locks.ReentrantLock
StackMap stack: java.lang.Throwable
6: astore 2
7: aload 1
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
8: aload 2
athrow
9: StackMap locals:
StackMap stack:
aload 1
invokevirtual java.util.concurrent.locks.ReentrantLock.unlock:()V
10: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 11 0 this Ljdk/internal/org/jline/utils/NonBlockingPumpReader;
1 11 1 lock Ljava/util/concurrent/locks/ReentrantLock;
Exception table:
from to target type
2 6 6 any
Exceptions:
throws java.io.IOException
}
SourceFile: "NonBlockingPumpReader.java"
NestMembers:
jdk.internal.org.jline.utils.NonBlockingPumpReader$NbpWriter
InnerClasses:
private NbpWriter = jdk.internal.org.jline.utils.NonBlockingPumpReader$NbpWriter of jdk.internal.org.jline.utils.NonBlockingPumpReader