public final class org.jruby.RubyRandom$RandomType
minor version: 0
major version: 59
flags: flags: (0x0031) ACC_PUBLIC, ACC_FINAL, ACC_SUPER
this_class: org.jruby.RubyRandom$RandomType
super_class: java.lang.Object
{
private final org.jruby.RubyInteger seed;
descriptor: Lorg/jruby/RubyInteger;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
private final org.jruby.util.Random impl;
descriptor: Lorg/jruby/util/Random;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
void <init>(org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/builtin/IRubyObject;)V
flags: (0x0000)
Code:
stack=6, locals=2, args_size=2
start local 0 start local 1 0: aload 0
invokespecial java.lang.Object.<init>:()V
1: aload 0
aload 1
invokeinterface org.jruby.runtime.builtin.IRubyObject.convertToInteger:()Lorg/jruby/RubyInteger;
putfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
2: aload 0
getfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
instanceof org.jruby.RubyFixnum
ifeq 5
3: aload 0
aload 0
getfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
checkcast org.jruby.RubyFixnum
invokestatic org.jruby.RubyRandom$RandomType.randomFromFixnum:(Lorg/jruby/RubyFixnum;)Lorg/jruby/util/Random;
putfield org.jruby.RubyRandom$RandomType.impl:Lorg/jruby/util/Random;
4: goto 11
StackMap locals: org.jruby.RubyRandom$RandomType org.jruby.runtime.builtin.IRubyObject
StackMap stack:
5: aload 0
getfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
instanceof org.jruby.RubyBignum
ifeq 8
6: aload 0
aload 0
getfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
checkcast org.jruby.RubyBignum
invokestatic org.jruby.RubyRandom$RandomType.randomFromBignum:(Lorg/jruby/RubyBignum;)Lorg/jruby/util/Random;
putfield org.jruby.RubyRandom$RandomType.impl:Lorg/jruby/util/Random;
7: goto 11
8: StackMap locals:
StackMap stack:
aload 1
invokeinterface org.jruby.runtime.builtin.IRubyObject.getRuntime:()Lorg/jruby/Ruby;
9: ldc "failed to convert %s into Integer"
iconst_1
anewarray java.lang.Object
dup
iconst_0
aload 1
invokeinterface org.jruby.runtime.builtin.IRubyObject.getMetaClass:()Lorg/jruby/RubyClass;
invokevirtual org.jruby.RubyClass.getName:()Ljava/lang/String;
aastore
invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
10: invokevirtual org.jruby.Ruby.newTypeError:(Ljava/lang/String;)Lorg/jruby/exceptions/RaiseException;
athrow
11: StackMap locals:
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 12 0 this Lorg/jruby/RubyRandom$RandomType;
0 12 1 seed Lorg/jruby/runtime/builtin/IRubyObject;
MethodParameters:
Name Flags
seed
public static org.jruby.util.Random randomFromFixnum(org.jruby.RubyFixnum);
descriptor: (Lorg/jruby/RubyFixnum;)Lorg/jruby/util/Random;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
invokestatic org.jruby.RubyNumeric.num2long:(Lorg/jruby/runtime/builtin/IRubyObject;)J
invokestatic org.jruby.RubyRandom$RandomType.randomFromLong:(J)Lorg/jruby/util/Random;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 seed Lorg/jruby/RubyFixnum;
MethodParameters:
Name Flags
seed
public static org.jruby.util.Random randomFromLong(long);
descriptor: (J)Lorg/jruby/util/Random;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=6, locals=5, args_size=1
start local 0 0: lload 0
invokestatic java.lang.Math.abs:(J)J
lstore 2
start local 2 1: lload 2
lload 2
ldc 4294967295
land
lcmp
ifne 3
2: new org.jruby.util.Random
dup
lload 2
l2i
invokespecial org.jruby.util.Random.<init>:(I)V
areturn
3: StackMap locals: long
StackMap stack:
iconst_2
newarray 10
astore 4
start local 4 4: aload 4
iconst_0
lload 2
l2i
iastore
5: aload 4
iconst_1
lload 2
bipush 32
lshr
l2i
iastore
6: new org.jruby.util.Random
dup
aload 4
invokespecial org.jruby.util.Random.<init>:([I)V
areturn
end local 4 end local 2 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 seed J
1 7 2 v J
4 7 4 ints [I
MethodParameters:
Name Flags
seed
public static org.jruby.util.Random randomFromBignum(org.jruby.RubyBignum);
descriptor: (Lorg/jruby/RubyBignum;)Lorg/jruby/util/Random;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=1, locals=2, args_size=1
start local 0 0: aload 0
invokevirtual org.jruby.RubyBignum.getBigIntegerValue:()Ljava/math/BigInteger;
astore 1
start local 1 1: aload 1
invokestatic org.jruby.RubyRandom$RandomType.randomFromBigInteger:(Ljava/math/BigInteger;)Lorg/jruby/util/Random;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 seed Lorg/jruby/RubyBignum;
1 2 1 big Ljava/math/BigInteger;
MethodParameters:
Name Flags
seed
public static org.jruby.util.Random randomFromBigInteger(java.math.BigInteger);
descriptor: (Ljava/math/BigInteger;)Lorg/jruby/util/Random;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=4, locals=5, args_size=1
start local 0 0: aload 0
invokevirtual java.math.BigInteger.signum:()I
ifge 2
1: aload 0
invokevirtual java.math.BigInteger.abs:()Ljava/math/BigInteger;
astore 0
2: StackMap locals:
StackMap stack:
aload 0
invokevirtual java.math.BigInteger.toByteArray:()[B
astore 1
start local 1 3: aload 1
arraylength
istore 2
start local 2 4: aload 1
iconst_0
baload
ifne 6
5: iinc 2 -1
6: StackMap locals: byte[] int
StackMap stack:
iload 2
iconst_3
iadd
iconst_4
idiv
sipush 624
invokestatic java.lang.Math.min:(II)I
istore 3
start local 3 7: aload 1
iload 3
invokestatic org.jruby.RubyRandom$RandomType.bigEndianToInts:([BI)[I
astore 4
start local 4 8: iload 3
iconst_1
if_icmpgt 10
9: new org.jruby.util.Random
dup
aload 4
iconst_0
iaload
invokespecial org.jruby.util.Random.<init>:(I)V
areturn
10: StackMap locals: int int[]
StackMap stack:
new org.jruby.util.Random
dup
aload 4
invokespecial org.jruby.util.Random.<init>:([I)V
areturn
end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 11 0 big Ljava/math/BigInteger;
3 11 1 buf [B
4 11 2 buflen I
7 11 3 len I
8 11 4 ints [I
MethodParameters:
Name Flags
big
void <init>(org.jruby.runtime.builtin.IRubyObject, org.jruby.RubyBignum, int);
descriptor: (Lorg/jruby/runtime/builtin/IRubyObject;Lorg/jruby/RubyBignum;I)V
flags: (0x0000)
Code:
stack=5, locals=7, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
invokespecial java.lang.Object.<init>:()V
1: aload 0
aload 1
invokeinterface org.jruby.runtime.builtin.IRubyObject.convertToInteger:()Lorg/jruby/RubyInteger;
putfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
2: aload 2
invokevirtual org.jruby.RubyBignum.getBigIntegerValue:()Ljava/math/BigInteger;
invokevirtual java.math.BigInteger.toByteArray:()[B
astore 4
start local 4 3: aload 4
arraylength
iconst_4
idiv
newarray 10
astore 5
start local 5 4: iconst_0
istore 6
start local 6 5: goto 8
6: StackMap locals: org.jruby.RubyRandom$RandomType org.jruby.runtime.builtin.IRubyObject org.jruby.RubyBignum int byte[] int[] int
StackMap stack:
aload 5
iload 6
aload 4
iload 6
invokestatic org.jruby.RubyRandom.getIntBigIntegerBuffer:([BI)I
iastore
7: iinc 6 1
StackMap locals:
StackMap stack:
8: iload 6
aload 5
arraylength
if_icmplt 6
end local 6 9: aload 0
new org.jruby.util.Random
dup
aload 5
iload 3
invokespecial org.jruby.util.Random.<init>:([II)V
putfield org.jruby.RubyRandom$RandomType.impl:Lorg/jruby/util/Random;
10: return
end local 5 end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 11 0 this Lorg/jruby/RubyRandom$RandomType;
0 11 1 vseed Lorg/jruby/runtime/builtin/IRubyObject;
0 11 2 state Lorg/jruby/RubyBignum;
0 11 3 left I
3 11 4 bytes [B
4 11 5 ints [I
5 9 6 i I
MethodParameters:
Name Flags
vseed
state
left
public boolean equals(java.lang.Object);
descriptor: (Ljava/lang/Object;)Z
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=3, args_size=2
start local 0 start local 1 0: aload 0
aload 1
if_acmpne 1
iconst_1
ireturn
1: StackMap locals:
StackMap stack:
aload 1
instanceof org.jruby.RubyRandom$RandomType
ifne 2
iconst_0
ireturn
2: StackMap locals:
StackMap stack:
aload 1
checkcast org.jruby.RubyRandom$RandomType
astore 2
start local 2 3: aload 0
getfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
aload 0
getfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
invokevirtual org.jruby.RubyInteger.getRuntime:()Lorg/jruby/Ruby;
invokevirtual org.jruby.Ruby.getCurrentContext:()Lorg/jruby/runtime/ThreadContext;
aload 2
getfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
invokevirtual org.jruby.RubyInteger.op_equal:(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
invokeinterface org.jruby.runtime.builtin.IRubyObject.isTrue:()Z
ifeq 4
aload 0
getfield org.jruby.RubyRandom$RandomType.impl:Lorg/jruby/util/Random;
aload 2
getfield org.jruby.RubyRandom$RandomType.impl:Lorg/jruby/util/Random;
invokevirtual org.jruby.util.Random.equals:(Ljava/lang/Object;)Z
ifeq 4
iconst_1
ireturn
StackMap locals: org.jruby.RubyRandom$RandomType
StackMap stack:
4: iconst_0
ireturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Lorg/jruby/RubyRandom$RandomType;
0 5 1 obj Ljava/lang/Object;
3 5 2 rhs Lorg/jruby/RubyRandom$RandomType;
MethodParameters:
Name Flags
obj
public int hashCode();
descriptor: ()I
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: sipush 629
aload 0
getfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
invokevirtual org.jruby.RubyInteger.hashCode:()I
iadd
bipush 37
imul
aload 0
getfield org.jruby.RubyRandom$RandomType.impl:Lorg/jruby/util/Random;
invokevirtual org.jruby.util.Random.hashCode:()I
iadd
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/RubyRandom$RandomType;
void <init>(org.jruby.RubyRandom$RandomType);
descriptor: (Lorg/jruby/RubyRandom$RandomType;)V
flags: (0x0000)
Code:
stack=4, locals=2, args_size=2
start local 0 start local 1 0: aload 0
invokespecial java.lang.Object.<init>:()V
1: aload 0
aload 1
getfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
putfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
2: aload 0
new org.jruby.util.Random
dup
aload 1
getfield org.jruby.RubyRandom$RandomType.impl:Lorg/jruby/util/Random;
invokespecial org.jruby.util.Random.<init>:(Lorg/jruby/util/Random;)V
putfield org.jruby.RubyRandom$RandomType.impl:Lorg/jruby/util/Random;
3: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 this Lorg/jruby/RubyRandom$RandomType;
0 4 1 orig Lorg/jruby/RubyRandom$RandomType;
MethodParameters:
Name Flags
orig
int genrandInt32();
descriptor: ()I
flags: (0x0000)
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield org.jruby.RubyRandom$RandomType.impl:Lorg/jruby/util/Random;
invokevirtual org.jruby.util.Random.genrandInt32:()I
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/RubyRandom$RandomType;
double genrandReal();
descriptor: ()D
flags: (0x0000)
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
getfield org.jruby.RubyRandom$RandomType.impl:Lorg/jruby/util/Random;
invokevirtual org.jruby.util.Random.genrandReal:()D
dreturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/RubyRandom$RandomType;
double genrandReal2();
descriptor: ()D
flags: (0x0000)
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
getfield org.jruby.RubyRandom$RandomType.impl:Lorg/jruby/util/Random;
invokevirtual org.jruby.util.Random.genrandReal2:()D
dreturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/RubyRandom$RandomType;
org.jruby.RubyInteger getSeed();
descriptor: ()Lorg/jruby/RubyInteger;
flags: (0x0000)
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/RubyRandom$RandomType;
org.jruby.RubyBignum getState();
descriptor: ()Lorg/jruby/RubyBignum;
flags: (0x0000)
Code:
stack=4, locals=4, args_size=1
start local 0 0: aload 0
getfield org.jruby.RubyRandom$RandomType.impl:Lorg/jruby/util/Random;
invokevirtual org.jruby.util.Random.getState:()[I
astore 1
start local 1 1: aload 1
arraylength
iconst_4
imul
newarray 8
astore 2
start local 2 2: iconst_0
istore 3
start local 3 3: goto 6
4: StackMap locals: int[] byte[] int
StackMap stack:
aload 2
iload 3
aload 1
iload 3
iaload
invokestatic org.jruby.RubyRandom.setIntBigIntegerBuffer:([BII)V
5: iinc 3 1
StackMap locals:
StackMap stack:
6: iload 3
aload 1
arraylength
if_icmplt 4
end local 3 7: aload 0
getfield org.jruby.RubyRandom$RandomType.seed:Lorg/jruby/RubyInteger;
invokevirtual org.jruby.RubyInteger.getRuntime:()Lorg/jruby/Ruby;
new java.math.BigInteger
dup
aload 2
invokespecial java.math.BigInteger.<init>:([B)V
invokestatic org.jruby.RubyBignum.newBignum:(Lorg/jruby/Ruby;Ljava/math/BigInteger;)Lorg/jruby/RubyBignum;
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 8 0 this Lorg/jruby/RubyRandom$RandomType;
1 8 1 ints [I
2 8 2 bytes [B
3 7 3 idx I
int getLeft();
descriptor: ()I
flags: (0x0000)
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield org.jruby.RubyRandom$RandomType.impl:Lorg/jruby/util/Random;
invokevirtual org.jruby.util.Random.getLeft:()I
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/RubyRandom$RandomType;
private static int[] bigEndianToInts(byte[], int);
descriptor: ([BI)[I
flags: (0x000a) ACC_PRIVATE, ACC_STATIC
Code:
stack=4, locals=4, args_size=2
start local 0 start local 1 0: iload 1
newarray 10
astore 2
start local 2 1: iconst_0
istore 3
start local 3 2: goto 5
3: StackMap locals: int[] int
StackMap stack:
aload 2
iload 3
aload 0
iload 3
invokestatic org.jruby.RubyRandom.getIntBigIntegerBuffer:([BI)I
iastore
4: iinc 3 1
StackMap locals:
StackMap stack:
5: iload 3
aload 2
arraylength
if_icmplt 3
end local 3 6: aload 2
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 buf [B
0 7 1 initKeyLen I
1 7 2 initKey [I
2 6 3 idx I
MethodParameters:
Name Flags
buf
initKeyLen
}
SourceFile: "RubyRandom.java"
NestHost: org.jruby.RubyRandom
InnerClasses:
public final RandomType = org.jruby.RubyRandom$RandomType of org.jruby.RubyRandom