public class org.apache.kafkaesqueesque.common.utils.Bytes extends java.lang.Object implements java.lang.Comparable
{
public static final byte[] EMPTY;
private static final char[] HEX_CHARS_UPPER;
private final byte[] bytes;
private int hashCode;
public static final org.apache.kafkaesqueesque.common.utils.Bytes$ByteArrayComparator BYTES_LEXICO_COMPARATOR;
public static org.apache.kafkaesqueesque.common.utils.Bytes wrap(byte[])
{
byte[] v;
org.apache.kafkaesqueesque.common.utils.Bytes v;
v := @parameter: byte[];
if v != null goto label;
return null;
label:
v = new org.apache.kafkaesqueesque.common.utils.Bytes;
specialinvoke v.<org.apache.kafkaesqueesque.common.utils.Bytes: void <init>(byte[])>(v);
return v;
}
public void <init>(byte[])
{
byte[] v;
org.apache.kafkaesqueesque.common.utils.Bytes v;
v := @this: org.apache.kafkaesqueesque.common.utils.Bytes;
v := @parameter: byte[];
specialinvoke v.<java.lang.Object: void <init>()>();
v.<org.apache.kafkaesqueesque.common.utils.Bytes: byte[] bytes> = v;
v.<org.apache.kafkaesqueesque.common.utils.Bytes: int hashCode> = 0;
return;
}
public byte[] get()
{
byte[] v;
org.apache.kafkaesqueesque.common.utils.Bytes v;
v := @this: org.apache.kafkaesqueesque.common.utils.Bytes;
v = v.<org.apache.kafkaesqueesque.common.utils.Bytes: byte[] bytes>;
return v;
}
public int hashCode()
{
byte[] v;
int v, v, v;
org.apache.kafkaesqueesque.common.utils.Bytes v;
v := @this: org.apache.kafkaesqueesque.common.utils.Bytes;
v = v.<org.apache.kafkaesqueesque.common.utils.Bytes: int hashCode>;
if v != 0 goto label;
v = v.<org.apache.kafkaesqueesque.common.utils.Bytes: byte[] bytes>;
v = staticinvoke <java.util.Arrays: int hashCode(byte[])>(v);
v.<org.apache.kafkaesqueesque.common.utils.Bytes: int hashCode> = v;
label:
v = v.<org.apache.kafkaesqueesque.common.utils.Bytes: int hashCode>;
return v;
}
public boolean equals(java.lang.Object)
{
byte[] v, v;
org.apache.kafkaesqueesque.common.utils.Bytes v;
int v, v;
java.lang.Object v;
boolean v, v;
v := @this: org.apache.kafkaesqueesque.common.utils.Bytes;
v := @parameter: java.lang.Object;
if v != v goto label;
return 1;
label:
if v != null goto label;
return 0;
label:
v = virtualinvoke v.<org.apache.kafkaesqueesque.common.utils.Bytes: int hashCode()>();
v = virtualinvoke v.<java.lang.Object: int hashCode()>();
if v == v goto label;
return 0;
label:
v = v instanceof org.apache.kafkaesqueesque.common.utils.Bytes;
if v == 0 goto label;
v = v.<org.apache.kafkaesqueesque.common.utils.Bytes: byte[] bytes>;
v = virtualinvoke v.<org.apache.kafkaesqueesque.common.utils.Bytes: byte[] get()>();
v = staticinvoke <java.util.Arrays: boolean equals(byte[],byte[])>(v, v);
return v;
label:
return 0;
}
public int compareTo(org.apache.kafkaesqueesque.common.utils.Bytes)
{
byte[] v, v;
org.apache.kafkaesqueesque.common.utils.Bytes$ByteArrayComparator v;
int v;
org.apache.kafkaesqueesque.common.utils.Bytes v, v;
v := @this: org.apache.kafkaesqueesque.common.utils.Bytes;
v := @parameter: org.apache.kafkaesqueesque.common.utils.Bytes;
v = <org.apache.kafkaesqueesque.common.utils.Bytes: org.apache.kafkaesqueesque.common.utils.Bytes$ByteArrayComparator BYTES_LEXICO_COMPARATOR>;
v = v.<org.apache.kafkaesqueesque.common.utils.Bytes: byte[] bytes>;
v = v.<org.apache.kafkaesqueesque.common.utils.Bytes: byte[] bytes>;
v = interfaceinvoke v.<org.apache.kafkaesqueesque.common.utils.Bytes$ByteArrayComparator: int compare(java.lang.Object,java.lang.Object)>(v, v);
return v;
}
public java.lang.String toString()
{
byte[] v, v;
int v;
java.lang.String v;
org.apache.kafkaesqueesque.common.utils.Bytes v;
v := @this: org.apache.kafkaesqueesque.common.utils.Bytes;
v = v.<org.apache.kafkaesqueesque.common.utils.Bytes: byte[] bytes>;
v = v.<org.apache.kafkaesqueesque.common.utils.Bytes: byte[] bytes>;
v = lengthof v;
v = staticinvoke <org.apache.kafkaesqueesque.common.utils.Bytes: java.lang.String toString(byte[],int,int)>(v, 0, v);
return v;
}
private static java.lang.String toString(byte[], int, int)
{
byte[] v;
short v;
byte v;
int v, v, v, v, v, v, v, v, v, v;
java.lang.String v, v, v;
char v, v;
char[] v, v;
java.lang.StringBuilder v;
v := @parameter: byte[];
v := @parameter: int;
v := @parameter: int;
v = new java.lang.StringBuilder;
specialinvoke v.<java.lang.StringBuilder: void <init>()>();
if v != null goto label;
v = virtualinvoke v.<java.lang.StringBuilder: java.lang.String toString()>();
return v;
label:
v = lengthof v;
if v < v goto label;
v = virtualinvoke v.<java.lang.StringBuilder: java.lang.String toString()>();
return v;
label:
v = v + v;
v = lengthof v;
if v <= v goto label;
v = lengthof v;
v = v - v;
label:
v = v;
label:
v = v + v;
if v >= v goto label;
v = v[v];
v = v & 255;
if v < 32 goto label;
if v > 126 goto label;
if v == 92 goto label;
virtualinvoke v.<java.lang.StringBuilder: java.lang.StringBuilder append(char)>(v);
goto label;
label:
virtualinvoke v.<java.lang.StringBuilder: java.lang.StringBuilder append(java.lang.String)>("\\x");
v = <org.apache.kafkaesqueesque.common.utils.Bytes: char[] HEX_CHARS_UPPER>;
v = v / 16;
v = v[v];
virtualinvoke v.<java.lang.StringBuilder: java.lang.StringBuilder append(char)>(v);
v = <org.apache.kafkaesqueesque.common.utils.Bytes: char[] HEX_CHARS_UPPER>;
v = v % 16;
v = v[v];
virtualinvoke v.<java.lang.StringBuilder: java.lang.StringBuilder append(char)>(v);
label:
v = v + 1;
goto label;
label:
v = virtualinvoke v.<java.lang.StringBuilder: java.lang.String toString()>();
return v;
}
public static org.apache.kafkaesqueesque.common.utils.Bytes increment(org.apache.kafkaesqueesque.common.utils.Bytes) throws java.lang.IndexOutOfBoundsException
{
byte[] v, v;
java.lang.IndexOutOfBoundsException v;
org.apache.kafkaesqueesque.common.utils.Bytes v, v;
byte v, v;
int v, v, v, v, v;
boolean v;
v := @parameter: org.apache.kafkaesqueesque.common.utils.Bytes;
v = virtualinvoke v.<org.apache.kafkaesqueesque.common.utils.Bytes: byte[] get()>();
v = lengthof v;
v = newarray (byte)[v];
v = 1;
v = lengthof v;
v = v - 1;
label:
if v < 0 goto label;
v = v[v];
v = (int) -1;
if v != v goto label;
if v != 1 goto label;
v[v] = 0;
goto label;
label:
v = v[v];
v = v + v;
v[v] = v;
v = 0;
label:
v = v - 1;
goto label;
label:
if v != 0 goto label;
v = staticinvoke <org.apache.kafkaesqueesque.common.utils.Bytes: org.apache.kafkaesqueesque.common.utils.Bytes wrap(byte[])>(v);
return v;
label:
v = new java.lang.IndexOutOfBoundsException;
specialinvoke v.<java.lang.IndexOutOfBoundsException: void <init>()>();
throw v;
}
static void <clinit>()
{
byte[] v;
char[] v;
org.apache.kafkaesqueesque.common.utils.Bytes$LexicographicByteArrayComparator v;
v = newarray (byte)[0];
<org.apache.kafkaesqueesque.common.utils.Bytes: byte[] EMPTY> = v;
v = newarray (char)[16];
v[0] = 48;
v[1] = 49;
v[2] = 50;
v[3] = 51;
v[4] = 52;
v[5] = 53;
v[6] = 54;
v[7] = 55;
v[8] = 56;
v[9] = 57;
v[10] = 65;
v[11] = 66;
v[12] = 67;
v[13] = 68;
v[14] = 69;
v[15] = 70;
<org.apache.kafkaesqueesque.common.utils.Bytes: char[] HEX_CHARS_UPPER> = v;
v = new org.apache.kafkaesqueesque.common.utils.Bytes$LexicographicByteArrayComparator;
specialinvoke v.<org.apache.kafkaesqueesque.common.utils.Bytes$LexicographicByteArrayComparator: void <init>()>();
<org.apache.kafkaesqueesque.common.utils.Bytes: org.apache.kafkaesqueesque.common.utils.Bytes$ByteArrayComparator BYTES_LEXICO_COMPARATOR> = v;
return;
}
}