Completed
Push — master ( a3214e...3969e1 )
by Yannick
111:17 queued 84:43
created
require/class.Translation.php 1 patch
Doc Comments   +8 added lines patch added patch discarded remove patch
@@ -58,6 +58,10 @@  discard block
 block discarded – undo
58 58
 		} else return $ident;
59 59
 	}
60 60
 
61
+	/**
62
+	 * @param string $correct_ident
63
+	 * @param string $source
64
+	 */
61 65
 	public function addOperator($ident,$correct_ident,$source) {
62 66
 		$query = "INSERT INTO translation (Operator,Operator_correct,Source) VALUES (:ident,:correct_ident,:source)";
63 67
 		$query_values = array(':ident' => $ident,':correct_ident' => $correct_ident, ':source' => $source);
@@ -69,6 +73,10 @@  discard block
 block discarded – undo
69 73
 		}
70 74
 	}
71 75
 
76
+	/**
77
+	 * @param string $correct_ident
78
+	 * @param string $source
79
+	 */
72 80
 	public function updateOperator($ident,$correct_ident,$source) {
73 81
 		$query = "UPDATE translation SET Operator_correct = :correct_ident,Source = :source WHERE Operator = :ident";
74 82
 		$query_values = array(':ident' => $ident,':correct_ident' => $correct_ident, ':source' => $source);
Please login to merge, or discard this patch.
require/class.Stats.php 1 patch
Doc Comments   +35 added lines patch added patch discarded remove patch
@@ -18,6 +18,10 @@  discard block
 block discarded – undo
18 18
 		$this->db = $Connection->db();
19 19
 	}
20 20
 
21
+	/**
22
+	 * @param string $type
23
+	 * @param string $stats_date
24
+	 */
21 25
 	public function addLastStatsUpdate($type,$stats_date) {
22 26
 		$query = "DELETE FROM config WHERE name = :type;
23 27
 			    INSERT INTO config (name,value) VALUES (:type,:stats_date);";
@@ -1368,6 +1372,10 @@  discard block
 block discarded – undo
1368 1372
 		$all = $sth->fetchAll(PDO::FETCH_ASSOC);
1369 1373
 		return $all;
1370 1374
 	}
1375
+
1376
+	/**
1377
+	 * @param string $type
1378
+	 */
1371 1379
 	public function deleteStatsByType($type,$stats_airline = '', $filter_name = '') {
1372 1380
 		if ($filter_name == '') $filter_name = $this->filter_name;
1373 1381
 		$query = "DELETE FROM stats WHERE stats_type = :type AND stats_airline = :stats_airline AND filter_name = :filter_name";
@@ -1379,6 +1387,11 @@  discard block
 block discarded – undo
1379 1387
 			echo "error : ".$e->getMessage();
1380 1388
 		}
1381 1389
 	}
1390
+
1391
+	/**
1392
+	 * @param string $type
1393
+	 * @param string $year
1394
+	 */
1382 1395
 	public function getSumStats($type,$year,$stats_airline = '',$filter_name = '',$month = '') {
1383 1396
 		if ($filter_name == '') $filter_name = $this->filter_name;
1384 1397
 		global $globalArchiveMonths, $globalDBdriver;
@@ -1578,6 +1591,10 @@  discard block
 block discarded – undo
1578 1591
 		else return 0;
1579 1592
 	}
1580 1593
 
1594
+	/**
1595
+	 * @param string $type
1596
+	 * @param string $stats_date
1597
+	 */
1581 1598
 	public function addStat($type,$cnt,$stats_date,$stats_airline = '',$filter_name = '') {
1582 1599
 		global $globalDBdriver;
1583 1600
 		if ($filter_name == '') $filter_name = $this->filter_name;
@@ -1631,6 +1648,9 @@  discard block
 block discarded – undo
1631 1648
         }
1632 1649
         */
1633 1650
 
1651
+	/**
1652
+	 * @param string $stats_type
1653
+	 */
1634 1654
 	public function getStatsSource($stats_type,$year = '',$month = '',$day = '') {
1635 1655
 		global $globalDBdriver;
1636 1656
 		$query = "SELECT * FROM stats_source WHERE stats_type = :stats_type";
@@ -1674,6 +1694,9 @@  discard block
 block discarded – undo
1674 1694
 		return $all;
1675 1695
 	}
1676 1696
 
1697
+	/**
1698
+	 * @param string $stats_type
1699
+	 */
1677 1700
 	public function addStatSource($data,$source_name,$stats_type,$date) {
1678 1701
 		global $globalDBdriver;
1679 1702
 		if ($globalDBdriver == 'mysql') {
@@ -1689,6 +1712,10 @@  discard block
 block discarded – undo
1689 1712
 			return "error : ".$e->getMessage();
1690 1713
 		}
1691 1714
 	}
