2007-09-02 18:24:49 +04:00
|
|
|
<?php
|
|
|
|
class SerializeTest extends Doctrine_Record
|
|
|
|
{
|
2008-02-04 00:29:57 +03:00
|
|
|
public static function initMetadata($class)
|
2007-09-02 18:24:49 +04:00
|
|
|
{
|
2008-02-04 00:29:57 +03:00
|
|
|
$class->setTableName('serialize_test');
|
2007-09-02 18:24:49 +04:00
|
|
|
|
2008-02-04 00:29:57 +03:00
|
|
|
$class->setColumn('booltest', 'boolean');
|
|
|
|
$class->setColumn('integertest', 'integer', 4, array('unsigned' => true));
|
|
|
|
$class->setColumn('floattest', 'float');
|
|
|
|
$class->setColumn('stringtest', 'string', 200, array('fixed' => true));
|
|
|
|
$class->setColumn('arraytest', 'array', 10000);
|
|
|
|
$class->setColumn('objecttest', 'object');
|
|
|
|
$class->setColumn('blobtest', 'blob');
|
|
|
|
$class->setColumn('clobtest', 'clob');
|
|
|
|
$class->setColumn('timestamptest', 'timestamp');
|
|
|
|
$class->setColumn('timetest', 'time');
|
|
|
|
$class->setColumn('datetest', 'date');
|
|
|
|
$class->setColumn('enumtest', 'enum', 4,
|
2007-09-02 18:24:49 +04:00
|
|
|
array(
|
|
|
|
'values' => array(
|
|
|
|
'php',
|
|
|
|
'java',
|
|
|
|
'python'
|
|
|
|
)
|
|
|
|
)
|
|
|
|
);
|
2008-02-04 00:29:57 +03:00
|
|
|
$class->setColumn('gziptest', 'gzip');
|
2007-09-02 18:24:49 +04:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|