This class contains the parameters needed for grouping the values of a Property. More...
#include <Grouping.h>
Public Member Functions | |
const std::vector< te::map::GroupingItem * > & | getGroupingItems () const |
It gets the vector of grouping items. More... | |
const size_t | getNumSlices () const |
It gets the number of slices used in the Equal Steps and Quantil groupings. More... | |
const size_t | getPrecision () const |
It gets the precision used for the property values. More... | |
std::string | getPropertyName () const |
It gets the property name whose values will be grouped. More... | |
int | getPropertyType () const |
It gets the property type whose values will be grouped. More... | |
const double | getStdDeviation () const |
It gets the standard deviation used in the Standard Deviation grouping. More... | |
std::string | getSummary () const |
It gets the grouping summary. It is used only in case 1 to n. More... | |
const GroupingType | getType () const |
It gets the grouping type. More... | |
Grouping (const std::string &propertyName, GroupingType type, size_t precision=6) | |
It constructs a new Grouping instance. More... | |
Grouping (const Grouping &rhs) | |
Copy constructor. More... | |
bool | isVisible () const |
It gets the grouping visibility. More... | |
void | setGroupingItems (std::vector< te::map::GroupingItem * > &items) |
It sets the vector of grouping items. More... | |
void | setNumSlices (size_t numSlices) |
It sets the number of slices for the EqualSteps and Quantil groupings. More... | |
void | setPrecision (size_t precision) |
It sets the precision to be used for the property values. More... | |
void | setPropertyName (const std::string &name) |
It sets the property name whose values will be grouped. More... | |
void | setPropertyType (const int &type) |
It sets the property type whose values will be grouped. More... | |
void | setStdDeviation (double stdDeviation) |
It sets the standard deviation for the Standard Deviation grouping. More... | |
void | setSummary (const std::string &summary) |
It gets the grouping summary. It is used only in case 1 to n. More... | |
void | setType (GroupingType type) |
It sets the grouping type. More... | |
void | setVisibility (bool visible) |
It sets the grouping visibility. More... | |
~Grouping () | |
Destructor. More... | |
Private Attributes | |
bool | m_isVisible |
A flag that indicates if the grouping is visible. More... | |
std::vector< te::map::GroupingItem * > | m_items |
The vector of grouping items. More... | |
size_t | m_numSlices |
The number of slices used in the Equal Steps and Quantil groupings. More... | |
size_t | m_precision |
The precision of the values. More... | |
std::string | m_propertyName |
The property name whose values will be used to make the grouping. More... | |
int | m_propertyType |
The property type whose values will be used to make the grouping. More... | |
double | m_stdDeviation |
The standard deviation used in the Standard Deviation grouping. More... | |
std::string | m_summary |
The summary used in case 1 to n. More... | |
GroupingType | m_type |
The grouping type. More... | |
This class contains the parameters needed for grouping the values of a Property.
Definition at line 59 of file Grouping.h.
te::map::Grouping::Grouping | ( | const std::string & | propertyName, |
GroupingType | type, | ||
size_t | precision = 6 |
||
) |
It constructs a new Grouping instance.
propertyName | The property name whose values will be used to make the grouping. |
type | The grouping type. |
precision | The precision to be set to the property values. |
Definition at line 33 of file Grouping.cpp.
References m_propertyType, and te::dt::UNKNOWN_TYPE.
te::map::Grouping::~Grouping | ( | ) |
te::map::Grouping::Grouping | ( | const Grouping & | rhs | ) |
Copy constructor.
Definition at line 43 of file Grouping.cpp.
References m_items, m_numSlices, m_stdDeviation, setGroupingItems(), setNumSlices(), and setStdDeviation().
const std::vector< te::map::GroupingItem * > & te::map::Grouping::getGroupingItems | ( | ) | const |
It gets the vector of grouping items.
Definition at line 130 of file Grouping.cpp.
Referenced by te::map::DataSetLayerRenderer::drawGrouping(), te::layout::LegendModel::drawGroupingLegend(), te::map::AbstractLayerRenderer::drawLayerGrouping(), te::map::QueryLayerRenderer::drawLayerGroupingMem(), te::map::AbstractLayerRenderer::drawLayerGroupingMem(), te::map::QueryLayerRenderer::drawLayerLinkedGroupingMem(), te::layout::LegendItem::paint(), te::qt::widgets::GroupingWidget::setGrouping(), te::layout::LegendModel::updateBox(), and te::map::serialize::WriteLayerGrouping().
const size_t te::map::Grouping::getNumSlices | ( | ) | const |
It gets the number of slices used in the Equal Steps and Quantil groupings.
The number of slices.
Definition at line 110 of file Grouping.cpp.
Referenced by te::qt::widgets::GroupingWidget::setGrouping().
const size_t te::map::Grouping::getPrecision | ( | ) | const |
It gets the precision used for the property values.
The precision used for the property values.
Definition at line 100 of file Grouping.cpp.
Referenced by te::map::QueryLayerRenderer::drawLayerGroupingMem(), te::map::AbstractLayerRenderer::drawLayerGroupingMem(), te::map::QueryLayerRenderer::drawLayerLinkedGroupingMem(), te::qt::widgets::GroupingWidget::setGrouping(), and te::map::serialize::WriteLayerGrouping().
std::string te::map::Grouping::getPropertyName | ( | ) | const |
It gets the property name whose values will be grouped.
Definition at line 68 of file Grouping.cpp.
Referenced by te::map::DataSetLayerRenderer::drawGrouping(), te::layout::LegendModel::drawGroupingLegend(), te::map::AbstractLayerRenderer::drawLayerGrouping(), te::map::QueryLayerRenderer::drawLayerGroupingMem(), te::map::AbstractLayerRenderer::drawLayerGroupingMem(), te::map::QueryLayerRenderer::drawLayerLinkedGroupingMem(), te::layout::LegendItem::paint(), te::qt::widgets::GroupingWidget::setGrouping(), te::layout::LegendModel::updateBox(), and te::map::serialize::WriteLayerGrouping().
int te::map::Grouping::getPropertyType | ( | ) | const |
It gets the property type whose values will be grouped.
Definition at line 79 of file Grouping.cpp.
Referenced by te::map::DataSetLayerRenderer::drawGrouping(), te::map::AbstractLayerRenderer::drawLayerGrouping(), and te::map::serialize::WriteLayerGrouping().
const double te::map::Grouping::getStdDeviation | ( | ) | const |
It gets the standard deviation used in the Standard Deviation grouping.
The standard deviation.
Definition at line 120 of file Grouping.cpp.
Referenced by te::qt::widgets::GroupingWidget::setGrouping(), and te::map::serialize::WriteLayerGrouping().
std::string te::map::Grouping::getSummary | ( | ) | const |
It gets the grouping summary. It is used only in case 1 to n.
Definition at line 152 of file Grouping.cpp.
Referenced by te::map::QueryLayerRenderer::drawLayerLinkedGroupingMem(), and te::map::serialize::WriteLayerGrouping().
const te::map::GroupingType te::map::Grouping::getType | ( | ) | const |
It gets the grouping type.
Definition at line 90 of file Grouping.cpp.
Referenced by te::map::DataSetLayerRenderer::drawGrouping(), te::layout::LegendModel::drawGroupingLegend(), te::map::AbstractLayerRenderer::drawLayerGrouping(), te::map::QueryLayerRenderer::drawLayerGroupingMem(), te::map::AbstractLayerRenderer::drawLayerGroupingMem(), te::map::QueryLayerRenderer::drawLayerLinkedGroupingMem(), te::layout::LegendItem::paint(), te::qt::widgets::GroupingWidget::setGrouping(), te::layout::LegendModel::updateBox(), and te::map::serialize::WriteLayerGrouping().
bool te::map::Grouping::isVisible | ( | ) | const |
It gets the grouping visibility.
Definition at line 142 of file Grouping.cpp.
Referenced by te::map::DataSetLayerRenderer::draw(), te::map::QueryLayerRenderer::draw(), te::map::AbstractLayerRenderer::draw(), te::layout::LegendModel::drawLegend(), te::layout::LegendItem::paint(), and te::layout::LegendModel::updateBox().
void te::map::Grouping::setGroupingItems | ( | std::vector< te::map::GroupingItem * > & | items | ) |
It sets the vector of grouping items.
The | vector of grouping items. |
Definition at line 135 of file Grouping.cpp.
Referenced by te::sa::CreateBayesGrouping(), te::sa::CreateKernelGrouping(), te::sa::CreateSampleGeneratorStratifiedGrouping(), te::sa::CreateSkaterGrouping(), te::qt::plugins::terralib4::GetGrouping(), and Grouping().
void te::map::Grouping::setNumSlices | ( | size_t | numSlices | ) |
It sets the number of slices for the EqualSteps and Quantil groupings.
numSlices | The number of slices. |
Definition at line 115 of file Grouping.cpp.
Referenced by te::sa::CreateBayesGrouping(), te::sa::CreateKernelGrouping(), and Grouping().
void te::map::Grouping::setPrecision | ( | size_t | precision | ) |
It sets the precision to be used for the property values.
precision | The precision value. |
Definition at line 105 of file Grouping.cpp.
Referenced by te::sa::CreateBayesGrouping(), te::sa::CreateKernelGrouping(), te::sa::CreateSampleGeneratorStratifiedGrouping(), and te::sa::CreateSkaterGrouping().
void te::map::Grouping::setPropertyName | ( | const std::string & | name | ) |
It sets the property name whose values will be grouped.
name | The property name. |
Definition at line 74 of file Grouping.cpp.
void te::map::Grouping::setPropertyType | ( | const int & | type | ) |
It sets the property type whose values will be grouped.
type | The property type. |
Definition at line 84 of file Grouping.cpp.
Referenced by te::sa::CreateBayesGrouping(), te::sa::CreateKernelGrouping(), te::sa::CreateSampleGeneratorStratifiedGrouping(), te::sa::CreateSkaterGrouping(), and te::qt::plugins::terralib4::GetGrouping().
void te::map::Grouping::setStdDeviation | ( | double | stdDeviation | ) |
It sets the standard deviation for the Standard Deviation grouping.
stdDeviation | The standard deviation. |
Definition at line 125 of file Grouping.cpp.
Referenced by te::sa::CreateBayesGrouping(), te::sa::CreateKernelGrouping(), te::sa::CreateSampleGeneratorStratifiedGrouping(), te::sa::CreateSkaterGrouping(), te::qt::plugins::terralib4::GetGrouping(), and Grouping().
void te::map::Grouping::setSummary | ( | const std::string & | summary | ) |
It gets the grouping summary. It is used only in case 1 to n.
summary | The summary mode. It can be: "MIN", "MAX", "SUM", "AVERAGE", "MEDIAN", "STDDEV" or "VARIANCE" |
Definition at line 157 of file Grouping.cpp.
void te::map::Grouping::setType | ( | GroupingType | type | ) |
It sets the grouping type.
type | The grouping type. |
Definition at line 95 of file Grouping.cpp.
void te::map::Grouping::setVisibility | ( | bool | visible | ) |
It sets the grouping visibility.
visible | The visibility value. |
Definition at line 147 of file Grouping.cpp.
|
private |
A flag that indicates if the grouping is visible.
Definition at line 205 of file Grouping.h.
|
private |
|
private |
The number of slices used in the Equal Steps and Quantil groupings.
Definition at line 203 of file Grouping.h.
Referenced by Grouping().
|
private |
The precision of the values.
Definition at line 202 of file Grouping.h.
|
private |
The property name whose values will be used to make the grouping.
Definition at line 199 of file Grouping.h.
|
private |
The property type whose values will be used to make the grouping.
Definition at line 200 of file Grouping.h.
Referenced by Grouping().
|
private |
The standard deviation used in the Standard Deviation grouping.
Definition at line 204 of file Grouping.h.
Referenced by Grouping().
|
private |
The summary used in case 1 to n.
Definition at line 207 of file Grouping.h.
|
private |
The grouping type.
Definition at line 201 of file Grouping.h.