@Test public void testEquals() { StackedXYAreaRenderer r1 = new StackedXYAreaRenderer(); StackedXYAreaRenderer r2 = new StackedXYAreaRenderer(); assertEquals(r1, r2); assertEquals(r2, r1); r1.setShapePaint(new GradientPaint(1.0f, 2.0f, Color.yellow, 3.0f, 4.0f, Color.green)); assertFalse(r1.equals(r2)); r2.setShapePaint(new GradientPaint(1.0f, 2.0f, Color.yellow, 3.0f, 4.0f, Color.green)); assertEquals(r1, r2); Stroke s = new BasicStroke(1.23f); r1.setShapeStroke(s); assertFalse(r1.equals(r2)); r2.setShapeStroke(s); assertEquals(r1, r2); }
@Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof StackedXYAreaRenderer) || !super.equals(obj)) { return false; } StackedXYAreaRenderer that = (StackedXYAreaRenderer) obj; if (!PaintUtilities.equal(this.shapePaint, that.shapePaint)) { return false; } if (!ObjectUtilities.equal(this.shapeStroke, that.shapeStroke)) { return false; } return true; }
StackedXYAreaRenderer extends XYAreaRenderer implements Cloneable, PublicCloneable, Serializable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof StackedXYAreaRenderer) || !super.equals(obj)) { return false; } StackedXYAreaRenderer that = (StackedXYAreaRenderer) obj; if (!PaintUtilities.equal(this.shapePaint, that.shapePaint)) { return false; } if (!ObjectUtilities.equal(this.shapeStroke, that.shapeStroke)) { return false; } return true; } }
StackedXYAreaRenderer extends XYAreaRenderer implements Cloneable, PublicCloneable, Serializable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof StackedXYAreaRenderer) || !super.equals(obj)) { return false; } StackedXYAreaRenderer that = (StackedXYAreaRenderer) obj; if (!PaintUtilities.equal(this.shapePaint, that.shapePaint)) { return false; } if (!ObjectUtilities.equal(this.shapeStroke, that.shapeStroke)) { return false; } return true; } StackedXYAreaRenderer();  StackedXYAreaRenderer(int type);  StackedXYAreaRenderer(int type, XYToolTipGenerator labelGenerator,
                                 XYURLGenerator urlGenerator); }
StackedXYAreaRenderer extends XYAreaRenderer implements Cloneable, PublicCloneable, Serializable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof StackedXYAreaRenderer) || !super.equals(obj)) { return false; } StackedXYAreaRenderer that = (StackedXYAreaRenderer) obj; if (!PaintUtilities.equal(this.shapePaint, that.shapePaint)) { return false; } if (!ObjectUtilities.equal(this.shapeStroke, that.shapeStroke)) { return false; } return true; } StackedXYAreaRenderer();  StackedXYAreaRenderer(int type);  StackedXYAreaRenderer(int type, XYToolTipGenerator labelGenerator,
                                 XYURLGenerator urlGenerator); Paint getShapePaint(); void setShapePaint(Paint shapePaint); Stroke getShapeStroke(); void setShapeStroke(Stroke shapeStroke); @Override XYItemRendererState initialise(Graphics2D g2,
                                          Rectangle2D dataArea,
                                          XYPlot plot,
                                          XYDataset data,
                                          PlotRenderingInfo info); @Override int getPassCount(); @Override Range findRangeBounds(XYDataset dataset); @Override void drawItem(Graphics2D g2,
                         XYItemRendererState state,
                         Rectangle2D dataArea,
                         PlotRenderingInfo info,
                         XYPlot plot,
                         ValueAxis domainAxis,
                         ValueAxis rangeAxis,
                         XYDataset dataset,
                         int series,
                         int item,
                         CrosshairState crosshairState,
                         int pass); @Override boolean equals(Object obj); @Override Object clone(); }
StackedXYAreaRenderer extends XYAreaRenderer implements Cloneable, PublicCloneable, Serializable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof StackedXYAreaRenderer) || !super.equals(obj)) { return false; } StackedXYAreaRenderer that = (StackedXYAreaRenderer) obj; if (!PaintUtilities.equal(this.shapePaint, that.shapePaint)) { return false; } if (!ObjectUtilities.equal(this.shapeStroke, that.shapeStroke)) { return false; } return true; } StackedXYAreaRenderer();  StackedXYAreaRenderer(int type);  StackedXYAreaRenderer(int type, XYToolTipGenerator labelGenerator,
                                 XYURLGenerator urlGenerator); Paint getShapePaint(); void setShapePaint(Paint shapePaint); Stroke getShapeStroke(); void setShapeStroke(Stroke shapeStroke); @Override XYItemRendererState initialise(Graphics2D g2,
                                          Rectangle2D dataArea,
                                          XYPlot plot,
                                          XYDataset data,
                                          PlotRenderingInfo info); @Override int getPassCount(); @Override Range findRangeBounds(XYDataset dataset); @Override void drawItem(Graphics2D g2,
                         XYItemRendererState state,
                         Rectangle2D dataArea,
                         PlotRenderingInfo info,
                         XYPlot plot,
                         ValueAxis domainAxis,
                         ValueAxis rangeAxis,
                         XYDataset dataset,
                         int series,
                         int item,
                         CrosshairState crosshairState,
                         int pass); @Override boolean equals(Object obj); @Override Object clone();  }