Java java.lang Long fields, constructors, methods, implement or subclass

Example usage for Java java.lang Long fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for java.lang Long.

The text is from its open source code.

Field

longMIN_VALUE
A constant holding the minimum value a long can have, -263.
longMAX_VALUE
A constant holding the maximum value a long can have, 263-1.
ClassTYPE
The Class instance representing the primitive type long .
intSIZE
The number of bits used to represent a long value in two's complement binary form.
intBYTES
The number of bytes used to represent a long value in two's complement binary form.

Constructor

Long(long value)
Constructs a newly allocated Long object that represents the specified long argument.
Long(String s)
Constructs a newly allocated Long object that represents the long value indicated by the String parameter.

Method

intbitCount(long i)
Returns the number of one-bits in the two's complement binary representation of the specified long value.
bytebyteValue()
Returns the value of this Long as a byte after a narrowing primitive conversion.
intcompare(long x, long y)
Compares two long values numerically.
intcompareTo(Long anotherLong)
Compares two Long objects numerically.
intcompareUnsigned(long x, long y)
Compares two long values numerically treating the values as unsigned.
Longdecode(String nm)
Decodes a String into a Long .
longdivideUnsigned(long dividend, long divisor)
Returns the unsigned quotient of dividing the first argument by the second where each argument and the result is interpreted as an unsigned value.
doubledoubleValue()
Returns the value of this Long as a double after a widening primitive conversion.
booleanequals(Object obj)
Compares this object to the specified object.
floatfloatValue()
Returns the value of this Long as a float after a widening primitive conversion.
ClassgetClass()
Returns the runtime class of this Object .
LonggetLong(String nm)
Determines the long value of the system property with the specified name.
LonggetLong(String nm, long val)
Determines the long value of the system property with the specified name.
LonggetLong(String nm, Long val)
Returns the long value of the system property with the specified name.
inthashCode()
Returns a hash code for this Long .
inthashCode(long value)
Returns a hash code for a long value; compatible with Long.hashCode() .
longhighestOneBit(long i)
Returns a long value with at most a single one-bit, in the position of the highest-order ("leftmost") one-bit in the specified long value.
intintValue()
Returns the value of this Long as an int after a narrowing primitive conversion.
longlongValue()
Returns the value of this Long as a long value.
longlowestOneBit(long i)
Returns a long value with at most a single one-bit, in the position of the lowest-order ("rightmost") one-bit in the specified long value.
longmax(long a, long b)
Returns the greater of two long values as if by calling Math#max(long,long) Math.max .
intnumberOfLeadingZeros(long i)
Returns the number of zero bits preceding the highest-order ("leftmost") one-bit in the two's complement binary representation of the specified long value.
intnumberOfTrailingZeros(long i)
Returns the number of zero bits following the lowest-order ("rightmost") one-bit in the two's complement binary representation of the specified long value.
longparseLong(String s, int radix)
Parses the string argument as a signed long in the radix specified by the second argument.
longparseLong(String s)
Parses the string argument as a signed decimal long .
longparseUnsignedLong(String s)
Parses the string argument as an unsigned decimal long .
longparseUnsignedLong(String s, int radix)
Parses the string argument as an unsigned long in the radix specified by the second argument.
longreverse(long i)
Returns the value obtained by reversing the order of the bits in the two's complement binary representation of the specified long value.
longreverseBytes(long i)
Returns the value obtained by reversing the order of the bytes in the two's complement representation of the specified long value.
longrotateLeft(long i, int distance)
Returns the value obtained by rotating the two's complement binary representation of the specified long value left by the specified number of bits.
longrotateRight(long i, int distance)
Returns the value obtained by rotating the two's complement binary representation of the specified long value right by the specified number of bits.
shortshortValue()
Returns the value of this Long as a short after a narrowing primitive conversion.
intsignum(long i)
Returns the signum function of the specified long value.
StringtoBinaryString(long i)
Returns a string representation of the long argument as an unsigned integer in base 2.
StringtoHexString(long i)
Returns a string representation of the long argument as an unsigned integer in base 16.
StringtoOctalString(long i)
Returns a string representation of the long argument as an unsigned integer in base 8.
StringtoString()
Returns a String object representing this Long 's value.
StringtoString(long i)
Returns a String object representing the specified long .
StringtoString(long i, int radix)
Returns a string representation of the first argument in the radix specified by the second argument.
StringtoUnsignedString(long i)
Returns a string representation of the argument as an unsigned decimal value.
LongvalueOf(String s)
Returns a Long object holding the value of the specified String .
LongvalueOf(long l)
Returns a Long instance representing the specified long value.
LongvalueOf(String s, int radix)
Returns a Long object holding the value extracted from the specified String when parsed with the radix given by the second argument.
voidwait(long timeoutMillis)
Causes the current thread to wait until it is awakened, typically by being notified or interrupted, or until a certain amount of real time has elapsed.