A PHP representation of the CQL float datatype

Implements

Methods

__construct

( mixed $value )

Creates a new float.

Parameters:
Name Type Details
$value double|int|string|Cassandra\Float

A float value as a string, number or Cassandra\Float

string

__toString

( )

Returns string representation of the float value.

Returns:
Type Details
string

float value

Cassandra\Type

type

( )

The type of this float.

Returns:
Type Details
Cassandra\Type
float

value

( )

Returns the float value.

Returns:
Type Details
float

float value

bool

isInfinite

( )
Returns:
Type Details
bool
bool

isFinite

( )
Returns:
Type Details
bool
bool

isNaN

( )
Returns:
Type Details
bool
Parameters:
Name Type Details
$num Cassandra\Numeric

a number to add to this one

Returns:
Type Details
Cassandra\Numeric

sum

Parameters:
Name Type Details
$num Cassandra\Numeric

a number to subtract from this one

Returns:
Type Details
Cassandra\Numeric

difference

Parameters:
Name Type Details
$num Cassandra\Numeric

a number to multiply this one by

Returns:
Type Details
Cassandra\Numeric

product

Parameters:
Name Type Details
$num Cassandra\Numeric

a number to divide this one by

Returns:
Type Details
Cassandra\Numeric

quotient

Parameters:
Name Type Details
$num Cassandra\Numeric

a number to divide this one by

Returns:
Type Details
Cassandra\Numeric

remainder

Returns:
Type Details
Cassandra\Numeric

absolute value

Returns:
Type Details
Cassandra\Numeric

negative value

Returns:
Type Details
Cassandra\Numeric

square root

int

toInt

( )
Returns:
Type Details
int

this number as int

float

toDouble

( )
Returns:
Type Details
float

this number as float

static Cassandra\Float

min

( )

Minimum possible Cassandra\Float value

Static
This method is static
Returns:
Type Details
Cassandra\Float

minimum value

static Cassandra\Float

max

( )

Maximum possible Cassandra\Float value

Static
This method is static
Returns:
Type Details
Cassandra\Float

maximum value