]> gitweb.fperrin.net Git - Dictionary.git/blob - jars/icu4j-52_1/main/tests/core/src/com/ibm/icu/dev/test/util/Equator.java
Upgrade ICU4J.
[Dictionary.git] / jars / icu4j-52_1 / main / tests / core / src / com / ibm / icu / dev / test / util / Equator.java
1 /*
2  *******************************************************************************
3  * Copyright (C) 2002-2004, International Business Machines Corporation and    *
4  * others. All Rights Reserved.                                                *
5  *******************************************************************************
6  */
7 package com.ibm.icu.dev.test.util;
8
9 public interface Equator {
10     /**
11       * Comparator function. If overridden, must handle case of null,
12       * and compare any two objects that could be compared.
13       * Must obey normal rules of symmetry: a=b => b=a
14       * and transitivity: a=b & b=c => a=b)
15       * @param a
16       * @param b
17       * @return true if a and b are equal
18       */
19      public boolean isEqual(Object a, Object b);
20
21     /**
22      * Must obey normal rules: a=b => getHashCode(a)=getHashCode(b)
23      * @param object
24      * @return a hash code for the object
25      */
26     public int getHashCode(Object object);
27 }