class FloatType extends Type (View source)

Constants

MIXED

TARRAY

BOOLEAN

DATETIME

FLOAT

INTEGER

OBJECT

STRING

Methods

__construct()

No description

from Type
mixed
convertToCouchDBValue(mixed $value)

No description

mixed
convertToPHPValue(mixed $value)

No description

static Type
getType(string $name)

Factory method to create type instances.

from Type
static 
addType(string $name, string $className)

Adds a custom type to the type map.

from Type
static boolean
hasType(string $name)

Checks if exists support for a type.

from Type
static 
overrideType(string $name, string $className)

Overrides an already defined type to use a different implementation.

from Type
static array
getTypesMap()

Get the types array map which holds all registered types and the corresponding type class

from Type
__toString()

No description

from Type

Details

protected __construct()

mixed convertToCouchDBValue(mixed $value)

Parameters

mixed $value

Return Value

mixed

mixed convertToPHPValue(mixed $value)

Parameters

mixed $value

Return Value

mixed

static Type getType(string $name)

Factory method to create type instances.

Type instances are implemented as flyweights.

Parameters

string $name The name of the type (as returned by getName()).

Return Value

Type

Exceptions

TypeException

static addType(string $name, string $className)

Adds a custom type to the type map.

Parameters

string $name Name of the type. This should correspond to what getName() returns.
string $className The class name of the custom type.

Exceptions

CouchDBException

static boolean hasType(string $name)

Checks if exists support for a type.

Parameters

string $name Name of the type

Return Value

boolean TRUE if type is supported; FALSE otherwise

static overrideType(string $name, string $className)

Overrides an already defined type to use a different implementation.

Parameters

string $name
string $className

Exceptions

CouchDBException

static array getTypesMap()

Get the types array map which holds all registered types and the corresponding type class

Return Value

array $typesMap

__toString()