@@ -298,7 +298,7 @@ discard block |
||
298 | 298 | */ |
299 | 299 | private function _saveMultiPointMZRecord($type) { |
300 | 300 | |
301 | - fwrite($this->SHPFile, pack('dd', $this->SHPData[$type . 'min'], $this->SHPData[$type . 'max'])); |
|
301 | + fwrite($this->SHPFile, pack('dd', $this->SHPData[$type.'min'], $this->SHPData[$type.'max'])); |
|
302 | 302 | |
303 | 303 | for ($i = 0; $i <= $this->SHPData['numpoints']; $i++) { |
304 | 304 | fwrite($this->SHPFile, Util::packDouble($this->SHPData['points'][$type])); |
@@ -454,8 +454,8 @@ discard block |
||
454 | 454 | if (!isset($point[$direction])) { |
455 | 455 | continue; |
456 | 456 | } |
457 | - $min = $direction . 'min'; |
|
458 | - $max = $direction . 'max'; |
|
457 | + $min = $direction.'min'; |
|
458 | + $max = $direction.'max'; |
|
459 | 459 | if (!isset($this->SHPData[$min]) || ($this->SHPData[$min] > $point[$direction])) { |
460 | 460 | $this->SHPData[$min] = $point[$direction]; |
461 | 461 | } |
@@ -145,7 +145,7 @@ discard block |
||
145 | 145 | */ |
146 | 146 | public function testCreate() |
147 | 147 | { |
148 | - if (! ShapeFile::supports_dbase()) { |
|
148 | + if (!ShapeFile::supports_dbase()) { |
|
149 | 149 | $this->markTestSkipped('dbase extension missing'); |
150 | 150 | } |
151 | 151 | $this->createTestData(); |
@@ -162,7 +162,7 @@ discard block |
||
162 | 162 | */ |
163 | 163 | public function testDelete() |
164 | 164 | { |
165 | - if (! ShapeFile::supports_dbase()) { |
|
165 | + if (!ShapeFile::supports_dbase()) { |
|
166 | 166 | $this->markTestSkipped('dbase extension missing'); |
167 | 167 | } |
168 | 168 | $this->createTestData(); |
@@ -185,7 +185,7 @@ discard block |
||
185 | 185 | */ |
186 | 186 | public function testAdd() |
187 | 187 | { |
188 | - if (! ShapeFile::supports_dbase()) { |
|
188 | + if (!ShapeFile::supports_dbase()) { |
|
189 | 189 | $this->markTestSkipped('dbase extension missing'); |
190 | 190 | } |
191 | 191 | $this->createTestData(); |
@@ -189,6 +189,9 @@ discard block |
||
189 | 189 | return (count($this->records) - 1); |
190 | 190 | } |
191 | 191 | |
192 | + /** |
|
193 | + * @param integer $index |
|
194 | + */ |
|
192 | 195 | public function deleteRecord($index) { |
193 | 196 | if (isset($this->records[$index])) { |
194 | 197 | $this->fileLength -= ($this->records[$index]->getContentLength() + 4); |
@@ -455,7 +458,8 @@ discard block |
||
455 | 458 | /** |
456 | 459 | * Reads given number of bytes from SHP file |
457 | 460 | * |
458 | - * @return string|false |
|
461 | + * @param integer $bytes |
|
462 | + * @return string |
|
459 | 463 | */ |
460 | 464 | public function readSHP($bytes) |
461 | 465 | { |
@@ -482,6 +486,9 @@ discard block |
||
482 | 486 | return ShapeFile::nameShape($this->shapeType); |
483 | 487 | } |
484 | 488 | |
489 | + /** |
|
490 | + * @param integer $type |
|
491 | + */ |
|
485 | 492 | public static function nameShape($type) |
486 | 493 | { |
487 | 494 | if (isset(self::$shape_names[$type])) { |