org.stathissideris.ascii2image.graphics
Class ShapePoint

java.lang.Object
  extended by java.awt.geom.Point2D
      extended by java.awt.geom.Point2D.Float
          extended by org.stathissideris.ascii2image.graphics.ShapePoint
All Implemented Interfaces:
Serializable, Cloneable

public class ShapePoint
extends Point2D.Float

Author:
Efstathios Sideris
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class java.awt.geom.Point2D
Point2D.Double, Point2D.Float
 
Field Summary
static int TYPE_NORMAL
           
static int TYPE_ROUND
           
 
Fields inherited from class java.awt.geom.Point2D.Float
x, y
 
Constructor Summary
ShapePoint()
           
ShapePoint(float x, float y)
           
ShapePoint(float x, float y, int type)
           
ShapePoint(ShapePoint other)
           
 
Method Summary
 void assign(ShapePoint point)
           
 int getType()
           
 boolean isEastOf(ShapePoint point)
           
 boolean isInLineWith(ShapePoint point)
           
 boolean isLocked()
           
 boolean isNorthOf(ShapePoint point)
           
 boolean isSouthOf(ShapePoint point)
           
 boolean isWestOf(ShapePoint point)
           
 boolean isWithinEdge(ShapeEdge edge)
           
 void moveTo(ShapePoint point)
          Does the same as assign, but respects the locked attribute
 void setLocked(boolean b)
           
 void setType(int i)
           
 String toString()
           
 
Methods inherited from class java.awt.geom.Point2D.Float
getX, getY, setLocation, setLocation
 
Methods inherited from class java.awt.geom.Point2D
clone, distance, distance, distance, distanceSq, distanceSq, distanceSq, equals, hashCode, setLocation
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

TYPE_NORMAL

public static final int TYPE_NORMAL
See Also:
Constant Field Values

TYPE_ROUND

public static final int TYPE_ROUND
See Also:
Constant Field Values
Constructor Detail

ShapePoint

public ShapePoint()

ShapePoint

public ShapePoint(float x,
                  float y)

ShapePoint

public ShapePoint(float x,
                  float y,
                  int type)

ShapePoint

public ShapePoint(ShapePoint other)
Method Detail

getType

public int getType()
Returns:

setType

public void setType(int i)
Parameters:
i -

isInLineWith

public boolean isInLineWith(ShapePoint point)

isWithinEdge

public boolean isWithinEdge(ShapeEdge edge)

isNorthOf

public boolean isNorthOf(ShapePoint point)

isSouthOf

public boolean isSouthOf(ShapePoint point)

isWestOf

public boolean isWestOf(ShapePoint point)

isEastOf

public boolean isEastOf(ShapePoint point)

toString

public String toString()
Overrides:
toString in class Point2D.Float

assign

public void assign(ShapePoint point)

moveTo

public void moveTo(ShapePoint point)
Does the same as assign, but respects the locked attribute

Parameters:
point -

isLocked

public boolean isLocked()
Returns:

setLocked

public void setLocked(boolean b)
Parameters:
b -


Copyright © 2013. All Rights Reserved.