ModelCheckMethodCallback is responsible for registering and handling Model Quality Check methods through API. You can make your own implementation to extend the list of Model Check Methods with your own check logic.
More...
#include <ModelCheckMethodCallback.hpp>
|
| ModelCheckMethodCallback (const API_Guid &modelCheckTypeId, const GS::UniString &nonLocalizedModelCheckMethodName) |
| Constructs a new Model Check Method callback.
|
|
virtual GS::UniString | GetLocalizedCheckMethodName () const =0 |
| Callback function. The AddOn should return the localized name of the new Model Check Method.
|
|
virtual GS::UniString | GetLocalizedCheckMethodResultName () const =0 |
| Callback function. The AddOn should return the localized name of the new Model Check Method.
|
|
virtual std::optional< GS::UniString > | GetLocalizedCheckMethodInfoText () const =0 |
| Callback function. The AddOn can return a localized text that will pop up when the user hovers on the info icon.
|
|
virtual std::optional< RS::Icon > | GetIcon () const =0 |
| Callback function. The AddOn can return an icon that will showed on the Model Check dialog.
|
|
virtual std::optional< API_Guid > | GetGroupId () const =0 |
| Callback function. The AddOn can return a Model Check GroupId where the Model Check Method will be enrolled.
|
|
virtual bool | GetDefaultSelectionStatus () const =0 |
| Callback function. The AddOn should return the default state of the new Model Check Method.
|
|
virtual ModelCheckSettingType | GetCheckSettingType () const =0 |
| Callback function. Controls the type of the editbox displayed on the Model Check dialog.
|
|
virtual std::vector< double > | GetDefaultValues () const |
| Callback function. Provide the default value for the editbox displayed on the Model Check Dialog.
|
|
virtual std::vector< ModelCheckResult > | CheckProcess (GS::ProcessControl &processControl, const std::vector< double > &values)=0 |
| Callback function. The check logic should be placed here. It is called when the new Model Check Method is executed.
|
|
| AddonServiceInterface (const API_Guid &serviceIdentifier) |
| Creates and registers the AddonServiceInterface.
|
|
Result< void > | GetStatus (const API_Token &token) const |
| Get the status of the service registration.
|
|
virtual GSErrCode | Initialize () |
| The callback function for the initialization phase.
|
|
|
virtual GSErrCode | RegisterInterface () override |
| The callback function for the interface registration phase.
|
|
|
ACAPI::Error | status |
| The error status of the registration.
|
|
const API_Guid | serviceIdentifier |
| Identifier given by constructor.
|
|
ModelCheckMethodCallback is responsible for registering and handling Model Quality Check methods through API. You can make your own implementation to extend the list of Model Check Methods with your own check logic.
- Since
- Archicad 29
◆ ModelCheckMethodCallback()
ACAPI::ModelCheckMethodCallback::ModelCheckMethodCallback |
( |
const API_Guid & | modelCheckTypeId, |
|
|
const GS::UniString & | nonLocalizedModelCheckMethodName ) |
Constructs a new Model Check Method callback.
- Parameters
-
modelCheckTypeId | The identifier of the parent Model Check Type where the new method will be registered. |
nonLocalizedModelCheckMethodName | Non-localized name of the new Model Check Method. It should be unique, it's used for identification. |
◆ CheckProcess()
virtual std::vector< ModelCheckResult > ACAPI::ModelCheckMethodCallback::CheckProcess |
( |
GS::ProcessControl & | processControl, |
|
|
const std::vector< double > & | values ) |
|
pure virtual |
Callback function. The check logic should be placed here. It is called when the new Model Check Method is executed.
- Parameters
-
processControl | Process Control |
values | Values representing the settings |
- Returns
- Returns a vector of ModelCheckResult representing the elements that are filtered out by the check.
◆ GetCheckSettingType()
Callback function. Controls the type of the editbox displayed on the Model Check dialog.
- Returns
- Returns the value of ModelCheckSettingType enum.
◆ GetDefaultSelectionStatus()
virtual bool ACAPI::ModelCheckMethodCallback::GetDefaultSelectionStatus |
( |
| ) |
const |
|
pure virtual |
Callback function. The AddOn should return the default state of the new Model Check Method.
- Returns
- Returns the default state of the methods checkbox.
◆ GetDefaultValues()
virtual std::vector< double > ACAPI::ModelCheckMethodCallback::GetDefaultValues |
( |
| ) |
const |
|
virtual |
Callback function. Provide the default value for the editbox displayed on the Model Check Dialog.
- Returns
- Returns a vector of double values. The number of elements in the vector depends on the selected ModelCheckSettingType.
◆ GetGroupId()
virtual std::optional< API_Guid > ACAPI::ModelCheckMethodCallback::GetGroupId |
( |
| ) |
const |
|
pure virtual |
Callback function. The AddOn can return a Model Check GroupId where the Model Check Method will be enrolled.
New group can be registered with the ACAPI::ModelCheckManager::RegisterGroup () function.
- Returns
- Returns the groupId or std::nullopt.
◆ GetIcon()
virtual std::optional< RS::Icon > ACAPI::ModelCheckMethodCallback::GetIcon |
( |
| ) |
const |
|
pure virtual |
Callback function. The AddOn can return an icon that will showed on the Model Check dialog.
- Returns
- The icon or std::nullopt.
◆ GetLocalizedCheckMethodInfoText()
virtual std::optional< GS::UniString > ACAPI::ModelCheckMethodCallback::GetLocalizedCheckMethodInfoText |
( |
| ) |
const |
|
pure virtual |
Callback function. The AddOn can return a localized text that will pop up when the user hovers on the info icon.
- Returns
- Returns the localized info text or std::nullopt.
◆ GetLocalizedCheckMethodName()
virtual GS::UniString ACAPI::ModelCheckMethodCallback::GetLocalizedCheckMethodName |
( |
| ) |
const |
|
pure virtual |
Callback function. The AddOn should return the localized name of the new Model Check Method.
- Returns
- Returns the localized name that will be presented on the Model Check UI.
◆ GetLocalizedCheckMethodResultName()
virtual GS::UniString ACAPI::ModelCheckMethodCallback::GetLocalizedCheckMethodResultName |
( |
| ) |
const |
|
pure virtual |
Callback function. The AddOn should return the localized name of the new Model Check Method.
- Returns
- Returns the localized name that will be presented on the Model Check Result palette.
◆ RegisterInterface()
virtual GSErrCode ACAPI::ModelCheckMethodCallback::RegisterInterface |
( |
| ) |
|
|
overrideprotectedvirtual |
The callback function for the interface registration phase.
- Returns
- Returns NoError if everything went well, otherwise the error code.
Reimplemented from ACAPI::AddonServiceInterface.