Doctrine


Doctrine\DBAL\Types\ObjectType
/Doctrine/DBAL/Types/ObjectType.php at line 10

Class ObjectType

Class:ObjectType - Superclass: Type
Type
⌊ ObjectType

public class ObjectType
extends Type

Type that maps a PHP object to a clob SQL type.

Since:
2.0
Author:
Roman Borschel

Fields inherited from Doctrine\DBAL\Types\Type
BIGINT, BOOLEAN, DATE, DATETIME, DECIMAL, INTEGER, OBJECT, SMALLINT, STRING, TARRAY, TEXT, TIME
Method Summary
mixed

convertToDatabaseValue(mixed value, AbstractPlatform platform)

Converts a value from its PHP representation to its database representation of this type.

mixed

convertToPHPValue(mixed value, AbstractPlatform platform)

Converts a value from its database representation to its PHP representation of this type.

string

getName()

Gets the name of this type.

void

getSqlDeclaration(array fieldDeclaration, AbstractPlatform platform)

Gets the SQL declaration snippet for a field of this type.

Methods inherited from Doctrine\DBAL\Types\Type
addType, convertToDatabaseValue, convertToPHPValue, getBindingType, getDefaultLength, getName, getSqlDeclaration, getType, getTypesMap, hasType, overrideType

Method Detail

/Doctrine/DBAL/Types/ObjectType.php at line 17

convertToDatabaseValue

public mixed convertToDatabaseValue(mixed value, AbstractPlatform platform)

Converts a value from its PHP representation to its database representation of this type.

Parameters:
value - The value to convert.
platform - The currently used database platform.
Returns:
The database representation of the value.

/Doctrine/DBAL/Types/ObjectType.php at line 22

convertToPHPValue

public mixed convertToPHPValue(mixed value, AbstractPlatform platform)

Converts a value from its database representation to its PHP representation of this type.

Parameters:
value - The value to convert.
platform - The currently used database platform.
Returns:
The PHP representation of the value.

/Doctrine/DBAL/Types/ObjectType.php at line 27

getName

public string getName()

Gets the name of this type.

Todo:
Needed?

/Doctrine/DBAL/Types/ObjectType.php at line 12

getSqlDeclaration

public void getSqlDeclaration(array fieldDeclaration, AbstractPlatform platform)

Gets the SQL declaration snippet for a field of this type.

Parameters:
fieldDeclaration - The field declaration.
platform - The currently used database platform.

Doctrine