public class sun.nio.ch.ChannelInputStream extends java.io.InputStream
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: sun.nio.ch.ChannelInputStream
super_class: java.io.InputStream
{
protected final java.nio.channels.ReadableByteChannel ch;
descriptor: Ljava/nio/channels/ReadableByteChannel;
flags: (0x0014) ACC_PROTECTED, ACC_FINAL
private java.nio.ByteBuffer bb;
descriptor: Ljava/nio/ByteBuffer;
flags: (0x0002) ACC_PRIVATE
private byte[] bs;
descriptor: [B
flags: (0x0002) ACC_PRIVATE
private byte[] b1;
descriptor: [B
flags: (0x0002) ACC_PRIVATE
public static int read(java.nio.channels.ReadableByteChannel, java.nio.ByteBuffer, boolean);
descriptor: (Ljava/nio/channels/ReadableByteChannel;Ljava/nio/ByteBuffer;Z)I
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=2, locals=7, args_size=3
start local 0 start local 1 start local 2 0: aload 0
instanceof java.nio.channels.SelectableChannel
ifeq 15
1: aload 0
checkcast java.nio.channels.SelectableChannel
astore 3
start local 3 2: aload 3
invokevirtual java.nio.channels.SelectableChannel.blockingLock:()Ljava/lang/Object;
dup
astore 4
monitorenter
3: aload 3
invokevirtual java.nio.channels.SelectableChannel.isBlocking:()Z
istore 5
start local 5 4: iload 5
ifne 6
5: new java.nio.channels.IllegalBlockingModeException
dup
invokespecial java.nio.channels.IllegalBlockingModeException.<init>:()V
athrow
6: StackMap locals: java.nio.channels.SelectableChannel java.lang.Object int
StackMap stack:
iload 5
iload 2
if_icmpeq 8
7: aload 3
iload 2
invokevirtual java.nio.channels.SelectableChannel.configureBlocking:(Z)Ljava/nio/channels/SelectableChannel;
pop
8: StackMap locals:
StackMap stack:
aload 0
aload 1
invokeinterface java.nio.channels.ReadableByteChannel.read:(Ljava/nio/ByteBuffer;)I
istore 6
start local 6 9: iload 5
iload 2
if_icmpeq 11
10: aload 3
iload 5
invokevirtual java.nio.channels.SelectableChannel.configureBlocking:(Z)Ljava/nio/channels/SelectableChannel;
pop
11: StackMap locals: int
StackMap stack:
iload 6
aload 4
monitorexit
12: ireturn
end local 6 end local 5 13: StackMap locals: java.nio.channels.ReadableByteChannel java.nio.ByteBuffer int java.nio.channels.SelectableChannel java.lang.Object
StackMap stack: java.lang.Throwable
aload 4
monitorexit
14: athrow
end local 3 15: StackMap locals:
StackMap stack:
aload 0
aload 1
invokeinterface java.nio.channels.ReadableByteChannel.read:(Ljava/nio/ByteBuffer;)I
ireturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 16 0 ch Ljava/nio/channels/ReadableByteChannel;
0 16 1 bb Ljava/nio/ByteBuffer;
0 16 2 block Z
2 15 3 sc Ljava/nio/channels/SelectableChannel;
4 13 5 bm Z
9 13 6 n I
Exception table:
from to target type
3 12 13 any
13 14 13 any
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
ch
bb
block
public void <init>(java.nio.channels.ReadableByteChannel);
descriptor: (Ljava/nio/channels/ReadableByteChannel;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
invokespecial java.io.InputStream.<init>:()V
1: aload 0
aconst_null
putfield sun.nio.ch.ChannelInputStream.bb:Ljava/nio/ByteBuffer;
2: aload 0
aconst_null
putfield sun.nio.ch.ChannelInputStream.bs:[B
3: aload 0
aconst_null
putfield sun.nio.ch.ChannelInputStream.b1:[B
4: aload 0
aload 1
putfield sun.nio.ch.ChannelInputStream.ch:Ljava/nio/channels/ReadableByteChannel;
5: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 6 0 this Lsun/nio/ch/ChannelInputStream;
0 6 1 ch Ljava/nio/channels/ReadableByteChannel;
MethodParameters:
Name Flags
ch
public synchronized int read();
descriptor: ()I
flags: (0x0021) ACC_PUBLIC, ACC_SYNCHRONIZED
Code:
stack=2, locals=2, args_size=1
start local 0 0: aload 0
getfield sun.nio.ch.ChannelInputStream.b1:[B
ifnonnull 2
1: aload 0
iconst_1
newarray 8
putfield sun.nio.ch.ChannelInputStream.b1:[B
2: StackMap locals:
StackMap stack:
aload 0
aload 0
getfield sun.nio.ch.ChannelInputStream.b1:[B
invokevirtual sun.nio.ch.ChannelInputStream.read:([B)I
istore 1
start local 1 3: iload 1
iconst_1
if_icmpne 5
4: aload 0
getfield sun.nio.ch.ChannelInputStream.b1:[B
iconst_0
baload
sipush 255
iand
ireturn
5: StackMap locals: int
StackMap stack:
iconst_m1
ireturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 6 0 this Lsun/nio/ch/ChannelInputStream;
3 6 1 n I
Exceptions:
throws java.io.IOException
public synchronized int read(byte[], int, int);
descriptor: ([BII)I
flags: (0x0021) ACC_PUBLIC, ACC_SYNCHRONIZED
Code:
stack=3, locals=5, args_size=4
start local 0 start local 1 start local 2 start local 3 0: iload 2
iload 3
aload 1
arraylength
invokestatic java.util.Objects.checkFromIndexSize:(III)I
pop
1: iload 3
ifne 3
2: iconst_0
ireturn
3: StackMap locals:
StackMap stack:
aload 0
getfield sun.nio.ch.ChannelInputStream.bs:[B
aload 1
if_acmpne 5
4: aload 0
getfield sun.nio.ch.ChannelInputStream.bb:Ljava/nio/ByteBuffer;
goto 6
5: StackMap locals:
StackMap stack:
aload 1
invokestatic java.nio.ByteBuffer.wrap:([B)Ljava/nio/ByteBuffer;
6: StackMap locals:
StackMap stack: java.nio.ByteBuffer
astore 4
start local 4 7: aload 4
iload 2
iload 3
iadd
aload 4
invokevirtual java.nio.ByteBuffer.capacity:()I
invokestatic java.lang.Math.min:(II)I
invokevirtual java.nio.ByteBuffer.limit:(I)Ljava/nio/ByteBuffer;
pop
8: aload 4
iload 2
invokevirtual java.nio.ByteBuffer.position:(I)Ljava/nio/ByteBuffer;
pop
9: aload 0
aload 4
putfield sun.nio.ch.ChannelInputStream.bb:Ljava/nio/ByteBuffer;
10: aload 0
aload 1
putfield sun.nio.ch.ChannelInputStream.bs:[B
11: aload 0
aload 4
invokevirtual sun.nio.ch.ChannelInputStream.read:(Ljava/nio/ByteBuffer;)I
ireturn
end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 12 0 this Lsun/nio/ch/ChannelInputStream;
0 12 1 bs [B
0 12 2 off I
0 12 3 len I
7 12 4 bb Ljava/nio/ByteBuffer;
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
bs
off
len
protected int read(java.nio.ByteBuffer);
descriptor: (Ljava/nio/ByteBuffer;)I
flags: (0x0004) ACC_PROTECTED
Code:
stack=3, locals=2, args_size=2
start local 0 start local 1 0: aload 0
getfield sun.nio.ch.ChannelInputStream.ch:Ljava/nio/channels/ReadableByteChannel;
aload 1
iconst_1
invokestatic sun.nio.ch.ChannelInputStream.read:(Ljava/nio/channels/ReadableByteChannel;Ljava/nio/ByteBuffer;Z)I
ireturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lsun/nio/ch/ChannelInputStream;
0 1 1 bb Ljava/nio/ByteBuffer;
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
bb
public int available();
descriptor: ()I
flags: (0x0001) ACC_PUBLIC
Code:
stack=6, locals=4, args_size=1
start local 0 0: aload 0
getfield sun.nio.ch.ChannelInputStream.ch:Ljava/nio/channels/ReadableByteChannel;
instanceof java.nio.channels.SeekableByteChannel
ifeq 6
1: aload 0
getfield sun.nio.ch.ChannelInputStream.ch:Ljava/nio/channels/ReadableByteChannel;
checkcast java.nio.channels.SeekableByteChannel
astore 1
start local 1 2: lconst_0
aload 1
invokeinterface java.nio.channels.SeekableByteChannel.size:()J
aload 1
invokeinterface java.nio.channels.SeekableByteChannel.position:()J
lsub
invokestatic java.lang.Math.max:(JJ)J
lstore 2
start local 2 3: lload 2
ldc 2147483647
lcmp
ifle 4
ldc 2147483647
goto 5
StackMap locals: java.nio.channels.SeekableByteChannel long
StackMap stack:
4: lload 2
l2i
StackMap locals:
StackMap stack: int
5: ireturn
end local 2 end local 1 6: StackMap locals:
StackMap stack:
iconst_0
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 this Lsun/nio/ch/ChannelInputStream;
2 6 1 sbc Ljava/nio/channels/SeekableByteChannel;
3 6 2 rem J
Exceptions:
throws java.io.IOException
public synchronized long skip(long);
descriptor: (J)J
flags: (0x0021) ACC_PUBLIC, ACC_SYNCHRONIZED
Code:
stack=4, locals=10, args_size=2
start local 0 start local 1 0: aload 0
getfield sun.nio.ch.ChannelInputStream.ch:Ljava/nio/channels/ReadableByteChannel;
instanceof java.nio.channels.SeekableByteChannel
ifeq 12
1: aload 0
getfield sun.nio.ch.ChannelInputStream.ch:Ljava/nio/channels/ReadableByteChannel;
checkcast java.nio.channels.SeekableByteChannel
astore 3
start local 3 2: aload 3
invokeinterface java.nio.channels.SeekableByteChannel.position:()J
lstore 4
start local 4 3: lload 1
lconst_0
lcmp
ifle 9
4: lload 4
lload 1
ladd
lstore 6
start local 6 5: aload 3
invokeinterface java.nio.channels.SeekableByteChannel.size:()J
lstore 8
start local 8 6: lload 6
lconst_0
lcmp
iflt 7
lload 6
lload 8
lcmp
ifle 10
7: StackMap locals: sun.nio.ch.ChannelInputStream long java.nio.channels.SeekableByteChannel long long long
StackMap stack:
lload 8
lstore 6
end local 8 8: goto 10
end local 6 9: StackMap locals:
StackMap stack:
lload 4
lload 1
ladd
lconst_0
invokestatic java.lang.Long.max:(JJ)J
lstore 6
start local 6 10: StackMap locals: long
StackMap stack:
aload 3
lload 6
invokeinterface java.nio.channels.SeekableByteChannel.position:(J)Ljava/nio/channels/SeekableByteChannel;
pop
11: lload 6
lload 4
lsub
lreturn
end local 6 end local 4 end local 3 12: StackMap locals:
StackMap stack:
aload 0
lload 1
invokespecial java.io.InputStream.skip:(J)J
lreturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 13 0 this Lsun/nio/ch/ChannelInputStream;
0 13 1 n J
2 12 3 sbc Ljava/nio/channels/SeekableByteChannel;
3 12 4 pos J
5 9 6 newPos J
10 12 6 newPos J
6 8 8 size J
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
n
public void close();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield sun.nio.ch.ChannelInputStream.ch:Ljava/nio/channels/ReadableByteChannel;
invokeinterface java.nio.channels.ReadableByteChannel.close:()V
1: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lsun/nio/ch/ChannelInputStream;
Exceptions:
throws java.io.IOException
}
SourceFile: "ChannelInputStream.java"