|
PntValueValidator |
PntError |
PntErrorException |
PntErrorHandler |
PntGen |
PntIdentifiedOption |
PntIndex |
PntObject |
Template |
|
filter_var |
getDecimalPrecision |
getDerivedChangeConflictMessage |
getErrorInvalidNumber |
getInfiniteBig |
getInfiniteDate |
getInfiniteSmall |
getInfinity |
getInternalCharset |
getInternalDateFormat |
getInternalDecimalSeparator |
getInternalTimeFormat |
getInternalTimestampFormat |
getMaxValueFromMaxLength |
getNumberMaxValue |
getNumberMinValue |
getZeroDate |
initFromProp |
return null;
}
function validateString |
should return the same as a case sentitive = on database-stored values.
* expects a boolean or nu |
validate |
validateBoolean |
validateDate |
validateEmail |
validateNumber |
validateObject |
validateTime |
validateTimestamp |
validate_min_max |
|
<?php
/* Copyright (c) MetaClass, 2003-2013
Distrubuted and licensed under under the terms of the GNU Affero General Public License
version 3, or (at your option) any later version.
This program is distributed WITHOUT ANY WARRANTY; without even the implied warranty
of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the License, http://www.gnu.org/licenses/agpl.txt */
Gen::includeClass('PntValueValidator', 'pnt');
/** An object that checks values against its constraint settings and returns error messages.
* @see http://www.phppeanuts.org/site/index_php/Pagina/131
*
* This abstract superclass provides behavior for the concrete
* subclass ValueValidator in the root classFolder or in the application classFolder.
* To keep de application developers code (including localization overrides)
* separated from the framework code override methods in the
* concrete subclass rather then modify them here.
* @see http://www.phppeanuts.org/site/index_php/Menu/178
* @package pnt
*/
class PntValueValidator {
public $errorReadOnly='no changes allowed';
public $errorTooHigh='too high, max: ';
public $errorTooLow='too low, min: ';
public $errorTooShort='too short, min: ';
public $errorTooLong='too long, max: ';
public $errorInvalidEmail='invalid email address';
public $errorInvalidType='invalid type: ';
public $errorNotOfType='value must be a: ';
public $type;
public $readOnly;
public $minValue;
public $maxValue;
public $minLength;
public $maxLength;
public $decimal;
/** @return String the character encoding of domain model strings.
* The naming is to be compatible with http request header "content-type: text/html; charset= "
|
Copyright (c) MetaClass, 2003-
This code is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as
published by the Free Software Foundation, either version 3 of the
License, or (at your option) any later version.
This code is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
Click here for a copy of the license or see http://www.gnu.org/licenses/ .
|
|