<?php
// Connection Component Binding
Doctrine_Manager::getInstance()->bindComponent('PollResults', 'doctrine');

/**
 * BasePollResults
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property integer $id
 * @property integer $poll_id
 * @property integer $question_id
 * @property timestamp $created_at
 * @property Poll $Poll
 * @property PollQuestion $PollQuestion
 * 
 * @method integer      getId()           Returns the current record's "id" value
 * @method integer      getPollId()       Returns the current record's "poll_id" value
 * @method integer      getQuestionId()   Returns the current record's "question_id" value
 * @method timestamp    getCreatedAt()    Returns the current record's "created_at" value
 * @method Poll         getPoll()         Returns the current record's "Poll" value
 * @method PollQuestion getPollQuestion() Returns the current record's "PollQuestion" value
 * @method PollResults  setId()           Sets the current record's "id" value
 * @method PollResults  setPollId()       Sets the current record's "poll_id" value
 * @method PollResults  setQuestionId()   Sets the current record's "question_id" value
 * @method PollResults  setCreatedAt()    Sets the current record's "created_at" value
 * @method PollResults  setPoll()         Sets the current record's "Poll" value
 * @method PollResults  setPollQuestion() Sets the current record's "PollQuestion" value
 * 
 * @package    mongolcom
 * @subpackage model
 * @author     Your name here
 * @version    SVN: $Id: Builder.php 7490 2010-03-29 19:53:27Z jwage $
 */
abstract class BasePollResults extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('poll_results');
        $this->hasColumn('id', 'integer', 4, array(
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => true,
             'autoincrement' => true,
             'length' => 4,
             ));
        $this->hasColumn('poll_id', 'integer', 4, array(
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'notnull' => true,
             'autoincrement' => false,
             'length' => 4,
             ));
        $this->hasColumn('question_id', 'integer', 4, array(
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'notnull' => true,
             'autoincrement' => false,
             'length' => 4,
             ));
        $this->hasColumn('created_at', 'timestamp', 25, array(
             'type' => 'timestamp',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'notnull' => true,
             'autoincrement' => false,
             'length' => 25,
             ));
    }

    public function setUp()
    {
        parent::setUp();
        $this->hasOne('Poll', array(
             'local' => 'poll_id',
             'foreign' => 'id'));

        $this->hasOne('PollQuestion', array(
             'local' => 'question_id',
             'foreign' => 'id'));
    }
}