@Test public void testEquals() { DefaultTableXYDataset d1 = new DefaultTableXYDataset(); XYSeries s1 = new XYSeries("Series 1", true, false); s1.add(1.0, 1.1); s1.add(2.0, 2.2); d1.addSeries(s1); DefaultTableXYDataset d2 = new DefaultTableXYDataset(); XYSeries s2 = new XYSeries("Series 1", true, false); s2.add(1.0, 1.1); s2.add(2.0, 2.2); d2.addSeries(s2); assertEquals(d1, d2); assertEquals(d2, d1); s1.add(3.0, 3.3); assertFalse(d1.equals(d2)); s2.add(3.0, 3.3); assertEquals(d1, d2); }
@Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof DefaultTableXYDataset)) { return false; } DefaultTableXYDataset that = (DefaultTableXYDataset) obj; if (this.autoPrune != that.autoPrune) { return false; } if (this.propagateEvents != that.propagateEvents) { return false; } if (!this.intervalDelegate.equals(that.intervalDelegate)) { return false; } if (!ObjectUtilities.equal(this.data, that.data)) { return false; } return true; }
DefaultTableXYDataset extends AbstractIntervalXYDataset implements TableXYDataset, IntervalXYDataset, DomainInfo,
                   PublicCloneable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof DefaultTableXYDataset)) { return false; } DefaultTableXYDataset that = (DefaultTableXYDataset) obj; if (this.autoPrune != that.autoPrune) { return false; } if (this.propagateEvents != that.propagateEvents) { return false; } if (!this.intervalDelegate.equals(that.intervalDelegate)) { return false; } if (!ObjectUtilities.equal(this.data, that.data)) { return false; } return true; } }
DefaultTableXYDataset extends AbstractIntervalXYDataset implements TableXYDataset, IntervalXYDataset, DomainInfo,
                   PublicCloneable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof DefaultTableXYDataset)) { return false; } DefaultTableXYDataset that = (DefaultTableXYDataset) obj; if (this.autoPrune != that.autoPrune) { return false; } if (this.propagateEvents != that.propagateEvents) { return false; } if (!this.intervalDelegate.equals(that.intervalDelegate)) { return false; } if (!ObjectUtilities.equal(this.data, that.data)) { return false; } return true; } DefaultTableXYDataset();  DefaultTableXYDataset(boolean autoPrune); }
DefaultTableXYDataset extends AbstractIntervalXYDataset implements TableXYDataset, IntervalXYDataset, DomainInfo,
                   PublicCloneable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof DefaultTableXYDataset)) { return false; } DefaultTableXYDataset that = (DefaultTableXYDataset) obj; if (this.autoPrune != that.autoPrune) { return false; } if (this.propagateEvents != that.propagateEvents) { return false; } if (!this.intervalDelegate.equals(that.intervalDelegate)) { return false; } if (!ObjectUtilities.equal(this.data, that.data)) { return false; } return true; } DefaultTableXYDataset();  DefaultTableXYDataset(boolean autoPrune); boolean isAutoPrune(); void addSeries(XYSeries series); void updateXPoints(); @Override int getSeriesCount(); @Override int getItemCount(); XYSeries getSeries(int series); @Override Comparable getSeriesKey(int series); @Override int getItemCount(int series); @Override Number getX(int series, int item); @Override Number getStartX(int series, int item); @Override Number getEndX(int series, int item); @Override Number getY(int series, int index); @Override Number getStartY(int series, int item); @Override Number getEndY(int series, int item); void removeAllSeries(); void removeSeries(XYSeries series); void removeSeries(int series); void removeAllValuesForX(Number x); void prune(); @Override void seriesChanged(SeriesChangeEvent event); @Override boolean equals(Object obj); @Override int hashCode(); @Override Object clone(); @Override double getDomainLowerBound(boolean includeInterval); @Override double getDomainUpperBound(boolean includeInterval); @Override Range getDomainBounds(boolean includeInterval); double getIntervalPositionFactor(); void setIntervalPositionFactor(double d); double getIntervalWidth(); void setIntervalWidth(double d); boolean isAutoWidth(); void setAutoWidth(boolean b); }
DefaultTableXYDataset extends AbstractIntervalXYDataset implements TableXYDataset, IntervalXYDataset, DomainInfo,
                   PublicCloneable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof DefaultTableXYDataset)) { return false; } DefaultTableXYDataset that = (DefaultTableXYDataset) obj; if (this.autoPrune != that.autoPrune) { return false; } if (this.propagateEvents != that.propagateEvents) { return false; } if (!this.intervalDelegate.equals(that.intervalDelegate)) { return false; } if (!ObjectUtilities.equal(this.data, that.data)) { return false; } return true; } DefaultTableXYDataset();  DefaultTableXYDataset(boolean autoPrune); boolean isAutoPrune(); void addSeries(XYSeries series); void updateXPoints(); @Override int getSeriesCount(); @Override int getItemCount(); XYSeries getSeries(int series); @Override Comparable getSeriesKey(int series); @Override int getItemCount(int series); @Override Number getX(int series, int item); @Override Number getStartX(int series, int item); @Override Number getEndX(int series, int item); @Override Number getY(int series, int index); @Override Number getStartY(int series, int item); @Override Number getEndY(int series, int item); void removeAllSeries(); void removeSeries(XYSeries series); void removeSeries(int series); void removeAllValuesForX(Number x); void prune(); @Override void seriesChanged(SeriesChangeEvent event); @Override boolean equals(Object obj); @Override int hashCode(); @Override Object clone(); @Override double getDomainLowerBound(boolean includeInterval); @Override double getDomainUpperBound(boolean includeInterval); @Override Range getDomainBounds(boolean includeInterval); double getIntervalPositionFactor(); void setIntervalPositionFactor(double d); double getIntervalWidth(); void setIntervalWidth(double d); boolean isAutoWidth(); void setAutoWidth(boolean b);  }