shadow:standard@Integer<ushort>, shadow:standard@Integer<int>, shadow:standard@Integer<uint>, shadow:standard@Integer<long>, shadow:standard@Integer<ulong>, shadow:standard@Number<float>, shadow:standard@Number<double>, shadow:standard@CanHash

`immutable locked class ushort`

Class `ushort`

contains the methods that can be called on `ushort`

values.

Modifiers | Type | Name and Description |
---|---|---|

`public immutable constant` |
`ushort` |
`MAX` Largest value a |

`public immutable constant` |
`ushort` |
`MIN` Smallest value a |

Modifiers | Return Types | Method and Description |
---|---|---|

`public` |
`()` |
`create()` |

Modifiers | Return Types | Method and Description |
---|---|---|

`public` |
`()` |
`destroy()` |

Modifiers | Return Types | Method and Description |
---|---|---|

`public readonly locked` |
`(double)` |
`add(double other)` Adds a |

`public readonly locked` |
`(float)` |
`add(float other)` Adds a |

`public readonly locked` |
`(int)` |
`add(int other)` Adds an |

`public readonly locked` |
`(long)` |
`add(long other)` Adds a |

`public readonly locked` |
`(uint)` |
`add(uint other)` Adds a |

`public readonly locked` |
`(ulong)` |
`add(ulong other)` Adds a |

`public readonly locked` |
`(ushort)` |
`add(ushort other)` |

`public readonly locked` |
`(ushort, boolean)` |
`addWithOverflow(ushort value)` |

`public readonly locked` |
`(int)` |
`bitAnd(int other)` Computes the bitwise AND of the value and an |

`public readonly locked` |
`(long)` |
`bitAnd(long other)` Computes the bitwise AND of the value and a |

`public readonly locked` |
`(uint)` |
`bitAnd(uint other)` Computes the bitwise AND of the value and a |

`public readonly locked` |
`(ulong)` |
`bitAnd(ulong other)` Computes the bitwise AND of the value and a |

`public readonly locked` |
`(ushort)` |
`bitAnd(ushort other)` |

`public readonly locked` |
`(ushort)` |
`bitComplement()` |

`public readonly locked` |
`(int)` |
`bitOr(int other)` Computes the bitwise OR of the value and an |

`public readonly locked` |
`(long)` |
`bitOr(long other)` Computes the bitwise OR of the value and a |

`public readonly locked` |
`(uint)` |
`bitOr(uint other)` Computes the bitwise OR of the value and a |

`public readonly locked` |
`(ulong)` |
`bitOr(ulong other)` Computes the bitwise OR of the value and a |

`public readonly locked` |
`(ushort)` |
`bitOr(ushort other)` |

`public readonly locked` |
`(ushort)` |
`bitRotateLeft(int amount)` Finds the result of left-rotating the bits of the |

`public readonly locked` |
`(ushort)` |
`bitRotateLeft(uint amount)` |

`public readonly locked` |
`(ushort)` |
`bitRotateRight(int amount)` Finds the result of right-rotating the bits of the |

`public readonly locked` |
`(ushort)` |
`bitRotateRight(uint amount)` |

`public readonly locked` |
`(ushort)` |
`bitShiftLeft(int amount)` Finds the result of left-shifting the bits of the |

`public readonly locked` |
`(ushort)` |
`bitShiftLeft(uint amount)` |

`public readonly locked` |
`(ushort)` |
`bitShiftRight(int amount)` Finds the result of right-shifting the bits of the |

`public readonly locked` |
`(ushort)` |
`bitShiftRight(uint amount)` |

`public readonly locked` |
`(int)` |
`bitXor(int other)` Computes the bitwise XOR of the value and an |

`public readonly locked` |
`(long)` |
`bitXor(long other)` Computes the bitwise XOR of the value and a |

`public readonly locked` |
`(uint)` |
`bitXor(uint other)` Computes the bitwise XOR of the value and a |

