LuciadCPillar 2023.1.04
luciad::IPolylineRingConstraint Class Referenceabstract

A constraint on PolylineRing. More...

#include <luciad/geometries/constraints/IPolylineRingConstraint.h>

Public Member Functions

virtual ~IPolylineRingConstraint ()=default
 
virtual std::shared_ptr< PolylineRingapply (const std::shared_ptr< PolylineRing > &oldPolylineRing, const std::shared_ptr< PolylineRing > &newPolylineRing, const PolylineChange &changes)=0
 Applies this constraint on a pending change. More...
 
virtual std::shared_ptr< PolylineRingapply (const std::shared_ptr< PolylineRing > &polylineRing)=0
 Applies this constraint on a polyline ring without a (known) change. More...
 

Detailed Description

A constraint on PolylineRing.

This can be configured on a PolylineRingHandlesProvider.

Since
2020.1

Constructor & Destructor Documentation

◆ ~IPolylineRingConstraint()

virtual luciad::IPolylineRingConstraint::~IPolylineRingConstraint ( )
virtualdefault

Member Function Documentation

◆ apply() [1/2]

virtual std::shared_ptr< PolylineRing > luciad::IPolylineRingConstraint::apply ( const std::shared_ptr< PolylineRing > &  oldPolylineRing,
const std::shared_ptr< PolylineRing > &  newPolylineRing,
const PolylineChange changes 
)
pure virtual

Applies this constraint on a pending change.

Parameters
oldPolylineRingthe base polyline ring on which the change is performed, cannot be nullptr.
newPolylineRingthe result of the change, without any constraints applied, cannot be nullptr.
changesthe change that was applied.
Returns
the resulting polyline ring, after applying this constraint on the pending change. Cannot be nullptr. If the constraint does not apply, simply return the newPolylineRing.

◆ apply() [2/2]

virtual std::shared_ptr< PolylineRing > luciad::IPolylineRingConstraint::apply ( const std::shared_ptr< PolylineRing > &  polylineRing)
pure virtual

Applies this constraint on a polyline ring without a (known) change.

Parameters
polylineRingthe polyline ring to constrain, cannot be nullptr.
Returns
the resulting polyline ring, after applying this constraint. If the constraint does not apply, simply return the polylineRing. Cannot be nullptr.