Float

scala.Float
See theFloat companion class
object Float

Attributes

Companion
class
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Float.type

Members list

Value members

Concrete methods

def box(x: Float): Float

Transforms a value type into a boxed reference type.

Transforms a value type into a boxed reference type.

Runtime implementation determined by scala.runtime.BoxesRunTime.boxToFloat. See src/library/scala/runtime/BoxesRunTime.java.

Value parameters

x

the Float to be boxed

Attributes

Returns

a java.lang.Float offering x as its underlying value.

override def toString: String

The String representation of the scala.Float companion object.

The String representation of the scala.Float companion object.

Attributes

Definition Classes
Any
def unbox(x: Object): Float

Transforms a boxed type into a value type. Note that this method is not typesafe: it accepts any Object, but will throw an exception if the argument is not a java.lang.Float.

Transforms a boxed type into a value type. Note that this method is not typesafe: it accepts any Object, but will throw an exception if the argument is not a java.lang.Float.

Runtime implementation determined by scala.runtime.BoxesRunTime.unboxToFloat. See src/library/scala/runtime/BoxesRunTime.java.

Value parameters

x

the java.lang.Float to be unboxed.

Attributes

Returns

the Float resulting from calling floatValue() on x

Throws
ClassCastException

if the argument is not a java.lang.Float

Concrete fields

final val MaxValue: 3.4028235E38f

The largest finite positive number representable as a Float.

The largest finite positive number representable as a Float.

Attributes

final val MinPositiveValue: 1.4E-45f

The smallest positive value greater than 0.0f which is representable as a Float.

The smallest positive value greater than 0.0f which is representable as a Float.

Attributes

final val MinValue: -3.4028235E38f

The negative number with the greatest (finite) absolute value which is representable by a Float. Note that it differs from java.lang.Float.MIN_VALUE, which is the smallest positive value representable by a Float. In Scala that number is called Float.MinPositiveValue.

The negative number with the greatest (finite) absolute value which is representable by a Float. Note that it differs from java.lang.Float.MIN_VALUE, which is the smallest positive value representable by a Float. In Scala that number is called Float.MinPositiveValue.

Attributes

final val NaN: NaNf
final val NegativeInfinity: -Infinityf
final val PositiveInfinity: Infinityf

Implicits

Implicits

implicit def float2double(x: Float): Double