`public readonly locked` |
`(ulong)` |
`bitXor(ulong other)` Computes the bitwise XOR of the value and a |

`public readonly locked` |
`(ushort)` |
`bitXor(ushort other)` |

`public readonly locked` |
`(int)` |
`compare(double other)` Compares the current value to a |

`public readonly locked` |
`(int)` |
`compare(float other)` Compares the current value to a |

`public readonly locked` |
`(int)` |
`compare(int other)` Compares the current value to an |

`public readonly locked` |
`(int)` |
`compare(long other)` Compares the current value to a |

`public readonly locked` |
`(int)` |
`compare(uint other)` Compares the current value to a |

`public readonly locked` |
`(int)` |
`compare(ulong other)` Compares the current value to a |

`public readonly locked` |
`(int)` |
`compare(ushort other)` |

`public readonly` |
`(ushort)` |
`copy(AddressMap addresses)` |

`public readonly locked` |
`(double)` |
`cos()` Finds the cosine of the current value. |

`public readonly locked` |
`(double)` |
`divide(double other)` Divides the current value by a |

`public readonly locked` |
`(float)` |
`divide(float other)` Divides the current value by a |

`public readonly locked` |
`(int)` |
`divide(int other)` Divides the current value by an |

`public readonly locked` |
`(long)` |
`divide(long other)` Divides the current value by a |

`public readonly locked` |
`(uint)` |
`divide(uint other)` Divides the current value by a |

`public readonly locked` |
`(ulong)` |
`divide(ulong other)` Divides the current value by a |

`public readonly locked` |
`(ushort)` |
`divide(ushort other)` |

`public readonly locked` |
`(boolean)` |
`equal(double other)` Compares the current value to a |

`public readonly locked` |
`(boolean)` |
`equal(float other)` Compares the current value to a |

`public readonly locked` |
`(boolean)` |
`equal(int other)` Compares the current value to an |

`public readonly locked` |
`(boolean)` |
`equal(long other)` Compares the current value to a |

`public readonly locked` |
`(boolean)` |
`equal(uint other)` Compares the current value to a |

`public readonly locked` |
`(boolean)` |
`equal(ulong other)` Compares the current value to a |

`public readonly locked` |
`(boolean)` |
`equal(ushort other)` |

`public readonly locked` |
`(ushort)` |
`flipEndian()` |

`public readonly locked` |
`(ushort)` |
`leadingZeroes()` |

`public readonly locked` |
`(double)` |
`logBase10()` Finds the logarithm base 10 of the current value. |

`public readonly locked` |
`(double)` |
`logBase2()` Finds the logarithm base 2 of the current value. |

`public readonly locked` |
`(double)` |
`logBaseE()` Finds the natural logarithm of the current value. |

`public readonly locked` |
`(ushort)` |
`max(ushort other)` Finds the maximum of the current value and another |

`public readonly locked` |
`(ushort)` |
`min(ushort other)` Finds the minimum of the current value and another |

`public readonly locked` |
`(double)` |
`modulus(double other)` Divides the current value by a |

`public readonly locked` |
`(float)` |
`modulus(float other)` Divides the current value by a |

`public readonly locked` |
`(int)` |
`modulus(int other)` Divides the current value by an |

`public readonly locked` |
`(long)` |
`modulus(long other)` Divides the current value by a |

`public readonly locked` |
`(uint)` |
`modulus(uint other)` Divides the current value by a |

`public readonly locked` |
`(ulong)` |
`modulus(ulong other)` Divides the current value by a |

`public readonly locked` |
`(ushort)` |
`modulus(ushort other)` |

`public readonly locked` |
`(double)` |
`multiply(double other)` Multiplies the current value by a |

`public readonly locked` |
`(float)` |
`multiply(float other)` Multiplies the current value by a |

`public readonly locked` |
`(int)` |
`multiply(int other)` Multiplies the current value by an |

`public readonly locked` |
`(long)` |
`multiply(long other)` Multiplies the current value by a |

`public readonly locked` |
`(uint)` |
`multiply(uint other)` Multiplies the current value by a |

`public readonly locked` |
`(ulong)` |
`multiply(ulong other)` Multiplies the current value by a |

`public readonly locked` |
`(ushort)` |
`multiply(ushort other)` |

`public readonly locked` |
`(ushort, boolean)` |
`multiplyWithOverflow(ushort value)` |

`public readonly locked` |
`(ushort)` |
`ones()` |

`public readonly locked` |
`(double)` |
`power(double value)` Raises the current value to the power of a |

`public readonly locked` |
`(double)` |
`power(int value)` Raises the current value to the power of an |

`public readonly locked` |
`(double)` |
`sin()` Finds the sine of the current value. |

`public readonly locked` |
`(double)` |
`squareRoot()` Finds the square root of the value. |

`public readonly locked` |
`(double)` |
`subtract(double other)` Subtracts a |

`public readonly locked` |
`(float)` |
`subtract(float other)` Subtracts a |

`public readonly locked` |
`(int)` |
`subtract(int other)` Subtracts an |

`public readonly locked` |
`(long)` |
`subtract(long other)` Subtracts a |

`public readonly locked` |
`(uint)` |
`subtract(uint other)` Subtracts a |

`public readonly locked` |
`(ulong)` |
`subtract(ulong other)` Subtracts a |

`public readonly locked` |
`(ushort)` |
`subtract(ushort other)` |

`public readonly locked` |
`(ushort, boolean)` |
`subtractWithOverflow(ushort value)` |

`public readonly locked` |
`(double)` |
`tan()` Finds the tangent of the current value. |

`public readonly locked` |
`(byte)` |
`toByte()` |

`public readonly locked` |
`(code)` |
`toCode()` |

`public readonly locked` |
`(double)` |
`toDouble()` |

`public readonly locked` |
`(float)` |
`toFloat()` |

`public readonly locked` |
`(int)` |
`toInt()` |

`public readonly locked` |
`(long)` |
`toLong()` |

`public readonly locked` |
`(short)` |
`toShort()` |

`public readonly locked` |
`(short)` |
`toSigned()` Returns a signed version of the current value, overflowing if too large. |

`public readonly locked` |
`(String)` |
`toString()` Returns a |

`public readonly locked` |
`(String)` |
`toString(uint base)` Returns a |

`public readonly locked` |
`(ubyte)` |
`toUByte()` |

`public readonly locked` |
`(uint)` |
`toUInt()` |

`public readonly locked` |
`(ulong)` |
`toULong()` |

`public readonly locked` |
`(ushort)` |
`toUShort()` |

`public readonly locked` |
`(ushort)` |
`trailingZeroes()` |

Modifiers | Return Types | Method and Description |
---|---|---|

`public readonly get locked` |
`(ulong)` |
`hash()` Finds a hash value for the current value. |

`public create() => ()`

`public destroy() => ()`

`public readonly locked add(double other) => (double)`

Adds a `double`

to the current value and returns the resulting value.

`other`

- value to add

sum of the two values

`public readonly locked add(float other) => (float)`

Adds a `float`

to the current value and returns the resulting value.

`other`

- value to add

sum of the two values

`public readonly locked add(int other) => (int)`

Adds an `int`

to the current value and returns the resulting value.

`other`

- value to add

sum of the two values

`public readonly locked add(long other) => (long)`

Adds a `long`

to the current value and returns the resulting value.

`other`

- value to add

sum of the two values

`public readonly locked add(uint other) => (uint)`

Adds a `uint`

to the current value and returns the resulting value.

`other`

- value to add

sum of the two values

`public readonly locked add(ulong other) => (ulong)`

Adds a `ulong`

to the current value and returns the resulting value.

`other`

- value to add

sum of the two values

`public readonly locked bitAnd(int other) => (int)`

Computes the bitwise AND of the value and an `int`

value.

`other`

