All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
ScalarCapabilities.cpp
Go to the documentation of this file.
1 /* Copyright (C) 2001-2009 National Institute For Space Research (INPE) - Brazil.
2 
3  This file is part of the TerraLib - a Framework for building GIS enabled applications.
4 
5  TerraLib is free software: you can redistribute it and/or modify
6  it under the terms of the GNU Lesser General Public License as published by
7  the Free Software Foundation, either version 3 of the License,
8  or (at your option) any later version.
9 
10  TerraLib is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  GNU Lesser General Public License for more details.
14 
15  You should have received a copy of the GNU Lesser General Public License
16  along with TerraLib. See COPYING. If not, write to
17  TerraLib Team at <terralib-team@terralib.org>.
18  */
19 
20 /*!
21  \file ScalarCapabilities.cpp
22 
23  \brief Scalar capabilities include the ability to process logical expressions, comparisons and arithmetic operations including the ability to process a list of named functions.
24  */
25 
26 // TerraLib
27 #include "ArithmeticOperators.h"
28 #include "ComparisonOperators.h"
29 #include "ScalarCapabilities.h"
30 
32  : m_hasLogicalOperators(false),
33  m_comparisonOperators(0),
34  m_arithmeticOperators(0)
35 {
36 }
37 
39 {
40  delete m_comparisonOperators;
41  delete m_arithmeticOperators;
42 }
43 
45 {
46  return m_hasLogicalOperators;
47 }
48 
50 {
51  m_hasLogicalOperators = true;
52 }
53 
55 {
56  m_hasLogicalOperators = false;
57 }
58 
60 {
61  delete m_comparisonOperators;
62  m_comparisonOperators = cOps;
63 }
64 
66 {
67  return m_comparisonOperators;
68 }
69 
71 {
72  delete m_arithmeticOperators;
73  m_arithmeticOperators = aOps;
74 }
75 
77 {
78  return m_arithmeticOperators;
79 }
80 
const ComparisonOperators * getComparisonOperators() const
It returns the comparison operators.
bool hasLogicalOperators() const
It returns true if it has logical operators support, otherwise, returns false.
It is used to indicate what types of comparison operators are supported by a service.
void enableLogicalOperators()
It enables the logical operators support.
void setArithmeticOperators(ArithmeticOperators *aOps)
It sets the arithmetic operators.
It is used to indicate the arithmetic operators that a service can support.
Scalar capabilities include the ability to process logical expressions, comparisons and arithmetic op...
const ArithmeticOperators * getArithmeticOperators() const
It returns the arithmetic operators.
ScalarCapabilities()
It initializes a new ScalarCapabilities.
It is used to indicate what arithmetic operators the a service can support.
It is used to indicate what types of comparison operators are supported by a service.
void setComparisonOperators(ComparisonOperators *cOps)
It sets the comparison operators.