public interface ElementComparator
TokenSequence
.
An ElementComparator
always exists in the
context of a TokenSequence
; indexes refer
to this sequence.Modifier and Type | Field and Description |
---|---|
static int |
EQUALS
A value indicating the left value was equal to the right value
|
static int |
GREATER_THAN
A value indicating the left value was greater than the right value
|
static int |
LESS_THAN
A value indicating the left value was less than the right value
|
Modifier and Type | Method and Description |
---|---|
int |
compareElements(int lhsIndex,
int rhsIndex)
Compares two sequence elements, specified by index.
|
static final int LESS_THAN
static final int EQUALS
static final int GREATER_THAN
int compareElements(int lhsIndex, int rhsIndex)
lhsIndex
- the index of the left hand element
in the comparisonrhsIndex
- the index of the right hand element
in the comparison0
if the values are equal,
1
if the left elements value is greater,
-1
if the left elements value is lesser.
A null value is greater than any other non-null;
two null values compare as equal.Copyright © 2016 Actian Corporation. All rights reserved.