Class Condition

java.lang.Object
ch.tocco.nice2.persist.core.api.qb2.Condition
Direct Known Subclasses:
Equation, Factor, Junction, Order, PrimaryKeyCondition, PrimaryKeyInCondition

public abstract class Condition extends Object
  • Constructor Details

    • Condition

      public Condition()
  • Method Details

    • create

      public abstract Node create(TypeManager typeManager, EntityModel entityModel)
      Creates a new node representing this condition.
      Parameters:
      typeManager - the type manager as it might be required for creating nodes
      entityModel - the entity model which is the root of the query
    • createPathNode

      public static PathNode createPathNode(String pathName)
      Helper method that creates a PathNode from a given path.
    • createPathNode

      public static PathNode createPathNode(Path path)
      Helper method that creates a PathNode from a given path.
    • getType

      public static Type<?> getType(@Nullable @Nullable Object value, TypeManager typeManager)
      Uses the given type manager to get the type of the given value. It returns the NullType if the value is null and tries to find the type according to the class of the given value.