Moodle  2.2.1
http://www.collinsharper.com
Zend_Validate_Date Class Reference
Inheritance diagram for Zend_Validate_Date:
Collaboration diagram for Zend_Validate_Date:

Public Member Functions

 __construct ($options=array())
 getLocale ()
 setLocale ($locale=null)
 getFormat ()
 setFormat ($format=null)
 isValid ($value)

Data Fields

const INVALID = 'dateInvalid'
const INVALID_DATE = 'dateInvalidDate'
const FALSEFORMAT = 'dateFalseFormat'

Protected Attributes

 $_messageTemplates
 $_messageVariables
 $_format
 $_locale

Detailed Description

Definition at line 33 of file Date.php.


Constructor & Destructor Documentation

__construct ( options = array())

Sets validator options

Parameters:
string | Zend_Config$optionsOPTIONAL
Returns:
void

Definition at line 77 of file Date.php.

Here is the call graph for this function:


Member Function Documentation

getFormat ( )

Returns the locale option

Returns:
string|null

Definition at line 135 of file Date.php.

getLocale ( )

Returns the locale option

Returns:
string|Zend_Locale|null

Definition at line 112 of file Date.php.

isValid ( value)

Defined by Zend_Validate_Interface

Returns true if $value is a valid date of the format YYYY-MM-DD If optional $format or $locale is set the date format is checked according to Zend_Date, see Zend_Date::isDate()

Parameters:
string | array | Zend_Date$value
Returns:
boolean

Implements Zend_Validate_Interface.

Definition at line 162 of file Date.php.

Here is the call graph for this function:

setFormat ( format = null)

Sets the format option

Parameters:
string$format
Returns:
Zend_Validate_Date provides a fluent interface

Definition at line 146 of file Date.php.

Here is the caller graph for this function:

setLocale ( locale = null)

Sets the locale option

Parameters:
string | Zend_Locale$locale
Returns:
Zend_Validate_Date provides a fluent interface

Definition at line 123 of file Date.php.

Here is the caller graph for this function:


Field Documentation

$_format [protected]

Definition at line 62 of file Date.php.

$_locale [protected]

Definition at line 69 of file Date.php.

$_messageTemplates [protected]
Initial value:
 array(
        self::INVALID        => "Invalid type given, value should be string, integer, array or Zend_Date",
        self::INVALID_DATE   => "'%value%' does not appear to be a valid date",
        self::FALSEFORMAT    => "'%value%' does not fit the date format '%format%'",
    )

Reimplemented from Zend_Validate_Abstract.

Definition at line 44 of file Date.php.

$_messageVariables [protected]
Initial value:
 array(
        'format'  => '_format'
    )

Reimplemented from Zend_Validate_Abstract.

Definition at line 53 of file Date.php.

const FALSEFORMAT = 'dateFalseFormat'

Definition at line 37 of file Date.php.

const INVALID = 'dateInvalid'

Definition at line 35 of file Date.php.

const INVALID_DATE = 'dateInvalidDate'

Definition at line 36 of file Date.php.


The documentation for this class was generated from the following file:
 All Data Structures Namespaces Files Functions Variables Enumerations