@Test public void testEquals() { QuarterDateFormat qf1 = new QuarterDateFormat(TimeZone.getTimeZone( "GMT"), new String[] {"1", "2", "3", "4"}); QuarterDateFormat qf2 = new QuarterDateFormat(TimeZone.getTimeZone( "GMT"), new String[] {"1", "2", "3", "4"}); assertEquals(qf1, qf2); assertEquals(qf2, qf1); qf1 = new QuarterDateFormat(TimeZone.getTimeZone("PST"), new String[] {"1", "2", "3", "4"}); assertFalse(qf1.equals(qf2)); qf2 = new QuarterDateFormat(TimeZone.getTimeZone("PST"), new String[] {"1", "2", "3", "4"}); assertEquals(qf1, qf2); qf1 = new QuarterDateFormat(TimeZone.getTimeZone("PST"), new String[] {"A", "2", "3", "4"}); assertFalse(qf1.equals(qf2)); qf2 = new QuarterDateFormat(TimeZone.getTimeZone("PST"), new String[] {"A", "2", "3", "4"}); assertEquals(qf1, qf2); qf1 = new QuarterDateFormat(TimeZone.getTimeZone("PST"), new String[] {"A", "2", "3", "4"}, true); assertFalse(qf1.equals(qf2)); qf2 = new QuarterDateFormat(TimeZone.getTimeZone("PST"), new String[] {"A", "2", "3", "4"}, true); assertEquals(qf1, qf2); }
@Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof QuarterDateFormat)) { return false; } QuarterDateFormat that = (QuarterDateFormat) obj; if (!Arrays.equals(this.quarters, that.quarters)) { return false; } if (this.quarterFirst != that.quarterFirst) { return false; } return super.equals(obj); }
QuarterDateFormat extends DateFormat implements Cloneable, Serializable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof QuarterDateFormat)) { return false; } QuarterDateFormat that = (QuarterDateFormat) obj; if (!Arrays.equals(this.quarters, that.quarters)) { return false; } if (this.quarterFirst != that.quarterFirst) { return false; } return super.equals(obj); } }
QuarterDateFormat extends DateFormat implements Cloneable, Serializable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof QuarterDateFormat)) { return false; } QuarterDateFormat that = (QuarterDateFormat) obj; if (!Arrays.equals(this.quarters, that.quarters)) { return false; } if (this.quarterFirst != that.quarterFirst) { return false; } return super.equals(obj); } QuarterDateFormat();  QuarterDateFormat(TimeZone zone);  QuarterDateFormat(TimeZone zone, String[] quarterSymbols);  QuarterDateFormat(TimeZone zone, String[] quarterSymbols,
            boolean quarterFirst); }
QuarterDateFormat extends DateFormat implements Cloneable, Serializable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof QuarterDateFormat)) { return false; } QuarterDateFormat that = (QuarterDateFormat) obj; if (!Arrays.equals(this.quarters, that.quarters)) { return false; } if (this.quarterFirst != that.quarterFirst) { return false; } return super.equals(obj); } QuarterDateFormat();  QuarterDateFormat(TimeZone zone);  QuarterDateFormat(TimeZone zone, String[] quarterSymbols);  QuarterDateFormat(TimeZone zone, String[] quarterSymbols,
            boolean quarterFirst); @Override StringBuffer format(Date date, StringBuffer toAppendTo,
                               FieldPosition fieldPosition); @Override Date parse(String source, ParsePosition pos); @Override boolean equals(Object obj); }
QuarterDateFormat extends DateFormat implements Cloneable, Serializable { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof QuarterDateFormat)) { return false; } QuarterDateFormat that = (QuarterDateFormat) obj; if (!Arrays.equals(this.quarters, that.quarters)) { return false; } if (this.quarterFirst != that.quarterFirst) { return false; } return super.equals(obj); } QuarterDateFormat();  QuarterDateFormat(TimeZone zone);  QuarterDateFormat(TimeZone zone, String[] quarterSymbols);  QuarterDateFormat(TimeZone zone, String[] quarterSymbols,
            boolean quarterFirst); @Override StringBuffer format(Date date, StringBuffer toAppendTo,
                               FieldPosition fieldPosition); @Override Date parse(String source, ParsePosition pos); @Override boolean equals(Object obj); static final String[] REGULAR_QUARTERS; static final String[] ROMAN_QUARTERS; static final String[] GREEK_QUARTERS; }