@Test public void testHashCode() { XYBoxAnnotation a1 = new XYBoxAnnotation(1.0, 2.0, 3.0, 4.0, new BasicStroke(1.2f), Color.RED, Color.BLUE); XYBoxAnnotation a2 = new XYBoxAnnotation(1.0, 2.0, 3.0, 4.0, new BasicStroke(1.2f), Color.RED, Color.BLUE); assertEquals(a1, a2); int h1 = a1.hashCode(); int h2 = a2.hashCode(); assertEquals(h1, h2); }
@Override public int hashCode() { int result; long temp; temp = Double.doubleToLongBits(this.x0); result = (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.x1); result = 29 * result + (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.y0); result = 29 * result + (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.y1); result = 29 * result + (int) (temp ^ (temp >>> 32)); return result; }
XYBoxAnnotation extends AbstractXYAnnotation implements Cloneable, PublicCloneable, Serializable { @Override public int hashCode() { int result; long temp; temp = Double.doubleToLongBits(this.x0); result = (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.x1); result = 29 * result + (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.y0); result = 29 * result + (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.y1); result = 29 * result + (int) (temp ^ (temp >>> 32)); return result; } }
XYBoxAnnotation extends AbstractXYAnnotation implements Cloneable, PublicCloneable, Serializable { @Override public int hashCode() { int result; long temp; temp = Double.doubleToLongBits(this.x0); result = (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.x1); result = 29 * result + (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.y0); result = 29 * result + (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.y1); result = 29 * result + (int) (temp ^ (temp >>> 32)); return result; } XYBoxAnnotation(double x0, double y0, double x1, double y1);  XYBoxAnnotation(double x0, double y0, double x1, double y1,
                           Stroke stroke, Paint outlinePaint);  XYBoxAnnotation(double x0, double y0, double x1, double y1,
                           Stroke stroke, Paint outlinePaint, Paint fillPaint); }
XYBoxAnnotation extends AbstractXYAnnotation implements Cloneable, PublicCloneable, Serializable { @Override public int hashCode() { int result; long temp; temp = Double.doubleToLongBits(this.x0); result = (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.x1); result = 29 * result + (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.y0); result = 29 * result + (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.y1); result = 29 * result + (int) (temp ^ (temp >>> 32)); return result; } XYBoxAnnotation(double x0, double y0, double x1, double y1);  XYBoxAnnotation(double x0, double y0, double x1, double y1,
                           Stroke stroke, Paint outlinePaint);  XYBoxAnnotation(double x0, double y0, double x1, double y1,
                           Stroke stroke, Paint outlinePaint, Paint fillPaint); @Override void draw(Graphics2D g2, XYPlot plot, Rectangle2D dataArea,
                     ValueAxis domainAxis, ValueAxis rangeAxis,
                     int rendererIndex, PlotRenderingInfo info); @Override boolean equals(Object obj); @Override int hashCode(); @Override Object clone(); }
XYBoxAnnotation extends AbstractXYAnnotation implements Cloneable, PublicCloneable, Serializable { @Override public int hashCode() { int result; long temp; temp = Double.doubleToLongBits(this.x0); result = (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.x1); result = 29 * result + (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.y0); result = 29 * result + (int) (temp ^ (temp >>> 32)); temp = Double.doubleToLongBits(this.y1); result = 29 * result + (int) (temp ^ (temp >>> 32)); return result; } XYBoxAnnotation(double x0, double y0, double x1, double y1);  XYBoxAnnotation(double x0, double y0, double x1, double y1,
                           Stroke stroke, Paint outlinePaint);  XYBoxAnnotation(double x0, double y0, double x1, double y1,
                           Stroke stroke, Paint outlinePaint, Paint fillPaint); @Override void draw(Graphics2D g2, XYPlot plot, Rectangle2D dataArea,
                     ValueAxis domainAxis, ValueAxis rangeAxis,
                     int rendererIndex, PlotRenderingInfo info); @Override boolean equals(Object obj); @Override int hashCode(); @Override Object clone();  }