LuciadCPillar 2023.1.04
|
A callback interface that can signal that a feature was changed in the context of creation. More...
#include <luciad/create/features/IFeatureCreateCallback.h>
Public Member Functions | |
virtual | ~IFeatureCreateCallback ()=default |
virtual void | onFeatureChanged (const Feature &newFeature, ChangeStatus changeStatus)=0 |
Can be implemented to handle the given feature. More... | |
virtual void | onFeatureCreateFailed (const ErrorInfo &errorInfo)=0 |
Can be implemented to handle the case when feature creation has failed. More... | |
Static Public Member Functions | |
static std::shared_ptr< IFeatureCreateCallback > | create (std::function< void(const Feature &, ChangeStatus)> onChangedFunction, std::function< void(const ErrorInfo &)> onFailedFunction) |
Creates a default IFeatureCreateCallback instance that delegates the IFeatureCreateCallback::onFeatureChanged to the given function. More... | |
A callback interface that can signal that a feature was changed in the context of creation.
This class is used by IFeatureCreator
implementations.
|
virtualdefault |
|
static |
Creates a default IFeatureCreateCallback instance that delegates the IFeatureCreateCallback::onFeatureChanged
to the given function.
This is a convenience method that allows to reduce boiler plate code using lambdas.
onChangedFunction | the function that is called by IFeatureCreateCallback::onFeatureChanged |
onFailedFunction | the function that is called by IFeatureCreateCallback::onFeatureCreateFailed |
|
pure virtual |
Can be implemented to handle the given feature.
newFeature | the new feature |
changeStatus | the status of this change |
|
pure virtual |
Can be implemented to handle the case when feature creation has failed.
errorInfo | an info object that describes why creation failed |