forked from zendframework/zendframework
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'ZF-10637' of https://github.com/thomasweidner/zf2 into …
…hotfix/zf-10637
- Loading branch information
Showing
1 changed file
with
14 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,8 +13,8 @@ | |
* to [email protected] so we can send you a copy immediately. | ||
* | ||
* @category Zend | ||
* @package Zend_Validate | ||
* @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) | ||
* @package Zend_Validator | ||
* @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) | ||
* @license http://framework.zend.com/license/new-bsd New BSD License | ||
*/ | ||
|
||
|
@@ -38,13 +38,12 @@ | |
*/ | ||
class Size extends Validator\AbstractValidator | ||
{ | ||
/**#@+ | ||
/** | ||
* @const string Error constants | ||
*/ | ||
const TOO_BIG = 'fileSizeTooBig'; | ||
const TOO_SMALL = 'fileSizeTooSmall'; | ||
const NOT_FOUND = 'fileSizeNotFound'; | ||
/**#@-*/ | ||
|
||
/** | ||
* @var array Error message templates | ||
|
@@ -177,7 +176,11 @@ public function getMin($raw = false) | |
/** | ||
* Sets the minimum filesize | ||
* | ||
* @param integer $min The minimum filesize | ||
* Filesize can be an integer or an byte string | ||
* This includes 'B', 'kB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB' | ||
* For example: 2000, 2MB, 0.2GB | ||
* | ||
* @param integer|string $min The minimum filesize | ||
* @throws \Zend\Validator\Exception When min is greater than max | ||
* @return \Zend\Validator\File\Size Provides a fluent interface | ||
*/ | ||
|
@@ -217,9 +220,13 @@ public function getMax($raw = false) | |
/** | ||
* Sets the maximum filesize | ||
* | ||
* @param integer $max The maximum filesize | ||
* Filesize can be an integer or an byte string | ||
* This includes 'B', 'kB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB' | ||
* For example: 2000, 2MB, 0.2GB | ||
* | ||
* @param integer|string $max The maximum filesize | ||
* @throws \Zend\Validator\Exception When max is smaller than min | ||
* @return \Zend\Validator\StringLength Provides a fluent interface | ||
* @return \Zend\Validator\File\Size Provides a fluent interface | ||
*/ | ||
public function setMax($max) | ||
{ | ||
|