@Test public void testEquals() { StandardPieURLGenerator g1 = new StandardPieURLGenerator(); StandardPieURLGenerator g2 = new StandardPieURLGenerator(); assertEquals(g1, g2); g1 = new StandardPieURLGenerator("prefix", "category", "index"); assertFalse(g1.equals(g2)); g2 = new StandardPieURLGenerator("prefix", "category", "index"); assertEquals(g1, g2); g1 = new StandardPieURLGenerator("prefix2", "category", "index"); assertFalse(g1.equals(g2)); g2 = new StandardPieURLGenerator("prefix2", "category", "index"); assertEquals(g1, g2); g1 = new StandardPieURLGenerator("prefix2", "category2", "index"); assertFalse(g1.equals(g2)); g2 = new StandardPieURLGenerator("prefix2", "category2", "index"); assertEquals(g1, g2); g1 = new StandardPieURLGenerator("prefix2", "category2", "index2"); assertFalse(g1.equals(g2)); g2 = new StandardPieURLGenerator("prefix2", "category2", "index2"); assertEquals(g1, g2); g1 = new StandardPieURLGenerator("prefix2", "category2", null); assertFalse(g1.equals(g2)); g2 = new StandardPieURLGenerator("prefix2", "category2", null); assertEquals(g1, g2); }
@Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof StandardPieURLGenerator)) { return false; } StandardPieURLGenerator that = (StandardPieURLGenerator) obj; if (!this.prefix.equals(that.prefix)) { return false; } if (!this.categoryParameterName.equals(that.categoryParameterName)) { return false; } if (!ObjectUtilities.equal(this.indexParameterName, that.indexParameterName)) { return false; } return true; }
StandardPieURLGenerator implements PieURLGenerator, Serializable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof StandardPieURLGenerator)) { return false; } StandardPieURLGenerator that = (StandardPieURLGenerator) obj; if (!this.prefix.equals(that.prefix)) { return false; } if (!this.categoryParameterName.equals(that.categoryParameterName)) { return false; } if (!ObjectUtilities.equal(this.indexParameterName, that.indexParameterName)) { return false; } return true; } }
StandardPieURLGenerator implements PieURLGenerator, Serializable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof StandardPieURLGenerator)) { return false; } StandardPieURLGenerator that = (StandardPieURLGenerator) obj; if (!this.prefix.equals(that.prefix)) { return false; } if (!this.categoryParameterName.equals(that.categoryParameterName)) { return false; } if (!ObjectUtilities.equal(this.indexParameterName, that.indexParameterName)) { return false; } return true; } StandardPieURLGenerator();  StandardPieURLGenerator(String prefix);  StandardPieURLGenerator(String prefix,
                                   String categoryParameterName);  StandardPieURLGenerator(String prefix,
                                   String categoryParameterName,
                                   String indexParameterName); }
StandardPieURLGenerator implements PieURLGenerator, Serializable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof StandardPieURLGenerator)) { return false; } StandardPieURLGenerator that = (StandardPieURLGenerator) obj; if (!this.prefix.equals(that.prefix)) { return false; } if (!this.categoryParameterName.equals(that.categoryParameterName)) { return false; } if (!ObjectUtilities.equal(this.indexParameterName, that.indexParameterName)) { return false; } return true; } StandardPieURLGenerator();  StandardPieURLGenerator(String prefix);  StandardPieURLGenerator(String prefix,
                                   String categoryParameterName);  StandardPieURLGenerator(String prefix,
                                   String categoryParameterName,
                                   String indexParameterName); @Override String generateURL(PieDataset dataset, Comparable key,
            int pieIndex); @Override boolean equals(Object obj); }
StandardPieURLGenerator implements PieURLGenerator, Serializable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof StandardPieURLGenerator)) { return false; } StandardPieURLGenerator that = (StandardPieURLGenerator) obj; if (!this.prefix.equals(that.prefix)) { return false; } if (!this.categoryParameterName.equals(that.categoryParameterName)) { return false; } if (!ObjectUtilities.equal(this.indexParameterName, that.indexParameterName)) { return false; } return true; } StandardPieURLGenerator();  StandardPieURLGenerator(String prefix);  StandardPieURLGenerator(String prefix,
                                   String categoryParameterName);  StandardPieURLGenerator(String prefix,
                                   String categoryParameterName,
                                   String indexParameterName); @Override String generateURL(PieDataset dataset, Comparable key,
            int pieIndex); @Override boolean equals(Object obj);  }