Class AbstractConstraint

java.lang.Object
de.espirit.or.query.AbstractConstraint
All Implemented Interfaces:
AttributeConstraint, Constraint, Serializable, Cloneable
Direct Known Subclasses:
Compare, IsNotNull, IsNull

public abstract class AbstractConstraint extends Object implements AttributeConstraint
The base class for all implementations of Constraint which define an attribute based filter.
Since:
4.0.17
See Also:
  • Constructor Details

    • AbstractConstraint

      public AbstractConstraint()
  • Method Details

    • getType

      public abstract Constraint.Type getType()
      Return the type of this constraint.
      Specified by:
      getType in interface Constraint
      Returns:
      the type of this constraint.
      Since:
      4.0.17
    • getAttributeName

      @NotNull public final @NotNull String getAttributeName()
      Return the name of the attribute this constraint belongs to.
      Specified by:
      getAttributeName in interface AttributeConstraint
      Returns:
      the name of the attribute of this constraint
      Since:
      4.0.17
    • isEmpty

      public boolean isEmpty()
      Check if this is an empty constraint. Empty constraints could be omitted without changing the query result.
      Specified by:
      isEmpty in interface Constraint
      Returns:
      true if the constraint is empty, i.e. removing the constraint would not change the query result.
      Since:
      5.0.102