You are here

public function GeoRSS::collectionToGeoRSS in geoPHP 8

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

File

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

Class

GeoRSS
PHP Geometry/GeoRSS encoder/decoder

Code

public function collectionToGeoRSS($geom) {
  $georss = '<' . $this->nss . 'where>';
  $components = $geom
    ->getComponents();
  foreach ($geom
    ->getComponents() as $comp) {
    $georss .= $this
      ->geometryToGeoRSS($comp);
  }
  $georss .= '</' . $this->nss . 'where>';
  return $georss;
}