Web API Reference | MapGuide Open Source

- Overview
- Modules
- Classes

# Geometry

## Modules
| AGF Text
| Geometry Collections
| Spatial Relationships
| FDO Provider Spatial Operator Tests
| MgGeometry Spatial Operator Test Cases
| Oracle Spatial Operator Test Cases
| Geometry Classes

## Detailed Description

The Geometry API supports the round-tripping of 2D and 2.5D geometries as well as the analysis of 2D geometries.

## Creating geometries

Use an MgGeometryFactory object to create MgGeometry objects from coordinates. Click MgGeometryFactory to see a graphical overview of geometry creation.

Use an MgWktReaderWriter object to create MgGeometry objects from strings in AGF Text form.

Use an MgAgfReaderWriter object to translate MgGeometry objects into a form suitable for the creation of an MgGeometryProperty object for inserting into a datastore.

Click on the geometry class name to view sample creation code. The supported geometries are:

- MgPoint and MgMultiPoint
- MgLineString and MgMultiLineString
- MgCurveString and MgMultiCurveString
- MgPolygon and MgMultiPolygon
- MgCurvePolygon and MgMultiCurvePolygon
- MgMultiGeometry (heterogenous collection of geometries)

Comments or suggestions? Send us feedback.