public class org.apache.lucene.store.RAMOutputStream extends org.apache.lucene.store.IndexOutput implements org.apache.lucene.util.Accountable
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: org.apache.lucene.store.RAMOutputStream
super_class: org.apache.lucene.store.IndexOutput
{
static final int BUFFER_SIZE;
descriptor: I
flags: (0x0018) ACC_STATIC, ACC_FINAL
ConstantValue: 1024
private final org.apache.lucene.store.RAMFile file;
descriptor: Lorg/apache/lucene/store/RAMFile;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
private byte[] currentBuffer;
descriptor: [B
flags: (0x0002) ACC_PRIVATE
private int currentBufferIndex;
descriptor: I
flags: (0x0002) ACC_PRIVATE
private int bufferPosition;
descriptor: I
flags: (0x0002) ACC_PRIVATE
private long bufferStart;
descriptor: J
flags: (0x0002) ACC_PRIVATE
private int bufferLength;
descriptor: I
flags: (0x0002) ACC_PRIVATE
private final java.util.zip.Checksum crc;
descriptor: Ljava/util/zip/Checksum;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
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 Lorg/apache/lucene/store/RAMOutputStream;
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 org.apache.lucene.store.RAMOutputStream.$assertionsDisabled:Z
3: return
LocalVariableTable:
Start End Slot Name Signature
public void <init>();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=4, locals=1, args_size=1
start local 0 0: aload 0
ldc "noname"
new org.apache.lucene.store.RAMFile
dup
invokespecial org.apache.lucene.store.RAMFile.<init>:()V
iconst_0
invokespecial org.apache.lucene.store.RAMOutputStream.<init>:(Ljava/lang/String;Lorg/apache/lucene/store/RAMFile;Z)V
1: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/apache/lucene/store/RAMOutputStream;
public void <init>(org.apache.lucene.store.RAMFile, boolean);
descriptor: (Lorg/apache/lucene/store/RAMFile;Z)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=4, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
ldc "noname"
aload 1
iload 2
invokespecial org.apache.lucene.store.RAMOutputStream.<init>:(Ljava/lang/String;Lorg/apache/lucene/store/RAMFile;Z)V
1: return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/apache/lucene/store/RAMOutputStream;
0 2 1 f Lorg/apache/lucene/store/RAMFile;
0 2 2 checksum Z
MethodParameters:
Name Flags
f
checksum
public void <init>(java.lang.String, org.apache.lucene.store.RAMFile, boolean);
descriptor: (Ljava/lang/String;Lorg/apache/lucene/store/RAMFile;Z)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=4, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
new java.lang.StringBuilder
dup
ldc "RAMOutputStream(name=\""
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 1
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
ldc "\")"
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
aload 1
invokespecial org.apache.lucene.store.IndexOutput.<init>:(Ljava/lang/String;Ljava/lang/String;)V
1: aload 0
aload 2
putfield org.apache.lucene.store.RAMOutputStream.file:Lorg/apache/lucene/store/RAMFile;
2: aload 0
iconst_m1
putfield org.apache.lucene.store.RAMOutputStream.currentBufferIndex:I
3: aload 0
aconst_null
putfield org.apache.lucene.store.RAMOutputStream.currentBuffer:[B
4: iload 3
ifeq 7
5: aload 0
new org.apache.lucene.store.BufferedChecksum
dup
new java.util.zip.CRC32
dup
invokespecial java.util.zip.CRC32.<init>:()V
invokespecial org.apache.lucene.store.BufferedChecksum.<init>:(Ljava/util/zip/Checksum;)V
putfield org.apache.lucene.store.RAMOutputStream.crc:Ljava/util/zip/Checksum;
6: goto 8
7: StackMap locals: org.apache.lucene.store.RAMOutputStream java.lang.String org.apache.lucene.store.RAMFile int
StackMap stack:
aload 0
aconst_null
putfield org.apache.lucene.store.RAMOutputStream.crc:Ljava/util/zip/Checksum;
8: StackMap locals:
StackMap stack:
return
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 9 0 this Lorg/apache/lucene/store/RAMOutputStream;
0 9 1 name Ljava/lang/String;
0 9 2 f Lorg/apache/lucene/store/RAMFile;
0 9 3 checksum Z
MethodParameters:
Name Flags
name
f
checksum
public void writeTo(org.apache.lucene.store.DataOutput);
descriptor: (Lorg/apache/lucene/store/DataOutput;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=4, locals=10, args_size=2
start local 0 start local 1 0: aload 0
invokevirtual org.apache.lucene.store.RAMOutputStream.flush:()V
1: aload 0
getfield org.apache.lucene.store.RAMOutputStream.file:Lorg/apache/lucene/store/RAMFile;
getfield org.apache.lucene.store.RAMFile.length:J
lstore 2
start local 2 2: lconst_0
lstore 4
start local 4 3: iconst_0
istore 6
start local 6 4: goto 11
5: StackMap locals: long long int
StackMap stack:
sipush 1024
istore 7
start local 7 6: lload 4
iload 7
i2l
ladd
lstore 8
start local 8 7: lload 8
lload 2
lcmp
ifle 9
8: lload 2
lload 4
lsub
l2i
istore 7
9: StackMap locals: int long
StackMap stack:
aload 1
aload 0
getfield org.apache.lucene.store.RAMOutputStream.file:Lorg/apache/lucene/store/RAMFile;
iload 6
iinc 6 1
invokevirtual org.apache.lucene.store.RAMFile.getBuffer:(I)[B
iload 7
invokevirtual org.apache.lucene.store.DataOutput.writeBytes:([BI)V
10: lload 8
lstore 4
end local 8 end local 7 11: StackMap locals:
StackMap stack:
lload 4
lload 2
lcmp
iflt 5
12: return
end local 6 end local 4 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 13 0 this Lorg/apache/lucene/store/RAMOutputStream;
0 13 1 out Lorg/apache/lucene/store/DataOutput;
2 13 2 end J
3 13 4 pos J
4 13 6 buffer I
6 11 7 length I
7 11 8 nextPos J
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
out
public void writeTo(byte[], int);
descriptor: ([BI)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=12, args_size=3
start local 0 start local 1 start local 2 0: aload 0
invokevirtual org.apache.lucene.store.RAMOutputStream.flush:()V
1: aload 0
getfield org.apache.lucene.store.RAMOutputStream.file:Lorg/apache/lucene/store/RAMFile;
getfield org.apache.lucene.store.RAMFile.length:J
lstore 3
start local 3 2: lconst_0
lstore 5
start local 5 3: iconst_0
istore 7
start local 7 4: iload 2
istore 8
start local 8 5: goto 13
6: StackMap locals: org.apache.lucene.store.RAMOutputStream byte[] int long long int int
StackMap stack:
sipush 1024
istore 9
start local 9 7: lload 5
iload 9
i2l
ladd
lstore 10
start local 10 8: lload 10
lload 3
lcmp
ifle 10
9: lload 3
lload 5
lsub
l2i
istore 9
10: StackMap locals: int long
StackMap stack:
aload 0
getfield org.apache.lucene.store.RAMOutputStream.file:Lorg/apache/lucene/store/RAMFile;
iload 7
iinc 7 1
invokevirtual org.apache.lucene.store.RAMFile.getBuffer:(I)[B
iconst_0
aload 1
iload 8
iload 9
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
11: iload 8
iload 9
iadd
istore 8
12: lload 10
lstore 5
end local 10 end local 9 13: StackMap locals:
StackMap stack:
lload 5
lload 3
lcmp
iflt 6
14: return
end local 8 end local 7 end local 5 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 15 0 this Lorg/apache/lucene/store/RAMOutputStream;
0 15 1 bytes [B
0 15 2 offset I
2 15 3 end J
3 15 5 pos J
4 15 7 buffer I
5 15 8 bytesUpto I
7 13 9 length I
8 13 10 nextPos J
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
bytes
offset
public void reset();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=1, args_size=1
start local 0 0: aload 0
aconst_null
putfield org.apache.lucene.store.RAMOutputStream.currentBuffer:[B
1: aload 0
iconst_m1
putfield org.apache.lucene.store.RAMOutputStream.currentBufferIndex:I
2: aload 0
iconst_0
putfield org.apache.lucene.store.RAMOutputStream.bufferPosition:I
3: aload 0
lconst_0
putfield org.apache.lucene.store.RAMOutputStream.bufferStart:J
4: aload 0
iconst_0
putfield org.apache.lucene.store.RAMOutputStream.bufferLength:I
5: aload 0
getfield org.apache.lucene.store.RAMOutputStream.file:Lorg/apache/lucene/store/RAMFile;
lconst_0
invokevirtual org.apache.lucene.store.RAMFile.setLength:(J)V
6: aload 0
getfield org.apache.lucene.store.RAMOutputStream.crc:Ljava/util/zip/Checksum;
ifnull 8
7: aload 0
getfield org.apache.lucene.store.RAMOutputStream.crc:Ljava/util/zip/Checksum;
invokeinterface java.util.zip.Checksum.reset:()V
8: StackMap locals:
StackMap stack:
return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 9 0 this Lorg/apache/lucene/store/RAMOutputStream;
public void close();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
invokevirtual org.apache.lucene.store.RAMOutputStream.flush:()V
1: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/apache/lucene/store/RAMOutputStream;
Exceptions:
throws java.io.IOException
public void writeByte(byte);
descriptor: (B)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=2, args_size=2
start local 0 start local 1 0: aload 0
getfield org.apache.lucene.store.RAMOutputStream.bufferPosition:I
aload 0
getfield org.apache.lucene.store.RAMOutputStream.bufferLength:I
if_icmpne 3
1: aload 0
dup
getfield org.apache.lucene.store.RAMOutputStream.currentBufferIndex:I
iconst_1
iadd
putfield org.apache.lucene.store.RAMOutputStream.currentBufferIndex:I
2: aload 0
invokevirtual org.apache.lucene.store.RAMOutputStream.switchCurrentBuffer:()V
3: StackMap locals:
StackMap stack:
aload 0
getfield org.apache.lucene.store.RAMOutputStream.crc:Ljava/util/zip/Checksum;
ifnull 5
4: aload 0
getfield org.apache.lucene.store.RAMOutputStream.crc:Ljava/util/zip/Checksum;
iload 1
invokeinterface java.util.zip.Checksum.update:(I)V
5: StackMap locals:
StackMap stack:
aload 0
getfield org.apache.lucene.store.RAMOutputStream.currentBuffer:[B
aload 0
dup
getfield org.apache.lucene.store.RAMOutputStream.bufferPosition:I
dup_x1
iconst_1
iadd
putfield org.apache.lucene.store.RAMOutputStream.bufferPosition:I
iload 1
bastore
6: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 this Lorg/apache/lucene/store/RAMOutputStream;
0 7 1 b B
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
b
public void writeBytes(byte[], int, int);
descriptor: ([BII)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=6, args_size=4
start local 0 start local 1 start local 2 start local 3 0: getstatic org.apache.lucene.store.RAMOutputStream.$assertionsDisabled:Z
ifne 1
aload 1
ifnonnull 1
new java.lang.AssertionError
dup
invokespecial java.lang.AssertionError.<init>:()V
athrow
1: StackMap locals:
StackMap stack:
aload 0
getfield org.apache.lucene.store.RAMOutputStream.crc:Ljava/util/zip/Checksum;
ifnull 15
2: aload 0
getfield org.apache.lucene.store.RAMOutputStream.crc:Ljava/util/zip/Checksum;
aload 1
iload 2
iload 3
invokeinterface java.util.zip.Checksum.update:([BII)V
3: goto 15
4: StackMap locals:
StackMap stack:
aload 0
getfield org.apache.lucene.store.RAMOutputStream.bufferPosition:I
aload 0
getfield org.apache.lucene.store.RAMOutputStream.bufferLength:I
if_icmpne 7
5: aload 0
dup
getfield org.apache.lucene.store.RAMOutputStream.currentBufferIndex:I
iconst_1
iadd
putfield org.apache.lucene.store.RAMOutputStream.currentBufferIndex:I
6: aload 0
invokevirtual org.apache.lucene.store.RAMOutputStream.switchCurrentBuffer:()V
7: StackMap locals:
StackMap stack:
aload 0
getfield org.apache.lucene.store.RAMOutputStream.currentBuffer:[B
arraylength
aload 0
getfield org.apache.lucene.store.RAMOutputStream.bufferPosition:I
isub
istore 4
start local 4 8: iload 3
iload 4
if_icmpge 9
iload 3
goto 10
StackMap locals: int
StackMap stack:
9: iload 4
StackMap locals:
StackMap stack: int
10: istore 5
start local 5 11: aload 1
iload 2
aload 0
getfield org.apache.lucene.store.RAMOutputStream.currentBuffer:[B
aload 0
getfield org.apache.lucene.store.RAMOutputStream.bufferPosition:I
iload 5
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
12: iload 2
iload 5
iadd
istore 2
13: iload 3
iload 5
isub
istore 3
14: aload 0
dup
getfield org.apache.lucene.store.RAMOutputStream.bufferPosition:I
iload 5
iadd
putfield org.apache.lucene.store.RAMOutputStream.bufferPosition:I
end local 5 end local 4 15: StackMap locals:
StackMap stack:
iload 3
ifgt 4
16: return
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 17 0 this Lorg/apache/lucene/store/RAMOutputStream;
0 17 1 b [B
0 17 2 offset I
0 17 3 len I
8 15 4 remainInBuffer I
11 15 5 bytesToCopy I
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
b
offset
len
private final void switchCurrentBuffer();
descriptor: ()V
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
Code:
stack=5, locals=1, args_size=1
start local 0 0: aload 0
getfield org.apache.lucene.store.RAMOutputStream.currentBufferIndex:I
aload 0
getfield org.apache.lucene.store.RAMOutputStream.file:Lorg/apache/lucene/store/RAMFile;
invokevirtual org.apache.lucene.store.RAMFile.numBuffers:()I
if_icmpne 3
1: aload 0
aload 0
getfield org.apache.lucene.store.RAMOutputStream.file:Lorg/apache/lucene/store/RAMFile;
sipush 1024
invokevirtual org.apache.lucene.store.RAMFile.addBuffer:(I)[B
putfield org.apache.lucene.store.RAMOutputStream.currentBuffer:[B
2: goto 4
3: StackMap locals:
StackMap stack:
aload 0
aload 0
getfield org.apache.lucene.store.RAMOutputStream.file:Lorg/apache/lucene/store/RAMFile;
aload 0
getfield org.apache.lucene.store.RAMOutputStream.currentBufferIndex:I
invokevirtual org.apache.lucene.store.RAMFile.getBuffer:(I)[B
putfield org.apache.lucene.store.RAMOutputStream.currentBuffer:[B
4: StackMap locals:
StackMap stack:
aload 0
iconst_0
putfield org.apache.lucene.store.RAMOutputStream.bufferPosition:I
5: aload 0
ldc 1024
aload 0
getfield org.apache.lucene.store.RAMOutputStream.currentBufferIndex:I
i2l
lmul
putfield org.apache.lucene.store.RAMOutputStream.bufferStart:J
6: aload 0
aload 0
getfield org.apache.lucene.store.RAMOutputStream.currentBuffer:[B
arraylength
putfield org.apache.lucene.store.RAMOutputStream.bufferLength:I
7: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 8 0 this Lorg/apache/lucene/store/RAMOutputStream;
private void setFileLength();
descriptor: ()V
flags: (0x0002) ACC_PRIVATE
Code:
stack=4, locals=3, args_size=1
start local 0 0: aload 0
getfield org.apache.lucene.store.RAMOutputStream.bufferStart:J
aload 0
getfield org.apache.lucene.store.RAMOutputStream.bufferPosition:I
i2l
ladd
lstore 1
start local 1 1: lload 1
aload 0
getfield org.apache.lucene.store.RAMOutputStream.file:Lorg/apache/lucene/store/RAMFile;
getfield org.apache.lucene.store.RAMFile.length:J
lcmp
ifle 3
2: aload 0
getfield org.apache.lucene.store.RAMOutputStream.file:Lorg/apache/lucene/store/RAMFile;
lload 1
invokevirtual org.apache.lucene.store.RAMFile.setLength:(J)V
3: StackMap locals: long
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 this Lorg/apache/lucene/store/RAMOutputStream;
1 4 1 pointer J
protected void flush();
descriptor: ()V
flags: (0x0004) ACC_PROTECTED
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
invokevirtual org.apache.lucene.store.RAMOutputStream.setFileLength:()V
1: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/apache/lucene/store/RAMOutputStream;
Exceptions:
throws java.io.IOException
public long getFilePointer();
descriptor: ()J
flags: (0x0001) ACC_PUBLIC
Code:
stack=4, locals=1, args_size=1
start local 0 0: aload 0
getfield org.apache.lucene.store.RAMOutputStream.currentBufferIndex:I
ifge 1
lconst_0
goto 2
StackMap locals:
StackMap stack:
1: aload 0
getfield org.apache.lucene.store.RAMOutputStream.bufferStart:J
aload 0
getfield org.apache.lucene.store.RAMOutputStream.bufferPosition:I
i2l
ladd
StackMap locals:
StackMap stack: long
2: lreturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lorg/apache/lucene/store/RAMOutputStream;
public long ramBytesUsed();
descriptor: ()J
flags: (0x0001) ACC_PUBLIC
Code:
stack=4, locals=1, args_size=1
start local 0 0: aload 0
getfield org.apache.lucene.store.RAMOutputStream.file:Lorg/apache/lucene/store/RAMFile;
invokevirtual org.apache.lucene.store.RAMFile.numBuffers:()I
i2l
ldc 1024
lmul
lreturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/lucene/store/RAMOutputStream;
public java.util.Collection<org.apache.lucene.util.Accountable> getChildResources();
descriptor: ()Ljava/util/Collection;
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: ldc "file"
aload 0
getfield org.apache.lucene.store.RAMOutputStream.file:Lorg/apache/lucene/store/RAMFile;
invokestatic org.apache.lucene.util.Accountables.namedAccountable:(Ljava/lang/String;Lorg/apache/lucene/util/Accountable;)Lorg/apache/lucene/util/Accountable;
invokestatic java.util.Collections.singleton:(Ljava/lang/Object;)Ljava/util/Set;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/lucene/store/RAMOutputStream;
Signature: ()Ljava/util/Collection<Lorg/apache/lucene/util/Accountable;>;
public long getChecksum();
descriptor: ()J
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=1, args_size=1
start local 0 0: aload 0
getfield org.apache.lucene.store.RAMOutputStream.crc:Ljava/util/zip/Checksum;
ifnonnull 2
1: new java.lang.IllegalStateException
dup
ldc "internal RAMOutputStream created with checksum disabled"
invokespecial java.lang.IllegalStateException.<init>:(Ljava/lang/String;)V
athrow
2: StackMap locals:
StackMap stack:
aload 0
getfield org.apache.lucene.store.RAMOutputStream.crc:Ljava/util/zip/Checksum;
invokeinterface java.util.zip.Checksum.getValue:()J
lreturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lorg/apache/lucene/store/RAMOutputStream;
Exceptions:
throws java.io.IOException
}
SourceFile: "RAMOutputStream.java"
RuntimeVisibleAnnotations:
java.lang.Deprecated()