Public Member Functions | |
__construct ($options) | |
getHash () | |
setHash ($options) | |
addHash ($options) | |
isValid ($value, $file=null) | |
Data Fields | |
const | DOES_NOT_MATCH = 'fileHashDoesNotMatch' |
const | NOT_DETECTED = 'fileHashHashNotDetected' |
const | NOT_FOUND = 'fileHashNotFound' |
Protected Member Functions | |
_throw ($file, $errorType) | |
Protected Attributes | |
$_messageTemplates | |
$_hash |
Definition at line 35 of file Hash.php.
__construct | ( | $ | options ) |
Sets validator options
string | array | $options |
Reimplemented in Zend_Validate_File_Crc32, Zend_Validate_File_Md5, and Zend_Validate_File_Sha1.
_throw | ( | $ | file, |
$ | errorType | ||
) | [protected] |
addHash | ( | $ | options ) |
Adds the hash for one or multiple files
string | array | $options |
Reimplemented in Zend_Validate_File_Crc32, Zend_Validate_File_Md5, and Zend_Validate_File_Sha1.
getHash | ( | ) |
isValid | ( | $ | value, |
$ | file = null |
||
) |
Defined by Zend_Validate_Interface
Returns true if and only if the given file confirms the set hash
string | $value | Filename to check for hash |
array | $file | File data from Zend_File_Transfer |
Reimplemented in Zend_Validate_File_Crc32, Zend_Validate_File_Md5, and Zend_Validate_File_Sha1.
setHash | ( | $ | options ) |
Sets the hash for one or multiple files
string | array | $options |
Reimplemented in Zend_Validate_File_Crc32, Zend_Validate_File_Md5, and Zend_Validate_File_Sha1.
$_messageTemplates [protected] |
array( self::DOES_NOT_MATCH => "The file '%value%' does not match the given hashes", self::NOT_DETECTED => "There was no hash detected for the given file", self::NOT_FOUND => "The file '%value%' could not be found" )
Reimplemented from Zend_Validate_Abstract.
const DOES_NOT_MATCH = 'fileHashDoesNotMatch' |
string Error constants
Reimplemented in Zend_Validate_File_Crc32, Zend_Validate_File_Md5, and Zend_Validate_File_Sha1.