rasdaman complete source
qtunaryoperation.hh
Go to the documentation of this file.
1 #ifndef _QTUNARYOPERATION_
2 #define _QTUNARYOPERATION_
3 
4 #ifndef CPPSTDLIB
5 #include <ospace/string.h> // STL<ToolKit>
6 #else
7 #include <string>
8 #endif
9 
10 #include <stdio.h>
11 
12 #include "qlparser/qtoperation.hh"
13 
14 /*
15 * This file is part of rasdaman community.
16 *
17 * Rasdaman community is free software: you can redistribute it and/or modify
18 * it under the terms of the GNU General Public License as published by
19 * the Free Software Foundation, either version 3 of the License, or
20 * (at your option) any later version.
21 *
22 * Rasdaman community is distributed in the hope that it will be useful,
23 * but WITHOUT ANY WARRANTY; without even the implied warranty of
24 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25 * GNU General Public License for more details.
26 *
27 * You should have received a copy of the GNU General Public License
28 * along with rasdaman community. If not, see <http://www.gnu.org/licenses/>.
29 *
30 * Copyright 2003, 2004, 2005, 2006, 2007, 2008, 2009 Peter Baumann /
31 rasdaman GmbH.
32 *
33 * For more information please see <http://www.rasdaman.org>
34 * or contact Peter Baumann via <baumann@rasdaman.com>.
35 */
36 /**************************************************************
37  *
38  *
39  * COMMENTS:
40  *
41  ************************************************************/
42 
43 //@ManMemo: Module: {\bf qlparser}
44 
45 /*@Doc:
46 
47 The class serves as superclass for all operation classes taking one
48 argument.
49 
50 */
51 
53 {
54 public:
57 
60 
62  virtual ~QtUnaryOperation();
63 
65  virtual std::string getSpelling();
66 
68  virtual void simplify();
69 
71  virtual QtNodeList* getChilds( QtChildType flag );
72 
74  virtual QtAreaType getAreaType();
75 
77  virtual bool equalMeaning( QtNode* node );
78 
80  inline virtual void setInput( QtOperation* inputOld, QtOperation* inputNew );
81 
83  virtual void optimizeLoad( QtTrimList* trimList );
84 
89  virtual void printTree( int tab, std::ostream& s = std::cout, QtChildType mode = QT_ALL_NODES );
91 
92  //@Man: Read/Write methods for the operand
94 
97  inline virtual void setInput( QtOperation* input );
99  inline QtOperation* getInput();
100 
102 
103 protected:
106 };
107 
108 #include "qlparser/qtunaryoperation.icc"
109 
110 #endif
111 
virtual void simplify()
simplifies the tree
std::list< QtNode * > QtNodeList
list of QtNode pointers
Definition: qtnode.hh:91
std::vector< QtTrimElement * > QtTrimList
list of QtTrimData structures
Definition: qtnode.hh:88
QtAreaType
Definition: qtnode.hh:180
QtOperation * input
operation operand
Definition: qtunaryoperation.hh:105
virtual QtAreaType getAreaType()
test if the edge to the parent node is of type mdd or atomic
virtual void setInput(QtOperation *inputOld, QtOperation *inputNew)
method for query rewrite
virtual std::string getSpelling()
creates a unique name for a common subexpression
QtChildType
Definition: qtnode.hh:186
Definition: qtunaryoperation.hh:52
virtual void optimizeLoad(QtTrimList *trimList)
optimizing load access
QtOperation * getInput()
virtual void printTree(int tab, std::ostream &s=std::cout, QtChildType mode=QT_ALL_NODES)
debugging method
virtual ~QtUnaryOperation()
virtual destructor
Definition: qtnode.hh:73
QtUnaryOperation()
default constructor
Definition: qtoperation.hh:57
virtual QtNodeList * getChilds(QtChildType flag)
return childs of the node
virtual bool equalMeaning(QtNode *node)
tests if the two nodes have an equal meaning in the query tree
Definition: qtnode.hh:190