AbstractPrimitiveType
in package
implements
PrimitiveTypeInterface
AbstractYes
This is a simple Primitive Type implementation that other Primitive Type can inherit from.
Table of Contents
Interfaces
- PrimitiveTypeInterface
- Describes Primitive Type interface.
Methods
- boolean() : bool
- Retrieve random boolean.
- float() : float
- Retrieve random float.
- integer() : int
- Retrieve random integer.
- mixed() : mixed
- Retrieve random mixed.
- string() : string
- Retrieve random string.
Methods
boolean()
Retrieve random boolean.
public
boolean() : bool
Return values
boolfloat()
Retrieve random float.
public
float([float $Min = PHP_FLOAT_MIN ][, float $Max = PHP_FLOAT_MAX ][, int $Precision = 2 ]) : float
Parameters
- $Min : float = PHP_FLOAT_MIN
-
The minimum number.
- $Max : float = PHP_FLOAT_MAX
-
The maximum number.
- $Precision : int = 2
-
The precision number.
Return values
floatinteger()
Retrieve random integer.
public
integer([int $Min = PHP_INT_MIN ][, int $Max = PHP_INT_MAX ]) : int
Parameters
- $Min : int = PHP_INT_MIN
-
The minimum number.
- $Max : int = PHP_INT_MAX
-
The maximum number.
Return values
intmixed()
Retrieve random mixed.
public
mixed() : mixed
string()
Retrieve random string.
public
string([int $Length = 8 ][, string $Characters = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-._~+/" ]) : string
Parameters
- $Length : int = 8
-
The character length.
- $Characters : string = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-._~+/"
-
The character possibility.