gate.corpora
Class DocumentImpl.AnnotationComparator

java.lang.Object
  extended bygate.corpora.DocumentImpl.AnnotationComparator
All Implemented Interfaces:
Comparator
Enclosing class:
DocumentImpl

class DocumentImpl.AnnotationComparator
extends Object
implements Comparator

Inner class needed to compare annotations


Field Summary
(package private)  int orderOn
           
(package private)  int orderType
           
 
Constructor Summary
DocumentImpl.AnnotationComparator(int anOrderOn, int anOrderType)
          Constructs a comparator according to one of three sorter types: ORDER_ON_ANNOT_TYPE, ORDER_ON_END_OFFSET, ORDER_ON_START_OFFSET
 
Method Summary
 int compare(Object o1, Object o2)
          This method must be implemented according to Comparator interface
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Comparator
equals
 

Field Detail

orderOn

int orderOn

orderType

int orderType
Constructor Detail

DocumentImpl.AnnotationComparator

public DocumentImpl.AnnotationComparator(int anOrderOn,
                                         int anOrderType)
Constructs a comparator according to one of three sorter types: ORDER_ON_ANNOT_TYPE, ORDER_ON_END_OFFSET, ORDER_ON_START_OFFSET

Method Detail

compare

public int compare(Object o1,
                   Object o2)
This method must be implemented according to Comparator interface

Specified by:
compare in interface Comparator