Class java.awt.Point
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class java.awt.Point

java.lang.Object
   |
   +----java.awt.Point

public class Point
extends Object
An x,y coordinate.

Variable Index

 o x
The x coordinate.
 o y
The y coordinate.

Constructor Index

 o Point(int, int)
Constructs and initializes a Point from the specified x and y coordinates.

Method Index

 o equals(Object)
Checks whether two pointers are equal.
 o hashCode()
Returns the hashcode for this Point.
 o move(int, int)
Moves the point.
 o toString()
Returns the String representation of this Point's coordinates.
 o translate(int, int)
Translates the point.

Variables

 o x
  public int x
The x coordinate.
 o y
  public int y
The y coordinate.

Constructors

 o Point
  public Point(int x,
               int y)
Constructs and initializes a Point from the specified x and y coordinates.
Parameters:
x - the x coordinate
y - the y coordinate

Methods

 o move
  public void move(int x,
                   int y)
Moves the point.
 o translate
  public void translate(int x,
                        int y)
Translates the point.
 o hashCode
  public int hashCode()
Returns the hashcode for this Point.
Overrides:
hashCode in class Object
 o equals
  public boolean equals(Object obj)
Checks whether two pointers are equal.
Overrides:
equals in class Object
 o toString
  public String toString()
Returns the String representation of this Point's coordinates.
Overrides:
toString in class Object

All Packages  Class Hierarchy  This Package  Previous  Next  Index