Class Coordinates
Useful utility functions for handling Coordinate objects.
Inherited Members
Namespace: NetTopologySuite.Geometries
Assembly: NetTopologySuite.dll
Syntax
public static class Coordinates
Methods
| Edit this page View SourceCreate(int)
Factory method providing access to common Coordinate implementations.
Declaration
public static Coordinate Create(int dimension)
Parameters
Type | Name | Description |
---|---|---|
int | dimension |
Returns
Type | Description |
---|---|
Coordinate | created coordinate |
Create(int, int)
Factory method providing access to common Coordinate implementations.
Declaration
public static Coordinate Create(int dimension, int measures)
Parameters
Type | Name | Description |
---|---|---|
int | dimension | |
int | measures |
Returns
Type | Description |
---|---|
Coordinate | created coordinate |
Dimension(Coordinate)
Determine dimension based on subclass of Coordinate.
Declaration
public static int Dimension(Coordinate coordinate)
Parameters
Type | Name | Description |
---|---|---|
Coordinate | coordinate | supplied coordinate |
Returns
Type | Description |
---|---|
int | number of ordinates recorded |
HasZ(Coordinate)
Check if coordinate can store a z-ordinate value, based on subclass of Coordinate.
Declaration
public static bool HasZ(Coordinate coordinate)
Parameters
Type | Name | Description |
---|---|---|
Coordinate | coordinate | A coordinate |
Returns
Type | Description |
---|---|
bool |
|
Measures(Coordinate)
Determine number of measures based on subclass of Coordinate.
Declaration
public static int Measures(Coordinate coordinate)
Parameters
Type | Name | Description |
---|---|---|
Coordinate | coordinate | supplied coordinate |
Returns
Type | Description |
---|---|
int | number of measures recorded |
SpatialDimension(Coordinate)
Evaluates the number of spatial dimensions (x, y, z) that a coordinate can carry.
Declaration
public static int SpatialDimension(Coordinate c)
Parameters
Type | Name | Description |
---|---|---|
Coordinate | c | A coordinate |
Returns
Type | Description |
---|---|
int | The number of spatial dimensions |