Class: GeometryCollection

.Geo. GeometryCollection


new GeometryCollection(geometries [, boundaryBox])

A GeoJSON GeometryCollection object

Parameters:
Name Type Argument Description
geometries Array

An array of GeoJSON geometry objects

boundaryBox Array <optional>

An array with [min. longitude, min. latitude, max. longitude, max. latitude]

Example
var polygons = new jsonOdm.Geo.GeometryCollection([
   new jsonOdm.Geo.LineString([[51.5,32.1],[51.6,21]]),
   new jsonOdm.Geo.MultiPoint([[51.5,32],[51.6,21]]),
   new jsonOdm.Geo.LineString([[51.3,32.2],[51.9,21]])
]);

Methods


<static> intersects(geometryCollection, geometry)

Checks whether a GeometryCollection intersects another geometry

Parameters:
Name Type Description
geometryCollection jsonOdm.Geo.GeometryCollection
geometry jsonOdm.Geo.Point | jsonOdm.Geo.BoundaryBox | jsonOdm.Geo.MultiPoint | jsonOdm.Geo.LineString | jsonOdm.Geo.MultiLineString | jsonOdm.Geo.Polygon | jsonOdm.Geo.MultiPolygon | jsonOdm.Geo.GeometryCollection

Any jsonOdm.Geo.<geometry> object

Returns:
Type
boolean

<static> within(geometryCollection, geometry)

Checks whether a GeometryCollection is inside of another geometry

Parameters:
Name Type Description
geometryCollection jsonOdm.Geo.GeometryCollection
geometry jsonOdm.Geo.Point | jsonOdm.Geo.BoundaryBox | jsonOdm.Geo.MultiPoint | jsonOdm.Geo.LineString | jsonOdm.Geo.MultiLineString | jsonOdm.Geo.Polygon | jsonOdm.Geo.MultiPolygon | jsonOdm.Geo.GeometryCollection

Any jsonOdm.Geo.<geometry> object

Returns:
Type
boolean