List of usage examples for org.jfree.data.time Month hashCode
@Override public int hashCode()
From source file:org.jfree.data.time.MonthTest.java
/** * Two objects that are equal are required to return the same hashCode. *///from w w w . j a va 2 s .c o m @Test public void testHashcode() { Month m1 = new Month(2, 2003); Month m2 = new Month(2, 2003); assertTrue(m1.equals(m2)); int h1 = m1.hashCode(); int h2 = m2.hashCode(); assertEquals(h1, h2); }
From source file:org.jfree.data.time.junit.MonthTest.java
/** * Two objects that are equal are required to return the same hashCode. *//*from w w w .j ava2 s. c o m*/ public void testHashcode() { Month m1 = new Month(2, 2003); Month m2 = new Month(2, 2003); assertTrue(m1.equals(m2)); int h1 = m1.hashCode(); int h2 = m2.hashCode(); assertEquals(h1, h2); }