LuciadCPillar 2023.1.04
luciad::FeaturePainterMetadata Class Referenceabstract

Class to provide information on what type of changes affect the styling. More...

#include <luciad/layers/features/FeaturePainterMetadata.h>

Public Member Functions

virtual ~FeaturePainterMetadata ()=default
 
virtual void detailLevelScales (std::vector< MapScale > detailLevelScales)=0
 Sets a vector of map scales that determine when this painter should switch from one level-of-detail to the next. More...
 
virtual void painterDependsOnFeature (bool depends)=0
 Indicates whether a feature's style depends on the feature itself. More...
 
virtual void painterDependsOnFeatureState (const FeatureState &featureState, bool active)=0
 Indicates that a feature's style depends on the given state. More...
 

Detailed Description

Class to provide information on what type of changes affect the styling.

Constructor & Destructor Documentation

◆ ~FeaturePainterMetadata()

virtual luciad::FeaturePainterMetadata::~FeaturePainterMetadata ( )
virtualdefault

Member Function Documentation

◆ detailLevelScales()

virtual void luciad::FeaturePainterMetadata::detailLevelScales ( std::vector< MapScale detailLevelScales)
pure virtual

Sets a vector of map scales that determine when this painter should switch from one level-of-detail to the next.

This can be used to advertise that this painter supports multiple level-of-details for a given object. The current level-of-detail that is used is determined by the map and is passed back to the IFeaturePainter via the FeaturePainterContext::getDetailLevel() method. When this method is not called, level-of-detail is not supported.

All scales smaller than the smallest scale will correspond to detail level '0' (least detailed). All scales larger than the largest scale will correspond to detail level 'detailLevelScales.size()' (most detailed).

Parameters
detailLevelScalesthe switch scales for each level of detail

◆ painterDependsOnFeature()

virtual void luciad::FeaturePainterMetadata::painterDependsOnFeature ( bool  depends)
pure virtual

Indicates whether a feature's style depends on the feature itself.

For example, the feature's color may depend on a certain data property. This value is true by default.

Parameters
dependsWhen true, a feature needs to be repainted by the painter when it changes.

◆ painterDependsOnFeatureState()

virtual void luciad::FeaturePainterMetadata::painterDependsOnFeatureState ( const FeatureState featureState,
bool  active 
)
pure virtual

Indicates that a feature's style depends on the given state.

For example, the feature's color may change when it is selected. The luciad::FeatureState::selected() is active by default.

Parameters
featureStateThe feature state on which the painter depends. When a feature's state changes to this state, it needs to be repainted by the painter.
activeThe desired state of the given featureState.