Class SingleValueComparator
- java.lang.Object
-
- org.apache.solr.client.solrj.io.comp.SingleValueComparator
-
- All Implemented Interfaces:
Serializable,Comparator<Tuple>,StreamComparator,Expressible
public class SingleValueComparator extends Object implements StreamComparator
An equality Comparator to be used when a stream will only ever return a single field, ie, it has no sorted order- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description SingleValueComparator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StreamComparatorappend(StreamComparator other)intcompare(Tuple leftTuple, Tuple rightTuple)SingleValueComparatorcopyAliased(Map<String,String> aliases)booleanisDerivedFrom(StreamComparator base)ExplanationtoExplanation(StreamFactory factory)Returns an explanation about the stream objectStreamExpressionParametertoExpression(StreamFactory factory)-
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, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
-
-
-
Method Detail
-
toExpression
public StreamExpressionParameter toExpression(StreamFactory factory)
- Specified by:
toExpressionin interfaceExpressible
-
toExplanation
public Explanation toExplanation(StreamFactory factory) throws IOException
Description copied from interface:ExpressibleReturns an explanation about the stream object- Specified by:
toExplanationin interfaceExpressible- Parameters:
factory- Stream factory for this, contains information about the function name- Returns:
- Explanation about this stream object containing explanations of any child stream objects
- Throws:
IOException- throw on any error
-
compare
public int compare(Tuple leftTuple, Tuple rightTuple)
- Specified by:
comparein interfaceComparator<Tuple>
-
isDerivedFrom
public boolean isDerivedFrom(StreamComparator base)
- Specified by:
isDerivedFromin interfaceStreamComparator
-
copyAliased
public SingleValueComparator copyAliased(Map<String,String> aliases)
- Specified by:
copyAliasedin interfaceStreamComparator
-
append
public StreamComparator append(StreamComparator other)
- Specified by:
appendin interfaceStreamComparator
-
-