gate.util
Class TestEqual
java.lang.Object
|
+--gate.util.TestEqual
- public class TestEqual
- extends Object
This class provides some static utility methods such as equality test for
annotation sets and documents. They are mainly used by test classes.
Field Summary |
static String |
message
If set to true, explanation messages will be printed when a test fails. |
Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait |
message
public static String message
- If set to true, explanation messages will be printed when a test fails.
TestEqual
public TestEqual()
documentsEqual
public static boolean documentsEqual(Document doc1,
Document doc2)
- Checks two documents for equality.
- Parameters:
doc1
- a documentdoc2
- another document- Returns:
- a boolean.
annotationSetsEqual
public static boolean annotationSetsEqual(AnnotationSet as1,
AnnotationSet as2)
- Two AnnotationSet are equal if their name, the documents of which belong
to the AnnotationSets and annotations from the sets are the same
check
protected static boolean check(Object a,
Object b)
- Check: test 2 objects for equality