public class org.apache.cassandra.io.util.DataOutputBuffer extends org.apache.cassandra.io.util.BufferedDataOutputStreamPlus
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: org.apache.cassandra.io.util.DataOutputBuffer
super_class: org.apache.cassandra.io.util.BufferedDataOutputStreamPlus
{
static final long DOUBLING_THRESHOLD;
descriptor: J
flags: (0x0018) ACC_STATIC, ACC_FINAL
private static final int MAX_RECYCLE_BUFFER_SIZE;
descriptor: I
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
private static final int DEFAULT_INITIAL_BUFFER_SIZE;
descriptor: I
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: 128
public static final io.netty.util.concurrent.FastThreadLocal<org.apache.cassandra.io.util.DataOutputBuffer> scratchBuffer;
descriptor: Lio/netty/util/concurrent/FastThreadLocal;
flags: (0x0019) ACC_PUBLIC, ACC_STATIC, ACC_FINAL
Signature: Lio/netty/util/concurrent/FastThreadLocal<Lorg/apache/cassandra/io/util/DataOutputBuffer;>;
static final int MAX_ARRAY_SIZE;
descriptor: I
flags: (0x0018) ACC_STATIC, ACC_FINAL
ConstantValue: 2147483639
RuntimeInvisibleAnnotations:
com.google.common.annotations.VisibleForTesting()
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=3, locals=0, args_size=0
0: ldc Lorg/apache/cassandra/io/util/DataOutputBuffer;
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.cassandra.io.util.DataOutputBuffer.$assertionsDisabled:Z
3: ldc "cassandra.DOB_DOUBLING_THRESHOLD_MB"
ldc 64
invokestatic java.lang.Long.getLong:(Ljava/lang/String;J)Ljava/lang/Long;
invokevirtual java.lang.Long.longValue:()J
putstatic org.apache.cassandra.io.util.DataOutputBuffer.DOUBLING_THRESHOLD:J
4: ldc "cassandra.dob_max_recycle_bytes"
ldc 1048576
invokestatic java.lang.Integer.getInteger:(Ljava/lang/String;I)Ljava/lang/Integer;
invokevirtual java.lang.Integer.intValue:()I
putstatic org.apache.cassandra.io.util.DataOutputBuffer.MAX_RECYCLE_BUFFER_SIZE:I
5: new org.apache.cassandra.io.util.DataOutputBuffer$1
dup
invokespecial org.apache.cassandra.io.util.DataOutputBuffer$1.<init>:()V
putstatic org.apache.cassandra.io.util.DataOutputBuffer.scratchBuffer:Lio/netty/util/concurrent/FastThreadLocal;
6: return
LocalVariableTable:
Start End Slot Name Signature
public void <init>();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
sipush 128
invokespecial org.apache.cassandra.io.util.DataOutputBuffer.<init>:(I)V
1: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
public void <init>(int);
descriptor: (I)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
iload 1
invokestatic java.nio.ByteBuffer.allocate:(I)Ljava/nio/ByteBuffer;
invokespecial org.apache.cassandra.io.util.BufferedDataOutputStreamPlus.<init>:(Ljava/nio/ByteBuffer;)V
1: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
0 2 1 size I
MethodParameters:
Name Flags
size
public void <init>(java.nio.ByteBuffer);
descriptor: (Ljava/nio/ByteBuffer;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
aload 1
invokespecial org.apache.cassandra.io.util.BufferedDataOutputStreamPlus.<init>:(Ljava/nio/ByteBuffer;)V
1: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
0 2 1 buffer Ljava/nio/ByteBuffer;
MethodParameters:
Name Flags
buffer
public void flush();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: new java.lang.UnsupportedOperationException
dup
invokespecial java.lang.UnsupportedOperationException.<init>:()V
athrow
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
Exceptions:
throws java.io.IOException
static int saturatedArraySizeCast(long);
descriptor: (J)I
flags: (0x0008) ACC_STATIC
Code:
stack=4, locals=2, args_size=1
start local 0 0: lload 0
lconst_0
lcmp
iflt 1
iconst_1
goto 2
StackMap locals:
StackMap stack:
1: iconst_0
StackMap locals:
StackMap stack: int
2: invokestatic com.google.common.base.Preconditions.checkArgument:(Z)V
3: ldc 2147483639
lload 0
invokestatic java.lang.Math.min:(JJ)J
l2i
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 size J
RuntimeInvisibleAnnotations:
com.google.common.annotations.VisibleForTesting()
RuntimeInvisibleTypeAnnotations:
METHOD_RETURN
com.google.common.annotations.VisibleForTesting()
MethodParameters:
Name Flags
size
static int checkedArraySizeCast(long);
descriptor: (J)I
flags: (0x0008) ACC_STATIC
Code:
stack=4, locals=2, args_size=1
start local 0 0: lload 0
lconst_0
lcmp
iflt 1
iconst_1
goto 2
StackMap locals:
StackMap stack:
1: iconst_0
StackMap locals:
StackMap stack: int
2: invokestatic com.google.common.base.Preconditions.checkArgument:(Z)V
3: lload 0
ldc 2147483639
lcmp
ifgt 4
iconst_1
goto 5
StackMap locals:
StackMap stack:
4: iconst_0
StackMap locals:
StackMap stack: int
5: invokestatic com.google.common.base.Preconditions.checkArgument:(Z)V
6: lload 0
l2i
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 size J
RuntimeInvisibleAnnotations:
com.google.common.annotations.VisibleForTesting()
RuntimeInvisibleTypeAnnotations:
METHOD_RETURN
com.google.common.annotations.VisibleForTesting()
MethodParameters:
Name Flags
size
protected void doFlush(int);
descriptor: (I)V
flags: (0x0004) ACC_PROTECTED
Code:
stack=3, locals=2, args_size=2
start local 0 start local 1 0: aload 0
iload 1
i2l
invokevirtual org.apache.cassandra.io.util.DataOutputBuffer.expandToFit:(J)V
1: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
0 2 1 count I
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
count
long capacity();
descriptor: ()J
flags: (0x0000)
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
getfield org.apache.cassandra.io.util.DataOutputBuffer.buffer:Ljava/nio/ByteBuffer;
invokevirtual java.nio.ByteBuffer.capacity:()I
i2l
lreturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
RuntimeInvisibleAnnotations:
com.google.common.annotations.VisibleForTesting()
RuntimeInvisibleTypeAnnotations:
METHOD_RETURN
com.google.common.annotations.VisibleForTesting()
long validateReallocation(long);
descriptor: (J)J
flags: (0x0000)
Code:
stack=4, locals=4, args_size=2
start local 0 start local 1 0: lload 1
invokestatic org.apache.cassandra.io.util.DataOutputBuffer.saturatedArraySizeCast:(J)I
istore 3
start local 3 1: iload 3
i2l
aload 0
invokevirtual org.apache.cassandra.io.util.DataOutputBuffer.capacity:()J
lcmp
ifgt 3
2: new java.lang.RuntimeException
dup
invokespecial java.lang.RuntimeException.<init>:()V
athrow
3: StackMap locals: int
StackMap stack:
iload 3
i2l
lreturn
end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
0 4 1 newSize J
1 4 3 saturatedSize I
RuntimeInvisibleAnnotations:
com.google.common.annotations.VisibleForTesting()
RuntimeInvisibleTypeAnnotations:
METHOD_RETURN
com.google.common.annotations.VisibleForTesting()
MethodParameters:
Name Flags
newSize
long calculateNewSize(long);
descriptor: (J)J
flags: (0x0000)
Code:
stack=6, locals=7, args_size=2
start local 0 start local 1 0: aload 0
invokevirtual org.apache.cassandra.io.util.DataOutputBuffer.capacity:()J
lstore 3
start local 3 1: lload 3
lload 1
ladd
lstore 5
start local 5 2: lload 3
ldc 1048576
getstatic org.apache.cassandra.io.util.DataOutputBuffer.DOUBLING_THRESHOLD:J
lmul
lcmp
ifle 4
3: lload 3
ldc 3
lmul
ldc 2
ldiv
lload 5
invokestatic java.lang.Math.max:(JJ)J
lstore 5
goto 5
4: StackMap locals: long long
StackMap stack:
lload 3
ldc 2
lmul
lload 5
invokestatic java.lang.Math.max:(JJ)J
lstore 5
5: StackMap locals:
StackMap stack:
aload 0
lload 5
invokevirtual org.apache.cassandra.io.util.DataOutputBuffer.validateReallocation:(J)J
lreturn
end local 5 end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 6 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
0 6 1 count J
1 6 3 capacity J
2 6 5 newSize J
RuntimeInvisibleAnnotations:
com.google.common.annotations.VisibleForTesting()
RuntimeInvisibleTypeAnnotations:
METHOD_RETURN
com.google.common.annotations.VisibleForTesting()
MethodParameters:
Name Flags
count
protected void expandToFit(long);
descriptor: (J)V
flags: (0x0004) ACC_PROTECTED
Code:
stack=4, locals=4, args_size=2
start local 0 start local 1 0: lload 1
lconst_0
lcmp
ifgt 2
1: return
2: StackMap locals:
StackMap stack:
aload 0
lload 1
invokevirtual org.apache.cassandra.io.util.DataOutputBuffer.calculateNewSize:(J)J
invokestatic org.apache.cassandra.io.util.DataOutputBuffer.checkedArraySizeCast:(J)I
invokestatic java.nio.ByteBuffer.allocate:(I)Ljava/nio/ByteBuffer;
astore 3
start local 3 3: aload 0
getfield org.apache.cassandra.io.util.DataOutputBuffer.buffer:Ljava/nio/ByteBuffer;
invokevirtual java.nio.ByteBuffer.flip:()Ljava/nio/Buffer;
pop
4: aload 3
aload 0
getfield org.apache.cassandra.io.util.DataOutputBuffer.buffer:Ljava/nio/ByteBuffer;
invokevirtual java.nio.ByteBuffer.put:(Ljava/nio/ByteBuffer;)Ljava/nio/ByteBuffer;
pop
5: aload 0
aload 3
putfield org.apache.cassandra.io.util.DataOutputBuffer.buffer:Ljava/nio/ByteBuffer;
6: return
end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
0 7 1 count J
3 7 3 newBuffer Ljava/nio/ByteBuffer;
MethodParameters:
Name Flags
count
protected java.nio.channels.WritableByteChannel newDefaultChannel();
descriptor: ()Ljava/nio/channels/WritableByteChannel;
flags: (0x0004) ACC_PROTECTED
Code:
stack=3, locals=1, args_size=1
start local 0 0: new org.apache.cassandra.io.util.DataOutputBuffer$GrowingChannel
dup
aload 0
invokespecial org.apache.cassandra.io.util.DataOutputBuffer$GrowingChannel.<init>:(Lorg/apache/cassandra/io/util/DataOutputBuffer;)V
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
public void clear();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield org.apache.cassandra.io.util.DataOutputBuffer.buffer:Ljava/nio/ByteBuffer;
invokevirtual java.nio.ByteBuffer.clear:()Ljava/nio/Buffer;
pop
1: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
public void close();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=0, locals=1, args_size=1
start local 0 0: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
public java.nio.ByteBuffer buffer();
descriptor: ()Ljava/nio/ByteBuffer;
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
iconst_1
invokevirtual org.apache.cassandra.io.util.DataOutputBuffer.buffer:(Z)Ljava/nio/ByteBuffer;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
public java.nio.ByteBuffer buffer(boolean);
descriptor: (Z)Ljava/nio/ByteBuffer;
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=3, args_size=2
start local 0 start local 1 0: iload 1
ifne 5
1: aload 0
getfield org.apache.cassandra.io.util.DataOutputBuffer.buffer:Ljava/nio/ByteBuffer;
astore 2
start local 2 2: aload 2
invokevirtual java.nio.ByteBuffer.flip:()Ljava/nio/Buffer;
pop
3: aload 0
aconst_null
putfield org.apache.cassandra.io.util.DataOutputBuffer.buffer:Ljava/nio/ByteBuffer;
4: aload 2
areturn
end local 2 5: StackMap locals:
StackMap stack:
aload 0
getfield org.apache.cassandra.io.util.DataOutputBuffer.buffer:Ljava/nio/ByteBuffer;
invokevirtual java.nio.ByteBuffer.duplicate:()Ljava/nio/ByteBuffer;
astore 2
start local 2 6: aload 2
invokevirtual java.nio.ByteBuffer.flip:()Ljava/nio/Buffer;
pop
7: aload 2
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 8 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
0 8 1 duplicate Z
2 5 2 buf Ljava/nio/ByteBuffer;
6 8 2 result Ljava/nio/ByteBuffer;
MethodParameters:
Name Flags
duplicate
public byte[] getData();
descriptor: ()[B
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: getstatic org.apache.cassandra.io.util.DataOutputBuffer.$assertionsDisabled:Z
ifne 1
aload 0
getfield org.apache.cassandra.io.util.DataOutputBuffer.buffer:Ljava/nio/ByteBuffer;
invokevirtual java.nio.ByteBuffer.arrayOffset:()I
ifeq 1
new java.lang.AssertionError
dup
invokespecial java.lang.AssertionError.<init>:()V
athrow
1: StackMap locals:
StackMap stack:
aload 0
getfield org.apache.cassandra.io.util.DataOutputBuffer.buffer:Ljava/nio/ByteBuffer;
invokevirtual java.nio.ByteBuffer.array:()[B
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
public int getLength();
descriptor: ()I
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield org.apache.cassandra.io.util.DataOutputBuffer.buffer:Ljava/nio/ByteBuffer;
invokevirtual java.nio.ByteBuffer.position:()I
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
public boolean hasPosition();
descriptor: ()Z
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: iconst_1
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
public long position();
descriptor: ()J
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
invokevirtual org.apache.cassandra.io.util.DataOutputBuffer.getLength:()I
i2l
lreturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
public java.nio.ByteBuffer asNewBuffer();
descriptor: ()Ljava/nio/ByteBuffer;
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
invokevirtual org.apache.cassandra.io.util.DataOutputBuffer.toByteArray:()[B
invokestatic java.nio.ByteBuffer.wrap:([B)Ljava/nio/ByteBuffer;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
public byte[] toByteArray();
descriptor: ()[B
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=3, args_size=1
start local 0 0: aload 0
invokevirtual org.apache.cassandra.io.util.DataOutputBuffer.buffer:()Ljava/nio/ByteBuffer;
astore 1
start local 1 1: aload 1
invokevirtual java.nio.ByteBuffer.remaining:()I
newarray 8
astore 2
start local 2 2: aload 1
aload 2
invokevirtual java.nio.ByteBuffer.get:([B)Ljava/nio/ByteBuffer;
pop
3: aload 2
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 this Lorg/apache/cassandra/io/util/DataOutputBuffer;
1 4 1 buffer Ljava/nio/ByteBuffer;
2 4 2 result [B
}
SourceFile: "DataOutputBuffer.java"
NestMembers:
org.apache.cassandra.io.util.DataOutputBuffer$1 org.apache.cassandra.io.util.DataOutputBuffer$1$1 org.apache.cassandra.io.util.DataOutputBuffer$GrowingChannel
InnerClasses:
org.apache.cassandra.io.util.DataOutputBuffer$1
final GrowingChannel = org.apache.cassandra.io.util.DataOutputBuffer$GrowingChannel of org.apache.cassandra.io.util.DataOutputBuffer