toHalf

Converts this double-precision float value into a half-precision float value. The following special cases are handled:

Return

A half-precision float value


Converts this single-precision float value into a half-precision float value. The following special cases are handled:

Return

A half-precision float value


Returns the half-precision float value represented by the specified string. The string is converted to a half-precision float value as if by the String.toFloat() method.

Calling this function is equivalent to calling:

Half(value.toFloat())

See also

Throws

if the string does not contain a parsable number


Returns the half-precision float value represented by the specified Rational.