Class BooleanExpression

    • Constructor Detail

      • BooleanExpression

        public BooleanExpression​(int id)
      • BooleanExpression

        public BooleanExpression​(SqlParser p,
                                 int id)
    • Method Detail

      • supportsBasicCalculation

        protected abstract boolean supportsBasicCalculation()
        Returns:
        true if this expression can be calculated in plain Java, false otherwise
      • getNumberOfExternalCalculations

        protected abstract int getNumberOfExternalCalculations()
        Returns:
        the number of sub-expressions that have to be calculated using an external engine
      • getExternalCalculationConditions

        protected abstract List<Object> getExternalCalculationConditions()
        Returns:
        the sub-expressions that have to be calculated using an external engine
      • needsAliases

        public abstract boolean needsAliases​(Set<String> aliases)
      • isEmpty

        public boolean isEmpty()
      • extractSubQueries

        public abstract void extractSubQueries​(SubQueryCollector collector)
      • refersToParent

        public abstract boolean refersToParent()
      • transformToUpdateItem

        public Optional<UpdateItem> transformToUpdateItem()
        returns the equivalent of current condition as an UPDATE expression with the same syntax, if possible.

        Eg. name = 3 can be considered a condition or an assignment. This method transforms the condition in an assignment. This is used mainly for UPSERT operations.

        Returns:
        the equivalent of current condition as an UPDATE expression with the same syntax, if possible.
      • getMatchPatternInvolvedAliases

        public abstract List<String> getMatchPatternInvolvedAliases()
      • serialize

        public Result serialize()
      • deserialize

        public void deserialize​(Result fromResult)
      • isCacheable

        public abstract boolean isCacheable()