UInteger16 Summary The wrapper class for the unsigned short primitive type. Description The System.UInteger16 class represents 16-bit unsigned integers. The System.UInteger16 class is the wrapper class for the unsigned short primitive type. The range for 16-bit unsigned integers is [ 0, 65535 ] (inclusive). Examples Instantiation 123import System; System.UInteger16 x = new System.UInteger16(100); Auto-boxing 123import System; System.UInteger16 x = 100; Primitives Only 12unsigned short x = 1;unsigned short y = 2; Methods compareCompares the UInteger16 object to another UInteger16 object. fromStringConverts a string to an unsigned short value. fromStringOrConverts a string to its equivalent unsigned short value or the provided default value if the conversion fails. fromStringOrThrowConverts a string to a valid unsigned short value or throws an exception if the value cannot be converted. isEvenChecks if the number is an even number. isOddChecks if the number is an odd number. MAX_VALUERepresents the maximum value for the unsigned short type. MIN_VALUERepresents the minimum value for the unsigned short type. toBaseReturns a string representation of the integer value using the specified base. toBinaryReturns the binary (base 2) value of the integer. toDecimalReturns the decimal (base 10) value of the integer. toExponentialFormats the integer value using exponential notation. toExternalConverts the unsigned short value to its equivalent external value. toFixedFormats the integer value using fixed-point notation. toHexReturns the hexadecimal (base 16) value of the integer. toPrecisionFormats the integer value as a string to the given precision. toStringConverts the unsigned short value to an equivalent string value. UInteger16 (Constructor)Constructs a System.UInteger16 object. valueOfReturns the primitive unsigned short value wrapped by the System.UInteger16 object. Share HTML | BBCode | Direct Link