Class OperationIn

java.lang.Object
overit.geocall.sql.code.criterion.Criterion
overit.geocall.sql.code.criterion.OperationIn
All Implemented Interfaces:
Cloneable

public class OperationIn extends Criterion
The class extends Criterion and aims to represent the IN (or NOT IN) operator used in the clauses definition.
This Operation could be used like this way "NAMEFIELD IN ('VALUE1','VALUE2',....)" or "NAMEFIELD NOT IN ('VALUE1','VALUE2',....)".
  • Field Details

    • _not

      protected final boolean _not
  • Constructor Details

    • OperationIn

      public OperationIn()
      Creates a new OperationIn
    • OperationIn

      public OperationIn(boolean not)
      Creates a new OperationIn
      Parameters:
      not - Boolean value indicating the operator IN or NOT IN depending on the value
  • Method Details

    • define

      public Parts define(String name, Object value)
      Description copied from class: Criterion
      defines the Parts of the operation with all the information to become a fragment.
      Specified by:
      define in class Criterion
      Parameters:
      name - the nome of the context field
      value - the current value of the context field
      Returns:
      return null if the Criterion don't find an information, a Parts otherwise. Then Parts con also contain empty strings if the decision is to discard the name and the value
    • stringify

      protected static void stringify(StringBuilder sb, String name, Object o)
    • stringify

      protected static void stringify(StringBuilder sb, String name, SmallKeyList c)
    • equals

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

      public int hashCode()
      Overrides:
      hashCode in class Object