KernelParams.h
Go to the documentation of this file.
1 /* Copyright (C) 2008 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 terralib/sa/core/KernelParams.h
22 
23  \brief This file contains a class that represents the kernel parameters.
24 
25  \reference Adapted from TerraLib4.
26 */
27 
28 #ifndef __TERRALIB_SA_INTERNAL_KERNELPARAMS_H
29 #define __TERRALIB_SA_INTERNAL_KERNELPARAMS_H
30 
31 // Terralib Includes
32 #include "../../dataaccess/dataset/DataSet.h"
33 #include "../../dataaccess/dataset/DataSetType.h"
34 #include "../Config.h"
35 #include "../Enums.h"
36 
37 // STL Includes
38 #include <map>
39 #include <memory>
40 #include <string>
41 
42 namespace te
43 {
44  namespace sa
45  {
46  /*!
47  \class KernelInputParams
48 
49  \brief Class that represents the kernel input parameters.
50 
51  \sa KernelOperation
52  */
53 
55  {
56  public:
57 
58  /*! \brief Default constructor. */
60  {
61  m_intensityAttrName = "";
62  m_functionType = te::sa::Normal;
63  m_estimationType = te::sa::Density;
64  m_useAdaptativeRadius = true;
65  m_radiusPercentValue = 10;
66  }
67 
68  /*! \brief Virtual destructor. */
70  {
71  }
72 
73  public:
74 
75  std::auto_ptr<te::da::DataSetType> m_dsType; //!< Attribute used to access the data set metadata
76  std::auto_ptr<te::da::DataSet> m_ds; //!< Attribute with data set
77 
78  std::string m_intensityAttrName; //!< Attribute from dataset used as intensity attr (not obrigatory)
79 
80  te::sa::KernelFunctionType m_functionType; //!< Kernel function type
81  te::sa::KernelEstimationType m_estimationType; //!< Kernel estimation type
82 
83  bool m_useAdaptativeRadius; //!< Attribute to indicate if a an adaptative radius has to be used.
84  int m_radiusPercentValue; //!< Attribute with radius percent value (m_useAdaptativeRadius must be false)
85  };
86 
87  /*!
88  \class KernelOutputParams
89 
90  \brief Class that represents the kernel output parameters.
91 
92  \sa KernelOperation
93  */
94 
96  {
97  public:
98 
99  /*! \brief Default constructor. */
101  {
102  m_storageType = te::sa::Grid; //!< Kernel storage type
103  m_combinationType = te::sa::Ratio;
104  m_nCols = 50;
105  m_outputAttrName = "";
106  m_outputPath = "";
107  m_outputDataSetName = "";
108  }
109 
110  /*! \brief Virtual destructor. */
112  {
113  }
114 
115  public:
116 
117  te::sa::KernelOutputType m_storageType; //!< Kernel storage type
118  te::sa::KernelCombinationType m_combinationType; //!< Kernel combination type (used by ratio kernel)
119 
120  int m_nCols; //!< Attribute with number of columns to create the grid (if KernelOutputType is Grid)
121  std::string m_outputAttrName; //!< Attribute with the new attr name (if KernelOutputType is Attribute)
122  std::string m_outputPath; //!< Attribute with URI of the output file
123  std::string m_outputDataSetName; //!< Attribute that defines the output dataset name
124  };
125  } // end namespace sa
126 } // end namespace te
127 
128 #endif //__TERRALIB_SA_INTERNAL_KERNELPARAMS_H
Class that represents the kernel input parameters.
Definition: KernelParams.h:54
KernelEstimationType
Definition: Enums.h:77
te::sa::KernelOutputType m_storageType
Kernel storage type.
Definition: KernelParams.h:117
KernelOutputParams()
Default constructor.
Definition: KernelParams.h:100
KernelCombinationType
Types of kernel combination.
Definition: Enums.h:89
Class that represents the kernel output parameters.
Definition: KernelParams.h:95
KernelInputParams()
Default constructor.
Definition: KernelParams.h:59
int m_radiusPercentValue
Attribute with radius percent value (m_useAdaptativeRadius must be false)
Definition: KernelParams.h:84
URI C++ Library.
te::sa::KernelFunctionType m_functionType
Kernel function type.
Definition: KernelParams.h:80
std::auto_ptr< te::da::DataSet > m_ds
Attribute with data set.
Definition: KernelParams.h:76
~KernelOutputParams()
Virtual destructor.
Definition: KernelParams.h:111
std::string m_outputAttrName
Attribute with the new attr name (if KernelOutputType is Attribute)
Definition: KernelParams.h:121
te::sa::KernelCombinationType m_combinationType
Kernel combination type (used by ratio kernel)
Definition: KernelParams.h:118
KernelOutputType
Defines the kernel result storage mode.
Definition: Enums.h:104
std::string m_outputPath
Attribute with URI of the output file.
Definition: KernelParams.h:122
#define TESAEXPORT
You can use this macro in order to export/import classes and functions from this module.
Definition: Config.h:133
te::sa::KernelEstimationType m_estimationType
Kernel estimation type.
Definition: KernelParams.h:81
bool m_useAdaptativeRadius
Attribute to indicate if a an adaptative radius has to be used.
Definition: KernelParams.h:83
std::string m_outputDataSetName
Attribute that defines the output dataset name.
Definition: KernelParams.h:123
KernelFunctionType
Definition: Enums.h:63
std::auto_ptr< te::da::DataSetType > m_dsType
Attribute used to access the data set metadata.
Definition: KernelParams.h:75
std::string m_intensityAttrName
Attribute from dataset used as intensity attr (not obrigatory)
Definition: KernelParams.h:78
int m_nCols
Attribute with number of columns to create the grid (if KernelOutputType is Grid) ...
Definition: KernelParams.h:120
~KernelInputParams()
Virtual destructor.
Definition: KernelParams.h:69