Package org.graffiti.graphics
Class Port
java.lang.Object
org.graffiti.graphics.Port
public class Port extends Object
A port comprises a name and a coordinate.
-
Constructor Summary
-
Method Summary
Modifier and Type Method Description booleanequals(Object obj)StringgetName()Returns the name.doublegetX()Returns the x ccordinate of this port.doublegetY()Returns the y ccordinate of this port.voidsetName(String name)Sets the name.voidsetX(double x)Sets the x coordinate of this port.voidsetY(double y)Sets the y ccordinate of this port.
-
Constructor Details
-
Port
Constructor for Port.- Parameters:
name- DOCUMENT ME!x- DOCUMENT ME!y- DOCUMENT ME!
-
-
Method Details
-
setName
Sets the name.- Parameters:
name- The name to set
-
getName
Returns the name.- Returns:
- String
-
setX
public void setX(double x)Sets the x coordinate of this port.- Parameters:
x-
-
getX
public double getX()Returns the x ccordinate of this port.- Returns:
- double
-
setY
public void setY(double y)Sets the y ccordinate of this port.- Parameters:
y-
-
getY
public double getY()Returns the y ccordinate of this port.- Returns:
- double
-
equals
- Overrides:
equalsin classObject- See Also:
Object.equals(java.lang.Object)
-