java.io.Serializable
, java.lang.Comparable<ULong>
public final class ULong extends UNumber implements java.lang.Comparable<ULong>
unsigned long
typeModifier and Type | Field | Description |
---|---|---|
static ULong |
MAX |
A constant holding the maximum value + 1 an
signed long can
have as ULong, 263. |
static java.math.BigInteger |
MAX_VALUE |
A constant holding the maximum value an
unsigned long can
have, 264-1. |
static java.math.BigInteger |
MAX_VALUE_LONG |
A constant holding the maximum value + 1 an
signed long can
have, 263. |
static ULong |
MIN |
A constant holding the minimum value an
unsigned long can
have as ULong, 0. |
static java.math.BigInteger |
MIN_VALUE |
A constant holding the minimum value an
unsigned long can
have, 0. |
Modifier and Type | Method | Description |
---|---|---|
ULong |
add(int val) |
|
ULong |
add(long val) |
|
ULong |
add(ULong val) |
|
static int |
compare(long x,
long y) |
|
int |
compareTo(ULong o) |
|
double |
doubleValue() |
|
boolean |
equals(java.lang.Object obj) |
|
float |
floatValue() |
|
int |
hashCode() |
|
int |
intValue() |
|
long |
longValue() |
|
ULong |
subtract(int val) |
|
ULong |
subtract(long val) |
|
ULong |
subtract(ULong val) |
|
java.lang.String |
toString() |
|
static ULong |
valueOf(long value) |
Create an
unsigned long by masking it with
0xFFFFFFFFFFFFFFFF i.e. |
static ULong |
valueOf(java.lang.String value) |
Create an
unsigned long |
static ULong |
valueOf(java.math.BigInteger value) |
Create an
unsigned long |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
toBigInteger
public static final java.math.BigInteger MIN_VALUE
unsigned long
can
have, 0.public static final java.math.BigInteger MAX_VALUE
unsigned long
can
have, 264-1.public static final java.math.BigInteger MAX_VALUE_LONG
signed long
can
have, 263.public static final ULong MIN
unsigned long
can
have as ULong, 0.public static final ULong MAX
signed long
can
have as ULong, 263.public static ULong valueOf(java.lang.String value) throws java.lang.NumberFormatException
unsigned long
java.lang.NumberFormatException
- If value
does not contain a
parsable unsigned long
.public static ULong valueOf(long value)
unsigned long
by masking it with
0xFFFFFFFFFFFFFFFF
i.e. (long) -1
becomes
(uint) 18446744073709551615
public static ULong valueOf(java.math.BigInteger value) throws java.lang.NumberFormatException
unsigned long
java.lang.NumberFormatException
- If value
is not in the range
of an unsigned long
public static int compare(long x, long y)
public int intValue()
intValue
in class java.lang.Number
public long longValue()
longValue
in class java.lang.Number
public float floatValue()
floatValue
in class java.lang.Number
public double doubleValue()
doubleValue
in class java.lang.Number
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public int compareTo(ULong o)
compareTo
in interface java.lang.Comparable<ULong>
public ULong add(ULong val) throws java.lang.NumberFormatException
java.lang.NumberFormatException
public ULong add(int val) throws java.lang.NumberFormatException
java.lang.NumberFormatException
public ULong add(long val) throws java.lang.NumberFormatException
java.lang.NumberFormatException
public ULong subtract(int val)
public ULong subtract(long val)
Copyright © 2018. All rights reserved.