You are here

protected function GeoRSS::parseLines in geoPHP 8

Same name and namespace in other branches
  1. 7 geoPHP/lib/adapters/GeoRSS.class.php \GeoRSS::parseLines()
1 call to GeoRSS::parseLines()
GeoRSS::geomFromXML in geoPHP/lib/adapters/GeoRSS.class.php

File

geoPHP/lib/adapters/GeoRSS.class.php, line 110

Class

GeoRSS
PHP Geometry/GeoRSS encoder/decoder

Code

protected function parseLines() {
  $lines = array();
  $line_elements = $this->xmlobj
    ->getElementsByTagName('line');
  foreach ($line_elements as $line) {
    $components = $this
      ->getPointsFromCoords(trim($line->firstChild->nodeValue));
    $lines[] = new LineString($components);
  }
  return $lines;
}