- value to bitwise AND with

result of bitwise AND

`public readonly locked bitAnd(long other) => (long)`

Computes the bitwise AND of the value and a `long`

value.

`other`

- value to bitwise AND with

result of bitwise AND

`public readonly locked bitAnd(uint other) => (uint)`

Computes the bitwise AND of the value and a `uint`

value.

`other`

- value to bitwise AND with

result of bitwise AND

`public readonly locked bitAnd(ulong other) => (ulong)`

Computes the bitwise AND of the value and a `ulong`

value.

`other`

- value to bitwise AND with

result of bitwise AND

`public readonly locked bitComplement() => (ushort)`

`public readonly locked bitOr(int other) => (int)`

Computes the bitwise OR of the value and an `int`

value.

`other`

- value to bitwise OR with

result of bitwise OR

`public readonly locked bitOr(long other) => (long)`

Computes the bitwise OR of the value and a `long`

value.

`other`

- value to bitwise OR with

result of bitwise OR

`public readonly locked bitOr(uint other) => (uint)`

Computes the bitwise OR of the value and a `uint`

value.

`other`

- value to bitwise OR with

result of bitwise OR

`public readonly locked bitOr(ulong other) => (ulong)`

Computes the bitwise OR of the value and a `ulong`

value.

`other`

- value to bitwise OR with

result of bitwise OR

`public readonly locked bitRotateLeft(int amount) => (ushort)`

Finds the result of left-rotating the bits of the `ushort`

value by a signed amount which may be positive, negative, or zero.

`amount`

- bits to rotate

rotated value

`public readonly locked bitRotateRight(int amount) => (ushort)`

Finds the result of right-rotating the bits of the `ushort`

value by a signed amount which may be positive, negative, or zero.

`amount`

- bits to rotate

rotated value

`public readonly locked bitShiftLeft(int amount) => (ushort)`

Finds the result of left-shifting the bits of the `ushort`

value by a signed amount which may be positive, negative, or zero.

`amount`

- bits to shift

shifted value

`public readonly locked bitShiftRight(int amount) => (ushort)`

Finds the result of right-shifting the bits of the `ushort`

value by a signed amount which may be positive, negative, or zero.

`amount`

- bits to shift

shifted value

`public readonly locked bitXor(int other) => (int)`

Computes the bitwise XOR of the value and an `int`

value.

`other`

- value to bitwise XOR with

result of bitwise XOR

`public readonly locked bitXor(long other) => (long)`

Computes the bitwise XOR of the value and a `long`

value.

`other`

- value to bitwise XOR with

result of bitwise XOR

`public readonly locked bitXor(uint other) => (uint)`

Computes the bitwise XOR of the value and a `uint`

value.

`other`

- value to bitwise XOR with

result of bitwise XOR

`public readonly locked bitXor(ulong other) => (ulong)`

Computes the bitwise XOR of the value and a `ulong`

value.

`other`

- value to bitwise XOR with

result of bitwise XOR

`public readonly locked compare(double other) => (int)`

Compares the current value to a `double`

, returning `-1`

, `0`

, or `1`

, if the current value is smaller than, equal to, or larger than the other value, respectively.

`other`

- value to compare to

whether smaller, equal, or larger

`public readonly locked compare(float other) => (int)`

Compares the current value to a `float`

, returning `-1`

, `0`

, or `1`

, if the current value is smaller than, equal to, or larger than the other value, respectively.

`other`

- value to compare to

whether smaller, equal, or larger

`public readonly locked compare(int other) => (int)`

Compares the current value to an `int`

, returning `-1`

, `0`

, or `1`

, if the current value is smaller than, equal to, or larger than the other value, respectively.

`other`

- value to compare to

whether smaller, equal, or larger

`public readonly locked compare(long other) => (int)`

Compares the current value to a `long`

, returning `-1`

, `0`

, or `1`

, if the current value is smaller than, equal to, or larger than the other value, respectively.

`other`

