Class IntPoint

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable

    class IntPoint
    extends java.awt.Point
    Point class with faster hashCode() to speed up the rendering of Gouraud shadings. Should only be used for maps or sets when all elements are of this type, because the hashCode() method violates its general contract "If two objects are equal according to the equals(Object) method, then calling the hashCode method on each of the two objects must produce the same" when IntPoint is mixed with Point, because IntPoint(x,y) would have a different hashCode than Point(x,y).
    • Nested Class Summary

      • Nested classes/interfaces inherited from class java.awt.geom.Point2D

        java.awt.geom.Point2D.Double, java.awt.geom.Point2D.Float
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private static org.apache.commons.logging.Log LOG  
      • Fields inherited from class java.awt.Point

        x, y
    • Constructor Summary

      Constructors 
      Constructor Description
      IntPoint​(int x, int y)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object obj)  
      int hashCode()  
      • Methods inherited from class java.awt.Point

        getLocation, getX, getY, move, setLocation, setLocation, setLocation, toString, translate
      • Methods inherited from class java.awt.geom.Point2D

        clone, distance, distance, distance, distanceSq, distanceSq, distanceSq, setLocation
      • Methods inherited from class java.lang.Object

        finalize, getClass, notify, notifyAll, wait, wait, wait
    • Field Detail

      • LOG

        private static final org.apache.commons.logging.Log LOG
    • Constructor Detail

      • IntPoint

        IntPoint​(int x,
                 int y)
    • Method Detail

      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.awt.geom.Point2D
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.awt.Point