Completed
Push — master ( a99ae2...001830 )
by Michal
03:26
created
src/ShapeFile.lib.php 1 patch
Doc Comments   +29 added lines patch added patch discarded remove patch
@@ -27,6 +27,8 @@  discard block
 block discarded – undo
27 27
  * along with this program; if not, you can download one from
28 28
  * http://www.gnu.org/copyleft/gpl.html.
29 29
  *
30
+ * @param string $type
31
+ * @param string $data
30 32
  */
31 33
   function loadData($type, $data) {
32 34
     if (!$data) return $data;
@@ -34,6 +36,9 @@  discard block
 block discarded – undo
34 36
     return current($tmp);
35 37
   }
36 38
 
39
+  /**
40
+   * @param string $binValue
41
+   */
37 42
   function swap($binValue) {
38 43
     $result = $binValue{strlen($binValue) - 1};
39 44
     for($i = strlen($binValue) - 2; $i >= 0 ; $i--) {
@@ -43,6 +48,9 @@  discard block
 block discarded – undo
43 48
     return $result;
44 49
   }
45 50
 
51
+  /**
52
+   * @return string
53
+   */
46 54
   function packDouble($value, $mode = 'LE') {
47 55
     $value = (double)$value;
48 56
     $bin = pack("d", $value);
@@ -366,6 +374,9 @@  discard block
 block discarded – undo
366 374
       }
367 375
     }
368 376
 
377
+    /**
378
+     * @param string $error
379
+     */
369 380
     function setError($error) {
370 381
       $this->lastError = $error;
371 382
       return false;
@@ -384,6 +395,9 @@  discard block
 block discarded – undo
384 395
     var $SHPData = array();
385 396
     var $DBFData = array();
386 397
 
398
+    /**
399
+     * @param integer $shapeType
400
+     */
387 401
     public function __construct($shapeType) {
388 402
       $this->shapeType = $shapeType;
389 403
     }
@@ -617,6 +631,9 @@  discard block
 block discarded – undo
617 631
       }
618 632
     }
619 633
 
634
+    /**
635
+     * @param string $type
636
+     */
620 637
     function _loadMultiPointMZRecord( $type ) {
621 638
 
622 639
       $this->SHPData[$type."min"] = loadData("d", fread($this->SHPFile, 8));
@@ -650,6 +667,9 @@  discard block
 block discarded – undo
650 667
       }
651 668
     }
652 669
 
670
+    /**
671
+     * @param string $type
672
+     */
653 673
     function _saveMultiPointMZRecord( $type ) {
654 674
 
655 675
       fwrite($this->SHPFile, pack("dd", $this->SHPData[$type."min"], $this->SHPData[$type."max"]));
@@ -703,6 +723,9 @@  discard block
 block discarded – undo
703 723
       fseek($this->SHPFile, $firstIndex + ($readPoints*16));
704 724
     }
705 725
 
726
+    /**
727
+     * @param string $type
728
+     */
706 729
     function _loadPolyLineMZRecord( $type ) {
707 730
 
708 731
       $this->SHPData[$type."min"] = loadData("d", fread($this->SHPFile, 8));
@@ -751,6 +774,9 @@  discard block
 block discarded – undo
751 774
       }
752 775
     }
753 776
 
777
+    /**
778
+     * @param string $type
779
+     */
754 780
     function _savePolyLineMZRecord( $type ) {
755 781
       fwrite($this->SHPFile, pack("dd", $this->SHPData[$type."min"], $this->SHPData[$type."max"]));
756 782
 
@@ -983,6 +1009,9 @@  discard block
 block discarded – undo
983 1009
       }
984 1010
     }
985 1011
 
1012
+    /**
1013
+     * @param string $error
1014
+     */
986 1015
     function setError($error) {
987 1016
       $this->lastError = $error;
988 1017
       return false;
Please login to merge, or discard this patch.