From 3d2aab88629844f3136bbb4d9bc18ba0d04072a7 Mon Sep 17 00:00:00 2001 From: Ralph Wessel Date: Thu, 24 Oct 2024 18:06:18 +0100 Subject: [PATCH] Updated documentation --- .../Browser/Bridge/Account/GetAccounts.cpp | 2 +- .../Browser/Bridge/Account/GetAccounts.h | 2 +- .../Interface/Browser/Bridge/Base/AddModel.cpp | 1 - .../Interface/Browser/Bridge/Base/AddModel.h | 2 +- .../Interface/Browser/Bridge/Base/BaseBridge.h | 2 +- .../Browser/Bridge/Base/GetConnectorVersion.cpp | 8 ++++---- .../Browser/Bridge/Base/GetConnectorVersion.h | 6 +++--- .../Browser/Bridge/Base/GetDocumentState.cpp | 4 ++-- .../Browser/Bridge/Base/GetDocumentState.h | 6 +++--- .../Browser/Bridge/Base/HighlightModel.cpp | 10 ++-------- .../Browser/Bridge/Base/HighlightModel.h | 6 +++--- .../Interface/Browser/Bridge/Base/RemoveModel.h | 8 ++++---- .../Browser/Bridge/Base/UpdateModel.cpp | 4 ++-- .../Interface/Browser/Bridge/Base/UpdateModel.h | 8 ++++---- .../Interface/Browser/Bridge/Config/GetConfig.h | 2 +- .../Browser/Bridge/Config/UpdateConfig.h | 5 ++--- .../Browser/Bridge/Selection/GetSelection.h | 1 - .../Browser/Bridge/Send/GetSendFilters.h | 1 - .../Browser/Bridge/Send/GetSendSettings.cpp | 6 +++--- .../Browser/Bridge/Send/GetSendSettings.h | 7 +++---- .../Interface/Browser/Bridge/Send/Send.cpp | 8 +------- .../Interface/Browser/Bridge/Send/Send.h | 3 +-- .../Browser/Bridge/Test/GetComplexType.h | 7 +++---- .../Interface/Browser/Bridge/Test/GoAway.cpp | 7 ++++--- .../Connector/Record/Model/CardMover.cpp | 3 ++- .../Connector/Record/Model/CardMover.h | 6 +++--- .../Connector/Record/Model/ModelCard.h | 17 ++++++++++------- 27 files changed, 64 insertions(+), 78 deletions(-) diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Account/GetAccounts.cpp b/SpeckleConnector/Connector/Interface/Browser/Bridge/Account/GetAccounts.cpp index 0c042a8..07872f0 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Account/GetAccounts.cpp +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Account/GetAccounts.cpp @@ -14,7 +14,7 @@ using namespace speckle::utility; namespace { - using WrappedValue = active::serialise::CargoHold>, Vector>; + using WrappedValue = CargoHold>, Vector>; } diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Account/GetAccounts.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Account/GetAccounts.h index 798f492..f079268 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Account/GetAccounts.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Account/GetAccounts.h @@ -6,7 +6,7 @@ namespace connector::interfac::browser::bridge { /*! - JS Function class to retrieve the names of the methods supported by the bridge + JS Function class to retrieve the user's account(s) */ class GetAccounts : public speckle::interfac::browser::bridge::BridgeMethod { public: diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/AddModel.cpp b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/AddModel.cpp index 5df34d0..ca9da48 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/AddModel.cpp +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/AddModel.cpp @@ -2,7 +2,6 @@ #include "Connector/Connector.h" #include "Connector/Database/ModelCardDatabase.h" -#include "Connector/Interface/Browser/Bridge/Base/Arg/DocumentInfo.h" using namespace active::container; using namespace active::serialise; diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/AddModel.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/AddModel.h index b616315..9723578 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/AddModel.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/AddModel.h @@ -8,7 +8,7 @@ namespace connector::interfac::browser::bridge { - ///Argument parameter for a string + ///Argument parameter for a model card using CardHold = active::serialise::CargoHold; ///Argument type for this method using ModelCardEventWrapper = speckle::interfac::browser::bridge::JSArgType; diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/BaseBridge.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/BaseBridge.h index 6fb365a..5e5e248 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/BaseBridge.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/BaseBridge.h @@ -7,7 +7,7 @@ namespace connector::interfac::browser::bridge { /*! - A browser bridge to provide configuration settings + A browser bridge to manage document settings */ class BaseBridge : public speckle::interfac::browser::bridge::BrowserBridge, public speckle::event::ProjectSubscriber { public: diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetConnectorVersion.cpp b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetConnectorVersion.cpp index 5b8a14d..1e3e6e9 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetConnectorVersion.cpp +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetConnectorVersion.cpp @@ -25,13 +25,13 @@ GetConnectorVersion::GetConnectorVersion() : BridgeMethod{"GetConnectorVersion", /*-------------------------------------------------------------------- - Get the host application version + Get the connector software version - return: The application version + return: The connector software version --------------------------------------------------------------------*/ std::unique_ptr GetConnectorVersion::run() const { //Implement other platforms as required - String result{active::utility::String{connector::versionMajor} + "." + active::utility::String{connector::versionMinor} + "." + - active::utility::String{connector::versionPatch}}; + String result{String{connector::versionMajor} + "." + String{connector::versionMinor} + "." + + String{connector::versionPatch}}; return std::make_unique(result); } //GetConnectorVersion::run diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetConnectorVersion.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetConnectorVersion.h index 77a95be..5878765 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetConnectorVersion.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetConnectorVersion.h @@ -8,7 +8,7 @@ namespace connector::interfac::browser::bridge { class ConnectorConfig; /*! - JS Function class to retrieve the names of the methods supported by the bridge + JS Function class to get the connector software version */ class GetConnectorVersion : public speckle::interfac::browser::bridge::BridgeMethod { public: @@ -23,8 +23,8 @@ namespace connector::interfac::browser::bridge { // MARK: - Functions (const) /*! - Get the host application version - @return The application version + Get the connector software version + @return The connector software version */ std::unique_ptr run() const; }; diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetDocumentState.cpp b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetDocumentState.cpp index d57c177..bb334e7 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetDocumentState.cpp +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetDocumentState.cpp @@ -21,9 +21,9 @@ GetDocumentState::GetDocumentState() : BridgeMethod{"GetDocumentState", [&]() { /*-------------------------------------------------------------------- - Get the document info + Get the document model cards - return: The document info + return: The document model cards --------------------------------------------------------------------*/ std::unique_ptr GetDocumentState::run() const { if (auto modelCardDBase = connector()->getModelCardDatabase(); modelCardDBase != nullptr) { diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetDocumentState.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetDocumentState.h index 472b1db..c73ca07 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetDocumentState.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/GetDocumentState.h @@ -6,7 +6,7 @@ namespace connector::interfac::browser::bridge { /*! - JS Function class to retrieve the information about the active document + JS Function class to retrieve model cards stored in the current document */ class GetDocumentState : public speckle::interfac::browser::bridge::BridgeMethod { public: @@ -21,8 +21,8 @@ namespace connector::interfac::browser::bridge { // MARK: - Functions (const) /*! - Get the document info - @return The document info + Get the document model cards + @return The document model cards */ std::unique_ptr run() const; }; diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/HighlightModel.cpp b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/HighlightModel.cpp index 112eb83..b908447 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/HighlightModel.cpp +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/HighlightModel.cpp @@ -10,17 +10,11 @@ #include "Speckle/Database/BIMElementDatabase.h" #include "Speckle/Environment/Project.h" -#include - using namespace speckle::record::element; using namespace connector::interfac::browser::bridge; using namespace connector::record; using namespace speckle::utility; -namespace { - -} - /*-------------------------------------------------------------------- Default constructor --------------------------------------------------------------------*/ @@ -30,9 +24,9 @@ HighlightModel::HighlightModel() : BridgeMethod{"HighlightModel", [&](const Send /*-------------------------------------------------------------------- - Higlight the model card selection + Highlight elements linked to the model card selection - modelCardID: The ID of the model to send + modelCardID: The ID of the target model card --------------------------------------------------------------------*/ void HighlightModel::run(const String& modelCardID) const { // Find the specified model card diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/HighlightModel.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/HighlightModel.h index 0e7f91f..b593463 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/HighlightModel.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/HighlightModel.h @@ -16,7 +16,7 @@ namespace connector::interfac::browser::bridge { using SendArgs = speckle::interfac::browser::bridge::JSArgType; /*! - JS Function class to send a specified model + JS Function class to highlight elements from the selected model card in the open document */ class HighlightModel : public speckle::interfac::browser::bridge::BridgeMethod { public: @@ -31,8 +31,8 @@ namespace connector::interfac::browser::bridge { // MARK: - Functions (const) /*! - Higlight the model card selection - @param modelCardID The ID of the model to send + Highlight elements linked to the model card selection + @param modelCardID The ID of the target model card */ void run(const speckle::utility::String& modelCardID) const; }; diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/RemoveModel.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/RemoveModel.h index d6a900d..f5cde48 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/RemoveModel.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/RemoveModel.h @@ -8,13 +8,13 @@ namespace connector::interfac::browser::bridge { - ///Argument parameter for a string + ///Argument parameter for a model card using CardHold = active::serialise::CargoHold; ///Argument type for this method using ModelCardEventWrapper = speckle::interfac::browser::bridge::JSArgType; /*! - JS Function class to add a model card to the document storage + JS Function class to remove a model card from the document storage */ class RemoveModel : public speckle::interfac::browser::bridge::BridgeMethod { public: @@ -29,8 +29,8 @@ namespace connector::interfac::browser::bridge { // MARK: - Functions (const) /*! - Add a model card to document storage - @param card The card to add + Remove a model card from document storage + @param card The card to remove */ void run(const connector::record::ModelCard& card) const; }; diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/UpdateModel.cpp b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/UpdateModel.cpp index cd845dc..fbab953 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/UpdateModel.cpp +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/UpdateModel.cpp @@ -26,9 +26,9 @@ UpdateModel::UpdateModel() : BridgeMethod{"UpdateModel", [&](const ModelCardEven /*-------------------------------------------------------------------- - Add a model card to document storage + Update a model card in document storage - card: The card to add + card: The card to update --------------------------------------------------------------------*/ void UpdateModel::run(const ModelCard& card) const { if (auto modelCardDBase = connector()->getModelCardDatabase(); modelCardDBase != nullptr) diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/UpdateModel.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/UpdateModel.h index 024151a..9829a21 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/UpdateModel.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Base/UpdateModel.h @@ -8,13 +8,13 @@ namespace connector::interfac::browser::bridge { - ///Argument parameter for a string + ///Argument parameter for a model card using CardHold = active::serialise::CargoHold; ///Argument type for this method using ModelCardEventWrapper = speckle::interfac::browser::bridge::JSArgType; /*! - JS Function class to add a model card to the document storage + JS Function class to update a model card in document storage */ class UpdateModel : public speckle::interfac::browser::bridge::BridgeMethod { public: @@ -29,8 +29,8 @@ namespace connector::interfac::browser::bridge { // MARK: - Functions (const) /*! - Add a model card to document storage - @param card The card to add + Update a model card in document storage + @param card The card to update */ void run(const connector::record::ModelCard& card) const; }; diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Config/GetConfig.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Config/GetConfig.h index ff4eea7..bd9acac 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Config/GetConfig.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Config/GetConfig.h @@ -6,7 +6,7 @@ namespace connector::interfac::browser::bridge { /*! - JS Function class to retrieve the names of the methods supported by the bridge + JS Function class to retrieve the current display configuration settings */ class GetConfig : public speckle::interfac::browser::bridge::BridgeMethod { public: diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Config/UpdateConfig.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Config/UpdateConfig.h index 3cd68fd..1076900 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Config/UpdateConfig.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Config/UpdateConfig.h @@ -9,11 +9,11 @@ namespace connector::interfac::browser::bridge { class ConnectorConfig; - ///Argument for a JS call to update the configuration + ///Argument for a JS call to update the display configuration settings using UpdateArgs = speckle::interfac::browser::bridge::JSArgType; /*! - JS Function class to retrieve the names of the methods supported by the bridge + JS Function class to update the display configuration settings */ class UpdateConfig : public speckle::interfac::browser::bridge::BridgeMethod { public: @@ -22,7 +22,6 @@ namespace connector::interfac::browser::bridge { /*! Constructor - @param bridge The parent bridge object (provides access to bridge methods) */ UpdateConfig(); diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Selection/GetSelection.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Selection/GetSelection.h index 66e827f..7dd06c2 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Selection/GetSelection.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Selection/GetSelection.h @@ -12,7 +12,6 @@ namespace connector::interfac::browser::bridge { /*! Constructor - @param bridge The parent bridge object (provides access to bridge methods) */ GetSelection(); diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/GetSendFilters.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/GetSendFilters.h index 9f52396..c666e8f 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/GetSendFilters.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/GetSendFilters.h @@ -18,7 +18,6 @@ namespace connector::interfac::browser::bridge { /*! Constructor - @param bridge The parent bridge object (provides access to bridge methods) */ GetSendFilters(); diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/GetSendSettings.cpp b/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/GetSendSettings.cpp index 96aa118..5616a40 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/GetSendSettings.cpp +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/GetSendSettings.cpp @@ -13,7 +13,7 @@ using namespace speckle::utility; namespace { - using WrappedValue = active::serialise::CargoHold, PackageWrap>, Vector>; + using WrappedValue = CargoHold, PackageWrap>, Vector>; } @@ -26,9 +26,9 @@ GetSendSettings::GetSendSettings() : BridgeMethod{"GetSendSettings", [&]() { /*-------------------------------------------------------------------- - Get the send filters + Get send settings relevant to the host BIM application - return: The send filters + return: The send settings --------------------------------------------------------------------*/ std::unique_ptr GetSendSettings::run() const { auto filters = std::make_unique>(); diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/GetSendSettings.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/GetSendSettings.h index 4823fc8..c57d274 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/GetSendSettings.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/GetSendSettings.h @@ -9,7 +9,7 @@ namespace connector::interfac::browser::bridge { class ConnectorConfig; /*! - JS Function class to retrieve the send filters + JS Function class to retrieve the send settings relevant to the host BIM application */ class GetSendSettings : public speckle::interfac::browser::bridge::BridgeMethod { public: @@ -18,15 +18,14 @@ namespace connector::interfac::browser::bridge { /*! Constructor - @param bridge The parent bridge object (provides access to bridge methods) */ GetSendSettings(); // MARK: - Functions (const) /*! - Get the send filters - @return The send filters + Get send settings relevant to the host BIM application + @return The send settings */ std::unique_ptr run() const; }; diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/Send.cpp b/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/Send.cpp index 279fd23..82bb4a2 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/Send.cpp +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/Send.cpp @@ -20,8 +20,6 @@ #include "Speckle/Record/Element/Element.h" using namespace speckle::record::element; -#include - using namespace active::serialise; using namespace connector::interfac::browser::bridge; using namespace connector::record; @@ -29,10 +27,6 @@ using namespace speckle::database; using namespace speckle::serialise; using namespace speckle::utility; -namespace { - -} - /*-------------------------------------------------------------------- Default constructor --------------------------------------------------------------------*/ @@ -44,7 +38,7 @@ Send::Send() : BridgeMethod{"Send", [&](const SendArgs& args) { /*-------------------------------------------------------------------- Send a specified model - modelCardID: The ID of the model to send + modelCardID: The ID of the model card identifying the objects to send --------------------------------------------------------------------*/ void Send::run(const String& modelCardID) const { //Find the specified model card diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/Send.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/Send.h index 7cead55..7c3cb44 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/Send.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Send/Send.h @@ -25,7 +25,6 @@ namespace connector::interfac::browser::bridge { /*! Constructor - @param bridge The parent bridge object (provides access to bridge methods) */ Send(); @@ -33,7 +32,7 @@ namespace connector::interfac::browser::bridge { /*! Send a specified model - @param modelCardID The ID of the model to send + @param modelCardID The ID of the model card identifying the objects to send */ void run(const speckle::utility::String& modelCardID) const; }; diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Test/GetComplexType.h b/SpeckleConnector/Connector/Interface/Browser/Bridge/Test/GetComplexType.h index 9e9a532..742ad20 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Test/GetComplexType.h +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Test/GetComplexType.h @@ -1,5 +1,5 @@ -#ifndef CONNECTOR_INTERFACE_BRIDGE_GET_CONFIG -#define CONNECTOR_INTERFACE_BRIDGE_GET_CONFIG +#ifndef CONNECTOR_INTERFACE_BRIDGE_GET_COMPLEX_TYPE +#define CONNECTOR_INTERFACE_BRIDGE_GET_COMPLEX_TYPE #include "Speckle/Interface/Browser/Bridge/BridgeMethod.h" @@ -15,7 +15,6 @@ namespace connector::interfac::browser::bridge { /*! Constructor - @param bridge The parent bridge object (provides access to bridge methods) */ GetComplexType(); @@ -30,4 +29,4 @@ namespace connector::interfac::browser::bridge { } -#endif //CONNECTOR_INTERFACE_BRIDGE_GET_CONFIG +#endif //CONNECTOR_INTERFACE_BRIDGE_GET_COMPLEX_TYPE diff --git a/SpeckleConnector/Connector/Interface/Browser/Bridge/Test/GoAway.cpp b/SpeckleConnector/Connector/Interface/Browser/Bridge/Test/GoAway.cpp index 69c0a90..3693d41 100644 --- a/SpeckleConnector/Connector/Interface/Browser/Bridge/Test/GoAway.cpp +++ b/SpeckleConnector/Connector/Interface/Browser/Bridge/Test/GoAway.cpp @@ -1,8 +1,9 @@ #include "Connector/Interface/Browser/Bridge/Test/GoAway.h" -using namespace connector::interfac::browser::bridge; +#include "Speckle/Environment/Platform.h" -#include +using namespace connector::interfac::browser::bridge; +using namespace speckle::environment; /*-------------------------------------------------------------------- Default constructor @@ -16,5 +17,5 @@ GoAway::GoAway() : BridgeMethod{"GoAway", [&]() { Write a message to the console --------------------------------------------------------------------*/ void GoAway::run() const { - std::cout << "Okay, going away."; + platform()->writeToConsole("Okay, going away."); } //GoAway::run diff --git a/SpeckleConnector/Connector/Record/Model/CardMover.cpp b/SpeckleConnector/Connector/Record/Model/CardMover.cpp index fdf8103..f793fe1 100644 --- a/SpeckleConnector/Connector/Record/Model/CardMover.cpp +++ b/SpeckleConnector/Connector/Record/Model/CardMover.cpp @@ -3,6 +3,7 @@ #include "Connector/Record/Model/ReceiverModelCard.h" #include "Connector/Record/Model/SenderModelCard.h" +using namespace active::serialise; using namespace connector::record; namespace { @@ -32,7 +33,7 @@ namespace { } ///The handler for model card packages -std::shared_ptr CardMover::m_handler = std::make_shared(attributeTag); +std::shared_ptr CardMover::m_handler = std::make_shared(attributeTag); /*-------------------------------------------------------------------- diff --git a/SpeckleConnector/Connector/Record/Model/CardMover.h b/SpeckleConnector/Connector/Record/Model/CardMover.h index 62bfe7c..09ebbb2 100644 --- a/SpeckleConnector/Connector/Record/Model/CardMover.h +++ b/SpeckleConnector/Connector/Record/Model/CardMover.h @@ -6,10 +6,10 @@ namespace connector::record { /*! - Wrapper to box/unbox objects during (de)serialisation, including reading/writing a specified attribute to determine object type + Wrapper to box/unbox model cards during (de)serialisation - Note that a derived class could also define the package handler, allowing the wrapper to be created via a default constructor that is - automatically bound to a set of internally defined object types + Model cards are polymorphic - this class ensures the type information is included when a card is serialised + and the correct object type is constructed on deserialisation */ class CardMover : public active::serialise::Mover { public: diff --git a/SpeckleConnector/Connector/Record/Model/ModelCard.h b/SpeckleConnector/Connector/Record/Model/ModelCard.h index 587ea72..ca3eadd 100644 --- a/SpeckleConnector/Connector/Record/Model/ModelCard.h +++ b/SpeckleConnector/Connector/Record/Model/ModelCard.h @@ -11,7 +11,10 @@ namespace connector::record { /*! - A connector send filter + Base class for a Speckle model card + + A model card captures key information about a model submitted to a Speckle server, e.g. the model ID, the target server + and account, and any settings or filters applicable to the host BIM application and open document */ class ModelCard : public speckle::database::Record { public: @@ -60,13 +63,13 @@ namespace connector::record { */ const speckle::utility::String& getModelID() const { return m_modelID; } /*! - Get the setting type - @return The setting type + Get the ID of the active BIM project + @return The ID of the active BIM project */ const speckle::utility::String& getProjectID() const { return m_projectID; } /*! - Get the setting type - @return The setting type + Get the user account ID + @return The user account ID */ const speckle::utility::String& getAccountID() const { return m_accountID; } /*! @@ -75,8 +78,8 @@ namespace connector::record { */ const speckle::utility::String& getMessage() const { return m_message; } /*! - Get the setting type - @return The setting type + Get the server URL + @return The server URL */ const speckle::utility::String& getServerURL() const { return m_serverURL; } /*!