Documentation

Floor

Table of Contents

floorCheck1Arg() void
floor() FLOOR. float|string
math() FLOOR.MATH. float|string
precise() FLOOR.PRECISE. float|string
argumentsOkPrecise() Avoid Scrutinizer problems concerning complexity. float|string
argsOk() Avoid Scrutinizer complexity problems. float|string
floorMathTest() Let FLOORMATH complexity pass Scrutinizer. bool
argumentsOk() Avoid Scrutinizer problems concerning complexity. float|string

Methods

floorCheck1Arg()

private static floorCheck1Arg( ) : void

floor()

FLOOR.

public static floor( $number : mixed [, $significance : mixed = null ] ) : float|string

Rounds number down, toward zero, to the nearest multiple of significance.

Excel Function: FLOOR(number[,significance])

Parameters
$number : mixed

Expect float. Number to round

$significance : mixed = null

Expect float. Significance

Return values
float|string —

Rounded Number, or a string containing an error

math()

FLOOR.MATH.

public static math( $number : mixed [, $significance : mixed = null ] , $mode : mixed ) : float|string

Round a number down to the nearest integer or to the nearest multiple of significance.

Excel Function: FLOOR.MATH(number[,significance[,mode]])

Parameters
$number : mixed

Number to round

$significance : mixed = null

Significance

$mode : mixed

direction to round negative numbers

Return values
float|string —

Rounded Number, or a string containing an error

precise()

FLOOR.PRECISE.

public static precise( $number : float [, $significance : float = 1 ] ) : float|string

Rounds number down, toward zero, to the nearest multiple of significance.

Excel Function: FLOOR.PRECISE(number[,significance])

Parameters
$number : float

Number to round

$significance : float = 1

Significance

Return values
float|string —

Rounded Number, or a string containing an error

argumentsOkPrecise()

Avoid Scrutinizer problems concerning complexity.

private static argumentsOkPrecise( $number : float , $significance : float ) : float|string
Parameters
$number : float
$significance : float
Return values
float|string

argsOk()

Avoid Scrutinizer complexity problems.

private static argsOk( $number : float , $significance : float , $mode : int ) : float|string
Parameters
$number : float
$significance : float
$mode : int
Return values
float|string —

Rounded Number, or a string containing an error

floorMathTest()

Let FLOORMATH complexity pass Scrutinizer.

private static floorMathTest( $number : float , $significance : float , $mode : int ) : bool
Parameters
$number : float
$significance : float
$mode : int
Return values
bool

argumentsOk()

Avoid Scrutinizer problems concerning complexity.

private static argumentsOk( $number : float , $significance : float ) : float|string
Parameters
$number : float
$significance : float
Return values
float|string

Search results