|
Moodle
2.2.1
http://www.collinsharper.com
|


Public Member Functions | |
| __construct ($options) | |
| isValid ($value, $file=null) | |
Data Fields | |
| const | TOO_BIG = 'fileFilesSizeTooBig' |
| const | TOO_SMALL = 'fileFilesSizeTooSmall' |
| const | NOT_READABLE = 'fileFilesSizeNotReadable' |
Protected Attributes | |
| $_messageTemplates | |
| $_files | |
Definition at line 35 of file FilesSize.php.
| __construct | ( | $ | options | ) |
Sets validator options
Min limits the used diskspace for all files, when used with max=null it is the maximum filesize It also accepts an array with the keys 'min' and 'max'
| integer | array | Zend_Config | $options | Options for this validator |
Reimplemented from Zend_Validate_File_Size.
Definition at line 69 of file FilesSize.php.

| isValid | ( | $ | value, |
| $ | file = null |
||
| ) |
Defined by Zend_Validate_Interface
Returns true if and only if the disk usage of all files is at least min and not bigger than max (when max is not null).
| string | array | $value | Real file to check for size |
| array | $file | File data from Zend_File_Transfer |
Reimplemented from Zend_Validate_File_Size.
Definition at line 105 of file FilesSize.php.

$_files [protected] |
Definition at line 58 of file FilesSize.php.
$_messageTemplates [protected] |
array( self::TOO_BIG => "All files in sum should have a maximum size of '%max%' but '%size%' were detected", self::TOO_SMALL => "All files in sum should have a minimum size of '%min%' but '%size%' were detected", self::NOT_READABLE => "One or more files can not be read", )
Reimplemented from Zend_Validate_File_Size.
Definition at line 47 of file FilesSize.php.
| const NOT_READABLE = 'fileFilesSizeNotReadable' |
Definition at line 42 of file FilesSize.php.
| const TOO_BIG = 'fileFilesSizeTooBig' |
string Error constants
Reimplemented from Zend_Validate_File_Size.
Definition at line 40 of file FilesSize.php.
| const TOO_SMALL = 'fileFilesSizeTooSmall' |
Reimplemented from Zend_Validate_File_Size.
Definition at line 41 of file FilesSize.php.