org.eclipse.actf.util.comparator

## Class ChainComparator

- java.lang.Object
- - org.eclipse.actf.util.comparator.ChainComparator

All Implemented Interfaces:
  Comparator<Object>

Direct Known Subclasses:
  ResultTableSorterBase.GuidelineComparator, ResultTableSorterBase.LinesComparator, ResultTableSorterBase.ScoreCompator, ResultTableSorterBase.SeverityComparator, ResultTableSorterBase.StringComparator

    public abstract class ChainComparator
    extends Object
    implements Comparator<Object>

Abstract class for implementing Comparator chain.

### Constructor Summary

Constructors
Constructor and Description
`ChainComparator()`

### Method Summary

Methods
`int` `compare(Object o1, Object o2)`
`int` `intResolve(int i1, int i2)` Return comparison result
`ChainComparator` `setNext(ChainComparator next)` Set next Comparator.

### Methods inherited from class java.lang.Object

`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface java.util.Comparator

`equals`

### Constructor Detail

#### ChainComparator

    public ChainComparator()

### Method Detail

#### setNext

    public ChainComparator setNext(ChainComparator next)

Set next Comparator.

Parameters:
  `next` - the next Comparator
Returns:
  the next Comparator

#### intResolve

    public final int intResolve(int i1,
                 int i2)

Return comparison result

Parameters:
  `i1` - the target integer value 1
  `i2` - the target integer value 2
Returns:
  a negative integer, zero, or a positive integer as the first argument is less than, equal to, or greater than the second.

#### compare

    public int compare(Object o1,
              Object o2)

Specified by:
  `compare` in interface `Comparator<Object>`