Zend Framework
1.12
|
Public Member Functions | |
addValidator (Zend_Validate_Interface $validator, $breakChainOnFailure=false) | |
Adds a validator to the end of the chain. | |
isValid ($value) | |
Returns true if and only if $value passes all validations in the chain. | |
getMessages () | |
Defined by Zend_Validate_Interface. | |
getErrors () | |
Defined by Zend_Validate_Interface. | |
Static Public Member Functions | |
static | getDefaultNamespaces () |
Returns the set default namespaces. | |
static | setDefaultNamespaces ($namespace) |
Sets new default namespaces. | |
static | addDefaultNamespaces ($namespace) |
Adds a new default namespace. | |
static | hasDefaultNamespaces () |
Returns true when defaultNamespaces are set. | |
static | is ($value, $classBaseName, array $args=array(), $namespaces=array()) |
static | getMessageLength () |
Returns the maximum allowed message length. | |
static | setMessageLength ($length=-1) |
Sets the maximum allowed message length. | |
static | getDefaultTranslator ($translator=null) |
Returns the default translation object. | |
static | setDefaultTranslator ($translator=null) |
Sets a default translation object for all validation objects. | |
Protected Attributes | |
$_validators = array() | |
$_messages = array() | |
$_errors = array() | |
Static Protected Attributes | |
static | $_defaultNamespaces = array() |
|
static |
Adds a new default namespace.
array | string | $namespace |
addValidator | ( | Zend_Validate_Interface | $validator, |
$breakChainOnFailure = false |
|||
) |
Adds a validator to the end of the chain.
If $breakChainOnFailure is true, then if the validator fails, the next validator in the chain, if one exists, will not be executed.
Zend_Validate_Interface | $validator | |
boolean | $breakChainOnFailure |
|
static |
Returns the set default namespaces.
|
static |
Returns the default translation object.
getErrors | ( | ) |
Defined by Zend_Validate_Interface.
Returns array of validation failure message codes
|
static |
Returns the maximum allowed message length.
getMessages | ( | ) |
Defined by Zend_Validate_Interface.
Returns array of validation failure messages
Implements Zend_Validate_Interface.
|
static |
Returns true when defaultNamespaces are set.
|
static |
mixed | $value | |
string | $classBaseName | |
array | $args | OPTIONAL |
mixed | $namespaces | OPTIONAL |
Zend_Validate_Exception |
isValid | ( | $value | ) |
Returns true if and only if $value passes all validations in the chain.
Validators are run in the order in which they were added to the chain (FIFO).
mixed | $value |
Implements Zend_Validate_Interface.
|
static |
Sets new default namespaces.
array | string | $namespace |
|
static |
Sets a default translation object for all validation objects.
Zend_Translate | Zend_Translate_Adapter | null | $translator |
|
static |
Sets the maximum allowed message length.
integer | $length |
|
staticprotected |
|
protected |
|
protected |
|
protected |