A LineSymbolizer is used to style a stroke along a linear geometry type, such as a string of line segments. More...
#include <LineSymbolizer.h>
Public Types | |
typedef R | ReturnType |
typedef Visitor | VisitorType |
Public Member Functions | |
virtual ReturnType | accept (VisitorType &guest) const =0 |
It call the visit method from the guest object. More... | |
Symbolizer * | clone () const |
It creates a new copy of this object. More... | |
Initializer Methods | |
Methods related to instantiation and destruction. | |
LineSymbolizer () | |
It initializes a new LineSymbolizer. More... | |
LineSymbolizer (const LineSymbolizer &rhs) | |
Copy constructor. More... | |
~LineSymbolizer () | |
Destructor. More... | |
Accessor methods | |
Methods used to get or set properties. | |
void | setGeometry (te::fe::PropertyName *geometry) |
The Geometry element of a LineSymbolizer defines the linear geometry to be used for styling. The Geometry element is optional and if it is absent then the all geometry properties of the feature type that is used in the containing FeatureType are used. Most frequently, though, feature types will have only a single geometry property. See OGC te::fe::PropertyName class for more information on attribute names. More... | |
const te::fe::PropertyName * | getGeometry () const |
void | setStroke (Stroke *stroke) |
A Stroke specifies the appearance of a linear geometry. The Stroke element is optional inside of LineSymbolizer (and other Symbolizers), and its absence means that no stroke is to be rendered. More... | |
const Stroke * | getStroke () const |
void | setPerpendicularOffset (ParameterValue *perpendicularOffset) |
PerpendicularOffset allows to draw lines in parallel to the original geometry. For complex line strings these parallel lines have to be constructed so that the distance between original geometry and drawn line stays equal. This construction can result in drawn lines that are actually smaller or longer than the original geometry. The distance is in uoms and is positive to the left-hand side of the line string. Negative numbers mean right. The default offset is 0. More... | |
const ParameterValue * | getPerpendicularOffset () const |
const std::string & | getType () const |
It returns the symbolizer type. More... | |
Accessor methods | |
Methods used to get or set properties. | |
void | setName (const std::string &name) |
const std::string & | getName () const |
void | setDescription (Description *d) |
const Description * | getDescription () const |
void | setBaseSymbolizer (te::xl::SimpleLink *baseSymbolizer) |
const te::xl::SimpleLink * | getBaseSymbolizer () const |
void | setVersion (const std::string &version) |
const std::string & | getVersion () const |
void | setUom (const te::common::BaseUnitOfMeasure *uom) |
It sets the unit-of-measure. More... | |
const te::common::BaseUnitOfMeasure * | getUom () const |
Private Attributes | |
te::fe::PropertyName * | m_geometry |
A Geometry gives reference to a (the) geometry property of a feature to be used for rendering. (Optional) More... | |
ParameterValue * | m_perpendicularOffset |
A PerpendicularOffset gives the perpendicular distance away from a line to draw a label. (Optional) More... | |
Stroke * | m_stroke |
A Stroke specifies the appearance of a linear geometry. (Optional) More... | |
Static Private Attributes | |
static const std::string | sm_type |
A static data member used in the implementation of getType method. More... | |
A LineSymbolizer is used to style a stroke along a linear geometry type, such as a string of line segments.
Definition at line 51 of file LineSymbolizer.h.
|
inherited |
Definition at line 58 of file BaseVisitable.h.
|
inherited |
Definition at line 57 of file BaseVisitable.h.
te::se::LineSymbolizer::LineSymbolizer | ( | ) |
It initializes a new LineSymbolizer.
Definition at line 34 of file LineSymbolizer.cpp.
te::se::LineSymbolizer::LineSymbolizer | ( | const LineSymbolizer & | rhs | ) |
Copy constructor.
rhs | The other line symbolizer. |
Definition at line 42 of file LineSymbolizer.cpp.
References te::se::ParameterValue::clone(), te::se::Stroke::clone(), te::fe::PropertyName::getName(), m_geometry, m_perpendicularOffset, and m_stroke.
te::se::LineSymbolizer::~LineSymbolizer | ( | ) |
Destructor.
Definition at line 58 of file LineSymbolizer.cpp.
|
pure virtualinherited |
It call the visit method from the guest object.
guest | The guest or visitor. |
|
virtual |
It creates a new copy of this object.
Implements te::se::Symbolizer.
Definition at line 103 of file LineSymbolizer.cpp.
Referenced by te::qt::widgets::LineSymbolizerWidget::setSymbolizer().
|
inherited |
Definition at line 94 of file Symbolizer.cpp.
Referenced by te::se::serialize::WriteSymbolizerHelper().
|
inherited |
Definition at line 83 of file Symbolizer.cpp.
Referenced by te::se::serialize::WriteSymbolizerHelper().
const te::fe::PropertyName * te::se::LineSymbolizer::getGeometry | ( | ) | const |
Definition at line 71 of file LineSymbolizer.cpp.
Referenced by LineSymbolizerWriter().
|
inherited |
Definition at line 72 of file Symbolizer.cpp.
Referenced by te::layout::LegendChildModel::drawLegend(), te::layout::LegendModel::drawStyleLegend(), and te::se::serialize::WriteSymbolizerHelper().
const te::se::ParameterValue * te::se::LineSymbolizer::getPerpendicularOffset | ( | ) | const |
Definition at line 93 of file LineSymbolizer.cpp.
Referenced by LineSymbolizerWriter().
const te::se::Stroke * te::se::LineSymbolizer::getStroke | ( | ) | const |
Definition at line 82 of file LineSymbolizer.cpp.
Referenced by LineSymbolizerWriter(), te::se::SymbolizerColorFinder::visit(), te::map::CanvasConfigurer::visit(), and te::qt::widgets::ChartConfigurer::visit().
|
virtual |
It returns the symbolizer type.
Implements te::se::Symbolizer.
Definition at line 98 of file LineSymbolizer.cpp.
|
inherited |
Definition at line 114 of file Symbolizer.cpp.
|
inherited |
Definition at line 104 of file Symbolizer.cpp.
Referenced by te::se::serialize::WriteSymbolizerHelper().
|
inherited |
Definition at line 88 of file Symbolizer.cpp.
|
inherited |
Definition at line 77 of file Symbolizer.cpp.
Referenced by te::se::serialize::ReadSymbolizerHelper().
void te::se::LineSymbolizer::setGeometry | ( | te::fe::PropertyName * | geometry | ) |
The Geometry element of a LineSymbolizer defines the linear geometry to be used for styling. The Geometry element is optional and if it is absent then the all geometry properties of the feature type that is used in the containing FeatureType are used. Most frequently, though, feature types will have only a single geometry property. See OGC te::fe::PropertyName class for more information on attribute names.
Definition at line 65 of file LineSymbolizer.cpp.
|
inherited |
Definition at line 67 of file Symbolizer.cpp.
Referenced by te::se::serialize::ReadSymbolizerHelper().
void te::se::LineSymbolizer::setPerpendicularOffset | ( | ParameterValue * | perpendicularOffset | ) |
PerpendicularOffset allows to draw lines in parallel to the original geometry. For complex line strings these parallel lines have to be constructed so that the distance between original geometry and drawn line stays equal. This construction can result in drawn lines that are actually smaller or longer than the original geometry. The distance is in uoms and is positive to the left-hand side of the line string. Negative numbers mean right. The default offset is 0.
Definition at line 87 of file LineSymbolizer.cpp.
void te::se::LineSymbolizer::setStroke | ( | Stroke * | stroke | ) |
A Stroke specifies the appearance of a linear geometry. The Stroke element is optional inside of LineSymbolizer (and other Symbolizers), and its absence means that no stroke is to be rendered.
Definition at line 76 of file LineSymbolizer.cpp.
Referenced by te::se::CreateLineSymbolizer(), te::se::CreateSymbolizer(), te::qt::widgets::LineSymbolizerWidget::LineSymbolizerWidget(), and te::qt::widgets::LineSymbolizerProperty::setSymbolizer().
|
inherited |
It sets the unit-of-measure.
All Symbolizers include an optional gml:uom-attribute as used by GML (this is set inside the abstract SymbolizerType and therefore inherited by all Symbolizers). This applies to all elements included inside a Symbolizer such as stroke-width, size, font-size, Gap, InitialGap, Displacement and PerpendicularOffset. If no uom is set inside of Symbolizer, all units are measured in pixel, the behaviour used by SLD 1.0.0. The following uom definitions are recommended to be used:
Definition at line 109 of file Symbolizer.cpp.
|
inherited |
Definition at line 99 of file Symbolizer.cpp.
Referenced by te::se::serialize::ReadSymbolizerHelper().
|
private |
A Geometry gives reference to a (the) geometry property of a feature to be used for rendering. (Optional)
Definition at line 144 of file LineSymbolizer.h.
Referenced by LineSymbolizer().
|
private |
A PerpendicularOffset gives the perpendicular distance away from a line to draw a label. (Optional)
Definition at line 146 of file LineSymbolizer.h.
Referenced by LineSymbolizer().
|
private |
A Stroke specifies the appearance of a linear geometry. (Optional)
Definition at line 145 of file LineSymbolizer.h.
Referenced by LineSymbolizer().
|
staticprivate |
A static data member used in the implementation of getType method.
Definition at line 148 of file LineSymbolizer.h.