|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ascape.model.space.Coordinate
org.ascape.model.space.CoordinateContinuous
org.ascape.model.space.Coordinate1DContinuous
org.ascape.model.space.Coordinate2DContinuous
public class Coordinate2DContinuous
A location within a two-dimensional continuous space.
| Field Summary |
|---|
| Fields inherited from class org.ascape.model.space.CoordinateContinuous |
|---|
values |
| Constructor Summary | |
|---|---|
Coordinate2DContinuous(double[] values)
Creates a 2-dimensional coordinate with the specified position values. |
|
Coordinate2DContinuous(double x,
double y)
Creates a 2-dimensional coordinate with the specified position values. |
|
Coordinate2DContinuous(int[] intValues)
Creates a 2-dimensional coordinate with the specified position values. |
|
| Method Summary | |
|---|---|
Coordinate |
add(Coordinate coordinate)
Adds the location of the supplied coordinate to this coordinate, returning the resulting coordinate. |
double |
getDistance(Coordinate target)
Returns the calculated distance between this coordinate and the supplied coordinate. |
double |
getYValue()
Returns the y value of this coordinate. |
void |
setYValue(double y)
Sets the y value for this coordinate. |
java.lang.String |
toString()
Returns a string representing this coordinate. |
| Methods inherited from class org.ascape.model.space.Coordinate1DContinuous |
|---|
getValue, getXValue, setValue, setXValue |
| Methods inherited from class org.ascape.model.space.CoordinateContinuous |
|---|
equals, getDimensionCount, getProduct, getValueAtDimension, getValues, setValueAtDimension, setValues |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Coordinate2DContinuous(double[] values)
values - the values
public Coordinate2DContinuous(double x,
double y)
x - the xy - the ypublic Coordinate2DContinuous(int[] intValues)
intValues - the int values| Method Detail |
|---|
public double getYValue()
public void setYValue(double y)
y - the ypublic double getDistance(Coordinate target)
getDistance in class Coordinate1DContinuoustarget - the location to calculate distance to
public Coordinate add(Coordinate coordinate)
add in class Coordinate1DContinuouscoordinate - the coordinate to sum with this one
public java.lang.String toString()
toString in class Coordinate1DContinuous
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||