From 1c1c1609227ac2d757c074a4bb2c6df5d026bb51 Mon Sep 17 00:00:00 2001
From: Cristiano Magro <cristiano.magro@vola.it>
Date: Tue, 16 Jan 2018 16:08:36 +0100
Subject: [PATCH] PHPCBF Vola style formattazione codice
---
src/UploadFile/SetupUpload.class.php | 33 ++++++++++++++++++---------------
1 files changed, 18 insertions(+), 15 deletions(-)
diff --git a/src/UploadFile/SetupUpload.class.php b/src/UploadFile/SetupUpload.class.php
index fed2bed..2a92db4 100644
--- a/src/UploadFile/SetupUpload.class.php
+++ b/src/UploadFile/SetupUpload.class.php
@@ -8,7 +8,6 @@
* javascript di gestione del plupload
*
* @author Cristiano Magro
- *
*/
class SetupUpload {
@@ -58,10 +57,11 @@
/**
* Dimensione massima del singolo file caricato
- *
- * Accetta sia '1024' che '1 kb' effettuando la conversione interna
+ *
+ * Accetta sia '1024' che '1 kb' effettuando la conversione interna
* necessaria.
- * @param string $x sia '1024' che '1 kb'
+ *
+ * @param string $x sia '1024' che '1 kb'
* @return \SetupUpload
*/
public function setSizeLimitFile($x) {
@@ -118,6 +118,7 @@
/**
* Restituisce il numero massimo di file previsti nella coda
+ *
* @return integer Max numero file
*/
public function getNumMaxFiles() {
@@ -126,12 +127,13 @@
/**
* Viene impostato il numero massimo di file caricabili
- * @param integer $numero
+ *
+ * @param integer $numero
* @return \SetupUpload fluent style
*/
public function setNumMaxFiles($numero) {
if (!is_integer($numero) || $numero <= 0) {
- throw new UploadFile_Exc();
+ throw new Upload_Exc_Error();
}
$this->numMaxFiles = $numero;
@@ -144,10 +146,11 @@
/**
* Dimensione Totale massima dei file caricabili
- *
- * Accetta sia '1024' che '1 kb' effettuando la conversione interna
+ *
+ * Accetta sia '1024' che '1 kb' effettuando la conversione interna
* necessaria.
- * @param string $x sia '1024' che '1 kb'
+ *
+ * @param string $x sia '1024' che '1 kb'
* @return \SetupUpload
*/
public function setSizeMaxFilesByte($x) {
@@ -196,10 +199,10 @@
/**
* Converte una stringa nei corrispondenti bytes.
- *
+ *
* 1 Mb = 1024^2
- *
- * @param string $strSize Stringa da convertire
+ *
+ * @param string $strSize Stringa da convertire
* @throws UploadFile_Excs
* @return integer
*/
@@ -214,13 +217,13 @@
//validazione
if (strlen(trim($strSize)) === 0) {
//una stringa vuota non può essere convertita
- throw new UploadFile_Exc();
+ throw new Upload_Exc_Error();
} elseif (strlen(trim($strValue)) === 0) {
//se non trovo la parte del valore della stringa non posso convertire
- throw new UploadFile_Exc();
+ throw new Upload_Exc_Error();
} elseif (strlen($strUnit) >= 1 && !array_key_exists($strUnit, $Units)) {
//l'unita' non e' nota
- throw new UploadFile_Exc();
+ throw new Upload_Exc_Error();
}
$Exponent = isset($Units[$strUnit]) ? $Units[$strUnit] : 0;
--
Gitblit v1.8.0