58 *
59 * The class {@code java.lang.Double} has a {@linkplain
60 * Double##equivalenceRelation discussion of equality,
61 * equivalence, and comparison of floating-point values} that is
62 * equally applicable to {@code float} values.
63 *
64 * <h2><a id=decimalToBinaryConversion>Decimal ↔ Binary Conversion Issues</a></h2>
65 *
66 * The {@linkplain Double##decimalToBinaryConversion discussion of binary to
67 * decimal conversion issues} in {@code java.lang.Double} is also
68 * applicable to {@code float} values.
69 *
70 * @see <a href="https://standards.ieee.org/ieee/754/6210/">
71 * <cite>IEEE Standard for Floating-Point Arithmetic</cite></a>
72 *
73 * @author Lee Boynton
74 * @author Arthur van Hoff
75 * @author Joseph D. Darcy
76 * @since 1.0
77 */
78 @jdk.internal.ValueBased
79 public final class Float extends Number
80 implements Comparable<Float>, Constable, ConstantDesc {
81 /**
82 * A constant holding the positive infinity of type
83 * {@code float}. It is equal to the value returned by
84 * {@code Float.intBitsToFloat(0x7f800000)}.
85 */
86 public static final float POSITIVE_INFINITY = 1.0f / 0.0f;
87
88 /**
89 * A constant holding the negative infinity of type
90 * {@code float}. It is equal to the value returned by
91 * {@code Float.intBitsToFloat(0xff800000)}.
92 */
93 public static final float NEGATIVE_INFINITY = -1.0f / 0.0f;
94
95 /**
96 * A constant holding a Not-a-Number (NaN) value of type
97 * {@code float}. It is equivalent to the value returned by
|
58 *
59 * The class {@code java.lang.Double} has a {@linkplain
60 * Double##equivalenceRelation discussion of equality,
61 * equivalence, and comparison of floating-point values} that is
62 * equally applicable to {@code float} values.
63 *
64 * <h2><a id=decimalToBinaryConversion>Decimal ↔ Binary Conversion Issues</a></h2>
65 *
66 * The {@linkplain Double##decimalToBinaryConversion discussion of binary to
67 * decimal conversion issues} in {@code java.lang.Double} is also
68 * applicable to {@code float} values.
69 *
70 * @see <a href="https://standards.ieee.org/ieee/754/6210/">
71 * <cite>IEEE Standard for Floating-Point Arithmetic</cite></a>
72 *
73 * @author Lee Boynton
74 * @author Arthur van Hoff
75 * @author Joseph D. Darcy
76 * @since 1.0
77 */
78 @jdk.internal.MigratedValueClass
79 @jdk.internal.ValueBased
80 public final class Float extends Number
81 implements Comparable<Float>, Constable, ConstantDesc {
82 /**
83 * A constant holding the positive infinity of type
84 * {@code float}. It is equal to the value returned by
85 * {@code Float.intBitsToFloat(0x7f800000)}.
86 */
87 public static final float POSITIVE_INFINITY = 1.0f / 0.0f;
88
89 /**
90 * A constant holding the negative infinity of type
91 * {@code float}. It is equal to the value returned by
92 * {@code Float.intBitsToFloat(0xff800000)}.
93 */
94 public static final float NEGATIVE_INFINITY = -1.0f / 0.0f;
95
96 /**
97 * A constant holding a Not-a-Number (NaN) value of type
98 * {@code float}. It is equivalent to the value returned by
|