JODA  0.13.1 (59b41972)
JSON On-Demand Analysis
Public Member Functions | Protected Attributes
joda::query::StaticEvalVisitor Class Reference

#include <StaticEvalVisitor.h>

Inheritance diagram for joda::query::StaticEvalVisitor:
[legend]
Collaboration diagram for joda::query::StaticEvalVisitor:
[legend]

Public Member Functions

void visit (AndPredicate *e) override
 
void visit (NegatePredicate *e) override
 
void visit (OrPredicate *e) override
 
void visit (EqualizePredicate *e) override
 
void visit (ComparePredicate *e) override
 
void visit (ValToPredicate *e) override
 
std::unique_ptr< PredicategetPred ()
 

Protected Attributes

bool changed = false
 
std::unique_ptr< Predicatepred
 

Detailed Description

Visitor analyzing a predicate tree for sub-trees with constant/static results. If such a subtree is found, it is replaced by the constant result in a copied instance.

Member Function Documentation

◆ getPred()

std::unique_ptr< joda::query::Predicate > joda::query::StaticEvalVisitor::getPred ( )
Returns
the optimized predicate
Here is the caller graph for this function:

◆ visit() [1/6]

void joda::query::StaticEvalVisitor::visit ( AndPredicate e)
overridevirtual

Visits an AndPredicate

Parameters
ePredicate to visit

Implements joda::query::PredicateVisitor.

Here is the call graph for this function:

◆ visit() [2/6]

void joda::query::StaticEvalVisitor::visit ( ComparePredicate e)
overridevirtual

Visits an ComparePredicate

Parameters
ePredicate to visit

Implements joda::query::PredicateVisitor.

Here is the call graph for this function:

◆ visit() [3/6]

void joda::query::StaticEvalVisitor::visit ( EqualizePredicate e)
overridevirtual

Visits an EqualizePredicate

Parameters
ePredicate to visit

Implements joda::query::PredicateVisitor.

Here is the call graph for this function:

◆ visit() [4/6]

void joda::query::StaticEvalVisitor::visit ( NegatePredicate e)
overridevirtual

Visits an NegatePredicate

Parameters
ePredicate to visit

Implements joda::query::PredicateVisitor.

Here is the call graph for this function:

◆ visit() [5/6]

void joda::query::StaticEvalVisitor::visit ( OrPredicate e)
overridevirtual

Visits an OrPredicate

Parameters
ePredicate to visit

Implements joda::query::PredicateVisitor.

Here is the call graph for this function:

◆ visit() [6/6]

void joda::query::StaticEvalVisitor::visit ( ValToPredicate e)
overridevirtual

Visits an ValToPredicate

Parameters
ePredicate to visit

Implements joda::query::PredicateVisitor.

Here is the call graph for this function:

Field Documentation

◆ changed

bool joda::query::StaticEvalVisitor::changed = false
protected

◆ pred

std::unique_ptr<Predicate> joda::query::StaticEvalVisitor::pred
protected

The documentation for this class was generated from the following files: