com.empireclassic.Remote
Class WorldCoord

java.lang.Object
  extended by java.awt.geom.Point2D
      extended by java.awt.Point
          extended by com.empireclassic.Remote.WorldCoord
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.lang.Comparable

public class WorldCoord
extends java.awt.Point
implements java.lang.Comparable

Author:
chas
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class java.awt.geom.Point2D
java.awt.geom.Point2D.Double, java.awt.geom.Point2D.Float
 
Field Summary
 
Fields inherited from class java.awt.Point
x, y
 
Constructor Summary
WorldCoord()
           
WorldCoord(double x, double y)
           
WorldCoord(int x, int y)
           
WorldCoord(IslandInfo island, IslandCoord coord)
           
WorldCoord(java.awt.Point p)
           
 
Method Summary
 IslandCoord asIslandCoord(IslandInfo island)
           
 int compareTo(java.lang.Object obj)
           
 java.lang.String toString()
           
 WorldCoord translated(int x, int y)
           
 WorldCoord translated(IslandCoord coord)
           
 WorldCoord translated(WorldCoord coord)
           
 WorldCoord wrap()
           
 WorldCoord wrapped()
           
 
Methods inherited from class java.awt.Point
equals, getLocation, getX, getY, move, setLocation, setLocation, setLocation, translate
 
Methods inherited from class java.awt.geom.Point2D
clone, distance, distance, distance, distanceSq, distanceSq, distanceSq, hashCode, setLocation
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

WorldCoord

public WorldCoord()

WorldCoord

public WorldCoord(java.awt.Point p)
Parameters:
p -

WorldCoord

public WorldCoord(double x,
                  double y)

WorldCoord

public WorldCoord(IslandInfo island,
                  IslandCoord coord)

WorldCoord

public WorldCoord(int x,
                  int y)
Parameters:
x -
y -
Method Detail

asIslandCoord

public IslandCoord asIslandCoord(IslandInfo island)

translated

public WorldCoord translated(IslandCoord coord)

translated

public WorldCoord translated(WorldCoord coord)

translated

public WorldCoord translated(int x,
                             int y)

wrap

public WorldCoord wrap()

wrapped

public WorldCoord wrapped()

compareTo

public int compareTo(java.lang.Object obj)
Specified by:
compareTo in interface java.lang.Comparable

toString

public java.lang.String toString()
Overrides:
toString in class java.awt.Point