TYPO3CMS  8
 All Classes Namespaces Files Functions Variables Pages
SchemaColumnDefinitionListener Class Reference

Public Member Functions

 onSchemaColumnDefinition (SchemaColumnDefinitionEventArgs $event)
 

Protected Member Functions

 getEnumerationTableColumnDefinition (array $tableColumn, AbstractPlatform $platform)
 
 getDatabaseType (string $typeDefiniton)
 
 getUnquotedEnumerationValues (string $typeDefiniton)
 

Detailed Description

Event listener to handle additional processing for custom doctrine types.

Definition at line 28 of file SchemaColumnDefinitionListener.php.

Member Function Documentation

getDatabaseType ( string  $typeDefiniton)
protected

Extract the field type from the definition string

Parameters
string$typeDefiniton
Returns
string

Definition at line 94 of file SchemaColumnDefinitionListener.php.

Referenced by SchemaColumnDefinitionListener\getEnumerationTableColumnDefinition(), and SchemaColumnDefinitionListener\onSchemaColumnDefinition().

getEnumerationTableColumnDefinition ( array  $tableColumn,
AbstractPlatform  $platform 
)
protected

Build a Doctrine column object for TYPE/TYPE columns.

Parameters
array$tableColumn
\Doctrine\DBAL\Platforms\AbstractPlatform$platform
Returns
Exceptions
Doctrine
Todo:
: The $tableColumn source currently only support MySQL definition style.

Definition at line 65 of file SchemaColumnDefinitionListener.php.

References SchemaColumnDefinitionListener\getDatabaseType(), and SchemaColumnDefinitionListener\getUnquotedEnumerationValues().

Referenced by SchemaColumnDefinitionListener\onSchemaColumnDefinition().

getUnquotedEnumerationValues ( string  $typeDefiniton)
protected
Parameters
string$typeDefiniton
Returns
array

Definition at line 106 of file SchemaColumnDefinitionListener.php.

Referenced by SchemaColumnDefinitionListener\getEnumerationTableColumnDefinition().

onSchemaColumnDefinition ( SchemaColumnDefinitionEventArgs  $event)

Listener for column definition events. This intercepts definitions for custom doctrine types and builds the appropriate Column Object.

Parameters
\Doctrine\DBAL\Event\SchemaColumnDefinitionEventArgs$event
Exceptions
Doctrine

Definition at line 37 of file SchemaColumnDefinitionListener.php.

References SchemaColumnDefinitionListener\getDatabaseType(), and SchemaColumnDefinitionListener\getEnumerationTableColumnDefinition().