Class TLcdOGCBinaryComparisonOperator

java.lang.Object
com.luciad.datamodel.TLcdDataObject
com.luciad.ogc.filter.model.TLcdOGCBinaryComparisonOperator
All Implemented Interfaces:
ILcdDataObject, ILcdGenericExpression, ILcdOGCCondition, ILcdCloneable, ILcdDeepCloneable, Cloneable

public class TLcdOGCBinaryComparisonOperator extends TLcdDataObject implements ILcdOGCCondition
This class represents the elements of type <ogc:BinaryComparisonOpType>. Namely:
  • <ogc:PropertyIsEqualTo>
  • <ogc:PropertyIsNotEqualTo>
  • <ogc:PropertyIsGreaterThan>
  • <ogc:PropertyIsGreaterOrEqualThan>
  • <ogc:PropertyIsLessThan>
  • <ogc:PropertyIsLessOrEqualThan>
According to the OGC Filter specification, the comparison operator is used to form expressions that evaluate the mathematical comparison between two arguments. If the arguments satisfy the comparison then the expression evaluates to TRUE. Otherwise the expression evaluates to FALSE.

A TLcdOGCBinaryComparisonOperator instance is composed of a type that must be one of the constants defined in this class, and two operands that can be any instances of ILcdOGCExpression. It also admits a matchCase property relevant in case of comparison between strings.

See Also:
  • Field Details

    • EQUAL

      public static final int EQUAL
      Comparison type that corresponds to the <ogc:PropertyIsEqualTo> element.
      See Also:
    • NOT_EQUAL

      public static final int NOT_EQUAL
      Comparison type that corresponds to the <ogc:PropertyIsNotEqualTo> element.
      See Also:
    • GREATER

      public static final int GREATER
      Comparison type that corresponds to the <ogc:PropertyIsGreaterThan> element.
      See Also:
    • LESS

      public static final int LESS
      Comparison type that corresponds to the <ogc:PropertyIsLessThan> element.
      See Also:
    • GREATER_OR_EQUAL

      public static final int GREATER_OR_EQUAL
      Comparison type that corresponds to the <ogc:PropertyIsGreaterOrEqualThan> element.
      See Also:
    • LESS_OR_EQUAL

      public static final int LESS_OR_EQUAL
      Comparison type that corresponds to the <ogc:PropertyIsLessOrEqualThan> element.
      See Also:
  • Constructor Details

    • TLcdOGCBinaryComparisonOperator

      public TLcdOGCBinaryComparisonOperator()
      Default constructor.
    • TLcdOGCBinaryComparisonOperator

      public TLcdOGCBinaryComparisonOperator(int aType)
      Creates an instance with a given comparison type.
      Parameters:
      aType - the given comparison type.
    • TLcdOGCBinaryComparisonOperator

      public TLcdOGCBinaryComparisonOperator(int aType, ILcdOGCExpression aFirstExpression, ILcdOGCExpression aSecondExpression)
      Creates an instance with a given comparison type and two given operands.
      Parameters:
      aType - the given comparison type.
      aFirstExpression - the first operand.
      aSecondExpression - the second operand.
  • Method Details

    • getType

      public int getType()
      Gets the comparison type.
      Returns:
      the comparison type.
    • setType

      public void setType(int aType)
      Sets the comparison type.
      Parameters:
      aType - the comparison type.
    • getFirstExpression

      public ILcdOGCExpression getFirstExpression()
      Gets the first operand of the comparison.
      Returns:
      the first operand of the comparison.
    • setFirstExpression

      public void setFirstExpression(ILcdOGCExpression aFirstExpression)
      Sets the first operand of the comparison.
      Parameters:
      aFirstExpression - the first operand of the comparison.
    • getSecondExpression

      public ILcdOGCExpression getSecondExpression()
      Gets the second operand of the comparison.
      Returns:
      the second operand of the comparison.
    • setSecondExpression

      public void setSecondExpression(ILcdOGCExpression aSecondExpression)
      Sets the second operand of the comparison.
      Parameters:
      aSecondExpression - the second operand of the comparison.
    • isMatchCase

      public boolean isMatchCase()
      Indicates whether the case must be matched in case of a comparison between strings. The default value is true.
      Returns:
      true if the case must be matched; false otherwise.
    • setMatchCase

      public void setMatchCase(boolean aMatchCase)
      Indicates whether the case must be matched in case of a comparison between strings. The default value is true.
      Parameters:
      aMatchCase - true if the case must be matched; false otherwise.
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class TLcdDataObject