All Packages Class Hierarchy This Package Previous Next Index
Class com.las.ogdi.OGDIRing
java.lang.Object
|
+----com.las.ogdi.OGDIRing
- public class OGDIRing
- extends Object
The Ring class defines an object composed of an array of Coordinate
objects homogenous in direction and closed. The closing coordinate is implicit.
- Version:
- 1.0
- Author:
- Las Inc.
-
OGDIRing(OGDICoordinate, OGDICoordinate[])
- Creates a Ring instance.
-
getCentroid()
- Gets the centroid of a Ring.
-
getCoords()
- Gets the coordinates of a Ring.
-
toString()
- Gets the complete ring description.
OGDIRing
public OGDIRing(OGDICoordinate centroid,
OGDICoordinate c[])
- Creates a Ring instance.
- Parameters:
- centroid - a centroid in the current coordinate system
- c - an array of coordinates in the current coordinate system
- Returns:
- no return
- Throws: IllegalArgumentException
- if ring is badly formatted (has no centroid or less than 3 coordinates)
getCoords
public OGDICoordinate[] getCoords()
- Gets the coordinates of a Ring.
- Parameters:
- no - parameter
- Returns:
- a Coordinate array
- Throws: no
- exception
getCentroid
public OGDICoordinate getCentroid()
- Gets the centroid of a Ring.
- Parameters:
- no - parameter
- Returns:
- a Coordinate centroid
- Throws: no
- exception
toString
public String toString()
- Gets the complete ring description.
- Parameters:
- no - parameter
- Returns:
- the ring's centroid and coordinates as a string
- Throws: no
- exception
- Overrides:
- toString in class Object
- See Also:
- toString
All Packages Class Hierarchy This Package Previous Next Index