[ Index ] |
|
Code source de Symfony 1.0.0 |
1 <?php 2 /* 3 * $Id: ValidatorMap.php 64 2005-05-13 02:43:56Z root $ 4 * 5 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 6 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 7 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 8 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 9 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 10 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 11 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 12 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 13 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 14 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 15 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 16 * 17 * This software consists of voluntary contributions made by many individuals 18 * and is licensed under the LGPL. For more information please see 19 * <http://propel.phpdb.org>. 20 */ 21 22 /** 23 * ValidatorMap is used to model a column validator. 24 * 25 * GENERAL NOTE 26 * ------------ 27 * The propel.map classes are abstract building-block classes for modeling 28 * the database at runtime. These classes are similar (a lite version) to the 29 * propel.engine.database.model classes, which are build-time modeling classes. 30 * These classes in themselves do not do any database metadata lookups, but instead 31 * are used by the MapBuilder classes that were generated for your datamodel. The 32 * MapBuilder that was created for your datamodel build a representation of your 33 * database by creating instances of the DatabaseMap, TableMap, ColumnMap, etc. 34 * classes. See propel/templates/om/php5/MapBuilder.tpl and the classes generated 35 * by that template for your datamodel to further understand how these are put 36 * together. 37 * 38 * @author Michael Aichler <aichler@mediacluster.de> 39 * @version $Revision: 64 $ 40 * @package propel.map 41 */ 42 class ValidatorMap 43 { 44 /** rule name of this validator */ 45 private $name; 46 /** the dot-path to class to use for validator */ 47 private $classname; 48 /** value to check against */ 49 private $value; 50 /** execption message thrown on invalid input */ 51 private $message; 52 /** related column */ 53 private $column; 54 55 public function __construct($containingColumn) 56 { 57 $this->column = $containingColumn; 58 } 59 60 public function getColumn() 61 { 62 return $this->column; 63 } 64 65 public function getColumnName() 66 { 67 return $this->column->getColumnName(); 68 } 69 70 public function setName($name) 71 { 72 $this->name = $name; 73 } 74 75 public function setClass($classname) 76 { 77 $this->classname = $classname; 78 } 79 80 public function setValue($value) 81 { 82 $this->value = $value; 83 } 84 85 public function setMessage($message) 86 { 87 $this->message = $message; 88 } 89 90 public function getName() 91 { 92 return $this->name; 93 } 94 95 public function getClass() 96 { 97 return $this->classname; 98 } 99 100 public function getValue() 101 { 102 return $this->value; 103 } 104 105 public function getMessage() 106 { 107 return $this->message; 108 } 109 }
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Fri Mar 16 22:42:14 2007 | par Balluche grâce à PHPXref 0.7 |