public function save($path,$name=null){
		if(!file_exists($path)){
			mkdir($path,0777,true);
		}

		$destinationPath=rtrim($path, '/');
		if($name){
			$destinationPath.='/'.$name;
		}
		else{
			$destinationPath.='/'.$this->name;
		}

		if(!copy($this->tmpName, $destinationPath)){
			//detect error reason
			$reason='Unknown';
			if(!file_exists($path)){
				$reason='Path "'.$path.'" not exists.';
			}
			else if(!is_writeable($path))
				$reason='Path "'.$path.'" required permission to write.';

			throw new FileFailSavedException($reason);
		}
	}