Changeset 4062

Show
Ignore:
Timestamp:
03/21/08 04:21:00 (16 months ago)
Author:
jwage
Message:

fixes #886

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • branches/0.10/lib/Doctrine/Import/Schema.php

    r4059 r4062  
    114114                                                          'keyField', 
    115115                                                          'keyValue')); 
     116 
     117    /** 
     118     * _validators 
     119     * 
     120     * Array of available validators 
     121     * 
     122     * @see getValidators() 
     123     * @var array Array of available validators 
     124     */ 
     125    protected $_validators = array(); 
     126 
     127    /** 
     128     * getValidators 
     129     * 
     130     * Retrieve the array of available validators 
     131     * 
     132     * @return array 
     133     */ 
     134    public function getValidators() 
     135    { 
     136        if (empty($this->_validators)) { 
     137            $this->_validators = Doctrine_Lib::getValidators(); 
     138        } 
     139 
     140        return $this->_validators; 
     141    } 
     142 
    116143    /** 
    117144     * getOption 
     
    348375 
    349376                    // Include all the specified and valid validators in the colDesc 
    350                     $validators = Doctrine_Lib::getValidators(); 
     377                    $validators = $this->getValidators(); 
    351378 
    352379                    foreach ($validators as $validator) { 
     
    643670        // This should be fixed, made cleaner 
    644671        if ($name == 'column') { 
    645             $validators = Doctrine_Lib::getValidators(); 
     672            $validators = $this->getValidators(); 
    646673            $validation = array_merge($validation, $validators); 
    647674        }