<?php
// Connection Component Binding
Doctrine_Manager::getInstance()->bindComponent('RMN_MODALIDAD', 'doctrine');

/**
 * BaseRMN_MODALIDAD
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 * 
 * @property integer $id_modalidad
 * @property integer $id_ley
 * @property string $nombre
 * @property integer $estado
 * @property integer $duracion_meses
 * @property Doctrine_Collection $RMN_TITULO_MODALIDAD
 * @property Doctrine_Collection $RMN_SOLICITUD
 * @property Doctrine_Collection $CA_MODALIDAD_NORMA
 * @property Doctrine_Collection $CA_ETAPA_MODALIDAD
 * 
 * @method integer             getIdModalidad()          Returns the current record's "id_modalidad" value
 * @method integer             getIdLey()                Returns the current record's "id_ley" value
 * @method string              getNombre()               Returns the current record's "nombre" value
 * @method integer             getEstado()               Returns the current record's "estado" value
 * @method integer             getDuracionMeses()        Returns the current record's "duracion_meses" value
 * @method Doctrine_Collection getRMNTITULOMODALIDAD()   Returns the current record's "RMN_TITULO_MODALIDAD" collection
 * @method Doctrine_Collection getRMNSOLICITUD()         Returns the current record's "RMN_SOLICITUD" collection
 * @method Doctrine_Collection getCAMODALIDADNORMA()     Returns the current record's "CA_MODALIDAD_NORMA" collection
 * @method Doctrine_Collection getCAETAPAMODALIDAD()     Returns the current record's "CA_ETAPA_MODALIDAD" collection
 * @method RMN_MODALIDAD       setIdModalidad()          Sets the current record's "id_modalidad" value
 * @method RMN_MODALIDAD       setIdLey()                Sets the current record's "id_ley" value
 * @method RMN_MODALIDAD       setNombre()               Sets the current record's "nombre" value
 * @method RMN_MODALIDAD       setEstado()               Sets the current record's "estado" value
 * @method RMN_MODALIDAD       setDuracionMeses()        Sets the current record's "duracion_meses" value
 * @method RMN_MODALIDAD       setRMNTITULOMODALIDAD()   Sets the current record's "RMN_TITULO_MODALIDAD" collection
 * @method RMN_MODALIDAD       setRMNSOLICITUD()         Sets the current record's "RMN_SOLICITUD" collection
 * @method RMN_MODALIDAD       setCAMODALIDADNORMA()     Sets the current record's "CA_MODALIDAD_NORMA" collection
 * @method RMN_MODALIDAD       setCAETAPAMODALIDAD()     Sets the current record's "CA_ETAPA_MODALIDAD" collection
 * 
 * @package    canon
 * @subpackage model
 * @author     Your name here
 * @version    SVN: $Id: Builder.php 7691 2011-02-04 15:43:29Z jwage $
 */
abstract class BaseRMN_MODALIDAD extends sfDoctrineRecord
{
    public function setTableDefinition()
    {
        $this->setTableName('RMN_MODALIDAD');
        $this->hasColumn('id_modalidad', 'integer', 8, array(
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => true,
             'length' => 8,
             ));
        $this->hasColumn('id_ley', 'integer', 8, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 8,
             ));
        $this->hasColumn('nombre', 'string', 64, array(
             'notnull' => true,
             'type' => 'string',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 64,
             ));
        $this->hasColumn('estado', 'integer', 1, array(
             'notnull' => true,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'default' => '0',
             'primary' => false,
             'length' => 1,
             ));
        $this->hasColumn('duracion_meses', 'integer', 8, array(
             'notnull' => false,
             'type' => 'integer',
             'fixed' => 0,
             'unsigned' => false,
             'primary' => false,
             'length' => 8,
             ));
    }

    public function setUp()
    {
        parent::setUp();
        $this->hasMany('RMN_TITULO_MODALIDAD', array(
             'local' => 'id_modalidad',
             'foreign' => 'id_modalidad'));

        $this->hasMany('RMN_SOLICITUD', array(
             'local' => 'id_modalidad',
             'foreign' => 'id_modalidad'));

        $this->hasMany('CA_MODALIDAD_NORMA', array(
             'local' => 'id_modalidad',
             'foreign' => 'id_modalidad'));

        $this->hasMany('CA_ETAPA_MODALIDAD', array(
             'local' => 'id_modalidad',
             'foreign' => 'id_modalidad'));
    }
}