code: public function setMaxSize($maxSize){
  		$serverMaxSize=$this->getServerMaxSize();
  		if($maxSize>$serverMaxSize){
  			throw new FileMaxSizeException($serverMaxSize);
  		}
  		$this->maxSize=$maxSize;
  		if($this->getValidator()){
  			$this->getValidator()->setOption('maxSize',$maxSize);
  		}
  	}
docs: Set max size file
  
  @param int $maxSize - size in bytes
  @throws FileMaxSizeException