- value to compare to

whether smaller, equal, or larger

`public readonly locked compare(uint other) => (int)`

Compares the current value to a `uint`

, returning `-1`

, `0`

, or `1`

, if the current value is smaller than, equal to, or larger than the other value, respectively.

`other`

- value to compare to

whether smaller, equal, or larger

`public readonly locked compare(ulong other) => (int)`

Compares the current value to a `ulong`

, returning `-1`

, `0`

, or `1`

, if the current value is smaller than, equal to, or larger than the other value, respectively.

`other`

- value to compare to

whether smaller, equal, or larger

`public readonly copy(AddressMap addresses) => (ushort)`

`public readonly locked cos() => (double)`

Finds the cosine of the current value.

cosine of the value

`public readonly locked divide(double other) => (double)`

Divides the current value by a `double`

and returns the quotient.

`other`

- value to divide by

quotient of the division

`public readonly locked divide(float other) => (float)`

Divides the current value by a `float`

and returns the quotient.

`other`

- value to divide by

quotient of the division

`public readonly locked divide(int other) => (int)`

Divides the current value by an `int`

and returns the quotient.

`other`

- value to divide by

quotient of the division

`public readonly locked divide(long other) => (long)`

Divides the current value by a `long`

and returns the quotient.

`other`

- value to divide by

quotient of the division

`public readonly locked divide(uint other) => (uint)`

Divides the current value by a `uint`

and returns the quotient.

`other`

- value to divide by

quotient of the division

`public readonly locked divide(ulong other) => (ulong)`

Divides the current value by a `ulong`

and returns the quotient.

`other`

- value to divide by

quotient of the division

`public readonly locked equal(double other) => (boolean)`

Compares the current value to a `double`

, returning `true`

if they represent the same number.

`other`

- value to compare to

`true`

if identical

`public readonly locked equal(float other) => (boolean)`

Compares the current value to a `float`

, returning `true`

if they represent the same number.

`other`

- value to compare to

`true`

if identical

`public readonly locked equal(int other) => (boolean)`

Compares the current value to an `int`

, returning `true`

if they represent the same number.

`other`

- value to compare to

`true`

if identical

`public readonly locked equal(long other) => (boolean)`

Compares the current value to a `long`

, returning `true`

if they represent the same number.

`other`

- value to compare to

`true`

if identical

`public readonly locked equal(uint other) => (boolean)`

Compares the current value to a `uint`

, returning `true`

if they represent the same number.

`other`

- value to compare to

`true`

if identical

`public readonly locked equal(ulong other) => (boolean)`

Compares the current value to a `ulong`

, returning `true`

if they represent the same number.

`other`

- value to compare to

`true`

if identical

`public readonly locked flipEndian() => (ushort)`

`public readonly locked leadingZeroes() => (ushort)`

`public readonly locked logBase10() => (double)`

Finds the logarithm base 10 of the current value.

logarithm base 10 of the value

`public readonly locked logBase2() => (double)`

Finds the logarithm base 2 of the current value.

logarithm base 2 of the value

`public readonly locked logBaseE() => (double)`

Finds the natural logarithm of the current value.

natural logarithm of the value

`public readonly locked max(ushort other) => (ushort)`

Finds the maximum of the current value and another `ushort`

.

`other`

- value

maximum value

`public readonly locked min(ushort other) => (ushort)`

Finds the minimum of the current value and another `ushort`

.

`other`

- value

minimum value

`public readonly locked modulus(double other) => (double)`

Divides the current value by a `double`

and returns the remainder.

`other`

- value to divide by

remainder of the division

`public readonly locked modulus(float other) => (float)`

Divides the current value by a `float`

and returns the remainder.

`other`

- value to divide by

remainder of the division

`public readonly locked modulus(int other) => (int)`

Divides the current value by an `int`

and returns the remainder.

`other`

- value to divide by

remainder of the division

`public readonly locked modulus(long other) => (long)`