1715
+
1716
+	/**
1717
+	 * @param string $type
1718
+	 */
1692 1719
 	public function addStatFlight($type,$date_name,$cnt,$stats_airline = '',$filter_name = '') {
1693 1720
 		$query = "INSERT INTO stats_flight (stats_type,flight_date,cnt,stats_airline,filter_name) VALUES (:type,:flight_date,:cnt,:stats_airline,:filter_name)";
1694 1721
 		$query_values = array(':type' => $type,':flight_date' => $date_name,':cnt' => $cnt, ':stats_airline' => $stats_airline,':filter_name' => $filter_name);
@@ -1955,6 +1982,10 @@  discard block
 block discarded – undo
1955 1982
 			return "error : ".$e->getMessage();
1956 1983
 		}
1957 1984
 	}
1985
+
1986
+	/**
1987
+	 * @param string $type
1988
+	 */
1958 1989
 	public function deleteStatFlight($type) {
1959 1990
 		$query = "DELETE FROM stats_flight WHERE stats_type = :type";
1960 1991
 		$query_values = array(':type' => $type);
@@ -1965,6 +1996,10 @@  discard block
 block discarded – undo
1965 1996
 			return "error : ".$e->getMessage();
1966 1997
 		}
1967 1998
 	}
1999
+
2000
+	/**
2001
+	 * @param string $type
2002
+	 */
1968 2003
 	public function deleteStatAirport($type) {
1969 2004
 		$query = "DELETE FROM stats_airport WHERE stats_type = :type";
1970 2005
 		$query_values = array(':type' => $type);
Please login to merge, or discard this patch.
install/class.update_db.php 1 patch
Doc Comments   +48 added lines patch added patch discarded remove patch
@@ -10,6 +10,9 @@  discard block
 block discarded – undo
10 10
 class update_db {
11 11
 	public static $db_sqlite;
12 12
 
13
+	/**
14
+	 * @param string $file
15
+	 */
13 16
 	public static function download($url, $file, $referer = '') {
14 17
 		//$file = str_replace('/',DIRECTORY_SEPARATOR,$file);
15 18
 		$fp = fopen($file, 'w+');
@@ -25,6 +28,9 @@  discard block
 block discarded – undo
25 28
 		fclose($fp);
26 29
 	}
27 30
 
31
+	/**
32
+	 * @param string $in_file
33
+	 */
28 34
 	public static function gunzip($in_file,$out_file_name = '') {
29 35
 		//echo $in_file.' -> '.$out_file_name."\n";
30 36
 		$buffer_size = 4096; // read 4kb at a time
@@ -46,6 +52,9 @@  discard block
 block discarded – undo
46 52
 		}
47 53
 	}
48 54
 
55
+	/**
56
+	 * @param string $in_file
57
+	 */
49 58
 	public static function unzip($in_file) {
50 59
 		if ($in_file != '' && file_exists($in_file)) {
51 60
 			$path = pathinfo(realpath($in_file), PATHINFO_DIRNAME);
@@ -67,6 +76,9 @@  discard block
 block discarded – undo
67 76
 		}
68 77
 	}
69 78
 	
79
+	/**
80
+	 * @param string $database_file
81
+	 */
70 82
 	public static function retrieve_route_sqlite_to_dest($database_file) {
71 83
 		global $globalDebug, $globalTransaction;
72 84
 		//$query = 'TRUNCATE TABLE routes';
@@ -109,6 +121,10 @@  discard block
 block discarded – undo
109 121
 		}
110 122
                 return '';
111 123
 	}
124
+
125
+	/**
126
+	 * @param string $database_file
127
+	 */
112 128
 	public static function retrieve_route_oneworld($database_file) {
113 129
 		global $globalDebug, $globalTransaction;
114 130
 		//$query = 'TRUNCATE TABLE routes';
@@ -150,6 +166,9 @@  discard block
 block discarded – undo
150 166
                 return '';
151 167
 	}
152 168
 	
169
+	/**
170
+	 * @param string $database_file
171
+	 */
153 172
 	public static function retrieve_route_skyteam($database_file) {
154 173
 		global $globalDebug, $globalTransaction;
155 174
 		//$query = 'TRUNCATE TABLE routes';
@@ -192,6 +211,10 @@  discard block
 block discarded – undo
192 211
 		}
193 212
                 return '';
194 213
 	}
214
+
215
+	/**
216
+	 * @param string $database_file
217
+	 */
195 218
 	public static function retrieve_modes_sqlite_to_dest($database_file) {
196 219
 		global $globalTransaction;
197 220
 		//$query = 'TRUNCATE TABLE aircraft_modes';
@@ -258,6 +281,9 @@  discard block
 block discarded – undo
258 281
 		return '';
259 282
 	}
260 283
 
284
+	/**
285
+	 * @param string $database_file
286
+	 */
261 287
 	public static function retrieve_modes_flarmnet($database_file) {
262 288
 		global $globalTransaction;
263 289
 		$Common = new Common();
@@ -328,6 +354,9 @@  discard block
 block discarded – undo
328 354
 		return '';
329 355
 	}
330 356
 
