<?php

/**
 * This class has been auto-generated by the Doctrine ORM Framework
 */
abstract class BaseThdFilm extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('thd_film');
        $this->hasColumn('id', 'integer', 4, array(
             'type' => 'integer',
             'unsigned' => '1',
             'primary' => true,
             'autoincrement' => true,
             'length' => '4',
             ));
        $this->hasColumn('ref', 'string', 255, array(
             'type' => 'string',
             'notnull' => true,
             'length' => '255',
             ));
        $this->hasColumn('title', 'string', 255, array(
             'type' => 'string',
             'notnull' => true,
             'length' => '255',
             ));
        $this->hasColumn('pitch', 'string', 2147483647, array(
             'type' => 'string',
             'notnull' => true,
             'length' => '2147483647',
             ));
        $this->hasColumn('duration', 'integer', 4, array(
             'type' => 'integer',
             'notnull' => true,
             'length' => '4',
             ));
        $this->hasColumn('directors', 'string', 2147483647, array(
             'type' => 'string',
             'notnull' => true,
             'length' => '2147483647',
             ));
        $this->hasColumn('actors', 'string', 2147483647, array(
             'type' => 'string',
             'notnull' => true,
             'length' => '2147483647',
             ));
        $this->hasColumn('slug_url', 'string', 255, array(
             'type' => 'string',
             'notnull' => true,
             'length' => '255',
             ));
        $this->hasColumn('original_title', 'string', 255, array(
             'type' => 'string',
             'length' => '255',
             ));
        $this->hasColumn('production_countries', 'string', 2147483647, array(
             'type' => 'string',
             'notnull' => true,
             'length' => '2147483647',
             ));
        $this->hasColumn('production_year', 'integer', 8, array(
             'type' => 'integer',
             'length' => '8',
             ));
        $this->hasColumn('uniqueid', 'string', 36, array(
             'type' => 'string',
             'notnull' => true,
             'length' => '36',
             ));


        $this->index('uniqueidindex', array(
             'fields' => 
             array(
              0 => 'uniqueid',
             ),
             'type' => 'unique',
             ));
    }

    public function setUp()
    {
        parent::setUp();
    $this->hasMany('ThdImage as images', array(
             'local' => 'id',
             'foreign' => 'film_id'));

        $this->hasMany('ThdVideo as videos', array(
             'local' => 'id',
             'foreign' => 'film_id'));
    }
}