The transformation of continuous values to distinct values (Categorize function). More...
#include <Categorize.h>
Public Types | |
typedef R | ReturnType |
enum | ThresholdsBelongToType { NONE, SUCCEEDING, PRECEDING } |
It controls the interval order. More... | |
typedef Visitor | VisitorType |
Public Member Functions | |
virtual ReturnType | accept (VisitorType &guest) const =0 |
It call the visit method from the guest object. More... | |
void | addThreshold (ParameterValue *v) |
void | addValue (ParameterValue *v) |
const std::string & | getFallbackValue () const |
ParameterValue * | getLookupValue () const |
const std::vector < ParameterValue * > & | getThresholds () const |
const ThresholdsBelongToType & | getThresholdsBelongTo () const |
const std::vector < ParameterValue * > & | getThresholdValues () const |
ParameterValue * | getValue () const |
void | setFallbackValue (const std::string &v) |
void | setLookupValue (ParameterValue *v) |
void | setThresholdsBelongTo (ThresholdsBelongToType t) |
void | setValue (ParameterValue *v) |
Initializer Methods | |
Methods related to instantiation and destruction. | |
Categorize () | |
It initializes a new Categorize. More... | |
Categorize (const Categorize &rhs) | |
Copy constructor. More... | |
~Categorize () | |
Destructor. More... | |
virtual Categorize * | clone () const |
It returns a clone of this object. More... | |
Protected Attributes | |
std::string | m_fallbackValue |
The value of the fallbackValue attribute is used as a default value, if the SE implementation does not support the function. If the implementation supports the function, then the result value is determined by executing the function. (Mandatory) More... | |
Private Attributes | |
ParameterValue * | m_lookupValue |
Mandatory. More... | |
ThresholdsBelongToType | m_threshholdsBelongTo |
(Optional) More... | |
std::vector< ParameterValue * > | m_thresholds |
A vector of threshold. (Optional) More... | |
std::vector< ParameterValue * > | m_thresholdValues |
A vector of threshold values. (Optional) More... | |
ParameterValue * | m_value |
Mandatory. More... | |
The transformation of continuous values to distinct values (Categorize function).
The Symbology encoding specification defines three pre-defined functions for transforming raw data:
The Thresholds have to be specified in ascending order and (like the LookupValue) have to be of a uniform and orderable type. The value of the function is determined by looking up into which interval between two thresholds the LookupValue falls. The first interval ranges from -Infinity to the first given threshold and the last one accordingly from the last threshold to +Infinity. In case the Categorize (or Interpolate) function is used inside a RasterSymbolizer as a ColorMap, the LookupValue is set to the fixed value "Rasterdata". The Values can be of any type, dependent on which symbolization context the function is employed. Color values (like #00ffff) or numeric values are typical. Whether the Threshold values themselves belong to the preceding or the succeeding interval can be controlled by the attribute thresholdsBelongTo= with the possible values "preceding" and "succeeding" the latter being the default.
Definition at line 90 of file Categorize.h.
|
inherited |
Definition at line 58 of file BaseVisitable.h.
|
inherited |
Definition at line 57 of file BaseVisitable.h.
It controls the interval order.
Enumerator | |
---|---|
NONE | |
SUCCEEDING | |
PRECEDING |
Definition at line 99 of file Categorize.h.
te::se::Categorize::Categorize | ( | ) |
It initializes a new Categorize.
Definition at line 31 of file Categorize.cpp.
te::se::Categorize::Categorize | ( | const Categorize & | rhs | ) |
Copy constructor.
rhs | The other Categorize. |
Definition at line 38 of file Categorize.cpp.
References te::se::ParameterValue::clone(), te::se::Function::getFallbackValue(), te::se::Function::m_fallbackValue, m_lookupValue, m_threshholdsBelongTo, m_thresholds, m_thresholdValues, and m_value.
te::se::Categorize::~Categorize | ( | ) |
|
pure virtualinherited |
It call the visit method from the guest object.
guest | The guest or visitor. |
void te::se::Categorize::addThreshold | ( | ParameterValue * | v | ) |
Definition at line 94 of file Categorize.cpp.
Referenced by te::qt::widgets::ColorMapWidget::buildCategorizationMap(), te::qt::widgets::ClassifierWizard::execute(), and te::qt::plugins::terralib4::GetRasterGrouping().
void te::se::Categorize::addValue | ( | ParameterValue * | v | ) |
Definition at line 99 of file Categorize.cpp.
Referenced by te::qt::widgets::ColorMapWidget::buildCategorizationMap(), te::qt::widgets::ClassifierWizard::execute(), and te::qt::plugins::terralib4::GetRasterGrouping().
|
virtual |
It returns a clone of this object.
Implements te::fe::Expression.
Definition at line 76 of file Categorize.cpp.
Referenced by te::se::ColorMap::ColorMap().
|
inherited |
Definition at line 42 of file Function.cpp.
Referenced by Categorize(), te::se::Interpolate::Interpolate(), and te::se::serialize::Save().
|
inline |
Definition at line 135 of file Categorize.h.
Referenced by te::se::serialize::Save().
const std::vector< te::se::ParameterValue * > & te::se::Categorize::getThresholds | ( | ) | const |
Definition at line 109 of file Categorize.cpp.
Referenced by te::map::RasterTransformConfigurer::getCategorizedMap(), and te::se::serialize::Save().
|
inline |
Definition at line 147 of file Categorize.h.
Referenced by te::se::serialize::Save().
const std::vector< te::se::ParameterValue * > & te::se::Categorize::getThresholdValues | ( | ) | const |
Definition at line 114 of file Categorize.cpp.
Referenced by te::map::RasterTransformConfigurer::getCategorizedMap(), and te::se::serialize::Save().
|
inline |
Definition at line 139 of file Categorize.h.
Referenced by te::se::serialize::Save().
|
inherited |
Definition at line 37 of file Function.cpp.
Referenced by te::qt::widgets::ColorMapWidget::buildCategorizationMap(), te::qt::widgets::ColorMapWidget::buildInterpolationMap(), te::qt::widgets::ClassifierWizard::execute(), and te::qt::plugins::terralib4::GetRasterGrouping().
void te::se::Categorize::setLookupValue | ( | ParameterValue * | v | ) |
Definition at line 81 of file Categorize.cpp.
Referenced by te::qt::widgets::ColorMapWidget::buildCategorizationMap(), te::qt::widgets::ClassifierWizard::execute(), and te::qt::plugins::terralib4::GetRasterGrouping().
void te::se::Categorize::setThresholdsBelongTo | ( | ThresholdsBelongToType | t | ) |
Definition at line 104 of file Categorize.cpp.
Referenced by te::qt::widgets::ColorMapWidget::buildCategorizationMap(), te::qt::widgets::ClassifierWizard::execute(), and te::qt::plugins::terralib4::GetRasterGrouping().
void te::se::Categorize::setValue | ( | ParameterValue * | v | ) |
Definition at line 88 of file Categorize.cpp.
|
protectedinherited |
The value of the fallbackValue attribute is used as a default value, if the SE implementation does not support the function. If the implementation supports the function, then the result value is determined by executing the function. (Mandatory)
Definition at line 88 of file Function.h.
Referenced by Categorize(), and te::se::Interpolate::Interpolate().
|
private |
|
private |
|
private |
A vector of threshold. (Optional)
Definition at line 157 of file Categorize.h.
Referenced by Categorize().
|
private |
A vector of threshold values. (Optional)
Definition at line 158 of file Categorize.h.
Referenced by Categorize().
|
private |