Package net.anwiba.spatial.coordinate
Class Coordinate
- java.lang.Object
-
- net.anwiba.spatial.coordinate.Coordinate
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Comparable<ICoordinate>,ICoordinate
public class Coordinate extends java.lang.Object implements ICoordinate
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from interface net.anwiba.spatial.coordinate.ICoordinate
X, Y, Z
-
-
Constructor Summary
Constructors Constructor Description Coordinate(double[] values, boolean isMeasured)Coordinate(double x, double y)Coordinate(double x, double y, double n, boolean isMeasured)Coordinate(double x, double y, double z, double m)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ICoordinateadd(ICoordinate other)intcompareTo(ICoordinate coordinate)booleanequals(java.lang.Object object)intgetDimension()doublegetMeasuredValue()doublegetValue(int index)double[]getValues()doublegetXValue()doublegetYValue()doublegetZValue()inthashCode()booleanisMeasured()ICoordinatesubtract(ICoordinate other)java.lang.StringtoString()booleantouch(double x, double y)booleantouch(ICoordinate other)
-
-
-
Method Detail
-
getDimension
public int getDimension()
- Specified by:
getDimensionin interfaceICoordinate
-
isMeasured
public boolean isMeasured()
- Specified by:
isMeasuredin interfaceICoordinate
-
getValue
public double getValue(int index)
- Specified by:
getValuein interfaceICoordinate
-
getXValue
public double getXValue()
- Specified by:
getXValuein interfaceICoordinate
-
getYValue
public double getYValue()
- Specified by:
getYValuein interfaceICoordinate
-
getZValue
public double getZValue()
- Specified by:
getZValuein interfaceICoordinate
-
getMeasuredValue
public double getMeasuredValue()
- Specified by:
getMeasuredValuein interfaceICoordinate
-
getValues
public double[] getValues()
- Specified by:
getValuesin interfaceICoordinate
-
add
public ICoordinate add(ICoordinate other)
- Specified by:
addin interfaceICoordinate
-
subtract
public ICoordinate subtract(ICoordinate other)
- Specified by:
subtractin interfaceICoordinate
-
touch
public boolean touch(ICoordinate other)
- Specified by:
touchin interfaceICoordinate
-
touch
public boolean touch(double x, double y)- Specified by:
touchin interfaceICoordinate
-
equals
public boolean equals(java.lang.Object object)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
compareTo
public int compareTo(ICoordinate coordinate)
- Specified by:
compareToin interfacejava.lang.Comparable<ICoordinate>
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-