Divides the current value by a `long`

and returns the remainder.

`other`

- value to divide by

remainder of the division

`public readonly locked modulus(uint other) => (uint)`

Divides the current value by a `uint`

and returns the remainder.

`other`

- value to divide by

remainder of the division

`public readonly locked modulus(ulong other) => (ulong)`

Divides the current value by a `ulong`

and returns the remainder.

`other`

- value to divide by

remainder of the division

`public readonly locked multiply(double other) => (double)`

Multiplies the current value by a `double`

and returns the resulting value.

`other`

- value to multiply by

product of the two values

`public readonly locked multiply(float other) => (float)`

Multiplies the current value by a `float`

and returns the resulting value.

`other`

- value to multiply by

product of the two values

`public readonly locked multiply(int other) => (int)`

Multiplies the current value by an `int`

and returns the resulting value.

`other`

- value to multiply by

product of the two values

`public readonly locked multiply(long other) => (long)`

Multiplies the current value by a `long`

and returns the resulting value.

`other`

- value to multiply by

product of the two values

`public readonly locked multiply(uint other) => (uint)`

Multiplies the current value by a `uint`

and returns the resulting value.

`other`

- value to multiply by

product of the two values

`public readonly locked multiply(ulong other) => (ulong)`

Multiplies the current value by a `ulong`

and returns the resulting value.

`other`

- value to multiply by

product of the two values

`public readonly locked ones() => (ushort)`

`public readonly locked power(double value) => (double)`

Raises the current value to the power of a `double`

.

`exponent`

- power to raise by

number after exponentiation

`public readonly locked power(int value) => (double)`

Raises the current value to the power of an `int`

.

`exponent`

- power to raise by

number after exponentiation

`public readonly locked sin() => (double)`

Finds the sine of the current value.

sine of the value

`public readonly locked squareRoot() => (double)`

Finds the square root of the value.

square root

`public readonly locked subtract(double other) => (double)`

Subtracts a `double`

from the current value and returns the resulting value.

`other`

- value to subtract

difference of the two values

`public readonly locked subtract(float other) => (float)`

Subtracts a `float`

from the current value and returns the resulting value.

`other`

- value to subtract

difference of the two values

`public readonly locked subtract(int other) => (int)`

Subtracts an `int`

from the current value and returns the resulting value.

`other`

- value to subtract

difference of the two values

`public readonly locked subtract(long other) => (long)`

Subtracts a `long`

from the current value and returns the resulting value.

`other`

- value to subtract

difference of the two values

`public readonly locked subtract(uint other) => (uint)`

Subtracts a `uint`

from the current value and returns the resulting value.

`other`

- value to subtract

difference of the two values

`public readonly locked subtract(ulong other) => (ulong)`

Subtracts a `ulong`

from the current value and returns the resulting value.

`other`

- value to subtract

difference of the two values

`public readonly locked tan() => (double)`

Finds the tangent of the current value.

tangent of the value

`public readonly locked toByte() => (byte)`

`public readonly locked toCode() => (code)`

`public readonly locked toDouble() => (double)`

`public readonly locked toFloat() => (float)`

`public readonly locked toInt() => (int)`

`public readonly locked toLong() => (long)`

`public readonly locked toShort() => (short)`

`public readonly locked toSigned() => (short)`

Returns a signed version of the current value, overflowing if too large.

signed value

`public readonly locked toString() => (String)`

Returns a `String`

representation of the value, in base 10.

`String`

representation

`public readonly locked toString(uint base) => (String)`

Returns a `String`

representation of the value, in the specified base.

`base`

- base of output representation

`String`

representation

`public readonly locked toUByte() => (ubyte)`

`public readonly locked toUInt() => (uint)`

`public readonly locked toULong() => (ulong)`

`public readonly locked toUShort() => (ushort)`

`public readonly locked trailingZeroes() => (ushort)`

`public readonly get locked hash() => (ulong)`

Finds a hash value for the current value.

hash value