|
iceberg-cpp
|
Represents a boolean expression tree. More...
#include <expression.h>
Public Types | |
| enum class | Operation { kTrue , kFalse , kIsNull , kNotNull , kIsNan , kNotNan , kLt , kLtEq , kGt , kGtEq , kEq , kNotEq , kIn , kNotIn , kNot , kAnd , kOr , kStartsWith , kNotStartsWith , kCount , kCountNull , kCountStar , kMax , kMin } |
| Operation types for expressions. | |
Public Member Functions | |
| virtual Operation | op () const =0 |
| Returns the operation for an expression node. | |
| virtual Result< std::shared_ptr< Expression > > | Negate () const |
| Returns the negation of this expression, equivalent to not(this). | |
| virtual bool | Equals (const Expression &other) const |
| Returns whether this expression will accept the same values as another. | |
| std::string | ToString () const override |
| Get a user-readable string representation. | |
| virtual bool | is_unbound_predicate () const |
| virtual bool | is_bound_predicate () const |
| virtual bool | is_unbound_aggregate () const |
| virtual bool | is_bound_aggregate () const |
Represents a boolean expression tree.
|
inlinevirtual |
Returns whether this expression will accept the same values as another.
| other | another expression |
Reimplemented in iceberg::True, iceberg::False, iceberg::And, iceberg::Or, iceberg::Not, iceberg::BoundUnaryPredicate, iceberg::BoundLiteralPredicate, and iceberg::BoundSetPredicate.
|
inlinevirtual |
Returns the negation of this expression, equivalent to not(this).
Reimplemented in iceberg::True, iceberg::False, iceberg::And, iceberg::Or, iceberg::Not, iceberg::UnboundPredicateImpl< B >, iceberg::BoundUnaryPredicate, iceberg::BoundLiteralPredicate, iceberg::BoundSetPredicate, and iceberg::UnboundPredicate.
|
pure virtual |
Returns the operation for an expression node.
Implemented in iceberg::Aggregate< T >, iceberg::Aggregate< BoundTerm >, iceberg::Aggregate< UnboundTerm< B > >, iceberg::True, iceberg::False, iceberg::And, iceberg::Or, iceberg::Not, iceberg::Predicate< T >, iceberg::Predicate< BoundTerm >, and iceberg::Predicate< UnboundTerm< B > >.
|
inlineoverridevirtual |
Get a user-readable string representation.
Implements iceberg::util::Formattable.
Reimplemented in iceberg::True, iceberg::False, iceberg::Or, iceberg::Not, and iceberg::UnboundPredicateImpl< B >.