357
+	/**
358
+	 * @param string $database_file
359
+	 */
331 360
 	public static function retrieve_modes_ogn($database_file) {
332 361
 		global $globalTransaction;
333 362
 		//$query = 'TRUNCATE TABLE aircraft_modes';
@@ -397,6 +426,9 @@  discard block
 block discarded – undo
397 426
 		return '';
398 427
 	}
399 428
 
429
+	/**
430
+	 * @param string $database_file
431
+	 */
400 432
 	public static function retrieve_owner($database_file,$country = 'F') {
401 433
 		global $globalTransaction, $globalMasterSource;
402 434
 		//$query = 'TRUNCATE TABLE aircraft_modes';
@@ -1332,6 +1364,10 @@  discard block
 block discarded – undo
1332 1364
 		return '';
1333 1365
         }
1334 1366
 
1367
+	/**
1368
+	 * @param string $filename
1369
+	 * @param string $tletype
1370
+	 */
1335 1371
 	public static function tle($filename,$tletype) {
1336 1372
 		require_once(dirname(__FILE__).'/../require/class.Spotter.php');
1337 1373
 		global $tmp_dir, $globalTransaction;
@@ -1381,6 +1417,9 @@  discard block
 block discarded – undo
1381 1417
 		return '';
1382 1418
         }
1383 1419
 
1420
+	/**
1421
+	 * @param string $filename
1422
+	 */
1384 1423
 	public static function satellite_ucsdb($filename) {
1385 1424
 		global $tmp_dir, $globalTransaction;
1386 1425
 		$query = "DELETE FROM satellite";
@@ -1428,6 +1467,9 @@  discard block
 block discarded – undo
1428 1467
 		return '';
1429 1468
 	}
1430 1469
 
1470
+	/**
1471
+	 * @param string $filename
1472
+	 */
1431 1473
 	public static function satellite_celestrak($filename) {
1432 1474
 		global $tmp_dir, $globalTransaction;
1433 1475
 		$satcat_sources = array(
@@ -1743,6 +1785,9 @@  discard block
 block discarded – undo
1743 1785
 
1744 1786
 	}
1745 1787
 */
1788
+	/**
1789
+	 * @param string $filename
1790
+	 */
1746 1791
 	public static function waypoints($filename) {
1747 1792
 		//require_once(dirname(__FILE__).'/../require/class.Spotter.php');
1748 1793
 		global $tmp_dir, $globalTransaction;
@@ -1790,6 +1835,9 @@  discard block
 block discarded – undo
1790 1835
 		return '';
1791 1836
         }
1792 1837
 
1838
+	/**
1839
+	 * @param string $filename
1840
+	 */
1793 1841
 	public static function ivao_airlines($filename) {
1794 1842
 		//require_once(dirname(__FILE__).'/../require/class.Spotter.php');
1795 1843
 		global $tmp_dir, $globalTransaction;
Please login to merge, or discard this patch.
require/class.Connection.php 1 patch
Doc Comments   +20 added lines patch added patch discarded remove patch
@@ -6,6 +6,9 @@  discard block
 block discarded – undo
6 6
 	public $dbs = array();
7 7
 	public $latest_schema = 46;
8 8
 	
9
+	/**
10
+	 * @param string $dbname
11
+	 */
9 12
 	public function __construct($dbc = null,$dbname = null,$user = null,$pass = null) {
10 13
 	    global $globalNoDB;
11 14
 	    if (isset($globalNoDB) && $globalNoDB === TRUE) {
@@ -142,6 +145,9 @@  discard block
 block discarded – undo
142 145
 		return true;
143 146
 	}
144 147
 
148
+	/**
149
+	 * @param string $table
150
+	 */
145 151
 	public function tableExists($table)
146 152
 	{
147 153
 		global $globalDBdriver, $globalDBname;
@@ -192,6 +198,11 @@  discard block
 block discarded – undo
192 198
 	/*
193 199
 	* Check if index exist
194 200
 	*/
201
+
202
+	/**
203
+	 * @param string $table
204
+	 * @param string $index
205
+	 */
195 206
 	public function indexExists($table,$index)
196 207
 	{
197 208
 		global $globalDBdriver, $globalDBname;
@@ -234,6 +245,10 @@  discard block
 block discarded – undo
234 245
 		return $columns;
235 246
 	}
236 247
 
248
+	/**
249
+	 * @param string $table
250
+	 * @param string $column
251
+	 */
237 252
 	public function getColumnType($table,$column) {
238 253
 		$select = $this->db->query('SELECT '.$column.' FROM '.$table);
239 254
 		$tomet = $select->getColumnMeta(0);
@@ -244,6 +259,11 @@  discard block
 block discarded – undo
244 259
 	* Check if a column name exist in a table
245 260
 	* @return Boolean column exist or not
246 261
 	*/
262
+
263
+	/**
264
+	 * @param string $table
265
+	 * @param string $name
266
+	 */
247 267
 	public function checkColumnName($table,$name)
248 268
 	{
249 269
 		global $globalDBdriver, $globalDBname;
Please login to merge, or discard this patch.