Impala
Impalaistheopensource,nativeanalyticdatabaseforApacheHadoop.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
tuple-is-null-predicate.h
Go to the documentation of this file.
1 // Copyright 2012 Cloudera Inc.
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14 
15 
16 #ifndef IMPALA_EXPRS_TUPLE_IS_NULL_PREDICATE_H_
17 #define IMPALA_EXPRS_TUPLE_IS_NULL_PREDICATE_H_
18 
19 #include "exprs/predicate.h"
20 
21 namespace impala {
22 
23 class TExprNode;
24 
31  protected:
32  friend class Expr;
33 
34  TupleIsNullPredicate(const TExprNode& node);
35 
36  virtual Status Prepare(RuntimeState* state, const RowDescriptor& row_desc,
37  ExprContext* ctx);
38  virtual Status GetCodegendComputeFn(RuntimeState* state, llvm::Function** fn);
39  virtual std::string DebugString() const;
40 
41  virtual bool IsConstant() const { return false; }
42 
43  virtual BooleanVal GetBooleanVal(ExprContext* context, TupleRow* row);
44 
45  private:
47  std::vector<TupleId> tuple_ids_;
48 
50  std::vector<int32_t> tuple_idxs_;
51 };
52 
53 }
54 
55 #endif
virtual std::string DebugString() const
virtual BooleanVal GetBooleanVal(ExprContext *context, TupleRow *row)
std::vector< int32_t > tuple_idxs_
Tuple indexes into the RowDescriptor. Only contains indexes of nullable tuples.
This is the superclass of all expr evaluation nodes.
Definition: expr.h:116
const RowDescriptor & row_desc() const
std::vector< TupleId > tuple_ids_
Tuple ids to check for NULL. May contain ids of nullable and non-nullable tuples. ...
TupleIsNullPredicate(const TExprNode &node)
virtual Status Prepare(RuntimeState *state, const RowDescriptor &row_desc, ExprContext *ctx)
virtual Status GetCodegendComputeFn(RuntimeState *state, llvm::Function **fn)