The comparison Java SequenceIterator methods take an input sequence argument, and produce the boolean result sequence by applying the specified comparison operator on the object's sequence and the corresponding elements in the input sequence.
If the two input sequence arguments are of different lengths the operation will be performed on only the number of elements in the shorter of the two sequences.
The operator can be one of the following:
SequenceIterator eq(SequenceIterator (input) The element of the result sequence is true
for corresponding elements that are equal in the input sequence; otherwisefalse
SequenceIterator ne(SequenceIterator (input) The element of the result sequence is true
for corresponding elements that are not equal in the input sequence; otherwisefalse
SequenceIterator gt(SequenceIterator (input) The element of the result sequence is true
for corresponding elements where the object's element is greater than the input; otherwisefalse
SequenceIterator ge(SequenceIterator (input) The element of the result sequence is true
for corresponding elements where the object's element is greater than or equal to the input; otherwisefalse
SequenceIterator lt(SequenceIterator (input) The element of the result sequence is true
for corresponding elements where the object's element is less than the input; otherwisefalse
SequenceIterator le(SequenceIterator (input) The element of the result sequence is true
for corresponding elements where the object's element is less than or equal to the input; otherwisefalse
Example
Following is an example code snippet demonstrating a comparison operator method:
Cursor<Quote> cursor = new Cursor<Quote>(con, Quote.class, "symbol"); for (Quote quote : cursor) { ... SequenceIterator eq = quote.high.eq(quote.close) ...