Copied!

Percent

Percent.php : 16
Implements Stringable

VO representing percent value e.g. 25%.

Properties

public $value

Percent.php : 20
public float $value

Methods

public__construct()

Percent.php : 22
public __construct(float $value)

Parameters

Name Type Default value Description
$value float - -

public__toString()

Percent.php : 42
public __toString() : string

Return values

string

publicequals()

Percent.php : 37
public equals(Percent $percent[, float $epsilon = self::DEFAULT_EPSILON ]) : bool

Parameters

Name Type Default value Description
$percent Percent - -
$epsilon float Percent::DEFAULT_EPSILON -

Return values

bool

publicfraction()

Percent.php : 47
public fraction(float $a, float $b) : Percent

Parameters

Name Type Default value Description
$a float - -
$b float - -

Return values

Percent

publicgetValue()

Percent.php : 27
public getValue() : float

Return values

float

publicgetValueAsFloat()

Percent.php : 32
public getValueAsFloat() : float

Return values

float

publichundred()

Percent.php : 68
public static hundred() : self

Return values

self

publiczero()

Percent.php : 58
public static zero() : self

Return values

self