casacore
Public Member Functions | Static Public Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
casacore::TableExprNode Class Reference

More...

#include <ExprNode.h>

Public Member Functions

 TableExprNode ()
 
TableExprNode operator+ () const
 Unary operators on numeric TableExprNode's. More...
 
TableExprNode operator- () const
 
TableExprNode operator! () const
 Unary NOT-operator on boolean TableExprNode's. More...
 
TableExprNode operator~ () const
 Unary bitwise negate-operator on integer TableExprNode's. More...
 
TableExprNode operator() (const TableExprNodeSet &indices)
 Slicing in a node containing an array. More...
 
TableExprNode in (const TableExprNode &array, const TaQLStyle &=TaQLStyle(0)) const
 The IN operator to test if a value is contained in an array or set. More...
 
TableExprNode in (const TableExprNodeSet &set, const TaQLStyle &=TaQLStyle(0)) const
 
TableExprNode useUnit (const Unit &unit) const
 Use a unit for the given TableExprNode. More...
 
 TableExprNode (const Bool &value)
 Constructors to convert a constant value to a TableExprNode. More...
 
 TableExprNode (const Int &value)
 
 TableExprNode (const uInt &value)
 
 TableExprNode (const Int64 &value)
 
 TableExprNode (const uInt64 &value)
 
 TableExprNode (const Float &value)
 
 TableExprNode (const Double &value)
 
 TableExprNode (const Complex &value)
 
 TableExprNode (const DComplex &value)
 
 TableExprNode (const String &value)
 
 TableExprNode (const std::string &value)
 
 TableExprNode (const char *)
 
 TableExprNode (const Regex &value)
 
 TableExprNode (const StringDistance &value)
 
 TableExprNode (const TaqlRegex &value)
 
 TableExprNode (const MVTime &value)
 
 TableExprNode (const Array< Bool > &value)
 
 TableExprNode (const Array< uChar > &value)
 
 TableExprNode (const Array< Short > &value)
 
 TableExprNode (const Array< uShort > &value)
 
 TableExprNode (const Array< Int > &value)
 
 TableExprNode (const Array< uInt > &value)
 
 TableExprNode (const Array< Int64 > &value)
 
 TableExprNode (const Array< uInt64 > &value)
 
 TableExprNode (const Array< Float > &value)
 
 TableExprNode (const Array< Double > &value)
 
 TableExprNode (const Array< Complex > &value)
 
 TableExprNode (const Array< DComplex > &value)
 
 TableExprNode (const Array< String > &value)
 
 TableExprNode (const Array< MVTime > &value)
 
 TableExprNode (const MArray< Bool > &value)
 
 TableExprNode (const MArray< uChar > &value)
 
 TableExprNode (const MArray< Short > &value)
 
 TableExprNode (const MArray< uShort > &value)
 
 TableExprNode (const MArray< Int > &value)
 
 TableExprNode (const MArray< uInt > &value)
 
 TableExprNode (const MArray< Int64 > &value)
 
 TableExprNode (const MArray< uInt64 > &value)
 
 TableExprNode (const MArray< Float > &value)
 
 TableExprNode (const MArray< Double > &value)
 
 TableExprNode (const MArray< Complex > &value)
 
 TableExprNode (const MArray< DComplex > &value)
 
 TableExprNode (const MArray< String > &value)
 
 TableExprNode (const MArray< MVTime > &value)
 
 TableExprNode (const TENShPtr &)
 Construct a node from a node representation shared pointer which increments the reference count. More...
 
 TableExprNode (TableExprNodeRep *rep)
 Construct from a node representation. More...
 
 TableExprNode (const TableExprNode &)
 copy constructor (reference semantics). More...
 
TableExprNodeoperator= (const TableExprNode &)
 Assignment (reference semantics). More...
 
 ~TableExprNode ()
 The destructor deletes all the underlying TableExprNode objects,. More...
 
Bool isNull () const
 Does the node contain no actual node? More...
 
void disableApplySelection ()
 Do not apply the selection. More...
 
void applySelection (const Vector< rownr_t > &rownrs)
 Re-create the column object for a selection of rows. More...
 
const Unitunit () const
 Get the unit of the expression. More...
 
const Recordattributes () const
 Get the attributes of the expression. More...
 
DataType dataType () const
 Get the data type of the expression. More...
 
Bool isScalar () const
 Is the expression a scalar? More...
 
rownr_t nrow () const
 Get the number of rows in the table associated with this expression. More...
 
void get (const TableExprId &id, Bool &value) const
 Get a value for this node in the given row. More...
 
void get (const TableExprId &id, Int64 &value) const
 
void get (const TableExprId &id, Double &value) const
 
void get (const TableExprId &id, DComplex &value) const
 
void get (const TableExprId &id, String &value) const
 
void get (const TableExprId &id, TaqlRegex &value) const
 
void get (const TableExprId &id, MVTime &value) const
 
void get (const TableExprId &id, MArray< Bool > &value) const
 
void get (const TableExprId &id, MArray< Int64 > &value) const
 
void get (const TableExprId &id, MArray< Double > &value) const
 
void get (const TableExprId &id, MArray< DComplex > &value) const
 
void get (const TableExprId &id, MArray< String > &value) const
 
void get (const TableExprId &id, MArray< MVTime > &value) const
 
void get (const TableExprId &id, Array< Bool > &value) const
 
void get (const TableExprId &id, Array< Int64 > &value) const
 
void get (const TableExprId &id, Array< Double > &value) const
 
void get (const TableExprId &id, Array< DComplex > &value) const
 
void get (const TableExprId &id, Array< String > &value) const
 
void get (const TableExprId &id, Array< MVTime > &value) const
 
Bool getBool (const TableExprId &id) const
 
Int64 getInt (const TableExprId &id) const
 
Double getDouble (const TableExprId &id) const
 
DComplex getDComplex (const TableExprId &id) const
 
MVTime getDate (const TableExprId &id) const
 
String getString (const TableExprId &id) const
 
Array< BoolgetArrayBool (const TableExprId &id) const
 
Array< Int64getArrayInt (const TableExprId &id) const
 
Array< DoublegetArrayDouble (const TableExprId &id) const
 
Array< DComplex > getArrayDComplex (const TableExprId &id) const
 
Array< StringgetArrayString (const TableExprId &id) const
 
Array< MVTimegetArrayDate (const TableExprId &id) const
 
MArray< BoolgetBoolAS (const TableExprId &id) const
 Get a value as an array, even it it is a scalar. More...
 
MArray< Int64getIntAS (const TableExprId &id) const
 
MArray< DoublegetDoubleAS (const TableExprId &id) const
 
MArray< DComplex > getDComplexAS (const TableExprId &id) const
 
MArray< StringgetStringAS (const TableExprId &id) const
 
MArray< MVTimegetDateAS (const TableExprId &id) const
 
DataType getColumnDataType () const
 Get the data type for doing a getColumn on the expression. More...
 
Array< BoolgetColumnBool (const RowNumbers &rownrs) const
 Get the value of the expression evaluated for the entire column. More...
 
Array< uChargetColumnuChar (const RowNumbers &rownrs) const
 
Array< ShortgetColumnShort (const RowNumbers &rownrs) const
 
Array< uShortgetColumnuShort (const RowNumbers &rownrs) const
 
Array< IntgetColumnInt (const RowNumbers &rownrs) const
 
Array< uIntgetColumnuInt (const RowNumbers &rownrs) const
 
Array< Int64getColumnInt64 (const RowNumbers &rownrs) const
 
Array< FloatgetColumnFloat (const RowNumbers &rownrs) const
 
Array< DoublegetColumnDouble (const RowNumbers &rownrs) const
 
Array< Complex > getColumnComplex (const RowNumbers &rownrs) const
 
Array< DComplex > getColumnDComplex (const RowNumbers &rownrs) const
 
Array< StringgetColumnString (const RowNumbers &rownrs) const
 
void show (ostream &) const
 Show the tree. More...
 
void ranges (Block< TableExprRange > &)
 Convert the tree to a number of range vectors which at least select the same things. More...
 
Bool checkTableSize (const Table &table, Bool canBeConst) const
 Check if tables used in expression have the same number of rows as the given table. More...
 
const Tabletable () const
 Get table. More...
 
const TENShPtrgetRep () const
 returns const pointer to the underlying TableExprNodeRep object. More...
 
const TableExprNodeRepgetNodeRep () const
 
void adaptUnit (const Unit &)
 Adapt the unit of the expression to the given unit (if not empty). More...
 
TENShPtr newPlus (const TENShPtr &right) const
 Construct a new node for the given operation. More...
 
TENShPtr newMinus (const TENShPtr &right) const
 
TENShPtr newTimes (const TENShPtr &right) const
 
TENShPtr newDivide (const TENShPtr &right) const
 
TENShPtr newModulo (const TENShPtr &right) const
 
TENShPtr newBitAnd (const TENShPtr &right) const
 
TENShPtr newBitOr (const TENShPtr &right) const
 
TENShPtr newBitXor (const TENShPtr &right) const
 
TENShPtr newEQ (const TENShPtr &right) const
 
TENShPtr newNE (const TENShPtr &right) const
 
TENShPtr newGE (const TENShPtr &right) const
 
TENShPtr newGT (const TENShPtr &right) const
 
TENShPtr newIN (const TENShPtr &right, const TaQLStyle &) const
 
TENShPtr newOR (const TENShPtr &right) const
 
TENShPtr newAND (const TENShPtr &right) const
 

Static Public Member Functions

static TableExprNode newColumnNode (const Table &tab, const String &name, const Vector< String > &fieldNames)
 Create a column node on behalf of the Table class. More...
 
static TableExprNode newKeyConst (const TableRecord &, const Vector< String > &fieldNames)
 Create a TableExprNodeConst for a table keyword (which is handled as a constant). More...
 
static TableRecordfindLastKeyRec (const TableRecord &keyset, const Vector< String > &fieldNames, String &fullName)
 Handle all field names except the last one. More...
 
static void throwInvDT (const String &message)
 Throw invalid data type exception. More...
 
static TableExprNode newFunctionNode (TableExprFuncNode::FunctionType, const TableExprNodeSet &set, const Table &table, const TaQLStyle &=TaQLStyle(0))
 Create function node of the given type with the given arguments. More...
 
static TableExprNode newFunctionNode (TableExprFuncNode::FunctionType, const TableExprNode &node)
 
static TableExprNode newFunctionNode (TableExprFuncNode::FunctionType, const TableExprNode &node1, const TableExprNode &node2)
 
static TableExprNode newFunctionNode (TableExprFuncNode::FunctionType, const TableExprNode &node1, const TableExprNode &node2, const TableExprNode &node3)
 
static TableExprNode newFunctionNode (TableExprFuncNode::FunctionType, const TableExprNode &array, const TableExprNodeSet &axes)
 
static TableExprNode newFunctionNode (TableExprFuncNode::FunctionType, const TableExprNode &array, const TableExprNode &node, const TableExprNodeSet &axes)
 
static TableExprNode newUDFNode (const String &name, const TableExprNodeSet &set, const Table &table, const TaQLStyle &=TaQLStyle(0))
 Create a user defined function node. More...
 
static TableExprNode newConeNode (TableExprFuncNode::FunctionType, const TableExprNodeSet &set, uInt origin=0)
 Create cone function node of the given type with the given arguments. More...
 
static TableExprNode newConeNode (TableExprFuncNode::FunctionType, const TableExprNode &node1, const TableExprNode &node2)
 
static TableExprNode newConeNode (TableExprFuncNode::FunctionType, const TableExprNode &node1, const TableExprNode &node2, const TableExprNode &node3)
 
static TableExprNode newRownrNode (const Table &table, uInt origin)
 Create rownumber() function node. More...
 
static TableExprNode newRowidNode (const Table &table)
 Create rowid() function node. More...
 
static TableExprNode newRandomNode (const Table &table)
 Create rand() function node. More...
 
static TableExprNode newArrayPartNode (const TableExprNode &arrayNode, const TableExprNodeSet &indices, const TaQLStyle &=TaQLStyle(0))
 Create ArrayElement node for the given array with the given index. More...
 

Private Member Functions

Array< BoolgetColumnBool (const Vector< uInt > &rownrs) const
 The same functions as above for the old Vector<uInt>. More...
 
Array< uChargetColumnuChar (const Vector< uInt > &rownrs) const
 
Array< ShortgetColumnShort (const Vector< uInt > &rownrs) const
 
Array< uShortgetColumnuShort (const Vector< uInt > &rownrs) const
 
Array< IntgetColumnInt (const Vector< uInt > &rownrs) const
 
Array< uIntgetColumnuInt (const Vector< uInt > &rownrs) const
 
Array< Int64getColumnInt64 (const Vector< uInt > &rownrs) const
 
Array< FloatgetColumnFloat (const Vector< uInt > &rownrs) const
 
Array< DoublegetColumnDouble (const Vector< uInt > &rownrs) const
 
Array< Complex > getColumnComplex (const Vector< uInt > &rownrs) const
 
Array< DComplex > getColumnDComplex (const Vector< uInt > &rownrs) const
 
Array< StringgetColumnString (const Vector< uInt > &rownrs) const
 
TENShPtr setBinaryNodeInfo (TableExprNodeBinary *tsnptr, const TENShPtr &right=TENShPtr()) const
 Put the new binary node object in a shared pointer. More...
 

Static Private Member Functions

static std::vector< TENShPtrconvertBlockTEN (Block< TableExprNode > &nodes)
 convert Block of TableExprNode to vector of TENShPtr. More...
 

Private Attributes

TENShPtr node_p
 The actual (counted referenced) representation of a node. More...
 

Detailed Description

Handle class for a table column expression tree

Intended use:

Public interface

Review Status

Reviewed By:
UNKNOWN
Date Reviewed:
before2004/08/25

Prerequisite

Etymology

TableExprNode represents a node in the tree reflecting a table select expression.

Synopsis

TableExprNode is the class to store a table select expression, making it possible to select rows from the table. The selected rows form a table which is a view of the original table.

TableExprNode is a handle class for the counted referenced class TableExprNodeRep. Classes (like TableExprNodePlusXX) derived from TableExprNodeRep hold the individual nodes in the expression, i.e. the operators and operands. The nodes form a binary tree reflecting the expression. E.g. the expression 2*COLUMN results in the node TableExprNodeTimes with its children TableExprNodeConst and TableExprNodeColumn. Constant subexpressions (like 2*3) are evaluated immediately and only the result is stored as a node.

There are a few TableExprNode constructors taking a constant scalar or array. In this way constant value are automatically converted to the appropriate TableExprNodeConst object.

The derived classes also reflect the data type of the node. Data types Bool, Int64, Double, DComplex and String are used. Char, uChar, Short, uShort, Int and uInt are converted to Int64, float to Double, and Complex to DComplex. Binary operators +, -, *, /, %, &, }, ^, ==, >=, >, <, <= and != are recognized. Also &&, ||, parentheses and unary +, -, ~ and ! are recognized. For strings the binary operator + can also be used. The operators have the normal C++ precedence. Furthermore functions (such as sin, max, ceil) can be used in an expression.
Operator() can be used to take a slice from an array.

The Table function col has to be used to create a TableExprNode object for a column in the table. The Table operator() can be used the do the actual selection from the top TableExprNode object.

Example

// Select from table X all rows where column RA<5 and where column
// SWITCH is true.
Table table("X");
Table subtable = table(table.col("RA") < 5 && table.col("SWITCH"));
// Select from that result all rows where the concatenation of
// the strings in columns STR1 and STR2 is equal to the string
// in keyword STRKEY.
Table subsub = subtable(subtable.col("STR1") + subtable.col("STR2")
== subtable.key("STRKEY"));
const Table & table() const
Get table.
Definition: ExprNode.h:571
TableExprNode col(const String &columnName) const

Motivation

Having TableExprNode as a handle class makes it possible to handle temporary objects created by the compiler in a smooth way. TableExprNode and its derivations allow to store an expression before actually evaluating it. This also allows the classes to be used by the table expression parser defined in TableParse and TableGram.

For each operator a special derived class is implemented. Another approach could have been to store the operator as a flag and switch on that. However, that causes extra overhead and the C++ virtual function mechanism is the designed for these purposes.

To Do

Definition at line 156 of file ExprNode.h.

Constructor & Destructor Documentation

◆ TableExprNode() [1/48]

casacore::TableExprNode::TableExprNode ( )

◆ TableExprNode() [2/48]

casacore::TableExprNode::TableExprNode ( const Bool value)

Constructors to convert a constant value to a TableExprNode.

The constructor for char* is also supported to convert a character-array to a string, since a two step conversion is not done automatically.

◆ TableExprNode() [3/48]

casacore::TableExprNode::TableExprNode ( const Int value)

◆ TableExprNode() [4/48]

casacore::TableExprNode::TableExprNode ( const uInt value)

◆ TableExprNode() [5/48]

casacore::TableExprNode::TableExprNode ( const Int64 value)

◆ TableExprNode() [6/48]

casacore::TableExprNode::TableExprNode ( const uInt64 value)

◆ TableExprNode() [7/48]

casacore::TableExprNode::TableExprNode ( const Float value)

◆ TableExprNode() [8/48]

casacore::TableExprNode::TableExprNode ( const Double value)

◆ TableExprNode() [9/48]

casacore::TableExprNode::TableExprNode ( const Complex &  value)

◆ TableExprNode() [10/48]

casacore::TableExprNode::TableExprNode ( const DComplex &  value)

◆ TableExprNode() [11/48]

casacore::TableExprNode::TableExprNode ( const String value)

◆ TableExprNode() [12/48]

casacore::TableExprNode::TableExprNode ( const std::string &  value)

◆ TableExprNode() [13/48]

casacore::TableExprNode::TableExprNode ( const char *  )

◆ TableExprNode() [14/48]

casacore::TableExprNode::TableExprNode ( const Regex value)

◆ TableExprNode() [15/48]

casacore::TableExprNode::TableExprNode ( const StringDistance value)

◆ TableExprNode() [16/48]

casacore::TableExprNode::TableExprNode ( const TaqlRegex value)

◆ TableExprNode() [17/48]

casacore::TableExprNode::TableExprNode ( const MVTime value)

◆ TableExprNode() [18/48]

casacore::TableExprNode::TableExprNode ( const Array< Bool > &  value)

◆ TableExprNode() [19/48]

casacore::TableExprNode::TableExprNode ( const Array< uChar > &  value)

◆ TableExprNode() [20/48]

casacore::TableExprNode::TableExprNode ( const Array< Short > &  value)

◆ TableExprNode() [21/48]

casacore::TableExprNode::TableExprNode ( const Array< uShort > &  value)

◆ TableExprNode() [22/48]

casacore::TableExprNode::TableExprNode ( const Array< Int > &  value)

◆ TableExprNode() [23/48]

casacore::TableExprNode::TableExprNode ( const Array< uInt > &  value)

◆ TableExprNode() [24/48]

casacore::TableExprNode::TableExprNode ( const Array< Int64 > &  value)

◆ TableExprNode() [25/48]

casacore::TableExprNode::TableExprNode ( const Array< uInt64 > &  value)
explicit

◆ TableExprNode() [26/48]

casacore::TableExprNode::TableExprNode ( const Array< Float > &  value)

◆ TableExprNode() [27/48]

casacore::TableExprNode::TableExprNode ( const Array< Double > &  value)

◆ TableExprNode() [28/48]

casacore::TableExprNode::TableExprNode ( const Array< Complex > &  value)

◆ TableExprNode() [29/48]

casacore::TableExprNode::TableExprNode ( const Array< DComplex > &  value)

◆ TableExprNode() [30/48]

casacore::TableExprNode::TableExprNode ( const Array< String > &  value)

◆ TableExprNode() [31/48]

casacore::TableExprNode::TableExprNode ( const Array< MVTime > &  value)

◆ TableExprNode() [32/48]

casacore::TableExprNode::TableExprNode ( const MArray< Bool > &  value)

◆ TableExprNode() [33/48]

casacore::TableExprNode::TableExprNode ( const MArray< uChar > &  value)

◆ TableExprNode() [34/48]

casacore::TableExprNode::TableExprNode ( const MArray< Short > &  value)

◆ TableExprNode() [35/48]

casacore::TableExprNode::TableExprNode ( const MArray< uShort > &  value)

◆ TableExprNode() [36/48]

casacore::TableExprNode::TableExprNode ( const MArray< Int > &  value)

◆ TableExprNode() [37/48]

casacore::TableExprNode::TableExprNode ( const MArray< uInt > &  value)

◆ TableExprNode() [38/48]

casacore::TableExprNode::TableExprNode ( const MArray< Int64 > &  value)

◆ TableExprNode() [39/48]

casacore::TableExprNode::TableExprNode ( const MArray< uInt64 > &  value)

◆ TableExprNode() [40/48]

casacore::TableExprNode::TableExprNode ( const MArray< Float > &  value)

◆ TableExprNode() [41/48]

casacore::TableExprNode::TableExprNode ( const MArray< Double > &  value)

◆ TableExprNode() [42/48]

casacore::TableExprNode::TableExprNode ( const MArray< Complex > &  value)

◆ TableExprNode() [43/48]

casacore::TableExprNode::TableExprNode ( const MArray< DComplex > &  value)

◆ TableExprNode() [44/48]

casacore::TableExprNode::TableExprNode ( const MArray< String > &  value)

◆ TableExprNode() [45/48]

casacore::TableExprNode::TableExprNode ( const MArray< MVTime > &  value)

◆ TableExprNode() [46/48]

casacore::TableExprNode::TableExprNode ( const TENShPtr )

Construct a node from a node representation shared pointer which increments the reference count.

◆ TableExprNode() [47/48]

casacore::TableExprNode::TableExprNode ( TableExprNodeRep rep)
inline

Construct from a node representation.

It takes over the pointer, so the object gets deleted automatically.

Definition at line 259 of file ExprNode.h.

◆ TableExprNode() [48/48]

casacore::TableExprNode::TableExprNode ( const TableExprNode )

copy constructor (reference semantics).

◆ ~TableExprNode()

casacore::TableExprNode::~TableExprNode ( )

The destructor deletes all the underlying TableExprNode objects,.

Member Function Documentation

◆ adaptUnit()

void casacore::TableExprNode::adaptUnit ( const Unit )

Adapt the unit of the expression to the given unit (if not empty).

Referenced by casacore::TableParseUpdate::adaptUnit().

◆ applySelection()

void casacore::TableExprNode::applySelection ( const Vector< rownr_t > &  rownrs)
inline

Re-create the column object for a selection of rows.

Nothing is done if the node does not represent a column object.

Definition at line 281 of file ExprNode.h.

References casacore::TableExprNodeRep::applySelection(), and node_p.

◆ attributes()

const Record& casacore::TableExprNode::attributes ( ) const
inline

Get the attributes of the expression.

Definition at line 289 of file ExprNode.h.

References casacore::TableExprNodeRep::attributes(), and node_p.

◆ checkTableSize()

Bool casacore::TableExprNode::checkTableSize ( const Table table,
Bool  canBeConst 
) const

Check if tables used in expression have the same number of rows as the given table.

◆ convertBlockTEN()

static std::vector<TENShPtr> casacore::TableExprNode::convertBlockTEN ( Block< TableExprNode > &  nodes)
staticprivate

convert Block of TableExprNode to vector of TENShPtr.

◆ dataType()

DataType casacore::TableExprNode::dataType ( ) const

Get the data type of the expression.

Currently the only possible values are TpBool, TpInt, TpDouble, TpDComplex, TpString, and TpOther. The latter is returned for a date or regex.

◆ disableApplySelection()

void casacore::TableExprNode::disableApplySelection ( )
inline

Do not apply the selection.

Definition at line 276 of file ExprNode.h.

References casacore::TableExprNodeRep::disableApplySelection(), and node_p.

◆ findLastKeyRec()

static TableRecord* casacore::TableExprNode::findLastKeyRec ( const TableRecord keyset,
const Vector< String > &  fieldNames,
String fullName 
)
static

Handle all field names except the last one.

ALl of them must be records. The last record is returned. fullName is filled with the full keyword name separated by dots.

◆ get() [1/19]

void casacore::TableExprNode::get ( const TableExprId id,
Array< Bool > &  value 
) const
inline

◆ get() [2/19]

void casacore::TableExprNode::get ( const TableExprId id,
Array< DComplex > &  value 
) const
inline

◆ get() [3/19]

void casacore::TableExprNode::get ( const TableExprId id,
Array< Double > &  value 
) const
inline

◆ get() [4/19]

void casacore::TableExprNode::get ( const TableExprId id,
Array< Int64 > &  value 
) const
inline

◆ get() [5/19]

void casacore::TableExprNode::get ( const TableExprId id,
Array< MVTime > &  value 
) const
inline

Definition at line 622 of file ExprNode.h.

References casacore::TableExprNodeRep::getArrayDate(), node_p, and casacore::value().

◆ get() [6/19]

void casacore::TableExprNode::get ( const TableExprId id,
Array< String > &  value 
) const
inline

◆ get() [7/19]

void casacore::TableExprNode::get ( const TableExprId id,
Bool value 
) const
inline

Get a value for this node in the given row.

These functions are implemented in the derived classes and will usually invoke the get in their children and apply the operator on the resulting values.

Definition at line 575 of file ExprNode.h.

References casacore::TableExprNodeRep::getBool(), node_p, and casacore::value().

◆ get() [8/19]

void casacore::TableExprNode::get ( const TableExprId id,
DComplex &  value 
) const
inline

Definition at line 581 of file ExprNode.h.

References casacore::TableExprNodeRep::getDComplex(), node_p, and casacore::value().

◆ get() [9/19]

void casacore::TableExprNode::get ( const TableExprId id,
Double value 
) const
inline

Definition at line 579 of file ExprNode.h.

References casacore::TableExprNodeRep::getDouble(), node_p, and casacore::value().

◆ get() [10/19]

void casacore::TableExprNode::get ( const TableExprId id,
Int64 value 
) const
inline

Definition at line 577 of file ExprNode.h.

References casacore::TableExprNodeRep::getInt(), node_p, and casacore::value().

◆ get() [11/19]

void casacore::TableExprNode::get ( const TableExprId id,
MArray< Bool > &  value 
) const
inline

Definition at line 589 of file ExprNode.h.

References casacore::TableExprNodeRep::getArrayBool(), node_p, and casacore::value().

◆ get() [12/19]

void casacore::TableExprNode::get ( const TableExprId id,
MArray< DComplex > &  value 
) const
inline

◆ get() [13/19]

void casacore::TableExprNode::get ( const TableExprId id,
MArray< Double > &  value 
) const
inline

◆ get() [14/19]

void casacore::TableExprNode::get ( const TableExprId id,
MArray< Int64 > &  value 
) const
inline

Definition at line 592 of file ExprNode.h.

References casacore::TableExprNodeRep::getArrayInt(), node_p, and casacore::value().

◆ get() [15/19]

void casacore::TableExprNode::get ( const TableExprId id,
MArray< MVTime > &  value 
) const
inline

Definition at line 604 of file ExprNode.h.

References casacore::TableExprNodeRep::getArrayDate(), node_p, and casacore::value().

◆ get() [16/19]

void casacore::TableExprNode::get ( const TableExprId id,
MArray< String > &  value 
) const
inline

◆ get() [17/19]

void casacore::TableExprNode::get ( const TableExprId id,
MVTime value 
) const
inline

Definition at line 587 of file ExprNode.h.

References casacore::TableExprNodeRep::getDate(), node_p, and casacore::value().

◆ get() [18/19]

void casacore::TableExprNode::get ( const TableExprId id,
String value 
) const
inline

Definition at line 583 of file ExprNode.h.

References casacore::TableExprNodeRep::getString(), node_p, and casacore::value().

◆ get() [19/19]

void casacore::TableExprNode::get ( const TableExprId id,
TaqlRegex value 
) const
inline

Definition at line 585 of file ExprNode.h.

References casacore::TableExprNodeRep::getRegex(), node_p, and casacore::value().

◆ getArrayBool()

Array< Bool > casacore::TableExprNode::getArrayBool ( const TableExprId id) const
inline

◆ getArrayDate()

Array< MVTime > casacore::TableExprNode::getArrayDate ( const TableExprId id) const
inline

Definition at line 647 of file ExprNode.h.

References casacore::TableExprNodeRep::getArrayDate(), and node_p.

◆ getArrayDComplex()

Array< DComplex > casacore::TableExprNode::getArrayDComplex ( const TableExprId id) const
inline

◆ getArrayDouble()

Array< Double > casacore::TableExprNode::getArrayDouble ( const TableExprId id) const
inline

◆ getArrayInt()

Array< Int64 > casacore::TableExprNode::getArrayInt ( const TableExprId id) const
inline

◆ getArrayString()

Array< String > casacore::TableExprNode::getArrayString ( const TableExprId id) const
inline

Definition at line 645 of file ExprNode.h.

References casacore::TableExprNodeRep::getArrayString(), and node_p.

◆ getBool()

Bool casacore::TableExprNode::getBool ( const TableExprId id) const
inline

Definition at line 625 of file ExprNode.h.

References casacore::TableExprNodeRep::getBool(), and node_p.

◆ getBoolAS()

MArray< Bool > casacore::TableExprNode::getBoolAS ( const TableExprId id) const
inline

Get a value as an array, even it it is a scalar.

This is useful in case one can give an argument as scalar or array.

Definition at line 649 of file ExprNode.h.

References casacore::TableExprNodeRep::getBoolAS(), and node_p.

◆ getColumnBool() [1/2]

Array< Bool > casacore::TableExprNode::getColumnBool ( const RowNumbers rownrs) const
inline

Get the value of the expression evaluated for the entire column.

The data of function called should match the data type as returned by function getColumnDataType.

Definition at line 662 of file ExprNode.h.

References casacore::TableExprNodeRep::getColumnBool(), and node_p.

Referenced by getColumnBool().

◆ getColumnBool() [2/2]

Array<Bool> casacore::TableExprNode::getColumnBool ( const Vector< uInt > &  rownrs) const
inlineprivate

The same functions as above for the old Vector<uInt>.

They are primarily meant for CASA's SplatalogueTable class. Normally they should not be used, hence declared private unless told otherwise.

Definition at line 390 of file ExprNode.h.

References getColumnBool().

◆ getColumnComplex() [1/2]

Array< Complex > casacore::TableExprNode::getColumnComplex ( const RowNumbers rownrs) const
inline

Definition at line 680 of file ExprNode.h.

References casacore::TableExprNodeRep::getColumnComplex(), and node_p.

Referenced by getColumnComplex().

◆ getColumnComplex() [2/2]

Array<Complex> casacore::TableExprNode::getColumnComplex ( const Vector< uInt > &  rownrs) const
inlineprivate

Definition at line 408 of file ExprNode.h.

References getColumnComplex().

◆ getColumnDataType()

DataType casacore::TableExprNode::getColumnDataType ( ) const

Get the data type for doing a getColumn on the expression.

This is the data type of the column if the expression consists of a single column only. Otherwise it is the expression data type as returned by function dataType.

◆ getColumnDComplex() [1/2]

Array< DComplex > casacore::TableExprNode::getColumnDComplex ( const RowNumbers rownrs) const
inline

Definition at line 682 of file ExprNode.h.

References casacore::TableExprNodeRep::getColumnDComplex(), and node_p.

Referenced by getColumnDComplex().

◆ getColumnDComplex() [2/2]

Array<DComplex> casacore::TableExprNode::getColumnDComplex ( const Vector< uInt > &  rownrs) const
inlineprivate

Definition at line 410 of file ExprNode.h.

References getColumnDComplex().

◆ getColumnDouble() [1/2]

Array< Double > casacore::TableExprNode::getColumnDouble ( const RowNumbers rownrs) const
inline

Definition at line 678 of file ExprNode.h.

References casacore::TableExprNodeRep::getColumnDouble(), and node_p.

Referenced by getColumnDouble().

◆ getColumnDouble() [2/2]

Array<Double> casacore::TableExprNode::getColumnDouble ( const Vector< uInt > &  rownrs) const
inlineprivate

Definition at line 406 of file ExprNode.h.

References getColumnDouble().

◆ getColumnFloat() [1/2]

Array< Float > casacore::TableExprNode::getColumnFloat ( const RowNumbers rownrs) const
inline

Definition at line 676 of file ExprNode.h.

References casacore::TableExprNodeRep::getColumnFloat(), and node_p.

Referenced by getColumnFloat().

◆ getColumnFloat() [2/2]

Array<Float> casacore::TableExprNode::getColumnFloat ( const Vector< uInt > &  rownrs) const
inlineprivate

Definition at line 404 of file ExprNode.h.

References getColumnFloat().

◆ getColumnInt() [1/2]

Array< Int > casacore::TableExprNode::getColumnInt ( const RowNumbers rownrs) const
inline

Definition at line 670 of file ExprNode.h.

References casacore::TableExprNodeRep::getColumnInt(), and node_p.

Referenced by getColumnInt().

◆ getColumnInt() [2/2]

Array<Int> casacore::TableExprNode::getColumnInt ( const Vector< uInt > &  rownrs) const
inlineprivate

Definition at line 398 of file ExprNode.h.

References getColumnInt().

◆ getColumnInt64() [1/2]

Array< Int64 > casacore::TableExprNode::getColumnInt64 ( const RowNumbers rownrs) const
inline

Definition at line 674 of file ExprNode.h.

References casacore::TableExprNodeRep::getColumnInt64(), and node_p.

Referenced by getColumnInt64().

◆ getColumnInt64() [2/2]

Array<Int64> casacore::TableExprNode::getColumnInt64 ( const Vector< uInt > &  rownrs) const
inlineprivate

Definition at line 402 of file ExprNode.h.

References getColumnInt64().

◆ getColumnShort() [1/2]

Array< Short > casacore::TableExprNode::getColumnShort ( const RowNumbers rownrs) const
inline

Definition at line 666 of file ExprNode.h.

References casacore::TableExprNodeRep::getColumnShort(), and node_p.

Referenced by getColumnShort().

◆ getColumnShort() [2/2]

Array<Short> casacore::TableExprNode::getColumnShort ( const Vector< uInt > &  rownrs) const
inlineprivate

Definition at line 394 of file ExprNode.h.

References getColumnShort().

◆ getColumnString() [1/2]

Array< String > casacore::TableExprNode::getColumnString ( const RowNumbers rownrs) const
inline

Definition at line 684 of file ExprNode.h.

References casacore::TableExprNodeRep::getColumnString(), and node_p.

Referenced by getColumnString().

◆ getColumnString() [2/2]

Array<String> casacore::TableExprNode::getColumnString ( const Vector< uInt > &  rownrs) const
inlineprivate

Definition at line 412 of file ExprNode.h.

References getColumnString().

◆ getColumnuChar() [1/2]

Array< uChar > casacore::TableExprNode::getColumnuChar ( const RowNumbers rownrs) const
inline

Definition at line 664 of file ExprNode.h.

References casacore::TableExprNodeRep::getColumnuChar(), and node_p.

Referenced by getColumnuChar().

◆ getColumnuChar() [2/2]

Array<uChar> casacore::TableExprNode::getColumnuChar ( const Vector< uInt > &  rownrs) const
inlineprivate

Definition at line 392 of file ExprNode.h.

References getColumnuChar().

◆ getColumnuInt() [1/2]

Array< uInt > casacore::TableExprNode::getColumnuInt ( const RowNumbers rownrs) const
inline

Definition at line 672 of file ExprNode.h.

References casacore::TableExprNodeRep::getColumnuInt(), and node_p.

Referenced by getColumnuInt().

◆ getColumnuInt() [2/2]

Array<uInt> casacore::TableExprNode::getColumnuInt ( const Vector< uInt > &  rownrs) const
inlineprivate

Definition at line 400 of file ExprNode.h.

References getColumnuInt().

◆ getColumnuShort() [1/2]

Array< uShort > casacore::TableExprNode::getColumnuShort ( const RowNumbers rownrs) const
inline

Definition at line 668 of file ExprNode.h.

References casacore::TableExprNodeRep::getColumnuShort(), and node_p.

Referenced by getColumnuShort().

◆ getColumnuShort() [2/2]

Array<uShort> casacore::TableExprNode::getColumnuShort ( const Vector< uInt > &  rownrs) const
inlineprivate

Definition at line 396 of file ExprNode.h.

References getColumnuShort().

◆ getDate()

MVTime casacore::TableExprNode::getDate ( const TableExprId id) const
inline

Definition at line 633 of file ExprNode.h.

References casacore::TableExprNodeRep::getDate(), and node_p.

◆ getDateAS()

MArray< MVTime > casacore::TableExprNode::getDateAS ( const TableExprId id) const
inline

Definition at line 659 of file ExprNode.h.

References casacore::TableExprNodeRep::getDateAS(), and node_p.

◆ getDComplex()

DComplex casacore::TableExprNode::getDComplex ( const TableExprId id) const
inline

Definition at line 631 of file ExprNode.h.

References casacore::TableExprNodeRep::getDComplex(), and node_p.

◆ getDComplexAS()

MArray< DComplex > casacore::TableExprNode::getDComplexAS ( const TableExprId id) const
inline

Definition at line 655 of file ExprNode.h.

References casacore::TableExprNodeRep::getDComplexAS(), and node_p.

◆ getDouble()

Double casacore::TableExprNode::getDouble ( const TableExprId id) const
inline

Definition at line 629 of file ExprNode.h.

References casacore::TableExprNodeRep::getDouble(), and node_p.

◆ getDoubleAS()

MArray< Double > casacore::TableExprNode::getDoubleAS ( const TableExprId id) const
inline

Definition at line 653 of file ExprNode.h.

References casacore::TableExprNodeRep::getDoubleAS(), and node_p.

◆ getInt()

Int64 casacore::TableExprNode::getInt ( const TableExprId id) const
inline

Definition at line 627 of file ExprNode.h.

References casacore::TableExprNodeRep::getInt(), and node_p.

◆ getIntAS()

MArray< Int64 > casacore::TableExprNode::getIntAS ( const TableExprId id) const
inline

Definition at line 651 of file ExprNode.h.

References casacore::TableExprNodeRep::getIntAS(), and node_p.

◆ getNodeRep()

const TableExprNodeRep * casacore::TableExprNode::getNodeRep ( ) const
inline

Definition at line 691 of file ExprNode.h.

References casacore::CountedPtr< t >::get(), and node_p.

◆ getRep()

const TENShPtr & casacore::TableExprNode::getRep ( ) const
inline

◆ getString()

String casacore::TableExprNode::getString ( const TableExprId id) const
inline

Definition at line 635 of file ExprNode.h.

References casacore::TableExprNodeRep::getString(), and node_p.

◆ getStringAS()

MArray< String > casacore::TableExprNode::getStringAS ( const TableExprId id) const
inline

Definition at line 657 of file ExprNode.h.

References casacore::TableExprNodeRep::getStringAS(), and node_p.

◆ in() [1/2]

TableExprNode casacore::TableExprNode::in ( const TableExprNode array,
const TaQLStyle style = TaQLStyle(0) 
) const
inline

The IN operator to test if a value is contained in an array or set.

The array can also be a scalar.

Definition at line 1226 of file ExprNode.h.

References getRep(), and newIN().

◆ in() [2/2]

TableExprNode casacore::TableExprNode::in ( const TableExprNodeSet set,
const TaQLStyle = TaQLStyle(0) 
) const

◆ isNull()

Bool casacore::TableExprNode::isNull ( ) const
inline

◆ isScalar()

Bool casacore::TableExprNode::isScalar ( ) const
inline

Is the expression a scalar?

Definition at line 299 of file ExprNode.h.

References node_p, casacore::TableExprNodeRep::valueType(), and casacore::TableExprNodeRep::VTScalar.

◆ newAND()

TENShPtr casacore::TableExprNode::newAND ( const TENShPtr right) const

◆ newArrayPartNode()

static TableExprNode casacore::TableExprNode::newArrayPartNode ( const TableExprNode arrayNode,
const TableExprNodeSet indices,
const TaQLStyle = TaQLStyle(0) 
)
static

Create ArrayElement node for the given array with the given index.

The origin is 0 for C++ and 1 for TaQL.

Referenced by operator()().

◆ newBitAnd()

TENShPtr casacore::TableExprNode::newBitAnd ( const TENShPtr right) const

Referenced by casacore::operator&().

◆ newBitOr()

TENShPtr casacore::TableExprNode::newBitOr ( const TENShPtr right) const

Referenced by casacore::operator|().

◆ newBitXor()

TENShPtr casacore::TableExprNode::newBitXor ( const TENShPtr right) const

Referenced by casacore::operator^().

◆ newColumnNode()

static TableExprNode casacore::TableExprNode::newColumnNode ( const Table tab,
const String name,
const Vector< String > &  fieldNames 
)
static

Create a column node on behalf of the Table class.

For builtin data types another type of node is created than for other data types.

◆ newConeNode() [1/3]

static TableExprNode casacore::TableExprNode::newConeNode ( TableExprFuncNode::FunctionType  ,
const TableExprNode node1,
const TableExprNode node2 
)
static

◆ newConeNode() [2/3]

static TableExprNode casacore::TableExprNode::newConeNode ( TableExprFuncNode::FunctionType  ,
const TableExprNode node1,
const TableExprNode node2,
const TableExprNode node3 
)
static

◆ newConeNode() [3/3]

static TableExprNode casacore::TableExprNode::newConeNode ( TableExprFuncNode::FunctionType  ,
const TableExprNodeSet set,
uInt  origin = 0 
)
static

Create cone function node of the given type with the given arguments.

Referenced by casacore::anyCone(), casacore::cones(), and casacore::findCone().

◆ newDivide()

TENShPtr casacore::TableExprNode::newDivide ( const TENShPtr right) const

Referenced by casacore::operator/().

◆ newEQ()

TENShPtr casacore::TableExprNode::newEQ ( const TENShPtr right) const

Referenced by casacore::operator==().

◆ newFunctionNode() [1/6]

static TableExprNode casacore::TableExprNode::newFunctionNode ( TableExprFuncNode::FunctionType  ,
const TableExprNode array,
const TableExprNode node,
const TableExprNodeSet axes 
)
static

◆ newFunctionNode() [2/6]

static TableExprNode casacore::TableExprNode::newFunctionNode ( TableExprFuncNode::FunctionType  ,
const TableExprNode array,
const TableExprNodeSet axes 
)
static

◆ newFunctionNode() [3/6]

static TableExprNode casacore::TableExprNode::newFunctionNode ( TableExprFuncNode::FunctionType  ,
const TableExprNode node 
)
static

◆ newFunctionNode() [4/6]

static TableExprNode casacore::TableExprNode::newFunctionNode ( TableExprFuncNode::FunctionType  ,
const TableExprNode node1,
const TableExprNode node2 
)
static

◆ newFunctionNode() [5/6]

static TableExprNode casacore::TableExprNode::newFunctionNode ( TableExprFuncNode::FunctionType  ,
const TableExprNode node1,
const TableExprNode node2,
const TableExprNode node3 
)
static

◆ newFunctionNode() [6/6]

static TableExprNode casacore::TableExprNode::newFunctionNode ( TableExprFuncNode::FunctionType  ,
const TableExprNodeSet set,
const Table table,
const TaQLStyle = TaQLStyle(0) 
)
static

Create function node of the given type with the given arguments.

Referenced by casacore::abs(), casacore::acos(), casacore::all(), casacore::alls(), casacore::amplitude(), casacore::angdist(), casacore::angdistx(), casacore::any(), casacore::anys(), casacore::arg(), casacore::array(), casacore::arrayData(), casacore::arrayFlatten(), casacore::arrayMask(), casacore::asin(), casacore::atan(), casacore::atan2(), casacore::avdev(), casacore::avdevs(), casacore::boolean(), casacore::boxedAll(), casacore::boxedAny(), casacore::boxedAvdev(), casacore::boxedMax(), casacore::boxedMean(), casacore::boxedMedian(), casacore::boxedMin(), casacore::boxedRms(), casacore::boxedStddev(), casacore::boxedVariance(), casacore::capitalize(), casacore::cdate(), casacore::cdow(), casacore::ceil(), casacore::cmonth(), casacore::conj(), casacore::cos(), casacore::cosh(), casacore::ctime(), casacore::ctodt(), casacore::cube(), casacore::date(), casacore::datetime(), casacore::day(), casacore::diagonal(), casacore::dms(), casacore::downcase(), casacore::exp(), casacore::floor(), casacore::fmod(), casacore::formComplex(), casacore::fractile(), casacore::fractiles(), casacore::hdms(), casacore::hms(), casacore::iif(), casacore::imag(), casacore::integer(), casacore::isdefined(), casacore::isFinite(), casacore::isInf(), casacore::isNaN(), casacore::log(), casacore::log10(), casacore::ltrim(), casacore::marray(), casacore::max(), casacore::maxs(), casacore::mean(), casacore::means(), casacore::median(), casacore::medians(), casacore::min(), casacore::mins(), casacore::mjd(), casacore::mjdtodate(), casacore::month(), casacore::ndim(), casacore::near(), casacore::nearAbs(), casacore::nelements(), casacore::nfalse(), casacore::nfalses(), casacore::norm(), casacore::ntrue(), casacore::ntrues(), casacore::pattern(), casacore::phase(), casacore::pow(), casacore::product(), casacore::products(), casacore::real(), casacore::regex(), casacore::replace(), casacore::rms(), casacore::rmss(), casacore::round(), casacore::rtrim(), casacore::runningAll(), casacore::runningAny(), casacore::runningAvdev(), casacore::runningMax(), casacore::runningMean(), casacore::runningMedian(), casacore::runningMin(), casacore::runningRms(), casacore::runningStddev(), casacore::runningVariance(), casacore::shape(), casacore::sign(), casacore::sin(), casacore::sinh(), casacore::sqlpattern(), casacore::sqrt(), casacore::square(), casacore::stddev(), casacore::stddevs(), casacore::strlength(), casacore::substr(), casacore::sum(), casacore::sums(), casacore::sumSquare(), casacore::sumSquares(), casacore::tan(), casacore::tanh(), casacore::time(), casacore::toString(), casacore::transpose(), casacore::trim(), casacore::upcase(), casacore::variance(), casacore::variances(), casacore::week(), casacore::weekday(), and casacore::year().

◆ newGE()

TENShPtr casacore::TableExprNode::newGE ( const TENShPtr right) const

◆ newGT()

TENShPtr casacore::TableExprNode::newGT ( const TENShPtr right) const

◆ newIN()

TENShPtr casacore::TableExprNode::newIN ( const TENShPtr right,
const TaQLStyle  
) const

Referenced by in().

◆ newKeyConst()

static TableExprNode casacore::TableExprNode::newKeyConst ( const TableRecord ,
const Vector< String > &  fieldNames 
)
static

Create a TableExprNodeConst for a table keyword (which is handled as a constant).

◆ newMinus()

TENShPtr casacore::TableExprNode::newMinus ( const TENShPtr right) const

Referenced by casacore::operator-().

◆ newModulo()

TENShPtr casacore::TableExprNode::newModulo ( const TENShPtr right) const

Referenced by casacore::operator%().

◆ newNE()

TENShPtr casacore::TableExprNode::newNE ( const TENShPtr right) const

Referenced by casacore::operator!=().

◆ newOR()

TENShPtr casacore::TableExprNode::newOR ( const TENShPtr right) const

◆ newPlus()

TENShPtr casacore::TableExprNode::newPlus ( const TENShPtr right) const

Construct a new node for the given operation.

Referenced by casacore::operator+().

◆ newRandomNode()

static TableExprNode casacore::TableExprNode::newRandomNode ( const Table table)
static

Create rand() function node.

◆ newRowidNode()

static TableExprNode casacore::TableExprNode::newRowidNode ( const Table table)
static

Create rowid() function node.

Origin is always 0.

◆ newRownrNode()

static TableExprNode casacore::TableExprNode::newRownrNode ( const Table table,
uInt  origin 
)
static

Create rownumber() function node.

Origin indicates whether the first row should be zero (for C++ binding) or an other value (one for TaQL binding).

◆ newTimes()

TENShPtr casacore::TableExprNode::newTimes ( const TENShPtr right) const

Referenced by casacore::operator*().

◆ newUDFNode()

static TableExprNode casacore::TableExprNode::newUDFNode ( const String name,
const TableExprNodeSet set,
const Table table,
const TaQLStyle = TaQLStyle(0) 
)
static

Create a user defined function node.

◆ nrow()

rownr_t casacore::TableExprNode::nrow ( ) const
inline

Get the number of rows in the table associated with this expression.

One is returned if the expression is a constant. Zero is returned if no table is associated with it.

Definition at line 305 of file ExprNode.h.

References node_p, and casacore::TableExprNodeRep::nrow().

◆ operator!()

TableExprNode casacore::TableExprNode::operator! ( ) const

Unary NOT-operator on boolean TableExprNode's.

◆ operator()()

TableExprNode casacore::TableExprNode::operator() ( const TableExprNodeSet indices)
inline

Slicing in a node containing an array.

It is possible to address a single pixel or an n-dimensional subarray. In case of a single pixel the result is a scalar node. Otherwise the result is an array node with the same dimensionality as the source.
Note that there exist TableExprNodeSet constructors to convert an IPosition or Slicer object automatically to a TableExprNodeSet. An IPosition addresses a single element and results in a scalar node, while a Slicer can address multiple elements and always results in an array node.

C++ indexing is 0-based.

Definition at line 1231 of file ExprNode.h.

References newArrayPartNode().

◆ operator+()

TableExprNode casacore::TableExprNode::operator+ ( ) const

Unary operators on numeric TableExprNode's.

◆ operator-()

TableExprNode casacore::TableExprNode::operator- ( ) const

◆ operator=()

TableExprNode& casacore::TableExprNode::operator= ( const TableExprNode )

Assignment (reference semantics).

◆ operator~()

TableExprNode casacore::TableExprNode::operator~ ( ) const

Unary bitwise negate-operator on integer TableExprNode's.

◆ ranges()

void casacore::TableExprNode::ranges ( Block< TableExprRange > &  blrange)
inline

Convert the tree to a number of range vectors which at least select the same things.

This function is very useful to convert the expression to some intervals covering the select expression. This can be used to do a rough fast selection via an index and do the the slower final selection on that much smaller subset. The function can only convert direct comparisons of columns with constants (via ==, !=, >, >=, < or <=) and their combinations using && or ||.

Definition at line 567 of file ExprNode.h.

References node_p, and casacore::TableExprNodeRep::ranges().

◆ setBinaryNodeInfo()

TENShPtr casacore::TableExprNode::setBinaryNodeInfo ( TableExprNodeBinary tsnptr,
const TENShPtr right = TENShPtr() 
) const
private

Put the new binary node object in a shared pointer.

Set the node's info and adapt the children if needed. If the node is constant, it is evaluated and returned as result.

◆ show()

void casacore::TableExprNode::show ( ostream &  os) const
inline

Show the tree.

Definition at line 687 of file ExprNode.h.

References node_p, and casacore::TableExprNodeRep::show().

◆ table()

const Table & casacore::TableExprNode::table ( ) const
inline

Get table.

This gets the Table object to which a TableExprNode belongs. A TableExprNode belongs to the Table to which the column(s) used in an expression belong. Note that all columns in an expression have to belong to the same table.

Definition at line 571 of file ExprNode.h.

References node_p, and casacore::TableExprNodeRep::table().

◆ throwInvDT()

static void casacore::TableExprNode::throwInvDT ( const String message)
static

Throw invalid data type exception.

◆ unit()

const Unit& casacore::TableExprNode::unit ( ) const
inline

Get the unit of the expression.

Definition at line 285 of file ExprNode.h.

References node_p, and casacore::TableExprNodeRep::unit().

◆ useUnit()

TableExprNode casacore::TableExprNode::useUnit ( const Unit unit) const

Use a unit for the given TableExprNode.

Note that if a column has a unit, it is automatically set. In that case this can be used to convert units.

Member Data Documentation

◆ node_p

TENShPtr casacore::TableExprNode::node_p
private

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