@@ -1098,6 +1098,10 @@ discard block |
||
| 1098 | 1098 | else return array(); |
| 1099 | 1099 | } |
| 1100 | 1100 | |
| 1101 | + /** |
|
| 1102 | + * @param string $type |
|
| 1103 | + * @param string $rules |
|
| 1104 | + */ |
|
| 1101 | 1105 | public function addNOTAM($ref,$title,$type,$fir,$code,$rules,$scope,$lower_limit,$upper_limit,$center_latitude,$center_longitude,$radius,$date_begin,$date_end,$permanent,$text,$full_notam) { |
| 1102 | 1106 | $query = "INSERT INTO notam (ref,title,notam_type,fir,code,rules,scope,lower_limit,upper_limit,center_latitude,center_longitude,radius,date_begin,date_end,permanent,notam_text,full_notam) VALUES (:ref,:title,:type,:fir,:code,:rules,:scope,:lower_limit,:upper_limit,:center_latitude,:center_longitude,:radius,:date_begin,:date_end,:permanent,:text,:full_notam)"; |
| 1103 | 1107 | $query_values = array(':ref' => $ref,':title' => $title,':type' => $type,':fir' => $fir,':code' => $code,':rules' => $rules,':scope' => $scope,':lower_limit' => $lower_limit,':upper_limit' => $upper_limit,':center_latitude' => $center_latitude,':center_longitude' => $center_longitude,':radius' => $radius,':date_begin' => $date_begin,':date_end' => $date_end,':permanent' => $permanent,':text' => $text,':full_notam' => $full_notam); |
@@ -1179,6 +1183,10 @@ discard block |
||
| 1179 | 1183 | } |
| 1180 | 1184 | } |
| 1181 | 1185 | } |
| 1186 | + |
|
| 1187 | + /** |
|
| 1188 | + * @param string $filename |
|
| 1189 | + */ |
|
| 1182 | 1190 | public function updateNOTAMfromTextFile($filename) { |
| 1183 | 1191 | $alldata = $this->parseNOTAMtextFile($filename); |
| 1184 | 1192 | if (count($alldata) > 0) { |
@@ -1223,6 +1231,9 @@ discard block |
||
| 1223 | 1231 | } |
| 1224 | 1232 | } |
| 1225 | 1233 | |
| 1234 | + /** |
|
| 1235 | + * @param string $icao |
|
| 1236 | + */ |
|
| 1226 | 1237 | public function downloadNOTAM($icao) { |
| 1227 | 1238 | date_default_timezone_set("UTC"); |
| 1228 | 1239 | $Common = new Common(); |
@@ -1359,6 +1370,9 @@ discard block |
||
| 1359 | 1370 | return $result; |
| 1360 | 1371 | } |
| 1361 | 1372 | |
| 1373 | + /** |
|
| 1374 | + * @param string $code |
|
| 1375 | + */ |
|
| 1362 | 1376 | public function parse_code($code) { |
| 1363 | 1377 | $code = str_split($code); |
| 1364 | 1378 | $code_fp = $code[1].$code[2]; |
@@ -40,6 +40,10 @@ |
||
| 40 | 40 | } |
| 41 | 41 | } |
| 42 | 42 | |
| 43 | + /** |
|
| 44 | + * @param string $id |
|
| 45 | + * @param string $ident |
|
| 46 | + */ |
|
| 43 | 47 | public function get_Schedule($id,$ident) { |
| 44 | 48 | global $globalDebug, $globalFork, $globalSchedulesFetch; |
| 45 | 49 | // Get schedule here, so it's done only one time |
@@ -125,6 +125,9 @@ discard block |
||
| 125 | 125 | public $tag_start = 0; |
| 126 | 126 | private $dom = null; |
| 127 | 127 | |
| 128 | + /** |
|
| 129 | + * @param simple_html_dom $dom |
|
| 130 | + */ |
|
| 128 | 131 | function __construct($dom) |
| 129 | 132 | { |
| 130 | 133 | $this->dom = $dom; |
@@ -1501,6 +1504,11 @@ discard block |
||
| 1501 | 1504 | } |
| 1502 | 1505 | |
| 1503 | 1506 | // parse attributes |
| 1507 | + |
|
| 1508 | + /** |
|
| 1509 | + * @param simple_html_dom_node $node |
|
| 1510 | + * @param string[] $space |
|
| 1511 | + */ |
|
| 1504 | 1512 | protected function parse_attr($node, $name, &$space) |
| 1505 | 1513 | { |
| 1506 | 1514 | // Per sourceforge: http://sourceforge.net/tracker/?func=detail&aid=3061408&group_id=218559&atid=1044037 |
@@ -1538,6 +1546,11 @@ discard block |
||
| 1538 | 1546 | } |
| 1539 | 1547 | |
| 1540 | 1548 | // link node's parent |
| 1549 | + |
|
| 1550 | + /** |
|
| 1551 | + * @param simple_html_dom_node $node |
|
| 1552 | + * @param boolean $is_child |
|
| 1553 | + */ |
|
| 1541 | 1554 | protected function link_nodes(&$node, $is_child) |
| 1542 | 1555 | { |
| 1543 | 1556 | $node->parent = $this->parent; |
@@ -1549,6 +1562,10 @@ discard block |
||
| 1549 | 1562 | } |
| 1550 | 1563 | |
| 1551 | 1564 | // as a text node |
| 1565 | + |
|
| 1566 | + /** |
|
| 1567 | + * @param string $tag |
|
| 1568 | + */ |
|
| 1552 | 1569 | protected function as_text_node($tag) |
| 1553 | 1570 | { |
| 1554 | 1571 | $node = new simple_html_dom_node($this); |
@@ -1559,12 +1576,18 @@ discard block |
||
| 1559 | 1576 | return true; |
| 1560 | 1577 | } |
| 1561 | 1578 | |
| 1579 | + /** |
|
| 1580 | + * @param string $chars |
|
| 1581 | + */ |
|
| 1562 | 1582 | protected function skip($chars) |
| 1563 | 1583 | { |
| 1564 | 1584 | $this->pos += strspn($this->doc, $chars, $this->pos); |
| 1565 | 1585 | $this->char = ($this->pos<$this->size) ? $this->doc[$this->pos] : null; // next |
| 1566 | 1586 | } |
| 1567 | 1587 | |
| 1588 | + /** |
|
| 1589 | + * @param string $chars |
|
| 1590 | + */ |
|
| 1568 | 1591 | protected function copy_skip($chars) |
| 1569 | 1592 | { |
| 1570 | 1593 | $pos = $this->pos; |
@@ -1575,6 +1598,9 @@ discard block |
||
| 1575 | 1598 | return substr($this->doc, $pos, $len); |
| 1576 | 1599 | } |
| 1577 | 1600 | |
| 1601 | + /** |
|
| 1602 | + * @param string $chars |
|
| 1603 | + */ |
|
| 1578 | 1604 | protected function copy_until($chars) |
| 1579 | 1605 | { |
| 1580 | 1606 | $pos = $this->pos; |
@@ -1584,6 +1610,9 @@ discard block |
||
| 1584 | 1610 | return substr($this->doc, $pos, $len); |
| 1585 | 1611 | } |
| 1586 | 1612 | |
| 1613 | + /** |
|
| 1614 | + * @param string $char |
|
| 1615 | + */ |
|
| 1587 | 1616 | protected function copy_until_char($char) |
| 1588 | 1617 | { |
| 1589 | 1618 | if ($this->char===null) return ''; |
@@ -1602,6 +1631,9 @@ discard block |
||
| 1602 | 1631 | return substr($this->doc, $pos_old, $pos-$pos_old); |
| 1603 | 1632 | } |
| 1604 | 1633 | |
| 1634 | + /** |
|
| 1635 | + * @param string $char |
|
| 1636 | + */ |
|
| 1605 | 1637 | protected function copy_until_char_escape($char) |
| 1606 | 1638 | { |
| 1607 | 1639 | if ($this->char===null) return ''; |
@@ -1633,6 +1665,10 @@ discard block |
||
| 1633 | 1665 | |
| 1634 | 1666 | // remove noise from html content |
| 1635 | 1667 | // save the noise in the $this->noise array. |
| 1668 | + |
|
| 1669 | + /** |
|
| 1670 | + * @param string $pattern |
|
| 1671 | + */ |
|
| 1636 | 1672 | protected function remove_noise($pattern, $remove_tag=false) |
| 1637 | 1673 | { |
| 1638 | 1674 | global $debug_object; |
@@ -1658,6 +1694,10 @@ discard block |
||
| 1658 | 1694 | } |
| 1659 | 1695 | |
| 1660 | 1696 | // restore noise to html content |
| 1697 | + |
|
| 1698 | + /** |
|
| 1699 | + * @param string|null $text |
|
| 1700 | + */ |
|
| 1661 | 1701 | function restore_noise($text) |
| 1662 | 1702 | { |
| 1663 | 1703 | global $debug_object; |
@@ -14,7 +14,7 @@ |
||
| 14 | 14 | /** |
| 15 | 15 | * Get SQL query part for filter used |
| 16 | 16 | * @param Array $filter the filter |
| 17 | - * @return Array the SQL part |
|
| 17 | + * @return string the SQL part |
|
| 18 | 18 | */ |
| 19 | 19 | public function getFilter($filter = array(),$where = false,$and = false) { |
| 20 | 20 | global $globalFilter, $globalStatsFilters, $globalFilterName, $globalDBdriver; |
@@ -14,7 +14,7 @@ discard block |
||
| 14 | 14 | /** |
| 15 | 15 | * Get SQL query part for filter used |
| 16 | 16 | * @param Array $filter the filter |
| 17 | - * @return Array the SQL part |
|
| 17 | + * @return string the SQL part |
|
| 18 | 18 | */ |
| 19 | 19 | public function getFilter($filter = array(),$where = false,$and = false) { |
| 20 | 20 | global $globalFilter, $globalStatsFilters, $globalFilterName, $globalDBdriver; |
@@ -759,10 +759,6 @@ discard block |
||
| 759 | 759 | * |
| 760 | 760 | * @param String $famtrackid the ID from flightaware |
| 761 | 761 | * @param String $ident the flight ident |
| 762 | - * @param String $aircraft_icao the aircraft type |
|
| 763 | - * @param String $departure_airport_icao the departure airport |
|
| 764 | - * @param String $arrival_airport_icao the arrival airport |
|
| 765 | - * @return String success or false |
|
| 766 | 762 | * |
| 767 | 763 | */ |
| 768 | 764 | public function addLiveTrackerData($famtrackid = '', $ident = '', $latitude = '', $longitude = '', $altitude = '', $heading = '', $groundspeed = '', $date = '', $putinarchive = false, $comment = '', $type = '',$noarchive = false,$format_source = '', $source_name = '', $over_country = '') |
@@ -254,6 +254,7 @@ discard block |
||
| 254 | 254 | * |
| 255 | 255 | * @param String $aircraft_registration the registration of the aircraft |
| 256 | 256 | * @param String $aircraft_name type of the aircraft |
| 257 | + * @param string $type |
|
| 257 | 258 | * @return Array the aircraft thumbnail, orignal url and copyright |
| 258 | 259 | * |
| 259 | 260 | */ |
@@ -287,6 +288,7 @@ discard block |
||
| 287 | 288 | * |
| 288 | 289 | * @param String $registration the registration of the aircraft |
| 289 | 290 | * @param String $name type of the aircraft |
| 291 | + * @param string $type |
|
| 290 | 292 | * @return Array the aircraft thumbnail, orignal url and copyright |
| 291 | 293 | * |
| 292 | 294 | */ |
@@ -325,6 +327,7 @@ discard block |
||
| 325 | 327 | * |
| 326 | 328 | * @param String $aircraft_registration the registration of the aircraft |
| 327 | 329 | * @param String $aircraft_name type of the aircraft |
| 330 | + * @param string $type |
|
| 328 | 331 | * @return Array the aircraft thumbnail, orignal url and copyright |
| 329 | 332 | * |
| 330 | 333 | */ |
@@ -367,6 +370,7 @@ discard block |
||
| 367 | 370 | * |
| 368 | 371 | * @param String $aircraft_registration the registration of the aircraft |
| 369 | 372 | * @param String $aircraft_name type of the aircraft |
| 373 | + * @param string $type |
|
| 370 | 374 | * @return Array the aircraft thumbnail, orignal url and copyright |
| 371 | 375 | * |
| 372 | 376 | */ |
@@ -401,6 +405,7 @@ discard block |
||
| 401 | 405 | * |
| 402 | 406 | * @param String $registration the registration of the aircraft |
| 403 | 407 | * @param String $name type of the aircraft |
| 408 | + * @param string $type |
|
| 404 | 409 | * @return Array the aircraft thumbnail, orignal url and copyright |
| 405 | 410 | * |
| 406 | 411 | */ |
@@ -429,6 +434,10 @@ discard block |
||
| 429 | 434 | return false; |
| 430 | 435 | } |
| 431 | 436 | |
| 437 | + /** |
|
| 438 | + * @param string $type |
|
| 439 | + * @param string $aircraft_icao |
|
| 440 | + */ |
|
| 432 | 441 | public function fromIvaoMtl($type,$aircraft_icao,$airline_icao) { |
| 433 | 442 | $Common = new Common(); |
| 434 | 443 | //echo "\n".'SEARCH IMAGE : http://mtlcatalog.ivao.aero/images/aircraft/'.$aircraft_icao.$airline_icao.'.jpg'; |
@@ -450,6 +459,7 @@ discard block |
||
| 450 | 459 | * |
| 451 | 460 | * @param String $aircraft_registration the registration of the aircraft |
| 452 | 461 | * @param String $aircraft_name type of the aircraft |
| 462 | + * @param string $type |
|
| 453 | 463 | * @return Array the aircraft thumbnail, orignal url and copyright |
| 454 | 464 | * |
| 455 | 465 | */ |
@@ -482,6 +492,7 @@ discard block |
||
| 482 | 492 | * |
| 483 | 493 | * @param String $aircraft_registration the registration of the aircraft |
| 484 | 494 | * @param String $aircraft_name type of the aircraft |
| 495 | + * @param string $type |
|
| 485 | 496 | * @return Array the aircraft thumbnail, orignal url and copyright |
| 486 | 497 | * |
| 487 | 498 | */ |
@@ -507,6 +518,7 @@ discard block |
||
| 507 | 518 | * |
| 508 | 519 | * @param String $registration the registration of the aircraft/mmsi |
| 509 | 520 | * @param String $name name |
| 521 | + * @param string $type |
|
| 510 | 522 | * @return Array the aircraft thumbnail, orignal url and copyright |
| 511 | 523 | * |
| 512 | 524 | */ |
@@ -568,6 +580,7 @@ discard block |
||
| 568 | 580 | * |
| 569 | 581 | * @param String $registration the registration of the aircraft |
| 570 | 582 | * @param String $name type of the aircraft |
| 583 | + * @param string $type |
|
| 571 | 584 | * @return Array the aircraft thumbnail, orignal url and copyright |
| 572 | 585 | * |
| 573 | 586 | */ |
@@ -14,7 +14,7 @@ |
||
| 14 | 14 | /** |
| 15 | 15 | * Get SQL query part for filter used |
| 16 | 16 | * @param Array $filter the filter |
| 17 | - * @return Array the SQL part |
|
| 17 | + * @return string the SQL part |
|
| 18 | 18 | */ |
| 19 | 19 | public function getFilter($filter = array(),$where = false,$and = false) { |
| 20 | 20 | global $globalFilter, $globalStatsFilters, $globalFilterName, $globalDBdriver; |
@@ -14,7 +14,7 @@ discard block |
||
| 14 | 14 | /** |
| 15 | 15 | * Get SQL query part for filter used |
| 16 | 16 | * @param Array $filter the filter |
| 17 | - * @return Array the SQL part |
|
| 17 | + * @return string the SQL part |
|
| 18 | 18 | */ |
| 19 | 19 | public function getFilter($filter = array(),$where = false,$and = false) { |
| 20 | 20 | global $globalFilter, $globalStatsFilters, $globalFilterName, $globalDBdriver; |
@@ -794,10 +794,6 @@ discard block |
||
| 794 | 794 | * |
| 795 | 795 | * @param String $fammarine_id the ID from flightaware |
| 796 | 796 | * @param String $ident the flight ident |
| 797 | - * @param String $aircraft_icao the aircraft type |
|
| 798 | - * @param String $departure_airport_icao the departure airport |
|
| 799 | - * @param String $arrival_airport_icao the arrival airport |
|
| 800 | - * @return String success or false |
|
| 801 | 797 | * |
| 802 | 798 | */ |
| 803 | 799 | public function addLiveMarineData($fammarine_id = '', $ident = '', $latitude = '', $longitude = '', $heading = '', $groundspeed = '', $date = '', $putinarchive = false, $mmsi = '',$type = '',$typeid = '',$imo = '', $callsign = '',$arrival_code = '',$arrival_date = '',$status = '',$statusid = '',$noarchive = false,$format_source = '', $source_name = '', $over_country = '') |
@@ -14,7 +14,7 @@ |
||
| 14 | 14 | /** |
| 15 | 15 | * Get SQL query part for filter used |
| 16 | 16 | * @param Array $filter the filter |
| 17 | - * @return Array the SQL part |
|
| 17 | + * @return string the SQL part |
|
| 18 | 18 | */ |
| 19 | 19 | public function getFilter($filter = array(),$where = false,$and = false) { |
| 20 | 20 | global $globalFilter, $globalStatsFilters, $globalFilterName, $globalDBdriver; |