You are here

public function GeoRSS::write in geoPHP 8

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

Serialize geometries into a GeoRSS string.

Parameters

Geometry $geometry:

Return value

string The georss string representation of the input geometries

Overrides GeoAdapter::write

File

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

Class

GeoRSS
PHP Geometry/GeoRSS encoder/decoder

Code

public function write(Geometry $geometry, $namespace = FALSE) {
  if ($namespace) {
    $this->namespace = $namespace;
    $this->nss = $namespace . ':';
  }
  return $this
    ->geometryToGeoRSS($geometry);
}