java.lang.Objectcomputational.geometry.meshgeneration.Square
public class Square
Constructor Summary | |
---|---|
Square(MyPoint Origin,
MyPoint destination)
|
|
Square(Square Q)
|
Method Summary | |
---|---|
int |
compareTo(java.lang.Object a)
|
boolean |
contains(Point P)
Tells whether the shape encloses a given point. |
boolean |
CrossedCollinearTest(boolean E,
boolean N,
boolean O,
boolean S,
BasicEdge Ed)
la funzione sotto serve per determinare se un Edge � collineare ad una combo di lati dello Square |
void |
draw(java.awt.Graphics gfx)
Draws the shape, using the current graphics context's color. |
void |
drawLabels(java.awt.Graphics gfx)
Draws the shape's associated labels, using the graphics context's color. |
void |
drawPoints(java.awt.Graphics gfx)
Draws the shape's defining points, using the graphics context's color. |
BasicEdge[] |
getBasicEdgeOfBoundary()
|
MyPoint |
getDestination()
|
Edge[] |
getEdges(java.util.LinkedList PoligonEdgeListofSquare)
|
java.util.LinkedList |
getFourMyPoints()
|
java.util.LinkedList |
getFourPoints()
|
java.lang.String |
getLabel()
Returns the text label associated to this shape. |
int |
getLengthEdge()
|
MyPoint |
getOrigin()
|
java.util.List |
getPoints()
Returns a list containing copies of the shape's defining points. |
Vertex |
getSteinerMyPoint()
|
boolean |
PointInsideSquare(MyPoint P)
|
boolean |
PoligonInterction(java.util.LinkedList PolygonList)
|
void |
setDestination(MyPoint D)
|
void |
setLabel(java.lang.String label)
Associates this shape with a given text label. |
void |
setOrigin(MyPoint O)
|
java.lang.String |
toString()
|
void |
translate(int dx,
int dy)
Translates the shape by the given amount. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Square(MyPoint Origin, MyPoint destination)
public Square(Square Q)
Method Detail |
---|
public int compareTo(java.lang.Object a)
public boolean contains(Point P)
Shape
contains
in interface Shape
P
- the point we test for encloseness.
public boolean CrossedCollinearTest(boolean E, boolean N, boolean O, boolean S, BasicEdge Ed)
public void draw(java.awt.Graphics gfx)
Shape
draw
in interface Shape
gfx
- the graphics context where this shape has to be drawn.public void drawLabels(java.awt.Graphics gfx)
Shape
drawLabels
in interface Shape
gfx
- the graphics context where this shape's labels have
to be drawn.public void drawPoints(java.awt.Graphics gfx)
Shape
drawPoints
in interface Shape
gfx
- the graphics context where this shape's points have
to be drawn.public BasicEdge[] getBasicEdgeOfBoundary()
public MyPoint getDestination()
public Edge[] getEdges(java.util.LinkedList PoligonEdgeListofSquare)
public java.util.LinkedList getFourMyPoints()
public java.util.LinkedList getFourPoints()
public java.lang.String getLabel()
Shape
getLabel
in interface Shape
public int getLengthEdge()
public MyPoint getOrigin()
public java.util.List getPoints()
Shape
getPoints
in interface Shape
public Vertex getSteinerMyPoint()
public boolean PointInsideSquare(MyPoint P)
public boolean PoligonInterction(java.util.LinkedList PolygonList)
public void setDestination(MyPoint D)
public void setLabel(java.lang.String label)
Shape
setLabel
in interface Shape
label
- the shape's new label.public void setOrigin(MyPoint O)
public java.lang.String toString()
toString
in class java.lang.Object
public void translate(int dx, int dy)
Shape
translate
in interface Shape
dx
- the amount to translate along the X-axis