rasdaman complete source
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
QtBinaryInduce Class Reference

#include <qtbinaryinduce.hh>

Inheritance diagram for QtBinaryInduce:
QtBinaryOperation QtOperation QtNode QtAnd QtBit QtDiv QtEqual QtIs QtLess QtLessEqual QtMinus QtMult QtNotEqual QtOr QtOverlay QtPlus QtXor

Public Member Functions

 QtBinaryInduce (QtOperation *input1, QtOperation *input2, Ops::OpType initOpType)
 constructor getting the two operands More...
 
QtDataevaluate (QtDataList *inputList)
 method for evaluating the node More...
 
virtual const QtTypeElementcheckType (QtTypeTuple *typeTuple=NULL)
 type checking of the subtree More...
 
- Public Member Functions inherited from QtBinaryOperation
 QtBinaryOperation ()
 default constructor More...
 
 QtBinaryOperation (QtNode *node)
 constructor getting the node to the parent More...
 
 QtBinaryOperation (QtOperation *input1, QtOperation *input2)
 constructor getting pointers to its operands More...
 
virtual ~QtBinaryOperation ()
 virtual destructor More...
 
virtual void simplify ()
 simplifies the tree More...
 
virtual bool equalMeaning (QtNode *node)
 test if the two nodes have an equal meaning in the query tree More...
 
virtual QtNodeListgetChilds (QtChildType flag)
 return childs of the node More...
 
virtual std::string getSpelling ()
 creates a unique name for a subexpression More...
 
virtual QtAreaType getAreaType ()
 test if the edge to the parent node is of type mdd or atomic More...
 
virtual void setInput (QtOperation *inputOld, QtOperation *inputNew)
 method for query rewrite More...
 
virtual void optimizeLoad (QtTrimList *trimList)
 optimizing load access More...
 
virtual void printTree (int tab, std::ostream &s=std::cout, QtChildType mode=QT_ALL_NODES)
 debugging method More...
 
virtual bool isCommutative () const
 returns commutativity information (by default, an operation IS commutative) More...
 
void setInput1 (QtOperation *input)
 
void setInput2 (QtOperation *input)
 
QtOperationgetInput1 ()
 
QtOperationgetInput2 ()
 
- Public Member Functions inherited from QtOperation
 QtOperation ()
 default constructor More...
 
 QtOperation (QtNode *parent)
 constructor getting a pointer to the parent More...
 
virtual QtOperationgetUniqueOrder (const QtNode::QtNodeType ID)
 for associative law More...
 
void printTree (int tab, std::ostream &s, QtChildType mode=QT_ALL_NODES)
 prints the tree More...
 
void printAlgebraicExpression (std::ostream &s)
 prints the algebraic expression More...
 
void setDataStreamType (const QtTypeElement &type)
 
const QtTypeElementgetDataStreamType () const
 
- Public Member Functions inherited from QtNode
 QtNode ()
 default constructor More...
 
 QtNode (QtNode *node)
 constructor getting a pointer to the parent More...
 
virtual ~QtNode ()
 destructor More...
 
bool subtype (enum QtNodeType a, enum QtNodeType b)
 returns weather class b is a subtype of class a More...
 
QtNodeListgetChild (const QtNodeType node, QtChildType flag=QT_DIRECT_CHILDS)
 return childs of a certain class More...
 
virtual const QtNodeType getNodeType () const
 methods for identification of nodes More...
 
enum QtNodeType getQtNodeTypeParent (enum QtNodeType)
 method for pre optimizations (basically load optimization) More...
 
QtNodegetParent () const
 
void setParent (QtNode *node)
 
const ParseInfogetParseInfo ()
 
void setParseInfo (const ParseInfo &info)
 

Protected Member Functions

QtDatacomputeOp (QtData *operand1, QtData *operand2)
 computes the binary operation More...
 
QtDatacomputeUnaryMDDOp (QtMDD *operand1, QtScalarData *operand2, const BaseType *resultBaseType, int scalarPos=1)
 computes an unary induce operation with one MDD object and a scalar value either being atomic or complex constant More...
 
QtDatacomputeBinaryMDDOp (QtMDD *operand1, QtMDD *operand2, const BaseType *resultBaseType)
 computes a binary induce operation on two MDD objects More...
 
QtDatacomputeBinaryOp (QtScalarData *operand1, QtScalarData *operand2, const BaseType *resultBaseType)
 computes a binary operation on two scalar objects More...
 
- Protected Member Functions inherited from QtBinaryOperation
bool getOperands (QtDataList *inputList, QtData *&operand1, QtData *&operand2)
 method for testing and evaluating the input branches More...
 
bool getOperand (QtDataList *inputList, QtData *&operand1, int number)
 method for testing and evaluating the input branches More...
 
- Protected Member Functions inherited from QtNode
void startTimer (const char *name)
 start node timer (called at evaluation time) More...
 
void stopTimer ()
 stop timer (at end of evaluation) More...
 
void pauseTimer ()
 pause More...
 
void resumeTimer ()
 resume More...
 
std::string getEvaluationTime ()
 get elapsed time if timer was started, returns a string e.g. "15 usecs" More...
 

Protected Attributes

Ops::OpType opType
 
- Protected Attributes inherited from QtBinaryOperation
QtOperationinput1
 first operation operand More...
 
QtOperationinput2
 second operation operand More...
 
- Protected Attributes inherited from QtOperation
QtTypeElement dataStreamType
 result type of the node More...
 
- Protected Attributes inherited from QtNode
ParseInfo parseInfo
 attribute for parser info More...
 

Additional Inherited Members

- Public Types inherited from QtNode
enum  QtNodeType {
  QT_UNDEFINED_NODE, QT_MDD_ACCESS, QT_OPERATION_ITERATOR, QT_SELECTION_ITERATOR,
  QT_JOIN_ITERATOR, QT_UPDATE, QT_INSERT, QT_DELETE,
  QT_COMMAND, QT_PLUS, QT_MINUS, QT_MULT,
  QT_DIV, QT_OR, QT_AND, QT_XOR,
  QT_IS, QT_EQUAL, QT_NOT_EQUAL, QT_LESS,
  QT_LESS_EQUAL, QT_NOT, QT_SQRT, QT_EXECUTE,
  QT_ONC_STREAM, QT_ITERATOR, QT_OPERATION, QT_BINARY_OPERATION,
  QT_BINARY_INDUCE, QT_GROUP_ITERATOR, QT_IDENT, QT_NARY_OPERATION,
  QT_UNARY_OPERATION, QT_CONDENSE, QT_UNARY_INDUCE, QT_ABS,
  QT_EXP, QT_LOG, QT_LN, QT_SIN,
  QT_COS, QT_TAN, QT_SINH, QT_COSH,
  QT_TANH, QT_ARCSIN, QT_ARCCOS, QT_ARCTAN,
  QT_REALPART, QT_IMAGINARPART, QT_CAST, QT_CSE_ROOT,
  QT_DOMAIN_OPERATION, QT_ALL, QT_SOME, QT_COUNTCELLS,
  QT_ADDCELLS, QT_AVGCELLS, QT_MINCELLS, QT_MAXCELLS,
  QT_MDD_VAR, QT_MDD_STREAM, QT_CONST, QT_DOT,
  QT_CONVERSION, QT_OID, QT_INTERVALOP, QT_MINTERVALOP,
  QT_POINTOP, QT_LO, QT_HI, QT_SDOM,
  QT_SHIFT, QT_EXTEND, QT_MARRAYOP, QT_CONDENSEOP,
  QT_SCALE, QT_OVERLAY, QT_BIT, QT_PYRAMID,
  QT_ENCODE, QT_CONCAT, QT_CASEOP, QT_INFO,
  QT_LAST_NODE_TYPE
}
 
enum  QtAreaType { QT_AREA_MDD, QT_AREA_SCALAR }
 
enum  QtChildType { QT_DIRECT_CHILDS, QT_LEAF_NODES, QT_ALL_NODES }
 
typedef std::vector< QtData * > QtDataList
 list of QtData pointers More...
 
typedef std::vector
< QtTrimElement * > 
QtTrimList
 list of QtTrimData structures More...
 
typedef std::list< QtNode * > QtNodeList
 list of QtNode pointers More...
 
typedef std::vector
< QtOperation * > 
QtOperationList
 list of QtOperation pointers More...
 
- Static Public Attributes inherited from QtNode
static const int QtNodes
 number of QtNodeTypes More...
 
static const QtNodeType QtRoot
 the root of the inheritance tree More...
 
static const QtNodeType QtInheritance [][2]
 the inheritance relations list More...
 

Constructor & Destructor Documentation

QtBinaryInduce::QtBinaryInduce ( QtOperation input1,
QtOperation input2,
Ops::OpType  initOpType 
)

constructor getting the two operands

Member Function Documentation

virtual const QtTypeElement& QtBinaryInduce::checkType ( QtTypeTuple typeTuple = NULL)
virtual

type checking of the subtree

Reimplemented from QtOperation.

Reimplemented in QtBit.

QtData* QtBinaryInduce::computeBinaryMDDOp ( QtMDD operand1,
QtMDD operand2,
const BaseType resultBaseType 
)
protected

computes a binary induce operation on two MDD objects

The method carries out the unary induce operation specified by { operation} on the two operands. { scalarPos } determines if the scalar value is the first (=1, default) or the second (=2) operand in the operation. For the result, a new transient MDD object is created and returned. In the end, the MDD object of the first operand is freed.

QtData* QtBinaryInduce::computeBinaryOp ( QtScalarData operand1,
QtScalarData operand2,
const BaseType resultBaseType 
)
protected

computes a binary operation on two scalar objects

The method carries out the binary induce operation specified by { operation} on the two operands. For the result, a new transient MDD object is created and returned. In the end, the MDD objects of the operands are freed.

QtData* QtBinaryInduce::computeOp ( QtData operand1,
QtData operand2 
)
protected

computes the binary operation

QtData* QtBinaryInduce::computeUnaryMDDOp ( QtMDD operand1,
QtScalarData operand2,
const BaseType resultBaseType,
int  scalarPos = 1 
)
protected

computes an unary induce operation with one MDD object and a scalar value either being atomic or complex constant

QtData* QtBinaryInduce::evaluate ( QtDataList inputList)
virtual

method for evaluating the node

Reimplemented from QtOperation.

Reimplemented in QtOr, and QtAnd.

Member Data Documentation

Ops::OpType QtBinaryInduce::opType
protected

The method carries out the binary operation specified by { operation} on the two operands.


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