|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.jscience.ml.gml.infoset.CoordinateTupleImpl
public class CoordinateTupleImpl
Convenience class that implements the CoordinateTuple interface. This class can either be used directly or be extended to add custom functionality. A coordinate tuple must have at least the X coordinate.
| Field Summary |
|---|
| Fields inherited from interface org.jscience.ml.gml.infoset.CoordinateTuple |
|---|
X_INDEX, Y_INDEX, Z_INDEX |
| Constructor Summary | |
|---|---|
protected |
CoordinateTupleImpl()
Creates a "dummy" CoordinateTuple object. |
|
CoordinateTupleImpl(Coordinate[] coordinates)
Initializes this coordinate tuple using the given coordinates. |
| Method Summary | |
|---|---|
Coordinate |
getCoordinate(int index)
Returns the n-th coordinate of this coordinate tuple. |
protected Coordinate[] |
getCoordinates()
Provides access to internal coordinates' structure. |
Coordinate |
getX()
Convenience method to retrieve the first coordinate. |
Coordinate |
getY()
Convenience method to retrieve the second coordinate. |
Coordinate |
getZ()
Convenience method to retrieve the third coordinate. |
protected void |
initialize(Coordinate[] coordinates)
Initializes this coordinate tuple. |
java.lang.String |
toString()
Returns a one-line string representation of this coordinate tuple. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
protected CoordinateTupleImpl()
public CoordinateTupleImpl(Coordinate[] coordinates)
coordinates - DOCUMENT ME!| Method Detail |
|---|
protected void initialize(Coordinate[] coordinates)
coordinates - The source array. Array members are copied into a new
array, but they are not cloned.public Coordinate getX()
getX in interface CoordinateTuplepublic Coordinate getY()
getY in interface CoordinateTuplepublic Coordinate getZ()
getZ in interface CoordinateTuplepublic Coordinate getCoordinate(int index)
getCoordinate in interface CoordinateTupleindex - Represents an index into the coordinate tuple. The lowest
index is 0.
public java.lang.String toString()
toString in class java.lang.Objectprotected Coordinate[] getCoordinates()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||