|
Algorithm Development Kit 1.0 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectalgs.model.twod.TwoDCircle
public class TwoDCircle
A circle is defined by a center point and a radius.
Constructor Summary | |
---|---|
TwoDCircle(double x,
double y,
double radius)
Construct a Circle. |
|
TwoDCircle(TwoDPoint origin,
double radius)
Construct a Circle. |
Method Summary | |
---|---|
IRectangle |
boundingRectangle()
return bounding rectangle for this circle. |
boolean |
equals(java.lang.Object o)
Must properly compute equals(Object) to compare based origin and radius |
IPoint |
getOrigin()
Return origin as an IPoint. |
double |
getRadius()
return the radius of the circle. |
double |
getX()
Return the x-coordinate value of the circle origin. |
double |
getY()
Return the y-coordinate value of the circle origin. |
int |
hashCode()
Hashcode. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public TwoDCircle(TwoDPoint origin, double radius)
origin
- radius
- public TwoDCircle(double x, double y, double radius)
x
- x-coordinate of originy
- y-coordinate of originradius
- radius of circleMethod Detail |
---|
public boolean equals(java.lang.Object o)
ICircle
equals
in interface ICircle
equals
in class java.lang.Object
Object.equals(Object)
public int hashCode()
hashCode
in class java.lang.Object
public IPoint getOrigin()
ICircle
getOrigin
in interface ICircle
public double getRadius()
ICircle
getRadius
in interface ICircle
public double getX()
ICircle
getX
in interface ICircle
public double getY()
ICircle
getY
in interface ICircle
public IRectangle boundingRectangle()
ICircle
boundingRectangle
in interface ICircle
public java.lang.String toString()
toString
in class java.lang.Object
|
Algorithm Development Kit 1.0 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |