You are here

private function GeoJSON::arrayToPoint in geoPHP 7

Same name and namespace in other branches
  1. 8 geoPHP/lib/adapters/GeoJSON.class.php \GeoJSON::arrayToPoint()
2 calls to GeoJSON::arrayToPoint()
GeoJSON::arrayToLineString in geoPHP/lib/adapters/GeoJSON.class.php
GeoJSON::arrayToMultiPoint in geoPHP/lib/adapters/GeoJSON.class.php

File

geoPHP/lib/adapters/GeoJSON.class.php, line 57

Class

GeoJSON
GeoJSON class : a geojson reader/writer.

Code

private function arrayToPoint($array) {
  if (!empty($array)) {
    return new Point($array[0], $array[1]);
  }
  else {
    return new Point();
  }
}