AbstractInt<T extends Number > class
abstract
Properties
bitLength
→ int
Returns the minimum number of bits required to store this integer.
no setter
bits
→ int
返回bit位数
no setter
hashCode
→ int
The hash code for this object.
no setter override
isEven
→ bool
Returns true if and only if this integer is even.
no setter
isOdd
→ bool
Returns true if and only if this integer is odd.
no setter
runtimeType
→ Type
A representation of the runtime type of the object.
no setter inherited
sign
→ int
Returns the sign of this integer.
no setter
value
→ int
实际值
no setter override
Methods
abs ()
→ T
Returns the absolute value of this integer.
byteValue ()
→ Byte
以byte形式返回指定数字的值
inherited
ceil ()
→ T
Returns this
.
ceilToDouble ()
→ double
Returns this.toDouble()
.
compareTo (T other )
→ int
Compares this object to another object.
override
doubleValue ()
→ double
以double形式返回指定数字的值
inherited
floor ()
→ T
Returns this
.
floorToDouble ()
→ double
Returns this.toDouble()
.
gcd (int other )
→ T
Returns the greatest common divisor of this integer and other
.
intValue ()
→ Integer
以int形式返回指定数字的值
inherited
longValue ()
→ Long
以long形式返回指定数字的值
inherited
modInverse (int modulus )
→ T
Returns the modular multiplicative inverse of this integer
modulo modulus
.
modPow (int exponent , int modulus )
→ T
Returns this integer to the power of exponent
modulo modulus
.
noSuchMethod (Invocation invocation )
→ dynamic
Invoked when a nonexistent method or property is accessed.
inherited
round ()
→ T
Returns this
.
roundToDouble ()
→ double
Returns this.toDouble()
.
shortValue ()
→ Short
以short形式返回指定数字的值
inherited
toRadixString (int radix )
→ String
Converts this to a string representation in the given radix
.
toSigned (int width )
→ int
Returns the least significant width
bits of this integer, extending the
highest retained bit to the sign. This is the same as truncating the value
to fit in width
bits using an signed 2-s complement representation. The
returned value has the same bit value in all positions higher than width
.
toString ()
→ String
Returns a string representation of this integer.
override
toUnsigned (int width )
→ int
Returns the least significant width
bits of this integer as a
non-negative number (i.e. unsigned representation). The returned value has
zeros in all bit positions higher than width
.
truncate ()
→ T
Returns this
.
truncateToDouble ()
→ double
Returns this.toDouble()
.
uByteValue ()
→ int
以无符号byte形式返回指定数字的值
inherited
uIntValue ()
→ int
以无符号int形式返回指定数字的值
inherited
uLongValue ()
→ int
以无符号long形式返回指定数字的值
inherited
uShortValue ()
→ int
以无符号short形式返回指定数字的值
inherited
valueOf (int num )
→ T
创建实例