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

Public Member Functions

 validate ($value)
 setName ($ruleName)
 getValidationScript ($options=null)

Data Fields

 $name

Detailed Description

Definition at line 21 of file Rule.php.


Member Function Documentation

getValidationScript ( options = null)

Returns the javascript test (the test should return true if the value is INVALID)

Parameters:
mixedOptions for the rule public
Returns:
array first element is code to setup validation, second is the check itself

Reimplemented in MoodleQuickForm_Rule_Required, HTML_QuickForm_Rule_Callback, HTML_QuickForm_Rule_Compare, HTML_QuickForm_Rule_Regex, HTML_QuickForm_Rule_Email, HTML_QuickForm_Rule_Range, and HTML_QuickForm_Rule_Required.

Definition at line 62 of file Rule.php.

setName ( ruleName)

Sets the rule name

public

Definition at line 50 of file Rule.php.

validate ( value)

Validates a value

public

Definition at line 40 of file Rule.php.


Field Documentation

$name

Definition at line 32 of file Rule.php.


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