@Test public void testHashcode() { Second s1 = new Second(13, 45, 5, 1, 2, 2003); Second s2 = new Second(13, 45, 5, 1, 2, 2003); assertEquals(s1, s2); int h1 = s1.hashCode(); int h2 = s2.hashCode(); assertEquals(h1, h2); }
@Override public int hashCode() { int result = 17; result = 37 * result + this.second; result = 37 * result + this.minute; result = 37 * result + this.hour; result = 37 * result + this.day.hashCode(); return result; }
Second extends RegularTimePeriod implements Serializable { @Override public int hashCode() { int result = 17; result = 37 * result + this.second; result = 37 * result + this.minute; result = 37 * result + this.hour; result = 37 * result + this.day.hashCode(); return result; } }
Second extends RegularTimePeriod implements Serializable { @Override public int hashCode() { int result = 17; result = 37 * result + this.second; result = 37 * result + this.minute; result = 37 * result + this.hour; result = 37 * result + this.day.hashCode(); return result; } Second();  Second(int second, Minute minute);  Second(int second, int minute, int hour,
                  int day, int month, int year);  Second(Date time);  Second(Date time, TimeZone zone, Locale locale); }
Second extends RegularTimePeriod implements Serializable { @Override public int hashCode() { int result = 17; result = 37 * result + this.second; result = 37 * result + this.minute; result = 37 * result + this.hour; result = 37 * result + this.day.hashCode(); return result; } Second();  Second(int second, Minute minute);  Second(int second, int minute, int hour,
                  int day, int month, int year);  Second(Date time);  Second(Date time, TimeZone zone, Locale locale); int getSecond(); Minute getMinute(); @Override long getFirstMillisecond(); @Override long getLastMillisecond(); @Override void peg(Calendar calendar); @Override RegularTimePeriod previous(); @Override RegularTimePeriod next(); @Override long getSerialIndex(); @Override long getFirstMillisecond(Calendar calendar); @Override long getLastMillisecond(Calendar calendar); @Override boolean equals(Object obj); @Override int hashCode(); @Override int compareTo(TimePeriod o1); static Second parseSecond(String s); }
Second extends RegularTimePeriod implements Serializable { @Override public int hashCode() { int result = 17; result = 37 * result + this.second; result = 37 * result + this.minute; result = 37 * result + this.hour; result = 37 * result + this.day.hashCode(); return result; } Second();  Second(int second, Minute minute);  Second(int second, int minute, int hour,
                  int day, int month, int year);  Second(Date time);  Second(Date time, TimeZone zone, Locale locale); int getSecond(); Minute getMinute(); @Override long getFirstMillisecond(); @Override long getLastMillisecond(); @Override void peg(Calendar calendar); @Override RegularTimePeriod previous(); @Override RegularTimePeriod next(); @Override long getSerialIndex(); @Override long getFirstMillisecond(Calendar calendar); @Override long getLastMillisecond(Calendar calendar); @Override boolean equals(Object obj); @Override int hashCode(); @Override int compareTo(TimePeriod o1); static Second parseSecond(String s); static final int FIRST_SECOND_IN_MINUTE; static final int LAST_SECOND_IN_MINUTE; }