diff --git a/scripts/filter.cpp.in b/scripts/filter.cpp.in index be68121a82..26f7ca9abf 100644 --- a/scripts/filter.cpp.in +++ b/scripts/filter.cpp.in @@ -45,7 +45,7 @@ IFilter::UniquePointer @FILTER_NAME@::clone() const return std::make_unique<@FILTER_NAME@>(); } -IFilter::PreflightResult @FILTER_NAME@::preflightImpl(const DataStructure& data, const Arguments& args) const +IFilter::PreflightResult @FILTER_NAME@::preflightImpl(const DataStructure& dataStructure, const Arguments& args) const { /**************************************************************************** * Write any preflight sanity checking codes in this function @@ -53,7 +53,7 @@ IFilter::PreflightResult @FILTER_NAME@::preflightImpl(const DataStructure& data, return {}; } -Result<> @FILTER_NAME@::executeImpl(DataStructure& data, const Arguments& args) const +Result<> @FILTER_NAME@::executeImpl(DataStructure& dataStructure, const Arguments& args) const { /**************************************************************************** * Write your algorithm implementation in this function diff --git a/scripts/filter.hpp.in b/scripts/filter.hpp.in index 7ab4a4d810..153ebabf2d 100644 --- a/scripts/filter.hpp.in +++ b/scripts/filter.hpp.in @@ -55,7 +55,7 @@ protected: * @param args * @return */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args) const override; /** * @brief @@ -63,7 +63,7 @@ protected: * @param args * @return */ - Result<> executeImpl(DataStructure& data, const Arguments& args) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args) const override; }; } // namespace nx::core diff --git a/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImageReaderFilter.hpp b/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImageReaderFilter.hpp index 6cd2cb6f36..d15980d988 100644 --- a/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImageReaderFilter.hpp +++ b/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImageReaderFilter.hpp @@ -107,7 +107,8 @@ class ITKIMAGEPROCESSING_EXPORT ITKImageReaderFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImageWriterFilter.hpp b/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImageWriterFilter.hpp index d7372f39d5..8b5800ed3b 100644 --- a/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImageWriterFilter.hpp +++ b/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImageWriterFilter.hpp @@ -103,7 +103,8 @@ class ITKIMAGEPROCESSING_EXPORT ITKImageWriterFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImportFijiMontageFilter.hpp b/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImportFijiMontageFilter.hpp index dbcb6cee2c..b356cdd365 100644 --- a/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImportFijiMontageFilter.hpp +++ b/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImportFijiMontageFilter.hpp @@ -103,7 +103,8 @@ class ITKIMAGEPROCESSING_EXPORT ITKImportFijiMontageFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; private: int32 m_InstanceId; diff --git a/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImportImageStackFilter.hpp b/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImportImageStackFilter.hpp index 4c4408a5bb..b639a95560 100644 --- a/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImportImageStackFilter.hpp +++ b/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKImportImageStackFilter.hpp @@ -102,7 +102,8 @@ class ITKIMAGEPROCESSING_EXPORT ITKImportImageStackFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKMhaFileReaderFilter.hpp b/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKMhaFileReaderFilter.hpp index 6b5bb580ad..2c0a40d0cc 100644 --- a/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKMhaFileReaderFilter.hpp +++ b/src/Plugins/ITKImageProcessing/src/ITKImageProcessing/Filters/ITKMhaFileReaderFilter.hpp @@ -88,7 +88,8 @@ class ITKIMAGEPROCESSING_EXPORT ITKMhaFileReaderFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/AlignSectionsMisorientationFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/AlignSectionsMisorientationFilter.hpp index 5e11327272..7169e0c753 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/AlignSectionsMisorientationFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/AlignSectionsMisorientationFilter.hpp @@ -106,7 +106,8 @@ class ORIENTATIONANALYSIS_EXPORT AlignSectionsMisorientationFilter : public IFil * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/AlignSectionsMutualInformationFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/AlignSectionsMutualInformationFilter.hpp index dcb212fd89..4b53255083 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/AlignSectionsMutualInformationFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/AlignSectionsMutualInformationFilter.hpp @@ -104,7 +104,8 @@ class ORIENTATIONANALYSIS_EXPORT AlignSectionsMutualInformationFilter : public I * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/BadDataNeighborOrientationCheckFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/BadDataNeighborOrientationCheckFilter.hpp index 77e9da9f0c..b39f4ee47e 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/BadDataNeighborOrientationCheckFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/BadDataNeighborOrientationCheckFilter.hpp @@ -101,7 +101,8 @@ class ORIENTATIONANALYSIS_EXPORT BadDataNeighborOrientationCheckFilter : public * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/CAxisSegmentFeaturesFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/CAxisSegmentFeaturesFilter.hpp index 29751809cd..aa24b9ede3 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/CAxisSegmentFeaturesFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/CAxisSegmentFeaturesFilter.hpp @@ -95,7 +95,7 @@ class ORIENTATIONANALYSIS_EXPORT CAxisSegmentFeaturesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -105,7 +105,8 @@ class ORIENTATIONANALYSIS_EXPORT CAxisSegmentFeaturesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ConvertHexGridToSquareGridFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ConvertHexGridToSquareGridFilter.hpp index d57e198654..2a2bd082d5 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ConvertHexGridToSquareGridFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ConvertHexGridToSquareGridFilter.hpp @@ -93,7 +93,8 @@ class ORIENTATIONANALYSIS_EXPORT ConvertHexGridToSquareGridFilter : public IFilt * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; private: int32 m_InstanceId; diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ConvertOrientationsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ConvertOrientationsFilter.hpp index 071fbf7588..e0e3ba67dd 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ConvertOrientationsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ConvertOrientationsFilter.hpp @@ -109,7 +109,8 @@ class ORIENTATIONANALYSIS_EXPORT ConvertOrientationsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ConvertQuaternionFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ConvertQuaternionFilter.hpp index 0a293b9f40..f079db7a77 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ConvertQuaternionFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ConvertQuaternionFilter.hpp @@ -98,7 +98,8 @@ class ORIENTATIONANALYSIS_EXPORT ConvertQuaternionFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/CreateEnsembleInfoFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/CreateEnsembleInfoFilter.hpp index b8fe1785eb..eb6b20884b 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/CreateEnsembleInfoFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/CreateEnsembleInfoFilter.hpp @@ -99,7 +99,8 @@ class ORIENTATIONANALYSIS_EXPORT CreateEnsembleInfoFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/EBSDSegmentFeaturesFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/EBSDSegmentFeaturesFilter.hpp index 4c06581773..0b8d2dfd1b 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/EBSDSegmentFeaturesFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/EBSDSegmentFeaturesFilter.hpp @@ -105,7 +105,8 @@ class ORIENTATIONANALYSIS_EXPORT EBSDSegmentFeaturesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/EbsdToH5EbsdFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/EbsdToH5EbsdFilter.hpp index 8b78860712..a12cde467f 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/EbsdToH5EbsdFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/EbsdToH5EbsdFilter.hpp @@ -92,7 +92,8 @@ class ORIENTATIONANALYSIS_EXPORT EbsdToH5EbsdFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindAvgCAxesFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindAvgCAxesFilter.hpp index e435cec850..8308e377ac 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindAvgCAxesFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindAvgCAxesFilter.hpp @@ -90,7 +90,7 @@ class ORIENTATIONANALYSIS_EXPORT FindAvgCAxesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -100,7 +100,8 @@ class ORIENTATIONANALYSIS_EXPORT FindAvgCAxesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindAvgOrientationsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindAvgOrientationsFilter.hpp index fe907f4457..4b92a1b5a2 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindAvgOrientationsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindAvgOrientationsFilter.hpp @@ -101,7 +101,8 @@ class ORIENTATIONANALYSIS_EXPORT FindAvgOrientationsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindBoundaryStrengthsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindBoundaryStrengthsFilter.hpp index c8b04c6aec..09d31b97d4 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindBoundaryStrengthsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindBoundaryStrengthsFilter.hpp @@ -93,7 +93,7 @@ class ORIENTATIONANALYSIS_EXPORT FindBoundaryStrengthsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -103,7 +103,8 @@ class ORIENTATIONANALYSIS_EXPORT FindBoundaryStrengthsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindCAxisLocationsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindCAxisLocationsFilter.hpp index 54d8275027..c90499f45e 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindCAxisLocationsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindCAxisLocationsFilter.hpp @@ -89,7 +89,7 @@ class ORIENTATIONANALYSIS_EXPORT FindCAxisLocationsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -99,7 +99,8 @@ class ORIENTATIONANALYSIS_EXPORT FindCAxisLocationsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindFeatureNeighborCAxisMisalignmentsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindFeatureNeighborCAxisMisalignmentsFilter.hpp index bdd67bbac4..a5cfe3bbeb 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindFeatureNeighborCAxisMisalignmentsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindFeatureNeighborCAxisMisalignmentsFilter.hpp @@ -91,7 +91,7 @@ class ORIENTATIONANALYSIS_EXPORT FindFeatureNeighborCAxisMisalignmentsFilter : p * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -101,7 +101,8 @@ class ORIENTATIONANALYSIS_EXPORT FindFeatureNeighborCAxisMisalignmentsFilter : p * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindFeatureReferenceCAxisMisorientationsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindFeatureReferenceCAxisMisorientationsFilter.hpp index d5de57cf4d..46abff9a63 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindFeatureReferenceCAxisMisorientationsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindFeatureReferenceCAxisMisorientationsFilter.hpp @@ -93,7 +93,7 @@ class ORIENTATIONANALYSIS_EXPORT FindFeatureReferenceCAxisMisorientationsFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -103,7 +103,8 @@ class ORIENTATIONANALYSIS_EXPORT FindFeatureReferenceCAxisMisorientationsFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindFeatureReferenceMisorientationsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindFeatureReferenceMisorientationsFilter.hpp index 59942593fb..0609cfaf9b 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindFeatureReferenceMisorientationsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindFeatureReferenceMisorientationsFilter.hpp @@ -104,7 +104,8 @@ class ORIENTATIONANALYSIS_EXPORT FindFeatureReferenceMisorientationsFilter : pub * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindGBCDFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindGBCDFilter.hpp index e026bba418..2e20612ba6 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindGBCDFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindGBCDFilter.hpp @@ -104,7 +104,8 @@ class ORIENTATIONANALYSIS_EXPORT FindGBCDFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindGBCDMetricBasedFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindGBCDMetricBasedFilter.hpp index 8c97cc1d58..2df32fb07f 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindGBCDMetricBasedFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindGBCDMetricBasedFilter.hpp @@ -101,7 +101,7 @@ class ORIENTATIONANALYSIS_EXPORT FindGBCDMetricBasedFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -111,7 +111,8 @@ class ORIENTATIONANALYSIS_EXPORT FindGBCDMetricBasedFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindGBPDMetricBasedFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindGBPDMetricBasedFilter.hpp index cb08ea097c..a87ac2b71e 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindGBPDMetricBasedFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindGBPDMetricBasedFilter.hpp @@ -100,7 +100,7 @@ class ORIENTATIONANALYSIS_EXPORT FindGBPDMetricBasedFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -110,7 +110,8 @@ class ORIENTATIONANALYSIS_EXPORT FindGBPDMetricBasedFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindKernelAvgMisorientationsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindKernelAvgMisorientationsFilter.hpp index 161a7e2271..43377fb155 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindKernelAvgMisorientationsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindKernelAvgMisorientationsFilter.hpp @@ -101,7 +101,8 @@ class ORIENTATIONANALYSIS_EXPORT FindKernelAvgMisorientationsFilter : public IFi * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindMisorientationsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindMisorientationsFilter.hpp index 6520335f66..2c04648c23 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindMisorientationsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindMisorientationsFilter.hpp @@ -101,7 +101,8 @@ class ORIENTATIONANALYSIS_EXPORT FindMisorientationsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindSchmidsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindSchmidsFilter.hpp index 4585a42fe5..cdf56f3a00 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindSchmidsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindSchmidsFilter.hpp @@ -107,7 +107,8 @@ class ORIENTATIONANALYSIS_EXPORT FindSchmidsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindShapesFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindShapesFilter.hpp index b54b7f21df..ffe41d7f68 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindShapesFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindShapesFilter.hpp @@ -103,7 +103,8 @@ class ORIENTATIONANALYSIS_EXPORT FindShapesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindSlipTransmissionMetricsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindSlipTransmissionMetricsFilter.hpp index fb6544ac08..3115b6e6a8 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindSlipTransmissionMetricsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindSlipTransmissionMetricsFilter.hpp @@ -92,7 +92,7 @@ class ORIENTATIONANALYSIS_EXPORT FindSlipTransmissionMetricsFilter : public IFil * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -102,7 +102,8 @@ class ORIENTATIONANALYSIS_EXPORT FindSlipTransmissionMetricsFilter : public IFil * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindTriangleGeomShapesFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindTriangleGeomShapesFilter.hpp index 3f5b26acbd..f1b053caba 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindTriangleGeomShapesFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/FindTriangleGeomShapesFilter.hpp @@ -96,7 +96,8 @@ class ORIENTATIONANALYSIS_EXPORT FindTriangleGeomShapesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateFZQuaternionsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateFZQuaternionsFilter.hpp index b1dd496f84..cf2bccb65f 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateFZQuaternionsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateFZQuaternionsFilter.hpp @@ -100,7 +100,8 @@ class ORIENTATIONANALYSIS_EXPORT GenerateFZQuaternionsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateFaceIPFColoringFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateFaceIPFColoringFilter.hpp index bfd258a0d5..43b73e963a 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateFaceIPFColoringFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateFaceIPFColoringFilter.hpp @@ -100,7 +100,8 @@ class ORIENTATIONANALYSIS_EXPORT GenerateFaceIPFColoringFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateFeatureFaceMisorientationFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateFeatureFaceMisorientationFilter.hpp index 1dfddc8fe1..d213c39aa1 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateFeatureFaceMisorientationFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateFeatureFaceMisorientationFilter.hpp @@ -100,7 +100,8 @@ class ORIENTATIONANALYSIS_EXPORT GenerateFeatureFaceMisorientationFilter : publi * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateGBCDPoleFigureFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateGBCDPoleFigureFilter.hpp index 3e69bbbc4a..aed56b03e4 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateGBCDPoleFigureFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateGBCDPoleFigureFilter.hpp @@ -102,7 +102,8 @@ class ORIENTATIONANALYSIS_EXPORT GenerateGBCDPoleFigureFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateIPFColorsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateIPFColorsFilter.hpp index 5a56c9e6e1..a6e55de5ef 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateIPFColorsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateIPFColorsFilter.hpp @@ -101,7 +101,8 @@ class ORIENTATIONANALYSIS_EXPORT GenerateIPFColorsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateQuaternionConjugateFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateQuaternionConjugateFilter.hpp index 2ad526bc9b..1149ecefc3 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateQuaternionConjugateFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/GenerateQuaternionConjugateFilter.hpp @@ -97,7 +97,8 @@ class ORIENTATIONANALYSIS_EXPORT GenerateQuaternionConjugateFilter : public IFil * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/MergeTwinsFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/MergeTwinsFilter.hpp index 78673079b8..2969dc7829 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/MergeTwinsFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/MergeTwinsFilter.hpp @@ -110,7 +110,8 @@ class ORIENTATIONANALYSIS_EXPORT MergeTwinsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/NeighborOrientationCorrelationFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/NeighborOrientationCorrelationFilter.hpp index cd3d062b07..2079e981e7 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/NeighborOrientationCorrelationFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/NeighborOrientationCorrelationFilter.hpp @@ -103,7 +103,8 @@ class ORIENTATIONANALYSIS_EXPORT NeighborOrientationCorrelationFilter : public I * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadAngDataFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadAngDataFilter.hpp index abed787991..4c1155d44f 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadAngDataFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadAngDataFilter.hpp @@ -104,7 +104,8 @@ class ORIENTATIONANALYSIS_EXPORT ReadAngDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; private: std::shared_ptr m_AngDataPrivate; diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadCtfDataFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadCtfDataFilter.hpp index 776bd649f1..b2268873d1 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadCtfDataFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadCtfDataFilter.hpp @@ -101,7 +101,8 @@ class ORIENTATIONANALYSIS_EXPORT ReadCtfDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadEnsembleInfoFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadEnsembleInfoFilter.hpp index c134fb2076..9c49850031 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadEnsembleInfoFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadEnsembleInfoFilter.hpp @@ -89,7 +89,7 @@ class ORIENTATIONANALYSIS_EXPORT ReadEnsembleInfoFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -99,7 +99,8 @@ class ORIENTATIONANALYSIS_EXPORT ReadEnsembleInfoFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5EbsdFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5EbsdFilter.hpp index a0e1d01f81..dd83ecaf3d 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5EbsdFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5EbsdFilter.hpp @@ -98,7 +98,8 @@ class ORIENTATIONANALYSIS_EXPORT ReadH5EbsdFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5EspritDataFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5EspritDataFilter.hpp index 2d6fdfdd70..80aeaf9e36 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5EspritDataFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5EspritDataFilter.hpp @@ -92,7 +92,7 @@ class ORIENTATIONANALYSIS_EXPORT ReadH5EspritDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -102,7 +102,8 @@ class ORIENTATIONANALYSIS_EXPORT ReadH5EspritDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5OimDataFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5OimDataFilter.hpp index 9882963e57..f1c83e0f07 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5OimDataFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5OimDataFilter.hpp @@ -92,7 +92,7 @@ class ORIENTATIONANALYSIS_EXPORT ReadH5OimDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -102,7 +102,8 @@ class ORIENTATIONANALYSIS_EXPORT ReadH5OimDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5OinaDataFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5OinaDataFilter.hpp index 5d03665b3a..c147dd00d3 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5OinaDataFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/ReadH5OinaDataFilter.hpp @@ -96,7 +96,8 @@ class ORIENTATIONANALYSIS_EXPORT ReadH5OinaDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/RodriguesConvertorFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/RodriguesConvertorFilter.hpp index 402803c86b..dddb6c62d2 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/RodriguesConvertorFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/RodriguesConvertorFilter.hpp @@ -97,7 +97,8 @@ class ORIENTATIONANALYSIS_EXPORT RodriguesConvertorFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/RotateEulerRefFrameFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/RotateEulerRefFrameFilter.hpp index abe882798c..a2fbe14eca 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/RotateEulerRefFrameFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/RotateEulerRefFrameFilter.hpp @@ -96,7 +96,8 @@ class ORIENTATIONANALYSIS_EXPORT RotateEulerRefFrameFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteGBCDGMTFileFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteGBCDGMTFileFilter.hpp index d254d6312e..35707d5e49 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteGBCDGMTFileFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteGBCDGMTFileFilter.hpp @@ -99,7 +99,8 @@ class ORIENTATIONANALYSIS_EXPORT WriteGBCDGMTFileFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteGBCDTriangleDataFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteGBCDTriangleDataFilter.hpp index f4292ec5ba..81943048ed 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteGBCDTriangleDataFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteGBCDTriangleDataFilter.hpp @@ -99,7 +99,8 @@ class ORIENTATIONANALYSIS_EXPORT WriteGBCDTriangleDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteINLFileFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteINLFileFilter.hpp index a7649213d3..013602a27c 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteINLFileFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteINLFileFilter.hpp @@ -92,7 +92,7 @@ class ORIENTATIONANALYSIS_EXPORT WriteINLFileFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -102,7 +102,8 @@ class ORIENTATIONANALYSIS_EXPORT WriteINLFileFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WritePoleFigureFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WritePoleFigureFilter.hpp index cebb39adc1..6ddbf31cf0 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WritePoleFigureFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WritePoleFigureFilter.hpp @@ -102,7 +102,7 @@ class ORIENTATIONANALYSIS_EXPORT WritePoleFigureFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -112,7 +112,8 @@ class ORIENTATIONANALYSIS_EXPORT WritePoleFigureFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteStatsGenOdfAngleFileFilter.hpp b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteStatsGenOdfAngleFileFilter.hpp index 983c00fdbf..645472ae23 100644 --- a/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteStatsGenOdfAngleFileFilter.hpp +++ b/src/Plugins/OrientationAnalysis/src/OrientationAnalysis/Filters/WriteStatsGenOdfAngleFileFilter.hpp @@ -99,7 +99,7 @@ class ORIENTATIONANALYSIS_EXPORT WriteStatsGenOdfAngleFileFilter : public IFilte * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -109,7 +109,8 @@ class ORIENTATIONANALYSIS_EXPORT WriteStatsGenOdfAngleFileFilter : public IFilte * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AddBadDataFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AddBadDataFilter.hpp index 0e51fab103..7d7f4ac237 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AddBadDataFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AddBadDataFilter.hpp @@ -93,7 +93,7 @@ class SIMPLNXCORE_EXPORT AddBadDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -103,7 +103,8 @@ class SIMPLNXCORE_EXPORT AddBadDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/LaplacianSmoothing.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/LaplacianSmoothing.hpp index 7b13b4d1ab..1742b11030 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/LaplacianSmoothing.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/LaplacianSmoothing.hpp @@ -32,7 +32,7 @@ struct SIMPLNXCORE_EXPORT LaplacianSmoothingInputValues class SIMPLNXCORE_EXPORT LaplacianSmoothing { public: - LaplacianSmoothing(DataStructure& data, LaplacianSmoothingInputValues* inputValues, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler); + LaplacianSmoothing(DataStructure& dataStructure, LaplacianSmoothingInputValues* inputValues, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler); ~LaplacianSmoothing() noexcept; LaplacianSmoothing(const LaplacianSmoothing&) = delete; diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ReadRawBinary.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ReadRawBinary.hpp index 5a5dfb2fce..b3f0492d0b 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ReadRawBinary.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ReadRawBinary.hpp @@ -22,7 +22,7 @@ struct SIMPLNXCORE_EXPORT ReadRawBinaryInputValues class SIMPLNXCORE_EXPORT ReadRawBinary { public: - ReadRawBinary(DataStructure& data, const ReadRawBinaryInputValues& inputValues, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler); + ReadRawBinary(DataStructure& dataStructure, const ReadRawBinaryInputValues& inputValues, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler); ~ReadRawBinary() noexcept; ReadRawBinary(const ReadRawBinary&) = delete; diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ReadStlFile.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ReadStlFile.cpp index 68d7d44f43..549c55a69e 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ReadStlFile.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ReadStlFile.cpp @@ -94,9 +94,9 @@ std::array CreateMinMaxCoords() } // End anonymous namespace -ReadStlFile::ReadStlFile(DataStructure& data, fs::path stlFilePath, const DataPath& geometryPath, const DataPath& faceGroupPath, const DataPath& faceNormalsDataPath, bool scaleOutput, +ReadStlFile::ReadStlFile(DataStructure& dataStructure, fs::path stlFilePath, const DataPath& geometryPath, const DataPath& faceGroupPath, const DataPath& faceNormalsDataPath, bool scaleOutput, float32 scaleFactor, const std::atomic_bool& shouldCancel) -: m_DataStructure(data) +: m_DataStructure(dataStructure) , m_FilePath(std::move(stlFilePath)) , m_GeometryDataPath(geometryPath) , m_FaceGroupPath(faceGroupPath) diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ReadStlFile.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ReadStlFile.hpp index 7b6693fd68..2505aaa43c 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ReadStlFile.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ReadStlFile.hpp @@ -21,8 +21,8 @@ namespace nx::core class SIMPLNXCORE_EXPORT ReadStlFile { public: - ReadStlFile(DataStructure& data, fs::path stlFilePath, const DataPath& geometryPath, const DataPath& faceGroupPath, const DataPath& faceNormalsDataPath, bool scaleOutput, float32 scaleFactor, - const std::atomic_bool& shouldCancel); + ReadStlFile(DataStructure& dataStructure, fs::path stlFilePath, const DataPath& geometryPath, const DataPath& faceGroupPath, const DataPath& faceNormalsDataPath, bool scaleOutput, + float32 scaleFactor, const std::atomic_bool& shouldCancel); ~ReadStlFile() noexcept; ReadStlFile(const ReadStlFile&) = delete; diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ScalarSegmentFeatures.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ScalarSegmentFeatures.hpp index da3fe7f6df..513349d339 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ScalarSegmentFeatures.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/Algorithms/ScalarSegmentFeatures.hpp @@ -39,7 +39,7 @@ class SIMPLNXCORE_EXPORT ScalarSegmentFeatures : public SegmentFeatures using FeatureIdsArrayType = Int32Array; using GoodVoxelsArrayType = BoolArray; - ScalarSegmentFeatures(DataStructure& data, ScalarSegmentFeaturesInputValues* inputValues, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler); + ScalarSegmentFeatures(DataStructure& dataStructure, ScalarSegmentFeaturesInputValues* inputValues, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler); ~ScalarSegmentFeatures() noexcept; ScalarSegmentFeatures(const ScalarSegmentFeatures&) = delete; diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignGeometriesFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignGeometriesFilter.cpp index 5025e08f8d..7bed477e93 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignGeometriesFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignGeometriesFilter.cpp @@ -443,15 +443,15 @@ IFilter::PreflightResult AlignGeometriesFilter::preflightImpl(const DataStructur } //------------------------------------------------------------------------------ -Result<> AlignGeometriesFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> AlignGeometriesFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto movingGeometryPath = args.value(k_MovingGeometry_Key); auto targetGeometryPath = args.value(k_TargetGeometry_Key); auto alignmentType = args.value(k_AlignmentType_Key); - auto& moving = data.getDataRefAs(movingGeometryPath); - auto& target = data.getDataRefAs(targetGeometryPath); + auto& moving = dataStructure.getDataRefAs(movingGeometryPath); + auto& target = dataStructure.getDataRefAs(targetGeometryPath); if(alignmentType == 0) { diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignGeometriesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignGeometriesFilter.hpp index 0bf097c092..89b7049be8 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignGeometriesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignGeometriesFilter.hpp @@ -82,7 +82,7 @@ class SIMPLNXCORE_EXPORT AlignGeometriesFilter : public IFilter * @param messageHandler * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief @@ -92,7 +92,8 @@ class SIMPLNXCORE_EXPORT AlignGeometriesFilter : public IFilter * @param messageHandler * @return Result<> */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignSectionsFeatureCentroidFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignSectionsFeatureCentroidFilter.hpp index f69a48c860..d11c4ec7e9 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignSectionsFeatureCentroidFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignSectionsFeatureCentroidFilter.hpp @@ -102,7 +102,8 @@ class SIMPLNXCORE_EXPORT AlignSectionsFeatureCentroidFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignSectionsListFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignSectionsListFilter.hpp index 14646711c9..90d45a261a 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignSectionsListFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AlignSectionsListFilter.hpp @@ -87,7 +87,7 @@ class SIMPLNXCORE_EXPORT AlignSectionsListFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -97,7 +97,8 @@ class SIMPLNXCORE_EXPORT AlignSectionsListFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AppendImageGeometryZSliceFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AppendImageGeometryZSliceFilter.hpp index 6aa834bb02..55af3b74d5 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AppendImageGeometryZSliceFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/AppendImageGeometryZSliceFilter.hpp @@ -89,7 +89,7 @@ class SIMPLNXCORE_EXPORT AppendImageGeometryZSliceFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -99,7 +99,8 @@ class SIMPLNXCORE_EXPORT AppendImageGeometryZSliceFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ApplyTransformationToGeometryFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ApplyTransformationToGeometryFilter.hpp index 51c617d667..60242633b3 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ApplyTransformationToGeometryFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ApplyTransformationToGeometryFilter.hpp @@ -94,7 +94,7 @@ class SIMPLNXCORE_EXPORT ApplyTransformationToGeometryFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -104,7 +104,8 @@ class SIMPLNXCORE_EXPORT ApplyTransformationToGeometryFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ApproximatePointCloudHullFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ApproximatePointCloudHullFilter.cpp index e5dde36907..9195ca0ef5 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ApproximatePointCloudHullFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ApproximatePointCloudHullFilter.cpp @@ -80,7 +80,7 @@ IFilter::UniquePointer ApproximatePointCloudHullFilter::clone() const } //------------------------------------------------------------------------------ -IFilter::PreflightResult ApproximatePointCloudHullFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, +IFilter::PreflightResult ApproximatePointCloudHullFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto gridResolution = args.value>(k_GridResolution_Key); @@ -100,7 +100,7 @@ IFilter::PreflightResult ApproximatePointCloudHullFilter::preflightImpl(const Da return {nonstd::make_unexpected(std::vector{Error{-11001, ss}})}; } - auto vertexGeom = data.getDataAs(vertexGeomPath); + auto vertexGeom = dataStructure.getDataAs(vertexGeomPath); int64 numVertices = vertexGeom->getNumberOfVertices(); auto action = std::make_unique(hullVertexGeomPath, numVertices, INodeGeometry0D::k_VertexDataName, CreateVertexGeometryAction::k_SharedVertexListName); @@ -112,7 +112,7 @@ IFilter::PreflightResult ApproximatePointCloudHullFilter::preflightImpl(const Da } //------------------------------------------------------------------------------ -Result<> ApproximatePointCloudHullFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> ApproximatePointCloudHullFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto gridResolution = args.value>(k_GridResolution_Key); @@ -122,7 +122,7 @@ Result<> ApproximatePointCloudHullFilter::executeImpl(DataStructure& data, const float inverseResolution[3] = {1.0f / gridResolution[0], 1.0f / gridResolution[1], 1.0f / gridResolution[2]}; - auto* source = data.getDataAs(vertexGeomPath); + auto* source = dataStructure.getDataAs(vertexGeomPath); auto* verts = source->getVertices(); DataStructure temp; @@ -289,7 +289,7 @@ Result<> ApproximatePointCloudHullFilter::executeImpl(DataStructure& data, const } } - auto* hull = data.getDataAs(hullVertexGeomPath); + auto* hull = dataStructure.getDataAs(hullVertexGeomPath); hull->resizeVertexList(tmpVerts.size() / 3); if(hull->getVertexAttributeMatrix() != nullptr) { diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ApproximatePointCloudHullFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ApproximatePointCloudHullFilter.hpp index 3b24d0cf7c..2e50a86795 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ApproximatePointCloudHullFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ApproximatePointCloudHullFilter.hpp @@ -87,17 +87,20 @@ class SIMPLNXCORE_EXPORT ApproximatePointCloudHullFilter : public IFilter * @param messageHandler * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ArrayCalculatorFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ArrayCalculatorFilter.hpp index ef7c8d9ccc..9381dc71e3 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ArrayCalculatorFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ArrayCalculatorFilter.hpp @@ -97,7 +97,8 @@ class SIMPLNXCORE_EXPORT ArrayCalculatorFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateArrayHistogramFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateArrayHistogramFilter.hpp index 8a882158ea..bc4efa570f 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateArrayHistogramFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateArrayHistogramFilter.hpp @@ -103,7 +103,8 @@ class SIMPLNXCORE_EXPORT CalculateArrayHistogramFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateFeatureSizesFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateFeatureSizesFilter.cpp index 9906a49b01..2ada87fba6 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateFeatureSizesFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateFeatureSizesFilter.cpp @@ -81,7 +81,8 @@ IFilter::UniquePointer CalculateFeatureSizesFilter::clone() const return std::make_unique(); } -IFilter::PreflightResult CalculateFeatureSizesFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +IFilter::PreflightResult CalculateFeatureSizesFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { auto geometryPath = args.value(k_GeometryPath_Key); @@ -94,9 +95,9 @@ IFilter::PreflightResult CalculateFeatureSizesFilter::preflightImpl(const DataSt DataPath equivalentDiametersPath = featureAttributeMatrixPath.createChildPath(equivalentDiametersName); DataPath numElementsPath = featureAttributeMatrixPath.createChildPath(numElementsName); - const auto* featureIdsArray = data.getDataAs(featureIdsPath); + const auto* featureIdsArray = dataStructure.getDataAs(featureIdsPath); - const auto* geometry = data.getDataAs(geometryPath); + const auto* geometry = dataStructure.getDataAs(geometryPath); if(geometry == nullptr) { @@ -110,7 +111,7 @@ IFilter::PreflightResult CalculateFeatureSizesFilter::preflightImpl(const DataSt const std::string arrayDataFormat = featureIdsArray->getDataFormat(); - const auto* featAttributeMatrix = data.getDataAs(featureAttributeMatrixPath); + const auto* featAttributeMatrix = dataStructure.getDataAs(featureAttributeMatrixPath); if(featAttributeMatrix == nullptr) { return {nonstd::make_unexpected( @@ -132,18 +133,18 @@ IFilter::PreflightResult CalculateFeatureSizesFilter::preflightImpl(const DataSt return {std::move(actions)}; } -Result<> CalculateFeatureSizesFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> CalculateFeatureSizesFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto saveElementSizes = args.value(k_SaveElementSizes_Key); auto featureIdsPath = args.value(k_CellFeatureIdsArrayPath_Key); - const auto& featureIdsArray = data.getDataRefAs(featureIdsPath); + const auto& featureIdsArray = dataStructure.getDataRefAs(featureIdsPath); const auto& featureIds = featureIdsArray.getDataStoreRef(); usize totalPoints = featureIdsArray.getNumberOfTuples(); auto geomPath = args.value(k_GeometryPath_Key); - auto* geom = data.getDataAs(geomPath); + auto* geom = dataStructure.getDataAs(geomPath); // If the geometry is an ImageGeometry or a RectilinearGeometry auto* imageGeom = dynamic_cast(geom); @@ -157,9 +158,9 @@ Result<> CalculateFeatureSizesFilter::executeImpl(DataStructure& data, const Arg DataPath volumesPath = featureAttributeMatrixPath.createChildPath(volumesName); DataPath equivalentDiametersPath = featureAttributeMatrixPath.createChildPath(equivalentDiametersName); DataPath numElementsPath = featureAttributeMatrixPath.createChildPath(numElementsName); - auto& volumes = data.getDataRefAs(volumesPath); - auto& equivalentDiameters = data.getDataRefAs(equivalentDiametersPath); - auto& numElements = data.getDataRefAs(numElementsPath); + auto& volumes = dataStructure.getDataRefAs(volumesPath); + auto& equivalentDiameters = dataStructure.getDataRefAs(equivalentDiametersPath); + auto& numElements = dataStructure.getDataRefAs(numElementsPath); usize featureIdsMaxIdx = std::distance(featureIds.begin(), std::max_element(featureIds.cbegin(), featureIds.cend())); usize maxValue = featureIds[featureIdsMaxIdx]; @@ -247,9 +248,9 @@ Result<> CalculateFeatureSizesFilter::executeImpl(DataStructure& data, const Arg auto equivalentDiametersPath = args.value(k_EquivalentDiametersName_Key); auto numElementsPath = args.value(k_NumElementsName_Key); - auto& volumes = data.getDataRefAs(volumesPath); - auto& equivalentDiameters = data.getDataRefAs(equivalentDiametersPath); - auto& numElements = data.getDataRefAs(numElementsPath); + auto& volumes = dataStructure.getDataRefAs(volumesPath); + auto& equivalentDiameters = dataStructure.getDataRefAs(equivalentDiametersPath); + auto& numElements = dataStructure.getDataRefAs(numElementsPath); usize numfeatures = volumes.getNumberOfTuples(); diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateFeatureSizesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateFeatureSizesFilter.hpp index 80d430afd6..92718af9c4 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateFeatureSizesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateFeatureSizesFilter.hpp @@ -91,17 +91,20 @@ class SIMPLNXCORE_EXPORT CalculateFeatureSizesFilter : public IFilter * @param messageHandler * @return PreflightResult */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateTriangleAreasFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateTriangleAreasFilter.hpp index 0fc51b6c55..f357d30269 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateTriangleAreasFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CalculateTriangleAreasFilter.hpp @@ -96,7 +96,8 @@ class SIMPLNXCORE_EXPORT CalculateTriangleAreasFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ChangeAngleRepresentationFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ChangeAngleRepresentationFilter.hpp index fa2df6e83d..78949390a2 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ChangeAngleRepresentationFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ChangeAngleRepresentationFilter.hpp @@ -96,7 +96,8 @@ class SIMPLNXCORE_EXPORT ChangeAngleRepresentationFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CombineAttributeArraysFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CombineAttributeArraysFilter.hpp index cf65b9a8fa..921b0039a5 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CombineAttributeArraysFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CombineAttributeArraysFilter.hpp @@ -98,7 +98,8 @@ class SIMPLNXCORE_EXPORT CombineAttributeArraysFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CombineStlFilesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CombineStlFilesFilter.hpp index ba6f5aaaf7..495a9a1aa1 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CombineStlFilesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CombineStlFilesFilter.hpp @@ -93,7 +93,7 @@ class SIMPLNXCORE_EXPORT CombineStlFilesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -103,7 +103,8 @@ class SIMPLNXCORE_EXPORT CombineStlFilesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ComputeFeatureRectFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ComputeFeatureRectFilter.hpp index 2109bc66d3..d58125a304 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ComputeFeatureRectFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ComputeFeatureRectFilter.hpp @@ -89,7 +89,7 @@ class SIMPLNXCORE_EXPORT ComputeFeatureRectFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -99,7 +99,8 @@ class SIMPLNXCORE_EXPORT ComputeFeatureRectFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ComputeMomentInvariants2DFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ComputeMomentInvariants2DFilter.hpp index 5b8e6d779d..d106483146 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ComputeMomentInvariants2DFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ComputeMomentInvariants2DFilter.hpp @@ -94,7 +94,7 @@ class SIMPLNXCORE_EXPORT ComputeMomentInvariants2DFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -104,7 +104,8 @@ class SIMPLNXCORE_EXPORT ComputeMomentInvariants2DFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ConvertColorToGrayScaleFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ConvertColorToGrayScaleFilter.hpp index 2b8e7a6f8b..479c14ce5c 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ConvertColorToGrayScaleFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ConvertColorToGrayScaleFilter.hpp @@ -99,7 +99,8 @@ class SIMPLNXCORE_EXPORT ConvertColorToGrayScaleFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ConvertDataFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ConvertDataFilter.hpp index 496ddd3468..ef8b8ac3ce 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ConvertDataFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ConvertDataFilter.hpp @@ -98,7 +98,8 @@ class SIMPLNXCORE_EXPORT ConvertDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CopyDataObjectFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CopyDataObjectFilter.cpp index 12c1c74045..73de454fff 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CopyDataObjectFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CopyDataObjectFilter.cpp @@ -70,7 +70,8 @@ IFilter::UniquePointer CopyDataObjectFilter::clone() const } //------------------------------------------------------------------------------ -IFilter::PreflightResult CopyDataObjectFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +IFilter::PreflightResult CopyDataObjectFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { auto dataArrayPaths = args.value(k_DataPath_Key); auto useNewParent = args.value(k_UseNewParent_Key); @@ -91,12 +92,12 @@ IFilter::PreflightResult CopyDataObjectFilter::preflightImpl(const DataStructure parentPath = args.value(k_NewPath_Key); // Scope AM check since we fully expect it to be a nullptr { - const auto* possibleAM = data.getDataAs(parentPath); + const auto* possibleAM = dataStructure.getDataAs(parentPath); if(possibleAM != nullptr) { for(const auto& path : dataArrayPaths) { - const auto* possibleIArray = data.getDataAs(path); + const auto* possibleIArray = dataStructure.getDataAs(path); if(possibleIArray != nullptr) { if(possibleAM->getShape() != possibleIArray->getTupleShape()) @@ -115,9 +116,9 @@ IFilter::PreflightResult CopyDataObjectFilter::preflightImpl(const DataStructure DataPath newDataPath = parentPath.createChildPath(newTargetName); std::vector allCreatedPaths = {newDataPath}; - if(data.getDataAs(dataArrayPath) != nullptr) + if(dataStructure.getDataAs(dataArrayPath) != nullptr) { - const auto pathsToBeCopied = GetAllChildDataPathsRecursive(data, dataArrayPath); + const auto pathsToBeCopied = GetAllChildDataPathsRecursive(dataStructure, dataArrayPath); if(pathsToBeCopied.has_value()) { for(const auto& sourcePath : pathsToBeCopied.value()) @@ -135,7 +136,7 @@ IFilter::PreflightResult CopyDataObjectFilter::preflightImpl(const DataStructure } //------------------------------------------------------------------------------ -Result<> CopyDataObjectFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> CopyDataObjectFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { return {}; diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CopyDataObjectFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CopyDataObjectFilter.hpp index 71f04469a3..aa13d36193 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CopyDataObjectFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CopyDataObjectFilter.hpp @@ -83,17 +83,20 @@ class SIMPLNXCORE_EXPORT CopyDataObjectFilter : public IFilter * @param messageHandler * @return PreflightResult */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CopyFeatureArrayToElementArrayFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CopyFeatureArrayToElementArrayFilter.hpp index 59b50fda59..92533c65e0 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CopyFeatureArrayToElementArrayFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CopyFeatureArrayToElementArrayFilter.hpp @@ -100,7 +100,8 @@ class SIMPLNXCORE_EXPORT CopyFeatureArrayToElementArrayFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateDataArrayFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateDataArrayFilter.cpp index 9942982355..4adf2fa638 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateDataArrayFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateDataArrayFilter.cpp @@ -21,11 +21,11 @@ namespace constexpr int32 k_EmptyParameterError = -123; template -void CreateAndInitArray(DataStructure& data, const DataPath& path, const std::string& initValue) +void CreateAndInitArray(DataStructure& dataStructure, const DataPath& path, const std::string& initValue) { Result result = ConvertTo::convert(initValue); T value = result.value(); - auto& dataArray = data.getDataRefAs>(path); + auto& dataArray = dataStructure.getDataRefAs>(path); auto& dataStore = dataArray.getDataStoreRef(); dataStore.fill(value); } @@ -172,7 +172,7 @@ IFilter::PreflightResult CreateDataArrayFilter::preflightImpl(const DataStructur } //------------------------------------------------------------------------------ -Result<> CreateDataArrayFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> CreateDataArrayFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto numericType = args.value(k_NumericType_Key); @@ -182,43 +182,43 @@ Result<> CreateDataArrayFilter::executeImpl(DataStructure& data, const Arguments switch(numericType) { case NumericType::int8: { - CreateAndInitArray(data, path, initValue); + CreateAndInitArray(dataStructure, path, initValue); break; } case NumericType::uint8: { - CreateAndInitArray(data, path, initValue); + CreateAndInitArray(dataStructure, path, initValue); break; } case NumericType::int16: { - CreateAndInitArray(data, path, initValue); + CreateAndInitArray(dataStructure, path, initValue); break; } case NumericType::uint16: { - CreateAndInitArray(data, path, initValue); + CreateAndInitArray(dataStructure, path, initValue); break; } case NumericType::int32: { - CreateAndInitArray(data, path, initValue); + CreateAndInitArray(dataStructure, path, initValue); break; } case NumericType::uint32: { - CreateAndInitArray(data, path, initValue); + CreateAndInitArray(dataStructure, path, initValue); break; } case NumericType::int64: { - CreateAndInitArray(data, path, initValue); + CreateAndInitArray(dataStructure, path, initValue); break; } case NumericType::uint64: { - CreateAndInitArray(data, path, initValue); + CreateAndInitArray(dataStructure, path, initValue); break; } case NumericType::float32: { - CreateAndInitArray(data, path, initValue); + CreateAndInitArray(dataStructure, path, initValue); break; } case NumericType::float64: { - CreateAndInitArray(data, path, initValue); + CreateAndInitArray(dataStructure, path, initValue); break; } default: diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateDataArrayFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateDataArrayFilter.hpp index 3538f5e7d1..e3e38e9856 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateDataArrayFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateDataArrayFilter.hpp @@ -86,7 +86,7 @@ class SIMPLNXCORE_EXPORT CreateDataArrayFilter : public IFilter * @param messageHandler * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateFeatureArrayFromElementArrayFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateFeatureArrayFromElementArrayFilter.hpp index 997203dd0b..05eff86683 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateFeatureArrayFromElementArrayFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateFeatureArrayFromElementArrayFilter.hpp @@ -98,7 +98,8 @@ class SIMPLNXCORE_EXPORT CreateFeatureArrayFromElementArrayFilter : public IFilt * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateGeometryFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateGeometryFilter.cpp index 2aaa144894..84763a0ddc 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateGeometryFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateGeometryFilter.cpp @@ -381,7 +381,7 @@ IFilter::PreflightResult CreateGeometryFilter::preflightImpl(const DataStructure } //------------------------------------------------------------------------------ -Result<> CreateGeometryFilter::executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> CreateGeometryFilter::executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto geometryPath = filterArgs.value(k_GeometryPath_Key); @@ -389,7 +389,7 @@ Result<> CreateGeometryFilter::executeImpl(DataStructure& data, const Arguments& auto treatWarningsAsErrors = filterArgs.value(k_WarningsAsErrors_Key); auto moveArrays = filterArgs.value(k_ArrayHandling_Key) == k_MoveArray; - auto iGeometry = data.getDataAs(geometryPath); + auto iGeometry = dataStructure.getDataAs(geometryPath); auto lengthUnit = static_cast(filterArgs.value(k_LengthUnitType_Key)); iGeometry->setUnits(lengthUnit); @@ -425,8 +425,8 @@ Result<> CreateGeometryFilter::executeImpl(DataStructure& data, const Arguments& { auto sharedEdgeListArrayPath = filterArgs.value(k_EdgeListPath_Key); const DataPath destEdgeListPath = geometryPath.createChildPath(sharedEdgeListArrayPath.getTargetName()); - const auto& edgesList = data.getDataRefAs(destEdgeListPath); - const auto& vertexList = data.getDataRefAs(geometryPath.createChildPath(sharedVertexListArrayPath.getTargetName())); + const auto& edgesList = dataStructure.getDataRefAs(destEdgeListPath); + const auto& vertexList = dataStructure.getDataRefAs(geometryPath.createChildPath(sharedVertexListArrayPath.getTargetName())); auto results = checkGeometryArraysCompatible(vertexList, edgesList, treatWarningsAsErrors, "edge"); if(results.invalid()) { @@ -437,8 +437,8 @@ Result<> CreateGeometryFilter::executeImpl(DataStructure& data, const Arguments& if(geometryType == k_TriangleGeometry || geometryType == k_QuadGeometry) { const DataPath destFaceListPath = geometryPath.createChildPath(sharedFaceListArrayPath.getTargetName()); - const auto& faceList = data.getDataRefAs(destFaceListPath); - const auto& vertexList = data.getDataRefAs(geometryPath.createChildPath(sharedVertexListArrayPath.getTargetName())); + const auto& faceList = dataStructure.getDataRefAs(destFaceListPath); + const auto& vertexList = dataStructure.getDataRefAs(geometryPath.createChildPath(sharedVertexListArrayPath.getTargetName())); auto results = checkGeometryArraysCompatible(vertexList, faceList, treatWarningsAsErrors, (geometryType == 4 ? "triangle" : "quadrilateral")); if(results.invalid()) { @@ -449,8 +449,8 @@ Result<> CreateGeometryFilter::executeImpl(DataStructure& data, const Arguments& if(geometryType == k_TetGeometry || geometryType == k_HexGeometry) { const DataPath destCellListPath = geometryPath.createChildPath(sharedCellListArrayPath.getTargetName()); - const auto& cellList = data.getDataRefAs(destCellListPath); - const auto& vertexList = data.getDataRefAs(geometryPath.createChildPath(sharedVertexListArrayPath.getTargetName())); + const auto& cellList = dataStructure.getDataRefAs(destCellListPath); + const auto& vertexList = dataStructure.getDataRefAs(geometryPath.createChildPath(sharedVertexListArrayPath.getTargetName())); auto results = checkGeometryArraysCompatible(vertexList, cellList, treatWarningsAsErrors, (geometryType == 6 ? "tetrahedral" : "hexahedral")); if(results.invalid()) { @@ -463,9 +463,9 @@ Result<> CreateGeometryFilter::executeImpl(DataStructure& data, const Arguments& auto xBoundsArrayPath = filterArgs.value(k_XBoundsPath_Key); auto yBoundsArrayPath = filterArgs.value(k_YBoundsPath_Key); auto zBoundsArrayPath = filterArgs.value(k_ZBoundsPath_Key); - const auto& srcXBounds = data.getDataRefAs(geometryPath.createChildPath(xBoundsArrayPath.getTargetName())); - const auto& srcYBounds = data.getDataRefAs(geometryPath.createChildPath(yBoundsArrayPath.getTargetName())); - const auto& srcZBounds = data.getDataRefAs(geometryPath.createChildPath(zBoundsArrayPath.getTargetName())); + const auto& srcXBounds = dataStructure.getDataRefAs(geometryPath.createChildPath(xBoundsArrayPath.getTargetName())); + const auto& srcYBounds = dataStructure.getDataRefAs(geometryPath.createChildPath(yBoundsArrayPath.getTargetName())); + const auto& srcZBounds = dataStructure.getDataRefAs(geometryPath.createChildPath(zBoundsArrayPath.getTargetName())); auto xResults = checkGridBoundsResolution(srcXBounds, treatWarningsAsErrors, "X"); auto yResults = checkGridBoundsResolution(srcYBounds, treatWarningsAsErrors, "Y"); auto zResults = checkGridBoundsResolution(srcZBounds, treatWarningsAsErrors, "Z"); diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateGeometryFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateGeometryFilter.hpp index 2ef6faaabb..f6a206742a 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateGeometryFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateGeometryFilter.hpp @@ -132,7 +132,8 @@ class SIMPLNXCORE_EXPORT CreateGeometryFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateImageGeometryFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateImageGeometryFilter.cpp index a6119d8242..78651f6264 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateImageGeometryFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateImageGeometryFilter.cpp @@ -126,7 +126,7 @@ IFilter::PreflightResult CreateImageGeometryFilter::preflightImpl(const DataStru } //------------------------------------------------------------------------------ -Result<> CreateImageGeometryFilter::executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> CreateImageGeometryFilter::executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { /**************************************************************************** diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateImageGeometryFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateImageGeometryFilter.hpp index 0e3b34ad4d..ba4f31ea5a 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateImageGeometryFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CreateImageGeometryFilter.hpp @@ -99,7 +99,8 @@ class SIMPLNXCORE_EXPORT CreateImageGeometryFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CropVertexGeometryFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CropVertexGeometryFilter.hpp index 4c74e233c4..716adb6a2a 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CropVertexGeometryFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/CropVertexGeometryFilter.hpp @@ -88,12 +88,14 @@ class SIMPLNXCORE_EXPORT CropVertexGeometryFilter : public IFilter PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/DeleteDataFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/DeleteDataFilter.cpp index 311fc4b5e1..d94a39a2df 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/DeleteDataFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/DeleteDataFilter.cpp @@ -193,7 +193,8 @@ IFilter::PreflightResult DeleteDataFilter::preflightImpl(const DataStructure& da return {std::move(deleteActions)}; } -Result<> DeleteDataFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +Result<> DeleteDataFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { return {}; } diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/DeleteDataFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/DeleteDataFilter.hpp index ab5a0e7134..75b312f24f 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/DeleteDataFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/DeleteDataFilter.hpp @@ -90,17 +90,20 @@ class SIMPLNXCORE_EXPORT DeleteDataFilter : public IFilter * @param messageHandler * @return PreflightResult */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ErodeDilateBadDataFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ErodeDilateBadDataFilter.hpp index 5adc6126b8..cb88344905 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ErodeDilateBadDataFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ErodeDilateBadDataFilter.hpp @@ -104,7 +104,8 @@ class SIMPLNXCORE_EXPORT ErodeDilateBadDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ErodeDilateCoordinationNumberFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ErodeDilateCoordinationNumberFilter.hpp index 3a615a1d2f..9e27737dd3 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ErodeDilateCoordinationNumberFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ErodeDilateCoordinationNumberFilter.hpp @@ -89,7 +89,7 @@ class SIMPLNXCORE_EXPORT ErodeDilateCoordinationNumberFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -99,7 +99,8 @@ class SIMPLNXCORE_EXPORT ErodeDilateCoordinationNumberFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ErodeDilateMaskFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ErodeDilateMaskFilter.hpp index 40c4e95e32..242dba76f8 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ErodeDilateMaskFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ErodeDilateMaskFilter.hpp @@ -93,7 +93,7 @@ class SIMPLNXCORE_EXPORT ErodeDilateMaskFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -103,7 +103,8 @@ class SIMPLNXCORE_EXPORT ErodeDilateMaskFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExecuteProcessFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExecuteProcessFilter.hpp index f221acff50..df55d8eb78 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExecuteProcessFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExecuteProcessFilter.hpp @@ -88,7 +88,7 @@ class SIMPLNXCORE_EXPORT ExecuteProcessFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -98,7 +98,8 @@ class SIMPLNXCORE_EXPORT ExecuteProcessFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractComponentAsArrayFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractComponentAsArrayFilter.hpp index b0e8fea3c4..86d9050a83 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractComponentAsArrayFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractComponentAsArrayFilter.hpp @@ -100,7 +100,8 @@ class SIMPLNXCORE_EXPORT ExtractComponentAsArrayFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractInternalSurfacesFromTriangleGeometryFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractInternalSurfacesFromTriangleGeometryFilter.cpp index fbece285f6..857ded1c45 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractInternalSurfacesFromTriangleGeometryFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractInternalSurfacesFromTriangleGeometryFilter.cpp @@ -256,7 +256,7 @@ IFilter::PreflightResult ExtractInternalSurfacesFromTriangleGeometryFilter::pref } //------------------------------------------------------------------------------ -Result<> ExtractInternalSurfacesFromTriangleGeometryFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> ExtractInternalSurfacesFromTriangleGeometryFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto nodeTypesArrayPath = args.value(k_NodeTypesPath_Key); @@ -269,20 +269,20 @@ Result<> ExtractInternalSurfacesFromTriangleGeometryFilter::executeImpl(DataStru auto minMaxNodeValues = args.value(k_NodeTypeRange_Key); - auto& triangleGeom = data.getDataRefAs(triangleGeomPath); - auto& internalTriangleGeom = data.getDataRefAs(internalTrianglesPath); + auto& triangleGeom = dataStructure.getDataRefAs(triangleGeomPath); + auto& internalTriangleGeom = dataStructure.getDataRefAs(internalTrianglesPath); auto& vertices = *triangleGeom.getVertices(); auto& triangles = *triangleGeom.getFaces(); auto numVerts = triangleGeom.getNumberOfVertices(); auto numTris = triangleGeom.getNumberOfFaces(); - auto& nodeTypes = data.getDataRefAs(nodeTypesArrayPath); + auto& nodeTypes = dataStructure.getDataRefAs(nodeTypesArrayPath); auto internalVerticesPath = internalTrianglesPath.createChildPath(CreateTriangleGeometryAction::k_DefaultVerticesName); - internalTriangleGeom.setVertices(*data.getDataAs(internalVerticesPath)); + internalTriangleGeom.setVertices(*dataStructure.getDataAs(internalVerticesPath)); auto internalFacesPath = internalTrianglesPath.createChildPath(CreateTriangleGeometryAction::k_DefaultFacesName); - internalTriangleGeom.setFaceList(*data.getDataAs(internalFacesPath)); + internalTriangleGeom.setFaceList(*dataStructure.getDataAs(internalFacesPath)); // int64 progIncrement = numTris / 100; // int64 prog = 1; @@ -385,8 +385,8 @@ Result<> ExtractInternalSurfacesFromTriangleGeometryFilter::executeImpl(DataStru for(const auto& targetArrayPath : copyVertexPaths) { DataPath destinationPath = internalTrianglesPath.createChildPath(vertexDataName).createChildPath(targetArrayPath.getTargetName()); - auto& src = data.getDataRefAs(targetArrayPath); - auto& dest = data.getDataRefAs(destinationPath); + auto& src = dataStructure.getDataRefAs(targetArrayPath); + auto& dest = dataStructure.getDataRefAs(destinationPath); ExecuteDataFunction(RemoveFlaggedVerticesFunctor{}, src.getDataType(), src, dest, vertNewIndex); } @@ -394,8 +394,8 @@ Result<> ExtractInternalSurfacesFromTriangleGeometryFilter::executeImpl(DataStru for(const auto& targetArrayPath : copyTrianglePaths) { DataPath destinationPath = internalTrianglesPath.createChildPath(faceDataName).createChildPath(targetArrayPath.getTargetName()); - auto& src = data.getDataRefAs(targetArrayPath); - auto& dest = data.getDataRefAs(destinationPath); + auto& src = dataStructure.getDataRefAs(targetArrayPath); + auto& dest = dataStructure.getDataRefAs(destinationPath); dest.getIDataStore()->resizeTuples({currentNewTriIndex}); ExecuteDataFunction(RemoveFlaggedVerticesFunctor{}, src.getDataType(), src, dest, triNewIndex); diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractInternalSurfacesFromTriangleGeometryFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractInternalSurfacesFromTriangleGeometryFilter.hpp index c3110d3d42..f3ab0696b4 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractInternalSurfacesFromTriangleGeometryFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractInternalSurfacesFromTriangleGeometryFilter.hpp @@ -88,7 +88,7 @@ class SIMPLNXCORE_EXPORT ExtractInternalSurfacesFromTriangleGeometryFilter : pub * @param shouldCancel * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractVertexGeometryFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractVertexGeometryFilter.hpp index fa106722ee..2ba9fea4b7 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractVertexGeometryFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ExtractVertexGeometryFilter.hpp @@ -97,7 +97,8 @@ class SIMPLNXCORE_EXPORT ExtractVertexGeometryFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindArrayStatisticsFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindArrayStatisticsFilter.cpp index 1ad14f0400..aea4734395 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindArrayStatisticsFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindArrayStatisticsFilter.cpp @@ -32,7 +32,7 @@ struct IsIntegerType } }; -OutputActions CreateCompatibleArrays(const DataStructure& data, const Arguments& args, usize numBins, std::vector tupleDims) +OutputActions CreateCompatibleArrays(const DataStructure& dataStructure, const Arguments& args, usize numBins, std::vector tupleDims) { auto findLength = args.value(FindArrayStatisticsFilter::k_FindLength_Key); auto findMin = args.value(FindArrayStatisticsFilter::k_FindMin_Key); @@ -48,7 +48,7 @@ OutputActions CreateCompatibleArrays(const DataStructure& data, const Arguments& auto computeByIndexValue = args.value(FindArrayStatisticsFilter::k_ComputeByIndex_Key); auto standardizeDataValue = args.value(FindArrayStatisticsFilter::k_StandardizeData_Key); auto inputArrayPath = args.value(FindArrayStatisticsFilter::k_SelectedArrayPath_Key); - auto* inputArray = data.getDataAs(inputArrayPath); + auto* inputArray = dataStructure.getDataAs(inputArrayPath); auto destinationAttributeMatrixValue = args.value(FindArrayStatisticsFilter::k_DestinationAttributeMatrixPath_Key); DataType dataType = inputArray->getDataType(); diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindArrayStatisticsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindArrayStatisticsFilter.hpp index b63ca6c34a..cc2795f1c5 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindArrayStatisticsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindArrayStatisticsFilter.hpp @@ -131,7 +131,8 @@ class SIMPLNXCORE_EXPORT FindArrayStatisticsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindBiasedFeaturesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindBiasedFeaturesFilter.hpp index d0f82a0143..22c5b78cc3 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindBiasedFeaturesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindBiasedFeaturesFilter.hpp @@ -90,7 +90,7 @@ class SIMPLNXCORE_EXPORT FindBiasedFeaturesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -100,7 +100,8 @@ class SIMPLNXCORE_EXPORT FindBiasedFeaturesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindBoundaryCellsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindBoundaryCellsFilter.hpp index 5d6fb5d8de..cdf0aa5caa 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindBoundaryCellsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindBoundaryCellsFilter.hpp @@ -89,7 +89,7 @@ class SIMPLNXCORE_EXPORT FindBoundaryCellsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -99,7 +99,8 @@ class SIMPLNXCORE_EXPORT FindBoundaryCellsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindBoundaryElementFractionsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindBoundaryElementFractionsFilter.hpp index 77ce2cf625..ece2b71fb1 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindBoundaryElementFractionsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindBoundaryElementFractionsFilter.hpp @@ -88,7 +88,7 @@ class SIMPLNXCORE_EXPORT FindBoundaryElementFractionsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -98,7 +98,8 @@ class SIMPLNXCORE_EXPORT FindBoundaryElementFractionsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindDifferencesMapFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindDifferencesMapFilter.cpp index aeeebb6adc..6d8b890a36 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindDifferencesMapFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindDifferencesMapFilter.cpp @@ -21,12 +21,12 @@ constexpr int32 k_MissingInputArray = -567; constexpr int32 k_ComponentCountMismatchError = -90003; constexpr int32 k_InvalidNumTuples = -90004; -IFilter::PreflightResult validateArrayTypes(const DataStructure& data, const std::vector& dataPaths) +IFilter::PreflightResult validateArrayTypes(const DataStructure& dataStructure, const std::vector& dataPaths) { std::optional dataType = {}; for(const auto& dataPath : dataPaths) { - if(auto dataArray = data.getDataAs(dataPath)) + if(auto dataArray = dataStructure.getDataAs(dataPath)) { if(!dataType.has_value()) { @@ -47,27 +47,27 @@ IFilter::PreflightResult validateArrayTypes(const DataStructure& data, const std return {}; } -WarningCollection warnOnUnsignedTypes(const DataStructure& data, const std::vector& paths) +WarningCollection warnOnUnsignedTypes(const DataStructure& dataStructure, const std::vector& paths) { WarningCollection results; for(const auto& dataPath : paths) { - if(data.getDataAs(dataPath)) + if(dataStructure.getDataAs(dataPath)) { std::string ss = fmt::format("Selected Attribute Arrays are of type uint8_t. Using unsigned integer types may result in underflow leading to extremely large values!"); results.push_back(Warning{-90004, ss}); } - if(data.getDataAs(dataPath)) + if(dataStructure.getDataAs(dataPath)) { std::string ss = fmt::format("Selected Attribute Arrays are of type uint16_t. Using unsigned integer types may result in underflow leading to extremely large values!"); results.push_back(Warning{-90005, ss}); } - if(data.getDataAs(dataPath)) + if(dataStructure.getDataAs(dataPath)) { std::string ss = fmt::format("Selected Attribute Arrays are of type uint32_t. Using unsigned integer types may result in underflow leading to extremely large values!"); results.push_back(Warning{-90006, ss}); } - if(data.getDataAs(dataPath)) + if(dataStructure.getDataAs(dataPath)) { std::string ss = fmt::format("Selected Attribute Arrays are of type uint64_t. Using unsigned integer types may result in underflow leading to extremely large values!"); results.push_back(Warning{-90007, ss}); @@ -252,12 +252,12 @@ IFilter::PreflightResult FindDifferencesMapFilter::preflightImpl(const DataStruc } //------------------------------------------------------------------------------ -Result<> FindDifferencesMapFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> FindDifferencesMapFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { - auto firstInputArray = data.getDataAs(args.value(k_FirstInputArrayPath_Key)); - auto secondInputArray = data.getDataAs(args.value(k_SecondInputArrayPath_Key)); - auto differenceMapArray = data.getDataAs(args.value(k_DifferenceMapArrayPath_Key)); + auto firstInputArray = dataStructure.getDataAs(args.value(k_FirstInputArrayPath_Key)); + auto secondInputArray = dataStructure.getDataAs(args.value(k_SecondInputArrayPath_Key)); + auto differenceMapArray = dataStructure.getDataAs(args.value(k_DifferenceMapArrayPath_Key)); auto dataType = firstInputArray->getDataType(); ExecuteDataFunction(ExecuteFindDifferenceMapFunctor{}, dataType, firstInputArray, secondInputArray, differenceMapArray); diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindDifferencesMapFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindDifferencesMapFilter.hpp index e2f957a74f..a91b9d127c 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindDifferencesMapFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindDifferencesMapFilter.hpp @@ -80,23 +80,29 @@ class SIMPLNXCORE_EXPORT FindDifferencesMapFilter : public IFilter protected: /** - * @brief - * @param dataStructure - * @param args - * @param messageHandler - * @return PreflightResult + * @brief Takes in a DataStructure and checks that the filter can be run on it with the given arguments. + * Returns any warnings/errors. Also returns the changes that would be applied to the DataStructure. + * Some parts of the actions may not be completely filled out if all the required information is not available at preflight time. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindEuclideanDistMapFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindEuclideanDistMapFilter.hpp index 26cf394efd..f6cec414b3 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindEuclideanDistMapFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindEuclideanDistMapFilter.hpp @@ -106,7 +106,8 @@ class SIMPLNXCORE_EXPORT FindEuclideanDistMapFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeatureCentroidsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeatureCentroidsFilter.hpp index fa1b1cd7d5..55ee90ba8f 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeatureCentroidsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeatureCentroidsFilter.hpp @@ -98,7 +98,8 @@ class SIMPLNXCORE_EXPORT FindFeatureCentroidsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeatureClusteringFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeatureClusteringFilter.hpp index 7cda3d8e5d..2ff4ad80d7 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeatureClusteringFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeatureClusteringFilter.hpp @@ -99,7 +99,7 @@ class SIMPLNXCORE_EXPORT FindFeatureClusteringFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -109,7 +109,8 @@ class SIMPLNXCORE_EXPORT FindFeatureClusteringFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeaturePhasesBinaryFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeaturePhasesBinaryFilter.hpp index 1c190c68ab..799797f478 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeaturePhasesBinaryFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeaturePhasesBinaryFilter.hpp @@ -88,7 +88,7 @@ class SIMPLNXCORE_EXPORT FindFeaturePhasesBinaryFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -98,7 +98,8 @@ class SIMPLNXCORE_EXPORT FindFeaturePhasesBinaryFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeaturePhasesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeaturePhasesFilter.hpp index 2101bdb629..32d6e52bb0 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeaturePhasesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindFeaturePhasesFilter.hpp @@ -102,7 +102,8 @@ class SIMPLNXCORE_EXPORT FindFeaturePhasesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindLargestCrossSectionsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindLargestCrossSectionsFilter.hpp index 9678d53b41..510ba8ce16 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindLargestCrossSectionsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindLargestCrossSectionsFilter.hpp @@ -89,7 +89,7 @@ class SIMPLNXCORE_EXPORT FindLargestCrossSectionsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -99,7 +99,8 @@ class SIMPLNXCORE_EXPORT FindLargestCrossSectionsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborListStatisticsFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborListStatisticsFilter.cpp index b5a5f324db..4cabd9256b 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborListStatisticsFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborListStatisticsFilter.cpp @@ -156,7 +156,7 @@ class FindNeighborListStatisticsImpl } // namespace //------------------------------------------------------------------------------ -OutputActions FindNeighborListStatisticsFilter::createCompatibleArrays(const DataStructure& data, const Arguments& args) const +OutputActions FindNeighborListStatisticsFilter::createCompatibleArrays(const DataStructure& dataStructure, const Arguments& args) const { auto findLength = args.value(k_FindLength_Key); auto findMin = args.value(k_FindMinimum_Key); @@ -167,7 +167,7 @@ OutputActions FindNeighborListStatisticsFilter::createCompatibleArrays(const Dat auto findSummation = args.value(k_FindSummation_Key); auto inputArrayPath = args.value(k_InputNeighborListPath_Key); - auto* inputArray = data.getDataAs(inputArrayPath); + auto* inputArray = dataStructure.getDataAs(inputArrayPath); std::vector tupleDims{inputArray->getNumberOfTuples()}; DataType dataType = inputArray->getDataType(); const DataPath outputGroupPath = inputArrayPath.getParent(); @@ -286,7 +286,7 @@ IFilter::UniquePointer FindNeighborListStatisticsFilter::clone() const } //------------------------------------------------------------------------------ -IFilter::PreflightResult FindNeighborListStatisticsFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, +IFilter::PreflightResult FindNeighborListStatisticsFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto findLength = args.value(k_FindLength_Key); @@ -308,7 +308,7 @@ IFilter::PreflightResult FindNeighborListStatisticsFilter::preflightImpl(const D std::vector dataArrayPaths; - auto inputArray = data.getDataAs(inputArrayPath); + auto inputArray = dataStructure.getDataAs(inputArrayPath); if(inputArray == nullptr) { std::string ss = fmt::format("Missing input array"); @@ -317,11 +317,11 @@ IFilter::PreflightResult FindNeighborListStatisticsFilter::preflightImpl(const D dataArrayPaths.push_back(inputArrayPath); - return {std::move(createCompatibleArrays(data, args))}; + return {std::move(createCompatibleArrays(dataStructure, args))}; } //------------------------------------------------------------------------------ -Result<> FindNeighborListStatisticsFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> FindNeighborListStatisticsFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto findLength = args.value(k_FindLength_Key); @@ -338,7 +338,7 @@ Result<> FindNeighborListStatisticsFilter::executeImpl(DataStructure& data, cons } auto inputArrayPath = args.value(k_InputNeighborListPath_Key); - auto& inputArray = data.getDataRefAs(inputArrayPath); + auto& inputArray = dataStructure.getDataRefAs(inputArrayPath); const DataPath outputGroupPath = inputArrayPath.getParent(); std::vector arrays(7, nullptr); @@ -346,37 +346,37 @@ Result<> FindNeighborListStatisticsFilter::executeImpl(DataStructure& data, cons if(findLength) { auto lengthPath = outputGroupPath.createChildPath(args.value(k_LengthName_Key)); - arrays[0] = data.getDataAs(lengthPath); + arrays[0] = dataStructure.getDataAs(lengthPath); } if(findMin) { auto minPath = outputGroupPath.createChildPath(args.value(k_MinimumName_Key)); - arrays[1] = data.getDataAs(minPath); + arrays[1] = dataStructure.getDataAs(minPath); } if(findMax) { auto maxPath = outputGroupPath.createChildPath(args.value(k_MaximumName_Key)); - arrays[2] = data.getDataAs(maxPath); + arrays[2] = dataStructure.getDataAs(maxPath); } if(findMean) { auto meanPath = outputGroupPath.createChildPath(args.value(k_MeanName_Key)); - arrays[3] = data.getDataAs(meanPath); + arrays[3] = dataStructure.getDataAs(meanPath); } if(findMedian) { auto medianPath = outputGroupPath.createChildPath(args.value(k_MedianName_Key)); - arrays[4] = data.getDataAs(medianPath); + arrays[4] = dataStructure.getDataAs(medianPath); } if(findStdDeviation) { auto stdDeviationPath = outputGroupPath.createChildPath(args.value(k_StandardDeviationName_Key)); - arrays[5] = data.getDataAs(stdDeviationPath); + arrays[5] = dataStructure.getDataAs(stdDeviationPath); } if(findSummation) { auto summationPath = outputGroupPath.createChildPath(args.value(k_SummationName_Key)); - arrays[6] = data.getDataAs(summationPath); + arrays[6] = dataStructure.getDataAs(summationPath); } DataType type = inputArray.getDataType(); diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborListStatisticsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborListStatisticsFilter.hpp index a53b94902f..61f485c92e 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborListStatisticsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborListStatisticsFilter.hpp @@ -100,17 +100,20 @@ class SIMPLNXCORE_EXPORT FindNeighborListStatisticsFilter : public IFilter * @param messageHandler * @return PreflightResult */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborhoodsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborhoodsFilter.hpp index dc109c544e..ef6beb3778 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborhoodsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborhoodsFilter.hpp @@ -102,7 +102,8 @@ class SIMPLNXCORE_EXPORT FindNeighborhoodsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborsFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborsFilter.cpp index 04d3fabb65..b61f9369dc 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborsFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborsFilter.cpp @@ -94,7 +94,7 @@ IFilter::UniquePointer FindNeighborsFilter::clone() const } //------------------------------------------------------------------------------ -IFilter::PreflightResult FindNeighborsFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +IFilter::PreflightResult FindNeighborsFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto storeBoundaryCells = args.value(k_StoreBoundary_Key); auto storeSurfaceFeatures = args.value(k_StoreSurface_Key); @@ -115,7 +115,7 @@ IFilter::PreflightResult FindNeighborsFilter::preflightImpl(const DataStructure& OutputActions actions; - auto& featureIdsArray = data.getDataRefAs(featureIdsPath); + auto& featureIdsArray = dataStructure.getDataRefAs(featureIdsPath); std::vector tupleShape = featureIdsArray.getIDataStore()->getTupleShape(); const std::vector cDims{1}; @@ -130,7 +130,7 @@ IFilter::PreflightResult FindNeighborsFilter::preflightImpl(const DataStructure& // Feature Data: // Validating the Feature Attribute Matrix and trying to find a child of the Group // that is an IDataArray subclass, so we can get the proper tuple shape - const auto* featureAttrMatrix = data.getDataAs(featureAttrMatrixPath); + const auto* featureAttrMatrix = dataStructure.getDataAs(featureAttrMatrixPath); if(featureAttrMatrix == nullptr) { return {nonstd::make_unexpected(std::vector{Error{-12600, "Cell Feature AttributeMatrix Path is NOT an AttributeMatrix"}})}; @@ -164,7 +164,7 @@ IFilter::PreflightResult FindNeighborsFilter::preflightImpl(const DataStructure& } //------------------------------------------------------------------------------ -Result<> FindNeighborsFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> FindNeighborsFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto storeBoundaryCells = args.value(k_StoreBoundary_Key); @@ -184,13 +184,13 @@ Result<> FindNeighborsFilter::executeImpl(DataStructure& data, const Arguments& DataPath sharedSurfaceAreaPath = featureAttrMatrixPath.createChildPath(sharedSurfaceAreaName); DataPath surfaceFeaturesPath = featureAttrMatrixPath.createChildPath(surfaceFeaturesName); - auto& featureIdsArray = data.getDataRefAs(featureIdsPath); - auto& numNeighborsArray = data.getDataRefAs(numNeighborsPath); - auto& neighborList = data.getDataRefAs(neighborListPath); - auto& sharedSurfaceAreaList = data.getDataRefAs(sharedSurfaceAreaPath); + auto& featureIdsArray = dataStructure.getDataRefAs(featureIdsPath); + auto& numNeighborsArray = dataStructure.getDataRefAs(numNeighborsPath); + auto& neighborList = dataStructure.getDataRefAs(neighborListPath); + auto& sharedSurfaceAreaList = dataStructure.getDataRefAs(sharedSurfaceAreaPath); - auto* boundaryCellsArray = data.getDataAs(boundaryCellsPath); - auto* surfaceFeaturesArray = data.getDataAs(surfaceFeaturesPath); + auto* boundaryCellsArray = dataStructure.getDataAs(boundaryCellsPath); + auto* surfaceFeaturesArray = dataStructure.getDataAs(surfaceFeaturesPath); auto& featureIds = featureIdsArray.getDataStoreRef(); auto& numNeighbors = numNeighborsArray.getDataStoreRef(); @@ -209,7 +209,7 @@ Result<> FindNeighborsFilter::executeImpl(DataStructure& data, const Arguments& return MakeErrorResult(-24500, out.str()); } - auto& imageGeom = data.getDataRefAs(imageGeomPath); + auto& imageGeom = dataStructure.getDataRefAs(imageGeomPath); SizeVec3 udims = imageGeom.getDimensions(); const auto imageGeomNumX = imageGeom.getNumXCells(); const auto imageGeomNumY = imageGeom.getNumYCells(); diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborsFilter.hpp index 6e3e228b27..a064c18038 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNeighborsFilter.hpp @@ -89,17 +89,20 @@ class SIMPLNXCORE_EXPORT FindNeighborsFilter : public IFilter * @param messageHandler * @return PreflightResult */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNumFeaturesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNumFeaturesFilter.hpp index b822e0651e..c9d0375fcd 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNumFeaturesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindNumFeaturesFilter.hpp @@ -97,7 +97,8 @@ class SIMPLNXCORE_EXPORT FindNumFeaturesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindSurfaceAreaToVolumeFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindSurfaceAreaToVolumeFilter.hpp index 53c711e175..4c3bc655b1 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindSurfaceAreaToVolumeFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindSurfaceAreaToVolumeFilter.hpp @@ -101,7 +101,8 @@ class SIMPLNXCORE_EXPORT FindSurfaceAreaToVolumeFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindSurfaceFeaturesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindSurfaceFeaturesFilter.hpp index f2277cd221..3466ced182 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindSurfaceFeaturesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindSurfaceFeaturesFilter.hpp @@ -114,7 +114,8 @@ class SIMPLNXCORE_EXPORT FindSurfaceFeaturesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindTriangleGeomCentroidsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindTriangleGeomCentroidsFilter.hpp index f5d71cc3bd..cc6f195a23 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindTriangleGeomCentroidsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindTriangleGeomCentroidsFilter.hpp @@ -91,7 +91,8 @@ class SIMPLNXCORE_EXPORT FindTriangleGeomCentroidsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindTriangleGeomSizesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindTriangleGeomSizesFilter.hpp index 47cf26e25a..6ff9ef6bc4 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindTriangleGeomSizesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindTriangleGeomSizesFilter.hpp @@ -91,7 +91,8 @@ class SIMPLNXCORE_EXPORT FindTriangleGeomSizesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindVertexToTriangleDistancesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindVertexToTriangleDistancesFilter.hpp index c9650d849d..d78d34a347 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindVertexToTriangleDistancesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindVertexToTriangleDistancesFilter.hpp @@ -89,7 +89,7 @@ class SIMPLNXCORE_EXPORT FindVertexToTriangleDistancesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -99,7 +99,8 @@ class SIMPLNXCORE_EXPORT FindVertexToTriangleDistancesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindVolFractionsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindVolFractionsFilter.hpp index 18b925d15e..9560492db3 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindVolFractionsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/FindVolFractionsFilter.hpp @@ -97,7 +97,8 @@ class SIMPLNXCORE_EXPORT FindVolFractionsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/GenerateColorTableFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/GenerateColorTableFilter.hpp index 85838bb398..95bf36a96a 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/GenerateColorTableFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/GenerateColorTableFilter.hpp @@ -102,7 +102,8 @@ class SIMPLNXCORE_EXPORT GenerateColorTableFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/GeneratePythonSkeletonFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/GeneratePythonSkeletonFilter.hpp index d062e4b582..040b97b073 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/GeneratePythonSkeletonFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/GeneratePythonSkeletonFilter.hpp @@ -90,7 +90,7 @@ class SIMPLNXCORE_EXPORT GeneratePythonSkeletonFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -100,7 +100,8 @@ class SIMPLNXCORE_EXPORT GeneratePythonSkeletonFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/GenerateVectorColorsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/GenerateVectorColorsFilter.hpp index b46a35a77e..1809e8fe6a 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/GenerateVectorColorsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/GenerateVectorColorsFilter.hpp @@ -88,7 +88,7 @@ class SIMPLNXCORE_EXPORT GenerateVectorColorsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -98,7 +98,8 @@ class SIMPLNXCORE_EXPORT GenerateVectorColorsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IdentifySampleFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IdentifySampleFilter.cpp index 4939d44c47..4b51845c65 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IdentifySampleFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IdentifySampleFilter.cpp @@ -19,14 +19,14 @@ constexpr int64 k_MISSING_GEOM_ERR = -650; struct IdentifySampleFunctor { template - void operator()(DataStructure& data, const DataPath& imageGeomPath, const DataPath& goodVoxelsArrayPath, bool fillHoles) + void operator()(DataStructure& dataStructure, const DataPath& imageGeomPath, const DataPath& goodVoxelsArrayPath, bool fillHoles) { using ArrayType = DataArray; - const auto* imageGeom = data.getDataAs(imageGeomPath); + const auto* imageGeom = dataStructure.getDataAs(imageGeomPath); std::vector cDims = {1}; - auto* goodVoxelsPtr = data.getDataAs(goodVoxelsArrayPath); + auto* goodVoxelsPtr = dataStructure.getDataAs(goodVoxelsArrayPath); auto& goodVoxels = goodVoxelsPtr->getDataStoreRef(); const auto totalPoints = static_cast(goodVoxelsPtr->getNumberOfTuples()); @@ -280,12 +280,13 @@ IFilter::UniquePointer IdentifySampleFilter::clone() const } //------------------------------------------------------------------------------ -IFilter::PreflightResult IdentifySampleFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +IFilter::PreflightResult IdentifySampleFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { const auto imageGeomPath = args.value(k_SelectedImageGeometryPath_Key); const auto goodVoxelsArrayPath = args.value(k_MaskArrayPath_Key); - const auto& inputData = data.getDataRefAs(goodVoxelsArrayPath); + const auto& inputData = dataStructure.getDataRefAs(goodVoxelsArrayPath); const DataType arrayType = inputData.getDataType(); if(arrayType != DataType::boolean && arrayType != DataType::uint8) { @@ -298,17 +299,17 @@ IFilter::PreflightResult IdentifySampleFilter::preflightImpl(const DataStructure } //------------------------------------------------------------------------------ -Result<> IdentifySampleFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> IdentifySampleFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { const auto fillHoles = args.value(k_FillHoles_Key); const auto imageGeomPath = args.value(k_SelectedImageGeometryPath_Key); const auto goodVoxelsArrayPath = args.value(k_MaskArrayPath_Key); - const auto& inputData = data.getDataRefAs(goodVoxelsArrayPath); + const auto& inputData = dataStructure.getDataRefAs(goodVoxelsArrayPath); const DataType arrayType = inputData.getDataType(); - ExecuteDataFunction(IdentifySampleFunctor{}, arrayType, data, imageGeomPath, goodVoxelsArrayPath, fillHoles); + ExecuteDataFunction(IdentifySampleFunctor{}, arrayType, dataStructure, imageGeomPath, goodVoxelsArrayPath, fillHoles); return {}; } diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IdentifySampleFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IdentifySampleFilter.hpp index 09acd622b9..37ae6e2e7c 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IdentifySampleFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IdentifySampleFilter.hpp @@ -82,17 +82,20 @@ class SIMPLNXCORE_EXPORT IdentifySampleFilter : public IFilter * @param messageHandler * @return PreflightResult */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeDataFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeDataFilter.cpp index 967eba100f..76f2eb8f0c 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeDataFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeDataFilter.cpp @@ -487,7 +487,8 @@ IFilter::UniquePointer InitializeDataFilter::clone() const } //------------------------------------------------------------------------------ -IFilter::PreflightResult InitializeDataFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +IFilter::PreflightResult InitializeDataFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { auto seedArrayNameValue = args.value(k_SeedArrayName_Key); auto initializeTypeValue = static_cast(args.value(k_InitType_Key)); @@ -495,7 +496,7 @@ IFilter::PreflightResult InitializeDataFilter::preflightImpl(const DataStructure nx::core::Result resultOutputActions; std::vector preflightUpdatedValues; - auto& iDataArray = data.getDataRefAs(args.value(k_ArrayPath_Key)); + auto& iDataArray = dataStructure.getDataRefAs(args.value(k_ArrayPath_Key)); usize numComp = iDataArray.getNumberOfComponents(); // check that the values string is greater than max comps if(iDataArray.getDataType() == DataType::boolean) @@ -663,7 +664,7 @@ IFilter::PreflightResult InitializeDataFilter::preflightImpl(const DataStructure } //------------------------------------------------------------------------------ -Result<> InitializeDataFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> InitializeDataFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto initType = static_cast(args.value(k_InitType_Key)); @@ -677,7 +678,7 @@ Result<> InitializeDataFilter::executeImpl(DataStructure& data, const Arguments& if(initType == InitializeType::Random || initType == InitializeType::RangedRandom) { // Store Seed Value in Top Level Array - data.getDataRefAs(DataPath({args.value(k_SeedArrayName_Key)}))[0] = seed; + dataStructure.getDataRefAs(DataPath({args.value(k_SeedArrayName_Key)}))[0] = seed; } InitializeDataInputValues inputValues; @@ -692,7 +693,7 @@ Result<> InitializeDataFilter::executeImpl(DataStructure& data, const Arguments& inputValues.randEnd = StringUtilities::split(StringUtilities::trimmed(args.value(k_InitEndRange_Key)), k_DelimiterChar); inputValues.standardizeSeed = args.value(k_StandardizeSeed_Key); - auto& iDataArray = data.getDataRefAs(args.value(k_ArrayPath_Key)); + auto& iDataArray = dataStructure.getDataRefAs(args.value(k_ArrayPath_Key)); ExecuteDataFunction(::FillArrayFunctor{}, iDataArray.getDataType(), iDataArray, inputValues); diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeDataFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeDataFilter.hpp index b59579a155..9d7c24026f 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeDataFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeDataFilter.hpp @@ -85,7 +85,7 @@ class SIMPLNXCORE_EXPORT InitializeDataFilter : public IFilter * @param shouldCancel * @return PreflightResult */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief @@ -96,7 +96,8 @@ class SIMPLNXCORE_EXPORT InitializeDataFilter : public IFilter * @param shouldCancel * @return Result<> */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; private: uint64 m_Seed = 0; diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeImageGeomCellDataFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeImageGeomCellDataFilter.cpp index 074a31e22d..83423bb74d 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeImageGeomCellDataFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeImageGeomCellDataFilter.cpp @@ -225,7 +225,7 @@ IFilter::UniquePointer InitializeImageGeomCellDataFilter::clone() const } //------------------------------------------------------------------------------ -IFilter::PreflightResult InitializeImageGeomCellDataFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, +IFilter::PreflightResult InitializeImageGeomCellDataFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto cellArrayPaths = args.value(k_CellArrayPaths_Key); @@ -268,7 +268,7 @@ IFilter::PreflightResult InitializeImageGeomCellDataFilter::preflightImpl(const errors.push_back(Error{-5553, fmt::format("Z Max ({}) less than Z Min ({})", zMax, zMin)}); } - const auto& imageGeom = data.getDataRefAs(imageGeomPath); + const auto& imageGeom = dataStructure.getDataRefAs(imageGeomPath); if(xMax > (static_cast(imageGeom.getNumXCells()) - 1)) { @@ -289,7 +289,7 @@ IFilter::PreflightResult InitializeImageGeomCellDataFilter::preflightImpl(const for(const DataPath& path : cellArrayPaths) { - const auto& dataArray = data.getDataRefAs(path); + const auto& dataArray = dataStructure.getDataRefAs(path); std::vector tupleShape = dataArray.getIDataStoreRef().getTupleShape(); if(tupleShape.size() != reversedImageDims.size()) @@ -321,7 +321,7 @@ IFilter::PreflightResult InitializeImageGeomCellDataFilter::preflightImpl(const } //------------------------------------------------------------------------------ -Result<> InitializeImageGeomCellDataFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> InitializeImageGeomCellDataFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto cellArrayPaths = args.value(k_CellArrayPaths_Key); @@ -339,7 +339,7 @@ Result<> InitializeImageGeomCellDataFilter::executeImpl(DataStructure& data, con } // Store Seed Value in Top Level Array - data.getDataRefAs(DataPath({args.value(k_SeedArrayName_Key)}))[0] = seed; + dataStructure.getDataRefAs(DataPath({args.value(k_SeedArrayName_Key)}))[0] = seed; uint64 xMin = minPoint.at(0); uint64 yMin = minPoint.at(1); @@ -352,13 +352,13 @@ Result<> InitializeImageGeomCellDataFilter::executeImpl(DataStructure& data, con InitType initType = ConvertIndexToInitType(initTypeIndex); RangeType initRange = {initRangeVec.at(0), initRangeVec.at(1)}; - const ImageGeom& imageGeom = data.getDataRefAs(imageGeomPath); + const ImageGeom& imageGeom = dataStructure.getDataRefAs(imageGeomPath); std::array dims = imageGeom.getDimensions().toArray(); for(const DataPath& path : cellArrayPaths) { - auto& iDataArray = data.getDataRefAs(path); + auto& iDataArray = dataStructure.getDataRefAs(path); ExecuteNeighborFunction(InitializeArrayFunctor{}, iDataArray.getDataType(), iDataArray, dims, xMin, xMax, yMin, yMax, zMin, zMax, initType, initValue, initRange, seed); // NO BOOL diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeImageGeomCellDataFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeImageGeomCellDataFilter.hpp index 59c9d77953..ddd71617b0 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeImageGeomCellDataFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InitializeImageGeomCellDataFilter.hpp @@ -97,7 +97,7 @@ class SIMPLNXCORE_EXPORT InitializeImageGeomCellDataFilter : public IFilter * @param shouldCancel * @return PreflightResult */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief @@ -108,7 +108,8 @@ class SIMPLNXCORE_EXPORT InitializeImageGeomCellDataFilter : public IFilter * @param shouldCancel * @return Result<> */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; private: uint64 m_Seed = 0; diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InterpolatePointCloudToRegularGridFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InterpolatePointCloudToRegularGridFilter.cpp index e0a05b8037..cac327b61d 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InterpolatePointCloudToRegularGridFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InterpolatePointCloudToRegularGridFilter.cpp @@ -336,7 +336,7 @@ IFilter::PreflightResult InterpolatePointCloudToRegularGridFilter::preflightImpl } //------------------------------------------------------------------------------ -Result<> InterpolatePointCloudToRegularGridFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> InterpolatePointCloudToRegularGridFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto useMask = args.value(k_UseMask_Key); @@ -353,8 +353,8 @@ Result<> InterpolatePointCloudToRegularGridFilter::executeImpl(DataStructure& da const DataPath interpolatedGroupPath = imageGeomPath.createChildPath(interpolatedGroupName); const auto sigmas = args.value>(k_GaussianSigmas_Key); - auto vertices = data.getDataAs(vertexGeomPath); - auto image = data.getDataAs(imageGeomPath); + auto vertices = dataStructure.getDataAs(vertexGeomPath); + auto image = dataStructure.getDataAs(imageGeomPath); SizeVec3 dims = image->getDimensions(); FloatVec3 res = image->getSpacing(); int64 kernelNumVoxels[3] = {0, 0, 0}; @@ -370,19 +370,19 @@ Result<> InterpolatePointCloudToRegularGridFilter::executeImpl(DataStructure& da BoolArray::store_type* mask = nullptr; if(useMask) { - mask = data.getDataAs(args.value(k_InputMaskPath_Key))->getDataStore(); + mask = dataStructure.getDataAs(args.value(k_InputMaskPath_Key))->getDataStore(); } - auto& voxelIndices = data.getDataRefAs(voxelIndicesPath); + auto& voxelIndices = dataStructure.getDataRefAs(voxelIndicesPath); // Make sure the NeighborList's outer most vector is resized to the number of tuples and initialized to non null values (empty vectors) for(const auto& interpolatedDataPath : interpolatedDataPaths) { - InitializeNeighborList(data, interpolatedGroupPath.createChildPath(interpolatedDataPath.getTargetName())); + InitializeNeighborList(dataStructure, interpolatedGroupPath.createChildPath(interpolatedDataPath.getTargetName())); } for(const auto& copyDataPath : copyDataPaths) { - InitializeNeighborList(data, interpolatedGroupPath.createChildPath(copyDataPath.getTargetName())); + InitializeNeighborList(dataStructure, interpolatedGroupPath.createChildPath(copyDataPath.getTargetName())); } usize maxImageIndex = ((dims[2] - 1) * dims[0] * dims[1]) + ((dims[1] - 1) * dims[0]) + (dims[0] - 1); @@ -455,8 +455,8 @@ Result<> InterpolatePointCloudToRegularGridFilter::executeImpl(DataStructure& da for(const auto& interpolatedDataPathItem : interpolatedDataPaths) { const auto dynamicArrayPath = interpolatedGroupPath.createChildPath(interpolatedDataPathItem.getTargetName()); - auto* dynamicArrayToInterpolate = data.getDataAs(dynamicArrayPath); - auto* sourceArray = data.getDataAs(interpolatedDataPathItem); + auto* dynamicArrayToInterpolate = dataStructure.getDataAs(dynamicArrayPath); + auto* sourceArray = dataStructure.getDataAs(interpolatedDataPathItem); const auto& type = sourceArray->getDataType(); if(type == DataType::boolean) // Can't be executed will throw error @@ -471,8 +471,8 @@ Result<> InterpolatePointCloudToRegularGridFilter::executeImpl(DataStructure& da for(const auto& copyDataPath : copyDataPaths) { auto dynamicArrayPath = interpolatedGroupPath.createChildPath(copyDataPath.getTargetName()); - auto* dynamicArrayToCopy = data.getDataAs(dynamicArrayPath); - auto* sourceArray = data.getDataAs(copyDataPath); + auto* dynamicArrayToCopy = dataStructure.getDataAs(dynamicArrayPath); + auto* sourceArray = dataStructure.getDataAs(copyDataPath); const auto& type = sourceArray->getDataType(); if(type == DataType::boolean) // Can't be executed will throw error @@ -487,8 +487,8 @@ Result<> InterpolatePointCloudToRegularGridFilter::executeImpl(DataStructure& da if(storeKernelDistances) { const DataPath kernelDistPath = interpolatedGroupPath.createChildPath(args.value(k_KernelDistancesArrayName_Key)); - InitializeNeighborList(data, kernelDistPath); - auto* kernelDistances = data.getDataAs(kernelDistPath); + InitializeNeighborList(dataStructure, kernelDistPath); + auto* kernelDistances = dataStructure.getDataAs(kernelDistPath); mapKernelDistances(kernelDistances, kernelValDistances, kernel, kernelNumVoxels, dims.data(), x, y, z); } diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InterpolatePointCloudToRegularGridFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InterpolatePointCloudToRegularGridFilter.hpp index 90485c4ab9..320f7cace1 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InterpolatePointCloudToRegularGridFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/InterpolatePointCloudToRegularGridFilter.hpp @@ -101,14 +101,17 @@ class SIMPLNXCORE_EXPORT InterpolatePointCloudToRegularGridFilter : public IFilt PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IterativeClosestPointFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IterativeClosestPointFilter.cpp index 13c989056e..21e6acbc25 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IterativeClosestPointFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IterativeClosestPointFilter.cpp @@ -120,19 +120,20 @@ IFilter::UniquePointer IterativeClosestPointFilter::clone() const } //------------------------------------------------------------------------------ -IFilter::PreflightResult IterativeClosestPointFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +IFilter::PreflightResult IterativeClosestPointFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { auto movingVertexPath = args.value(k_MovingVertexPath_Key); auto targetVertexPath = args.value(k_TargetVertexPath_Key); auto numIterations = args.value(k_NumIterations_Key); auto transformArrayPath = args.value(k_TransformArrayPath_Key); - if(data.getDataAs(movingVertexPath) == nullptr) + if(dataStructure.getDataAs(movingVertexPath) == nullptr) { auto ss = fmt::format("Moving Vertex Geometry not found at path: {}", movingVertexPath.toString()); return {nonstd::make_unexpected(std::vector{Error{k_MissingMovingVertex, ss}})}; } - if(data.getDataAs(targetVertexPath) == nullptr) + if(dataStructure.getDataAs(targetVertexPath) == nullptr) { auto ss = fmt::format("Target Vertex Geometry not found at path: {}", targetVertexPath.toString()); return {nonstd::make_unexpected(std::vector{Error{k_MissingTargetVertex, ss}})}; @@ -154,7 +155,7 @@ IFilter::PreflightResult IterativeClosestPointFilter::preflightImpl(const DataSt } //------------------------------------------------------------------------------ -Result<> IterativeClosestPointFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> IterativeClosestPointFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto movingVertexPath = args.value(k_MovingVertexPath_Key); @@ -163,8 +164,8 @@ Result<> IterativeClosestPointFilter::executeImpl(DataStructure& data, const Arg auto applyTransformation = args.value(k_ApplyTransformation_Key); auto transformArrayPath = args.value(k_TransformArrayPath_Key); - auto movingVertexGeom = data.getDataAs(movingVertexPath); - auto targetVertexGeom = data.getDataAs(targetVertexPath); + auto movingVertexGeom = dataStructure.getDataAs(movingVertexPath); + auto targetVertexGeom = dataStructure.getDataAs(targetVertexPath); if(movingVertexGeom == nullptr) { @@ -275,7 +276,7 @@ Result<> IterativeClosestPointFilter::executeImpl(DataStructure& data, const Arg counter++; } - auto* transformPtr = data.getDataAs(transformArrayPath)->getDataStore(); + auto* transformPtr = dataStructure.getDataAs(transformArrayPath)->getDataStore(); if(applyTransformation) { diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IterativeClosestPointFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IterativeClosestPointFilter.hpp index 4767a92775..7e2b8e1a3c 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IterativeClosestPointFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/IterativeClosestPointFilter.hpp @@ -84,17 +84,20 @@ class SIMPLNXCORE_EXPORT IterativeClosestPointFilter : public IFilter * @param messageHandler * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/KMeansFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/KMeansFilter.hpp index 69d48cbc61..1c38a43cb8 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/KMeansFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/KMeansFilter.hpp @@ -95,7 +95,7 @@ class SIMPLNXCORE_EXPORT KMeansFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -105,7 +105,8 @@ class SIMPLNXCORE_EXPORT KMeansFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/KMedoidsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/KMedoidsFilter.hpp index 25f494209f..f6f9c2c3b2 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/KMedoidsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/KMedoidsFilter.hpp @@ -95,7 +95,7 @@ class SIMPLNXCORE_EXPORT KMedoidsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -105,7 +105,8 @@ class SIMPLNXCORE_EXPORT KMedoidsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/LabelTriangleGeometryFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/LabelTriangleGeometryFilter.hpp index 12441f2142..9f17ec4aec 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/LabelTriangleGeometryFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/LabelTriangleGeometryFilter.hpp @@ -88,7 +88,7 @@ class SIMPLNXCORE_EXPORT LabelTriangleGeometryFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -98,7 +98,8 @@ class SIMPLNXCORE_EXPORT LabelTriangleGeometryFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/LaplacianSmoothingFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/LaplacianSmoothingFilter.hpp index 192d3af71d..aa0bb6b93c 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/LaplacianSmoothingFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/LaplacianSmoothingFilter.hpp @@ -94,6 +94,7 @@ class SIMPLNXCORE_EXPORT LaplacianSmoothingFilter : public IFilter * @param dataStructure The input DataStructure instance * @param filterArgs These are the input values for each parameter that is required for the filter * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; @@ -103,10 +104,13 @@ class SIMPLNXCORE_EXPORT LaplacianSmoothingFilter : public IFilter * On failure, there is no guarantee that the DataStructure is in a correct state. * @param dataStructure The input DataStructure instance * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MapPointCloudToRegularGridFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MapPointCloudToRegularGridFilter.cpp index 392382d96f..1561eacc39 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MapPointCloudToRegularGridFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MapPointCloudToRegularGridFilter.cpp @@ -26,7 +26,7 @@ constexpr int64 k_BadGridDimensions = -2601; constexpr int64 k_InvalidVertexGeometry = -2602; constexpr int64 k_IncompatibleMaskVoxelArrays = -2603; -void createRegularGrid(DataStructure& data, const Arguments& args) +void createRegularGrid(DataStructure& dataStructure, const Arguments& args) { const auto samplingGridType = args.value(MapPointCloudToRegularGridFilter::k_SamplingGridType_Key); const auto vertexGeomPath = args.value(MapPointCloudToRegularGridFilter::k_SelectedVertexGeometryPath_Key); @@ -39,13 +39,13 @@ void createRegularGrid(DataStructure& data, const Arguments& args) return; } - const auto* pointCloud = data.getDataAs(vertexGeomPath); - auto* image = data.getDataAs(newImageGeomPath); + const auto* pointCloud = dataStructure.getDataAs(vertexGeomPath); + auto* image = dataStructure.getDataAs(newImageGeomPath); int64 numVerts = pointCloud->getNumberOfVertices(); auto* vertex = pointCloud->getVertices(); - const auto* mask = data.getDataAs(maskArrayPath); + const auto* mask = dataStructure.getDataAs(maskArrayPath); // Find the largest/smallest (x,y,z) dimensions of the incoming data to be used to define the maximum dimensions for the regular grid std::vector meshMaxExtents; @@ -256,7 +256,7 @@ IFilter::UniquePointer MapPointCloudToRegularGridFilter::clone() const } //------------------------------------------------------------------------------ -IFilter::PreflightResult MapPointCloudToRegularGridFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, +IFilter::PreflightResult MapPointCloudToRegularGridFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto samplingGridType = args.value(k_SamplingGridType_Key); @@ -286,7 +286,7 @@ IFilter::PreflightResult MapPointCloudToRegularGridFilter::preflightImpl(const D actions.appendAction(std::move(imageAction)); } - const auto& vertexGeom = data.getDataRefAs(vertexGeomPath); + const auto& vertexGeom = dataStructure.getDataRefAs(vertexGeomPath); const AttributeMatrix* vertexData = vertexGeom.getVertexAttributeMatrix(); if(vertexData == nullptr) { @@ -298,7 +298,7 @@ IFilter::PreflightResult MapPointCloudToRegularGridFilter::preflightImpl(const D if(useMask) { auto maskArrayPath = args.value(k_InputMaskPath_Key); - const auto numMaskTuples = data.getDataRefAs(maskArrayPath).getNumberOfTuples(); + const auto numMaskTuples = dataStructure.getDataRefAs(maskArrayPath).getNumberOfTuples(); const auto numVoxelTuples = vertexData->getNumTuples(); if(numMaskTuples != numVoxelTuples) { @@ -315,7 +315,7 @@ IFilter::PreflightResult MapPointCloudToRegularGridFilter::preflightImpl(const D } //------------------------------------------------------------------------------ -Result<> MapPointCloudToRegularGridFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> MapPointCloudToRegularGridFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { const auto samplingGridType = args.value(k_SamplingGridType_Key); @@ -329,18 +329,18 @@ Result<> MapPointCloudToRegularGridFilter::executeImpl(DataStructure& data, cons { // Create the regular grid messageHandler("Creating Regular Grid"); - createRegularGrid(data, args); - image = data.getDataAs(args.value(k_CreatedImageGeometryPath_Key)); + createRegularGrid(dataStructure, args); + image = dataStructure.getDataAs(args.value(k_CreatedImageGeometryPath_Key)); } else if(samplingGridType == 1) { - image = data.getDataAs(args.value(k_SelectedImageGeometryPath_Key)); + image = dataStructure.getDataAs(args.value(k_SelectedImageGeometryPath_Key)); } - const auto& vertices = data.getDataRefAs(vertexGeomPath); + const auto& vertices = dataStructure.getDataRefAs(vertexGeomPath); const DataPath voxelIndicesPath = vertexGeomPath.createChildPath(vertices.getVertexAttributeMatrix()->getName()).createChildPath(voxelIndicesName); - auto& voxelIndices = data.getDataRefAs(voxelIndicesPath); - const auto* mask = data.getDataAs(maskArrayPath); + auto& voxelIndices = dataStructure.getDataRefAs(voxelIndicesPath); + const auto* mask = dataStructure.getDataAs(maskArrayPath); int64 numVerts = vertices.getNumberOfVertices(); SizeVec3 dims = image->getDimensions(); diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MapPointCloudToRegularGridFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MapPointCloudToRegularGridFilter.hpp index 10a1bfc270..5a2518269e 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MapPointCloudToRegularGridFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MapPointCloudToRegularGridFilter.hpp @@ -92,17 +92,20 @@ class SIMPLNXCORE_EXPORT MapPointCloudToRegularGridFilter : public IFilter * @param messageHandler * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MinNeighborsFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MinNeighborsFilter.cpp index 4f2ec0de2f..9bebeac9f5 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MinNeighborsFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MinNeighborsFilter.cpp @@ -22,7 +22,7 @@ constexpr int64 k_MissingFeaturePhasesError = -251; constexpr int32 k_InconsistentTupleCount = -252; constexpr int32 k_FetchChildArrayError = -5559; -void assignBadPoints(DataStructure& data, const Arguments& args, const std::atomic_bool& shouldCancel) +void assignBadPoints(DataStructure& dataStructure, const Arguments& args, const std::atomic_bool& shouldCancel) { auto imageGeomPath = args.value(MinNeighborsFilter::k_SelectedImageGeometryPath_Key); auto featureIdsPath = args.value(MinNeighborsFilter::k_FeatureIdsPath_Key); @@ -30,8 +30,8 @@ void assignBadPoints(DataStructure& data, const Arguments& args, const std::atom auto ignoredVoxelArrayPaths = args.value>(MinNeighborsFilter::k_IgnoredVoxelArrays_Key); auto cellDataAttrMatrix = args.value(MinNeighborsFilter::k_CellDataAttributeMatrixPath_Key); - auto& featureIdsArray = data.getDataRefAs(featureIdsPath); - auto& numNeighborsArray = data.getDataRefAs(numNeighborsPath); + auto& featureIdsArray = dataStructure.getDataRefAs(featureIdsPath); + auto& numNeighborsArray = dataStructure.getDataRefAs(numNeighborsPath); auto& featureIds = featureIdsArray.getDataStoreRef(); @@ -40,16 +40,16 @@ void assignBadPoints(DataStructure& data, const Arguments& args, const std::atom if(applyToSinglePhase) { auto featurePhasesPath = args.value(MinNeighborsFilter::k_FeaturePhasesPath_Key); - featurePhasesArray = data.getDataAs(featurePhasesPath); + featurePhasesArray = dataStructure.getDataAs(featurePhasesPath); } usize totalPoints = featureIdsArray.getNumberOfTuples(); - SizeVec3 udims = data.getDataRefAs(imageGeomPath).getDimensions(); + SizeVec3 udims = dataStructure.getDataRefAs(imageGeomPath).getDimensions(); // This was checked up in the execute function (which is called before this function) // so if we got this far then all should be good with the return. We might get // an empty vector<> but that is OK. - std::vector cellDataArrayPaths = nx::core::GetAllChildDataPaths(data, cellDataAttrMatrix, DataObject::Type::DataArray).value(); + std::vector cellDataArrayPaths = nx::core::GetAllChildDataPaths(dataStructure, cellDataAttrMatrix, DataObject::Type::DataArray).value(); std::array dims = { static_cast(udims[0]), @@ -199,7 +199,7 @@ void assignBadPoints(DataStructure& data, const Arguments& args, const std::atom { for(const auto& cellArrayPath : cellDataArrayPaths) { - auto* voxelArray = data.getDataAs(cellArrayPath); + auto* voxelArray = dataStructure.getDataAs(cellArrayPath); dynamic_cast(voxelArray)->copyTuple(neighbor, featureIdIndex); } } @@ -207,7 +207,7 @@ void assignBadPoints(DataStructure& data, const Arguments& args, const std::atom } } -nonstd::expected, Error> mergeContainedFeatures(DataStructure& data, const Arguments& args, const std::atomic_bool& shouldCancel) +nonstd::expected, Error> mergeContainedFeatures(DataStructure& dataStructure, const Arguments& args, const std::atomic_bool& shouldCancel) { auto imageGeomPath = args.value(MinNeighborsFilter::k_SelectedImageGeometryPath_Key); auto featureIdsPath = args.value(MinNeighborsFilter::k_FeatureIdsPath_Key); @@ -216,8 +216,8 @@ nonstd::expected, Error> mergeContainedFeatures(DataStructure& auto phaseNumber = args.value(MinNeighborsFilter::k_PhaseNumber_Key); - auto& featureIdsArray = data.getDataRefAs(featureIdsPath); - auto& numNeighborsArray = data.getDataRefAs(numNeighborsPath); + auto& featureIdsArray = dataStructure.getDataRefAs(featureIdsPath); + auto& numNeighborsArray = dataStructure.getDataRefAs(numNeighborsPath); auto& featureIds = featureIdsArray.getDataStoreRef(); auto& numNeighbors = numNeighborsArray.getDataStoreRef(); @@ -227,11 +227,11 @@ nonstd::expected, Error> mergeContainedFeatures(DataStructure& if(applyToSinglePhase) { auto featurePhasesPath = args.value(MinNeighborsFilter::k_FeaturePhasesPath_Key); - featurePhasesArray = data.getDataAs(featurePhasesPath); + featurePhasesArray = dataStructure.getDataAs(featurePhasesPath); } bool good = false; - usize totalPoints = data.getDataRefAs(imageGeomPath).getNumberOfCells(); + usize totalPoints = dataStructure.getDataRefAs(imageGeomPath).getNumberOfCells(); usize totalFeatures = numNeighborsArray.getNumberOfTuples(); std::vector activeObjects(totalFeatures, true); @@ -413,7 +413,7 @@ IFilter::PreflightResult MinNeighborsFilter::preflightImpl(const DataStructure& } //------------------------------------------------------------------------------ -Result<> MinNeighborsFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> MinNeighborsFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto featurePhasesPath = args.value(k_FeaturePhasesPath_Key); @@ -454,7 +454,7 @@ Result<> MinNeighborsFilter::executeImpl(DataStructure& data, const Arguments& a } auto cellDataAttrMatrix = args.value(MinNeighborsFilter::k_CellDataAttributeMatrixPath_Key); - auto result = nx::core::GetAllChildDataPaths(data, cellDataAttrMatrix, DataObject::Type::DataArray); + auto result = nx::core::GetAllChildDataPaths(dataStructure, cellDataAttrMatrix, DataObject::Type::DataArray); if(!result.has_value()) { return MakeErrorResult(-5556, fmt::format("Error fetching all Data Arrays from Group '{}'", cellDataAttrMatrix.toString())); @@ -464,10 +464,10 @@ Result<> MinNeighborsFilter::executeImpl(DataStructure& data, const Arguments& a assignBadPoints(dataStructure, args, shouldCancel); auto featureIdsPath = args.value(MinNeighborsFilter::k_FeatureIdsPath_Key); - auto& featureIdsArray = data.getDataRefAs(featureIdsPath); + auto& featureIdsArray = dataStructure.getDataRefAs(featureIdsPath); auto numNeighborsPath = args.value(MinNeighborsFilter::k_NumNeighborsPath_Key); - auto& numNeighborsArray = data.getDataRefAs(numNeighborsPath); + auto& numNeighborsArray = dataStructure.getDataRefAs(numNeighborsPath); DataPath cellFeatureGroupPath = numNeighborsPath.getParent(); size_t currentFeatureCount = numNeighborsArray.getNumberOfTuples(); diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MinNeighborsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MinNeighborsFilter.hpp index ed19e85875..79717b03ae 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MinNeighborsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MinNeighborsFilter.hpp @@ -82,23 +82,29 @@ class SIMPLNXCORE_EXPORT MinNeighborsFilter : public IFilter protected: /** - * @brief - * @param dataStructure - * @param args - * @param messageHandler - * @return PreflightResult + * @brief Takes in a DataStructure and checks that the filter can be run on it with the given arguments. + * Returns any warnings/errors. Also returns the changes that would be applied to the DataStructure. + * Some parts of the actions may not be completely filled out if all the required information is not available at preflight time. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MoveDataFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MoveDataFilter.cpp index 0f71c47cfd..f7d762623c 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MoveDataFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MoveDataFilter.cpp @@ -60,7 +60,7 @@ IFilter::UniquePointer MoveDataFilter::clone() const } //------------------------------------------------------------------------------ -IFilter::PreflightResult MoveDataFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +IFilter::PreflightResult MoveDataFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto dataPaths = args.value(k_SourceDataPaths_Key); auto newParentPath = args.value(k_DestinationParentPath_Key); @@ -70,12 +70,12 @@ IFilter::PreflightResult MoveDataFilter::preflightImpl(const DataStructure& data // Scope AM check since we fully expect it to be a nullptr { - const auto* possibleAM = data.getDataAs(newParentPath); + const auto* possibleAM = dataStructure.getDataAs(newParentPath); if(possibleAM != nullptr) { for(const auto& path : dataPaths) { - const auto* possibleIArray = data.getDataAs(path); + const auto* possibleIArray = dataStructure.getDataAs(path); if(possibleIArray != nullptr) { if(possibleAM->getShape() != possibleIArray->getTupleShape()) @@ -99,7 +99,8 @@ IFilter::PreflightResult MoveDataFilter::preflightImpl(const DataStructure& data } //------------------------------------------------------------------------------ -Result<> MoveDataFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +Result<> MoveDataFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { return {}; } diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MoveDataFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MoveDataFilter.hpp index ffae0aa9ff..b57845d7ec 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MoveDataFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MoveDataFilter.hpp @@ -81,17 +81,20 @@ class SIMPLNXCORE_EXPORT MoveDataFilter : public IFilter * @param messageHandler * @return PreflightResult */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MultiThresholdObjectsFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MultiThresholdObjectsFilter.cpp index d9e713bf38..8385b6c40d 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MultiThresholdObjectsFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MultiThresholdObjectsFilter.cpp @@ -431,7 +431,8 @@ IFilter::UniquePointer MultiThresholdObjectsFilter::clone() const } // ----------------------------------------------------------------------------- -IFilter::PreflightResult MultiThresholdObjectsFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +IFilter::PreflightResult MultiThresholdObjectsFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { auto thresholdsObject = args.value(k_ArrayThresholdsObject_Key); auto maskArrayName = args.value(k_CreatedDataName_Key); @@ -450,7 +451,7 @@ IFilter::PreflightResult MultiThresholdObjectsFilter::preflightImpl(const DataSt for(const auto& path : thresholdPaths) { - if(data.getData(path) == nullptr) + if(dataStructure.getData(path) == nullptr) { auto errorMessage = fmt::format("Could not find DataArray at path {}.", path.toString()); return {nonstd::make_unexpected(std::vector{Error{to_underlying(ErrorCodes::PathNotFoundError), errorMessage}})}; @@ -460,7 +461,7 @@ IFilter::PreflightResult MultiThresholdObjectsFilter::preflightImpl(const DataSt // Check for Scalar arrays for(const auto& dataPath : thresholdPaths) { - const auto* currentDataArray = data.getDataAs(dataPath); + const auto* currentDataArray = dataStructure.getDataAs(dataPath); if(currentDataArray != nullptr && currentDataArray->getNumberOfComponents() != 1) { auto errorMessage = fmt::format("Data Array is not a Scalar Data Array. Data Arrays must only have a single component. '{}:{}'", dataPath.toString(), currentDataArray->getNumberOfComponents()); @@ -470,12 +471,12 @@ IFilter::PreflightResult MultiThresholdObjectsFilter::preflightImpl(const DataSt // Check that all arrays the number of tuples match DataPath firstDataPath = *(thresholdPaths.begin()); - const auto* dataArray = data.getDataAs(firstDataPath); + const auto* dataArray = dataStructure.getDataAs(firstDataPath); size_t numTuples = dataArray->getNumberOfTuples(); for(const auto& dataPath : thresholdPaths) { - const auto* currentDataArray = data.getDataAs(dataPath); + const auto* currentDataArray = dataStructure.getDataAs(dataPath); if(numTuples != currentDataArray->getNumberOfTuples()) { auto errorMessage = diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MultiThresholdObjectsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MultiThresholdObjectsFilter.hpp index d77de96659..b792446146 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MultiThresholdObjectsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/MultiThresholdObjectsFilter.hpp @@ -96,17 +96,20 @@ class SIMPLNXCORE_EXPORT MultiThresholdObjectsFilter : public IFilter * @param messageHandler * @return PreflightResult */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/NearestPointFuseRegularGridsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/NearestPointFuseRegularGridsFilter.hpp index 56b2d64764..ea483b9972 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/NearestPointFuseRegularGridsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/NearestPointFuseRegularGridsFilter.hpp @@ -90,7 +90,7 @@ class SIMPLNXCORE_EXPORT NearestPointFuseRegularGridsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -100,7 +100,8 @@ class SIMPLNXCORE_EXPORT NearestPointFuseRegularGridsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/PointSampleTriangleGeometryFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/PointSampleTriangleGeometryFilter.hpp index 7e96fd1b94..985213151c 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/PointSampleTriangleGeometryFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/PointSampleTriangleGeometryFilter.hpp @@ -108,7 +108,8 @@ class SIMPLNXCORE_EXPORT PointSampleTriangleGeometryFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/QuickSurfaceMeshFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/QuickSurfaceMeshFilter.hpp index 6143b29724..85fe52e6fb 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/QuickSurfaceMeshFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/QuickSurfaceMeshFilter.hpp @@ -109,7 +109,8 @@ class SIMPLNXCORE_EXPORT QuickSurfaceMeshFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadBinaryCTNorthstarFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadBinaryCTNorthstarFilter.hpp index fbf9594c04..1f44f7db78 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadBinaryCTNorthstarFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadBinaryCTNorthstarFilter.hpp @@ -108,7 +108,7 @@ class SIMPLNXCORE_EXPORT ReadBinaryCTNorthstarFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -118,7 +118,8 @@ class SIMPLNXCORE_EXPORT ReadBinaryCTNorthstarFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; private: int32 m_InstanceId; diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadDeformKeyFileV12Filter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadDeformKeyFileV12Filter.hpp index eea82bfb05..213b7771b1 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadDeformKeyFileV12Filter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadDeformKeyFileV12Filter.hpp @@ -103,7 +103,8 @@ class SIMPLNXCORE_EXPORT ReadDeformKeyFileV12Filter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; private: int32 m_InstanceId; diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadHDF5DatasetFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadHDF5DatasetFilter.hpp index 662ed47d43..cfb7cb8f78 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadHDF5DatasetFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadHDF5DatasetFilter.hpp @@ -97,7 +97,8 @@ class SIMPLNXCORE_EXPORT ReadHDF5DatasetFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadRawBinaryFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadRawBinaryFilter.hpp index b20a91afa3..13abd01b5f 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadRawBinaryFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadRawBinaryFilter.hpp @@ -106,7 +106,8 @@ class SIMPLNXCORE_EXPORT ReadRawBinaryFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadStlFileFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadStlFileFilter.cpp index dec90dc579..10142a36e3 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadStlFileFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadStlFileFilter.cpp @@ -165,7 +165,7 @@ IFilter::PreflightResult ReadStlFileFilter::preflightImpl(const DataStructure& d } //------------------------------------------------------------------------------ -Result<> ReadStlFileFilter::executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> ReadStlFileFilter::executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto pStlFilePathValue = filterArgs.value(k_StlFilePath_Key); @@ -182,7 +182,7 @@ Result<> ReadStlFileFilter::executeImpl(DataStructure& data, const Arguments& fi auto scaleFactor = filterArgs.value(k_ScaleFactor); // The actual STL File Reading is placed in a separate class `ReadStlFile` - Result<> result = ReadStlFile(data, pStlFilePathValue, pTriangleGeometryPath, pFaceDataGroupPath, pFaceNormalsPath, scaleOutput, scaleFactor, shouldCancel)(); + Result<> result = ReadStlFile(dataStructure, pStlFilePathValue, pTriangleGeometryPath, pFaceDataGroupPath, pFaceNormalsPath, scaleOutput, scaleFactor, shouldCancel)(); return result; } diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadStlFileFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadStlFileFilter.hpp index b9a0f0d553..5accce4b99 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadStlFileFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadStlFileFilter.hpp @@ -105,7 +105,8 @@ class SIMPLNXCORE_EXPORT ReadStlFileFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadTextDataArrayFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadTextDataArrayFilter.cpp index 709e41e6f3..8085bc82b5 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadTextDataArrayFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadTextDataArrayFilter.cpp @@ -88,7 +88,8 @@ IFilter::UniquePointer ReadTextDataArrayFilter::clone() const return std::make_unique(); } -IFilter::PreflightResult ReadTextDataArrayFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +IFilter::PreflightResult ReadTextDataArrayFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { auto numericType = args.value(k_ScalarType_Key); auto arrayPath = args.value(k_DataArrayPath_Key); @@ -102,7 +103,7 @@ IFilter::PreflightResult ReadTextDataArrayFilter::preflightImpl(const DataStruct std::vector tupleDims = {}; - auto* parentAM = data.getDataAs(arrayPath.getParent()); + auto* parentAM = dataStructure.getDataAs(arrayPath.getParent()); if(parentAM == nullptr) { if(!useDims) @@ -144,7 +145,7 @@ IFilter::PreflightResult ReadTextDataArrayFilter::preflightImpl(const DataStruct return {std::move(resultOutputActions)}; } -Result<> ReadTextDataArrayFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> ReadTextDataArrayFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto inputFilePath = args.value(k_InputFile_Key); @@ -158,43 +159,43 @@ Result<> ReadTextDataArrayFilter::executeImpl(DataStructure& data, const Argumen switch(numericType) { case NumericType::int8: { - auto dataArray = nx::core::ArrayFromPath(data, path); + auto dataArray = nx::core::ArrayFromPath(dataStructure, path); return CsvParser::ReadFile(inputFilePath, *dataArray, skipLines, delimiter); } case NumericType::uint8: { - auto dataArray = nx::core::ArrayFromPath(data, path); + auto dataArray = nx::core::ArrayFromPath(dataStructure, path); return CsvParser::ReadFile(inputFilePath, *dataArray, skipLines, delimiter); } case NumericType::int16: { - auto dataArray = nx::core::ArrayFromPath(data, path); + auto dataArray = nx::core::ArrayFromPath(dataStructure, path); return CsvParser::ReadFile(inputFilePath, *dataArray, skipLines, delimiter); } case NumericType::uint16: { - auto dataArray = nx::core::ArrayFromPath(data, path); + auto dataArray = nx::core::ArrayFromPath(dataStructure, path); return CsvParser::ReadFile(inputFilePath, *dataArray, skipLines, delimiter); } case NumericType::int32: { - auto dataArray = nx::core::ArrayFromPath(data, path); + auto dataArray = nx::core::ArrayFromPath(dataStructure, path); return CsvParser::ReadFile(inputFilePath, *dataArray, skipLines, delimiter); } case NumericType::uint32: { - auto dataArray = nx::core::ArrayFromPath(data, path); + auto dataArray = nx::core::ArrayFromPath(dataStructure, path); return CsvParser::ReadFile(inputFilePath, *dataArray, skipLines, delimiter); } case NumericType::int64: { - auto dataArray = nx::core::ArrayFromPath(data, path); + auto dataArray = nx::core::ArrayFromPath(dataStructure, path); return CsvParser::ReadFile(inputFilePath, *dataArray, skipLines, delimiter); } case NumericType::uint64: { - auto dataArray = nx::core::ArrayFromPath(data, path); + auto dataArray = nx::core::ArrayFromPath(dataStructure, path); return CsvParser::ReadFile(inputFilePath, *dataArray, skipLines, delimiter); } case NumericType::float32: { - auto dataArray = nx::core::ArrayFromPath(data, path); + auto dataArray = nx::core::ArrayFromPath(dataStructure, path); return CsvParser::ReadFile(inputFilePath, *dataArray, skipLines, delimiter); } case NumericType::float64: { - auto dataArray = nx::core::ArrayFromPath(data, path); + auto dataArray = nx::core::ArrayFromPath(dataStructure, path); return CsvParser::ReadFile(inputFilePath, *dataArray, skipLines, delimiter); } default: diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadTextDataArrayFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadTextDataArrayFilter.hpp index 305fbc15a8..08cc2d8870 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadTextDataArrayFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadTextDataArrayFilter.hpp @@ -86,17 +86,20 @@ class SIMPLNXCORE_EXPORT ReadTextDataArrayFilter : public IFilter * @param messageHandler * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadVtkStructuredPointsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadVtkStructuredPointsFilter.hpp index 33d5572b4c..4299c342ac 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadVtkStructuredPointsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReadVtkStructuredPointsFilter.hpp @@ -91,7 +91,7 @@ class SIMPLNXCORE_EXPORT ReadVtkStructuredPointsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -101,7 +101,8 @@ class SIMPLNXCORE_EXPORT ReadVtkStructuredPointsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RegularGridSampleSurfaceMeshFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RegularGridSampleSurfaceMeshFilter.hpp index db984b0389..43a9d69015 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RegularGridSampleSurfaceMeshFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RegularGridSampleSurfaceMeshFilter.hpp @@ -93,7 +93,7 @@ class SIMPLNXCORE_EXPORT RegularGridSampleSurfaceMeshFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -103,7 +103,8 @@ class SIMPLNXCORE_EXPORT RegularGridSampleSurfaceMeshFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedFeaturesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedFeaturesFilter.hpp index d0fa45b971..8613513038 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedFeaturesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedFeaturesFilter.hpp @@ -101,7 +101,8 @@ class SIMPLNXCORE_EXPORT RemoveFlaggedFeaturesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedTrianglesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedTrianglesFilter.hpp index 5c64ce64f1..fc38da088d 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedTrianglesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedTrianglesFilter.hpp @@ -87,7 +87,7 @@ class SIMPLNXCORE_EXPORT RemoveFlaggedTrianglesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -97,7 +97,8 @@ class SIMPLNXCORE_EXPORT RemoveFlaggedTrianglesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedVerticesFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedVerticesFilter.cpp index 091330f536..4b2c947d51 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedVerticesFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedVerticesFilter.cpp @@ -212,17 +212,17 @@ IFilter::PreflightResult RemoveFlaggedVerticesFilter::preflightImpl(const DataSt return {std::move(resultOutputActions), std::move(preflightUpdatedValues)}; } -Result<> RemoveFlaggedVerticesFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> RemoveFlaggedVerticesFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto vertexGeomPath = args.value(k_SelectedVertexGeometryPath_Key); auto maskArrayPath = args.value(k_InputMaskPath_Key); auto reducedVertexPath = args.value(k_CreatedVertexGeometryPath_Key); - const VertexGeom& vertexGeom = data.getDataRefAs(vertexGeomPath); + const VertexGeom& vertexGeom = dataStructure.getDataRefAs(vertexGeomPath); const std::string vertexDataName = vertexGeom.getVertexAttributeMatrixDataPath().getTargetName(); - auto& mask = data.getDataRefAs(maskArrayPath); + auto& mask = dataStructure.getDataRefAs(maskArrayPath); const size_t numVerticesToKeep = std::count(mask.begin(), mask.end(), false); const size_t numberOfVertices = vertexGeom.getNumberOfVertices(); @@ -230,7 +230,7 @@ Result<> RemoveFlaggedVerticesFilter::executeImpl(DataStructure& data, const Arg const std::vector tDims = {numVerticesToKeep}; // Resize the reduced vertex geometry object - VertexGeom& reducedVertexGeom = data.getDataRefAs(reducedVertexPath); + VertexGeom& reducedVertexGeom = dataStructure.getDataRefAs(reducedVertexPath); reducedVertexGeom.resizeVertexList(numVerticesToKeep); reducedVertexGeom.getVertexAttributeMatrix()->resizeTuples(tDims); @@ -260,7 +260,7 @@ Result<> RemoveFlaggedVerticesFilter::executeImpl(DataStructure& data, const Arg const DataPath destinationPath = reducedVertexGeom.getVertexAttributeMatrixDataPath().createChildPath(src.getName()); - auto& dest = data.getDataRefAs(destinationPath); + auto& dest = dataStructure.getDataRefAs(destinationPath); messageHandler(nx::core::IFilter::Message{nx::core::IFilter::Message::Type::Info, fmt::format("Copying source array '{}' to reduced geometry vertex data.", src.getName())}); ExecuteDataFunction(RemoveFlaggedVerticesFunctor{}, src.getDataType(), src, dest, mask, numVerticesToKeep); diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedVerticesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedVerticesFilter.hpp index 55115496d8..27fb72baf5 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedVerticesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveFlaggedVerticesFilter.hpp @@ -97,7 +97,8 @@ class SIMPLNXCORE_EXPORT RemoveFlaggedVerticesFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveMinimumSizeFeaturesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveMinimumSizeFeaturesFilter.hpp index e592d004ae..50734f0b30 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveMinimumSizeFeaturesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RemoveMinimumSizeFeaturesFilter.hpp @@ -83,23 +83,29 @@ class SIMPLNXCORE_EXPORT RemoveMinimumSizeFeaturesFilter : public IFilter protected: /** - * @brief - * @param dataStructure - * @param args - * @param messageHandler - * @return PreflightResult + * @brief Takes in a DataStructure and checks that the filter can be run on it with the given arguments. + * Returns any warnings/errors. Also returns the changes that would be applied to the DataStructure. + * Some parts of the actions may not be completely filled out if all the required information is not available at preflight time. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RenameDataObjectFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RenameDataObjectFilter.cpp index 030344a2bc..85d7eddd09 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RenameDataObjectFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RenameDataObjectFilter.cpp @@ -82,7 +82,7 @@ IFilter::PreflightResult RenameDataObjectFilter::preflightImpl(const DataStructu } //------------------------------------------------------------------------------ -Result<> RenameDataObjectFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> RenameDataObjectFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { return {}; diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RenameDataObjectFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RenameDataObjectFilter.hpp index dad971d4fb..17b8067544 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RenameDataObjectFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RenameDataObjectFilter.hpp @@ -86,7 +86,7 @@ class SIMPLNXCORE_EXPORT RenameDataObjectFilter : public IFilter * @param shouldCancel * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReplaceElementAttributesWithNeighborValuesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReplaceElementAttributesWithNeighborValuesFilter.hpp index 52d988d5a7..d1c9c782c1 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReplaceElementAttributesWithNeighborValuesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReplaceElementAttributesWithNeighborValuesFilter.hpp @@ -90,7 +90,7 @@ class SIMPLNXCORE_EXPORT ReplaceElementAttributesWithNeighborValuesFilter : publ * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -100,7 +100,8 @@ class SIMPLNXCORE_EXPORT ReplaceElementAttributesWithNeighborValuesFilter : publ * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ResampleImageGeomFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ResampleImageGeomFilter.hpp index 1bac3cbd47..97a576cae7 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ResampleImageGeomFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ResampleImageGeomFilter.hpp @@ -94,7 +94,7 @@ class SIMPLNXCORE_EXPORT ResampleImageGeomFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -104,7 +104,8 @@ class SIMPLNXCORE_EXPORT ResampleImageGeomFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ResampleRectGridToImageGeomFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ResampleRectGridToImageGeomFilter.hpp index 13faa11dd2..27ca6b6d4e 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ResampleRectGridToImageGeomFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ResampleRectGridToImageGeomFilter.hpp @@ -89,7 +89,7 @@ class SIMPLNXCORE_EXPORT ResampleRectGridToImageGeomFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -99,7 +99,8 @@ class SIMPLNXCORE_EXPORT ResampleRectGridToImageGeomFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReverseTriangleWindingFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReverseTriangleWindingFilter.hpp index 5aaceb52b6..38983695cc 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReverseTriangleWindingFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ReverseTriangleWindingFilter.hpp @@ -86,7 +86,7 @@ class SIMPLNXCORE_EXPORT ReverseTriangleWindingFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -96,7 +96,8 @@ class SIMPLNXCORE_EXPORT ReverseTriangleWindingFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RobustAutomaticThresholdFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RobustAutomaticThresholdFilter.cpp index 80271a7c19..4e14221b42 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RobustAutomaticThresholdFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RobustAutomaticThresholdFilter.cpp @@ -190,16 +190,16 @@ IFilter::PreflightResult RobustAutomaticThresholdFilter::preflightImpl(const Dat return {std::move(actions)}; } -Result<> RobustAutomaticThresholdFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> RobustAutomaticThresholdFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto inputArrayPath = args.value(k_InputArrayPath_Key); auto gradientArrayPath = args.value(k_GradientMagnitudePath_Key); auto createdMaskName = args.value(k_ArrayCreationName_Key); - const auto& inputArray = data.getDataRefAs(inputArrayPath); - const auto& gradientArray = data.getDataRefAs(gradientArrayPath); - auto& maskArray = data.getDataRefAs(inputArrayPath.replaceName(createdMaskName)); + const auto& inputArray = dataStructure.getDataRefAs(inputArrayPath); + const auto& gradientArray = dataStructure.getDataRefAs(gradientArrayPath); + auto& maskArray = dataStructure.getDataRefAs(inputArrayPath.replaceName(createdMaskName)); FindThreshold(inputArray, gradientArray, maskArray); diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RobustAutomaticThresholdFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RobustAutomaticThresholdFilter.hpp index 877f9d935a..203d25584b 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RobustAutomaticThresholdFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/RobustAutomaticThresholdFilter.hpp @@ -80,17 +80,20 @@ class SIMPLNXCORE_EXPORT RobustAutomaticThresholdFilter : public IFilter * @param messageHandler * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ScalarSegmentFeaturesFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ScalarSegmentFeaturesFilter.cpp index 16129f5fe4..650b39d87c 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ScalarSegmentFeaturesFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ScalarSegmentFeaturesFilter.cpp @@ -187,7 +187,7 @@ IFilter::PreflightResult ScalarSegmentFeaturesFilter::preflightImpl(const DataSt } // ----------------------------------------------------------------------------- -Result<> ScalarSegmentFeaturesFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> ScalarSegmentFeaturesFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { ScalarSegmentFeaturesInputValues inputValues; @@ -202,7 +202,7 @@ Result<> ScalarSegmentFeaturesFilter::executeImpl(DataStructure& data, const Arg inputValues.pCellFeaturesPath = inputValues.pGridGeomPath.createChildPath(args.value(k_CellFeatureName_Key)); inputValues.pActiveArrayPath = inputValues.pCellFeaturesPath.createChildPath(args.value(k_ActiveArrayName_Key)); - nx::core::ScalarSegmentFeatures filterAlgorithm(data, &inputValues, shouldCancel, messageHandler); + nx::core::ScalarSegmentFeatures filterAlgorithm(dataStructure, &inputValues, shouldCancel, messageHandler); Result<> result = filterAlgorithm(); return result; } diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ScalarSegmentFeaturesFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ScalarSegmentFeaturesFilter.hpp index e18590122f..c953fa0b2b 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ScalarSegmentFeaturesFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/ScalarSegmentFeaturesFilter.hpp @@ -89,23 +89,29 @@ class SIMPLNXCORE_EXPORT ScalarSegmentFeaturesFilter : public IFilter protected: /** - * @brief - * @param dataStructure - * @param args - * @param messageHandler - * @return PreflightResult + * @brief Takes in a DataStructure and checks that the filter can be run on it with the given arguments. + * Returns any warnings/errors. Also returns the changes that would be applied to the DataStructure. + * Some parts of the actions may not be completely filled out if all the required information is not available at preflight time. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SetImageGeomOriginScalingFilter.cpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SetImageGeomOriginScalingFilter.cpp index 6ee3dbce85..2b98b58f48 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SetImageGeomOriginScalingFilter.cpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SetImageGeomOriginScalingFilter.cpp @@ -124,7 +124,7 @@ IFilter::PreflightResult SetImageGeomOriginScalingFilter::preflightImpl(const Da } //------------------------------------------------------------------------------ -Result<> SetImageGeomOriginScalingFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> SetImageGeomOriginScalingFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { return {}; diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SetImageGeomOriginScalingFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SetImageGeomOriginScalingFilter.hpp index ba50394287..cca360628f 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SetImageGeomOriginScalingFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SetImageGeomOriginScalingFilter.hpp @@ -89,7 +89,7 @@ class SIMPLNXCORE_EXPORT SetImageGeomOriginScalingFilter : public IFilter * @param messageHandler * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SharedFeatureFaceFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SharedFeatureFaceFilter.hpp index c0622684b0..58dfc62755 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SharedFeatureFaceFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SharedFeatureFaceFilter.hpp @@ -94,7 +94,8 @@ class SIMPLNXCORE_EXPORT SharedFeatureFaceFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SilhouetteFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SilhouetteFilter.hpp index dd102cd39c..4c356383f1 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SilhouetteFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SilhouetteFilter.hpp @@ -90,7 +90,7 @@ class SIMPLNXCORE_EXPORT SilhouetteFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -100,7 +100,8 @@ class SIMPLNXCORE_EXPORT SilhouetteFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SplitAttributeArrayFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SplitAttributeArrayFilter.hpp index b7d354dc9d..ad1de970e3 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SplitAttributeArrayFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/SplitAttributeArrayFilter.hpp @@ -99,7 +99,8 @@ class SIMPLNXCORE_EXPORT SplitAttributeArrayFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/TriangleCentroidFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/TriangleCentroidFilter.hpp index e2d5ec6e9e..85ab46ab1b 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/TriangleCentroidFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/TriangleCentroidFilter.hpp @@ -96,7 +96,8 @@ class SIMPLNXCORE_EXPORT TriangleCentroidFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/TriangleDihedralAngleFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/TriangleDihedralAngleFilter.hpp index 525a872a96..d673012dc4 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/TriangleDihedralAngleFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/TriangleDihedralAngleFilter.hpp @@ -96,7 +96,8 @@ class SIMPLNXCORE_EXPORT TriangleDihedralAngleFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/TriangleNormalFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/TriangleNormalFilter.hpp index 33f008914d..e66ee12ae1 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/TriangleNormalFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/TriangleNormalFilter.hpp @@ -96,7 +96,8 @@ class SIMPLNXCORE_EXPORT TriangleNormalFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/UncertainRegularGridSampleSurfaceMeshFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/UncertainRegularGridSampleSurfaceMeshFilter.hpp index 4ec42ea567..9b2db90273 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/UncertainRegularGridSampleSurfaceMeshFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/UncertainRegularGridSampleSurfaceMeshFilter.hpp @@ -96,7 +96,7 @@ class SIMPLNXCORE_EXPORT UncertainRegularGridSampleSurfaceMeshFilter : public IF * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -106,7 +106,8 @@ class SIMPLNXCORE_EXPORT UncertainRegularGridSampleSurfaceMeshFilter : public IF * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteASCIIDataFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteASCIIDataFilter.hpp index 50e2a42ebd..dc59191a81 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteASCIIDataFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteASCIIDataFilter.hpp @@ -116,7 +116,8 @@ class SIMPLNXCORE_EXPORT WriteASCIIDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteAbaqusHexahedronFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteAbaqusHexahedronFilter.hpp index f9864082f6..042dbeb33f 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteAbaqusHexahedronFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteAbaqusHexahedronFilter.hpp @@ -90,7 +90,7 @@ class SIMPLNXCORE_EXPORT WriteAbaqusHexahedronFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -100,7 +100,8 @@ class SIMPLNXCORE_EXPORT WriteAbaqusHexahedronFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteAvizoRectilinearCoordinateFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteAvizoRectilinearCoordinateFilter.hpp index 66032afcd4..815f187408 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteAvizoRectilinearCoordinateFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteAvizoRectilinearCoordinateFilter.hpp @@ -89,7 +89,7 @@ class SIMPLNXCORE_EXPORT WriteAvizoRectilinearCoordinateFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -99,7 +99,8 @@ class SIMPLNXCORE_EXPORT WriteAvizoRectilinearCoordinateFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteAvizoUniformCoordinateFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteAvizoUniformCoordinateFilter.hpp index 5d0519e28b..7abf09d823 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteAvizoUniformCoordinateFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteAvizoUniformCoordinateFilter.hpp @@ -89,7 +89,7 @@ class SIMPLNXCORE_EXPORT WriteAvizoUniformCoordinateFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -99,7 +99,8 @@ class SIMPLNXCORE_EXPORT WriteAvizoUniformCoordinateFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteBinaryDataFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteBinaryDataFilter.hpp index 2484794f49..bd3af7e440 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteBinaryDataFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteBinaryDataFilter.hpp @@ -98,7 +98,8 @@ class SIMPLNXCORE_EXPORT WriteBinaryDataFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteFeatureDataCSVFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteFeatureDataCSVFilter.hpp index 6a2db8e406..b6c09c853f 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteFeatureDataCSVFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteFeatureDataCSVFilter.hpp @@ -108,7 +108,8 @@ class SIMPLNXCORE_EXPORT WriteFeatureDataCSVFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteLosAlamosFFTFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteLosAlamosFFTFilter.hpp index e06741a8af..ef15297522 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteLosAlamosFFTFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteLosAlamosFFTFilter.hpp @@ -89,7 +89,7 @@ class SIMPLNXCORE_EXPORT WriteLosAlamosFFTFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -99,7 +99,8 @@ class SIMPLNXCORE_EXPORT WriteLosAlamosFFTFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteStlFileFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteStlFileFilter.hpp index 19d7658c2d..847301ff88 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteStlFileFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteStlFileFilter.hpp @@ -91,7 +91,7 @@ class SIMPLNXCORE_EXPORT WriteStlFileFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -101,7 +101,8 @@ class SIMPLNXCORE_EXPORT WriteStlFileFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteVtkRectilinearGridFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteVtkRectilinearGridFilter.hpp index 79367e1dfe..ff82ab949f 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteVtkRectilinearGridFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteVtkRectilinearGridFilter.hpp @@ -88,7 +88,7 @@ class SIMPLNXCORE_EXPORT WriteVtkRectilinearGridFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -98,7 +98,8 @@ class SIMPLNXCORE_EXPORT WriteVtkRectilinearGridFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteVtkStructuredPointsFilter.hpp b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteVtkStructuredPointsFilter.hpp index d2fb4a3a36..f1ea6feecd 100644 --- a/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteVtkStructuredPointsFilter.hpp +++ b/src/Plugins/SimplnxCore/src/SimplnxCore/Filters/WriteVtkStructuredPointsFilter.hpp @@ -88,7 +88,7 @@ class SIMPLNXCORE_EXPORT WriteVtkStructuredPointsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - PreflightResult preflightImpl(const DataStructure& ds, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. @@ -98,7 +98,8 @@ class SIMPLNXCORE_EXPORT WriteVtkStructuredPointsFilter : public IFilter * @param messageHandler The MessageHandler object * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& filterArgs, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/SimplnxCore/test/CoreFilterTest.cpp b/src/Plugins/SimplnxCore/test/CoreFilterTest.cpp index 941ae8793b..a24aba6bde 100644 --- a/src/Plugins/SimplnxCore/test/CoreFilterTest.cpp +++ b/src/Plugins/SimplnxCore/test/CoreFilterTest.cpp @@ -134,16 +134,16 @@ TEST_CASE("CoreFilterTest:CreateDataGroupFilter") { Application::GetOrCreateInstance()->loadPlugins(unit_test::k_BuildDir.view(), true); - DataStructure data; + DataStructure dataStructure; CreateDataGroupFilter filter; Arguments args; const DataPath path({"foo", "bar", "baz"}); args.insert(CreateDataGroupFilter::k_DataObjectPath, path); - auto result = filter.execute(data, args); + auto result = filter.execute(dataStructure, args); REQUIRE(result.result.valid()); - DataObject* object = data.getData(path); + DataObject* object = dataStructure.getData(path); REQUIRE(object != nullptr); auto* group = dynamic_cast(object); REQUIRE(group != nullptr); - REQUIRE(data.getSize() == path.getLength()); + REQUIRE(dataStructure.getSize() == path.getLength()); } diff --git a/src/Plugins/SimplnxCore/test/PipelineTest.cpp b/src/Plugins/SimplnxCore/test/PipelineTest.cpp index 21db985a45..50d0abea89 100644 --- a/src/Plugins/SimplnxCore/test/PipelineTest.cpp +++ b/src/Plugins/SimplnxCore/test/PipelineTest.cpp @@ -86,7 +86,7 @@ class DeferredActionTestFilter : public IFilter } protected: - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override { OutputActions outputActions; outputActions.appendAction(std::make_unique(DataType::int32, std::vector{10}, std::vector{1}, k_DeferredActionPath)); @@ -94,10 +94,11 @@ class DeferredActionTestFilter : public IFilter return {std::move(outputActions)}; } - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override { // object should exist because the delete should happen after execute - if(data.getData(k_DeferredActionPath) == nullptr) + if(dataStructure.getData(k_DeferredActionPath) == nullptr) { return MakeErrorResult(-1, fmt::format("DataPath '{}' must exist", k_DeferredActionPath.toString())); } diff --git a/src/Plugins/TestOne/src/TestOne/Filters/CreateOutOfCoreArrayFilter.cpp b/src/Plugins/TestOne/src/TestOne/Filters/CreateOutOfCoreArrayFilter.cpp index b8cb183f41..5e98fe06c9 100644 --- a/src/Plugins/TestOne/src/TestOne/Filters/CreateOutOfCoreArrayFilter.cpp +++ b/src/Plugins/TestOne/src/TestOne/Filters/CreateOutOfCoreArrayFilter.cpp @@ -21,11 +21,11 @@ constexpr int32 k_RbrTupleDimsError = -196; constexpr int32 k_RbrTupleDimsInconsistent = -197; template -void CreateAndInitArray(DataStructure& data, const DataPath& path, const std::string& initValue) +void CreateAndInitArray(DataStructure& dataStructure, const DataPath& path, const std::string& initValue) { Result result = ConvertTo::convert(initValue); T value = result.value(); - auto& dataArray = data.getDataRefAs>(path); + auto& dataArray = dataStructure.getDataRefAs>(path); auto& dataStore = dataArray.getDataStoreRef(); std::fill(dataStore.begin(), dataStore.end(), value); } @@ -115,7 +115,7 @@ IFilter::PreflightResult CreateOutOfCoreArray::preflightImpl(const DataStructure return {std::move(actions)}; } -Result<> CreateOutOfCoreArray::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> CreateOutOfCoreArray::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto numericType = args.value(k_NumericType_Key); diff --git a/src/Plugins/TestOne/src/TestOne/Filters/CreateOutOfCoreArrayFilter.hpp b/src/Plugins/TestOne/src/TestOne/Filters/CreateOutOfCoreArrayFilter.hpp index 71d52956f2..0912ca8ea2 100644 --- a/src/Plugins/TestOne/src/TestOne/Filters/CreateOutOfCoreArrayFilter.hpp +++ b/src/Plugins/TestOne/src/TestOne/Filters/CreateOutOfCoreArrayFilter.hpp @@ -70,17 +70,20 @@ class TESTONE_EXPORT CreateOutOfCoreArray : public IFilter * @param messageHandler * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/TestOne/src/TestOne/Filters/DynamicTableExampleFilter.cpp b/src/Plugins/TestOne/src/TestOne/Filters/DynamicTableExampleFilter.cpp index 71a1ef945f..dec0c97173 100644 --- a/src/Plugins/TestOne/src/TestOne/Filters/DynamicTableExampleFilter.cpp +++ b/src/Plugins/TestOne/src/TestOne/Filters/DynamicTableExampleFilter.cpp @@ -94,13 +94,14 @@ IFilter::UniquePointer DynamicTableExampleFilter::clone() const } //------------------------------------------------------------------------------ -IFilter::PreflightResult DynamicTableExampleFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +IFilter::PreflightResult DynamicTableExampleFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { return {}; } //------------------------------------------------------------------------------ -Result<> DynamicTableExampleFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineFilter, const MessageHandler& messageHandler, +Result<> DynamicTableExampleFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineFilter, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { return {}; diff --git a/src/Plugins/TestOne/src/TestOne/Filters/DynamicTableExampleFilter.hpp b/src/Plugins/TestOne/src/TestOne/Filters/DynamicTableExampleFilter.hpp index a24a821ce1..30fedfc5b9 100644 --- a/src/Plugins/TestOne/src/TestOne/Filters/DynamicTableExampleFilter.hpp +++ b/src/Plugins/TestOne/src/TestOne/Filters/DynamicTableExampleFilter.hpp @@ -69,17 +69,20 @@ class TESTONE_EXPORT DynamicTableExampleFilter : public IFilter * @param messageHandler * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/TestOne/src/TestOne/Filters/ErrorWarningFilter.cpp b/src/Plugins/TestOne/src/TestOne/Filters/ErrorWarningFilter.cpp index 419da92f4b..006a57bb64 100644 --- a/src/Plugins/TestOne/src/TestOne/Filters/ErrorWarningFilter.cpp +++ b/src/Plugins/TestOne/src/TestOne/Filters/ErrorWarningFilter.cpp @@ -85,7 +85,8 @@ IFilter::UniquePointer ErrorWarningFilter::clone() const } //------------------------------------------------------------------------------ -nx::core::IFilter::PreflightResult ErrorWarningFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +nx::core::IFilter::PreflightResult ErrorWarningFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { auto preflightWarning = args.value(k_PreflightWarning_Key); auto preflightError = args.value(k_PreflightError_Key); @@ -110,7 +111,7 @@ nx::core::IFilter::PreflightResult ErrorWarningFilter::preflightImpl(const DataS } //------------------------------------------------------------------------------ -nx::core::Result<> ErrorWarningFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +nx::core::Result<> ErrorWarningFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { auto executeWarning = args.value(k_ExecuteWarning_Key); diff --git a/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter1Filter.cpp b/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter1Filter.cpp index 666654c597..fc73502ba5 100644 --- a/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter1Filter.cpp +++ b/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter1Filter.cpp @@ -119,7 +119,8 @@ IFilter::UniquePointer ExampleFilter1Filter::clone() const } //------------------------------------------------------------------------------ -IFilter::PreflightResult ExampleFilter1Filter::preflightImpl(const DataStructure& data, const Arguments& filterArgs, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +IFilter::PreflightResult ExampleFilter1Filter::preflightImpl(const DataStructure& dataStructure, const Arguments& filterArgs, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { // auto inputDir = filterArgs.value(k_InputDir_Key); // std::cout << "[ExampleFilter1Filter::PreflightImpl] inputDir=" << inputDir << std::endl; @@ -172,7 +173,7 @@ IFilter::PreflightResult ExampleFilter1Filter::preflightImpl(const DataStructure } //------------------------------------------------------------------------------ -Result<> ExampleFilter1Filter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +Result<> ExampleFilter1Filter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { return MakeWarningVoidResult(-100, "Example Warning from within an execute message"); diff --git a/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter1Filter.hpp b/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter1Filter.hpp index 5dcc18415d..13c5f914a2 100644 --- a/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter1Filter.hpp +++ b/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter1Filter.hpp @@ -75,17 +75,20 @@ class TESTONE_EXPORT ExampleFilter1Filter : public IFilter * @param messageHandler * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter2Filter.cpp b/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter2Filter.cpp index f2ebf744f0..fc8d2aa047 100644 --- a/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter2Filter.cpp +++ b/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter2Filter.cpp @@ -109,13 +109,14 @@ IFilter::UniquePointer ExampleFilter2Filter::clone() const } //------------------------------------------------------------------------------ -IFilter::PreflightResult ExampleFilter2Filter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +IFilter::PreflightResult ExampleFilter2Filter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { return {}; } //------------------------------------------------------------------------------ -Result<> ExampleFilter2Filter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineFilter, const MessageHandler& messageHandler, +Result<> ExampleFilter2Filter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineFilter, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { return {}; diff --git a/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter2Filter.hpp b/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter2Filter.hpp index 538e52417e..5929375b08 100644 --- a/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter2Filter.hpp +++ b/src/Plugins/TestOne/src/TestOne/Filters/ExampleFilter2Filter.hpp @@ -69,17 +69,20 @@ class TESTONE_EXPORT ExampleFilter2Filter : public IFilter * @param messageHandler * @return Result */ - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; /** - * @brief - * @param data - * @param args - * @param pipelineNode - * @param messageHandler - * @return Result<> + * @brief Applies the filter's algorithm to the DataStructure with the given arguments. Returns any warnings/errors. + * On failure, there is no guarantee that the DataStructure is in a correct state. + * @param dataStructure The input DataStructure instance + * @param filterArgs These are the input values for each parameter that is required for the filter + * @param pipelineNode The PipelineNode object that called this filter + * @param messageHandler The MessageHandler object + * @param shouldCancel The atomic boolean that holds if the filter should be canceled + * @return Returns a Result object with error or warning values if any of those occurred during execution of this function */ - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override; + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override; }; } // namespace nx::core diff --git a/src/Plugins/TestOne/src/TestOne/Filters/TestFilter.cpp b/src/Plugins/TestOne/src/TestOne/Filters/TestFilter.cpp index 7f2465ba9c..46064cf2a1 100644 --- a/src/Plugins/TestOne/src/TestOne/Filters/TestFilter.cpp +++ b/src/Plugins/TestOne/src/TestOne/Filters/TestFilter.cpp @@ -66,13 +66,14 @@ nx::core::IFilter::UniquePointer TestFilter::clone() const } //------------------------------------------------------------------------------ -nx::core::IFilter::PreflightResult TestFilter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +nx::core::IFilter::PreflightResult TestFilter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { return {}; } //------------------------------------------------------------------------------ -nx::core::Result<> TestFilter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +nx::core::Result<> TestFilter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { return {}; diff --git a/src/Plugins/TestTwo/src/TestTwo/Filters/Test2Filter.cpp b/src/Plugins/TestTwo/src/TestTwo/Filters/Test2Filter.cpp index 9571ed8d9e..8440425dec 100644 --- a/src/Plugins/TestTwo/src/TestTwo/Filters/Test2Filter.cpp +++ b/src/Plugins/TestTwo/src/TestTwo/Filters/Test2Filter.cpp @@ -65,13 +65,14 @@ nx::core::IFilter::UniquePointer Test2Filter::clone() const } //------------------------------------------------------------------------------ -nx::core::IFilter::PreflightResult Test2Filter::preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const +nx::core::IFilter::PreflightResult Test2Filter::preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const { return {}; } //------------------------------------------------------------------------------ -nx::core::Result<> Test2Filter::executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, +nx::core::Result<> Test2Filter::executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const { return {}; diff --git a/src/simplnx/Filter/IFilter.hpp b/src/simplnx/Filter/IFilter.hpp index 785e419b56..c6873e70cd 100644 --- a/src/simplnx/Filter/IFilter.hpp +++ b/src/simplnx/Filter/IFilter.hpp @@ -206,7 +206,7 @@ class SIMPLNX_EXPORT IFilter * @param shouldCancel * @return PreflightResult */ - virtual PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const = 0; + virtual PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const = 0; /** * @brief Classes that implement IFilter must provide this function for execute. @@ -218,7 +218,8 @@ class SIMPLNX_EXPORT IFilter * @param shouldCancel * @return Result<> */ - virtual Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const = 0; + virtual Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const = 0; }; using FilterCreationFunc = std::function; diff --git a/src/simplnx/Pipeline/AbstractPipelineNode.hpp b/src/simplnx/Pipeline/AbstractPipelineNode.hpp index 88a0c6417d..2f183094ff 100644 --- a/src/simplnx/Pipeline/AbstractPipelineNode.hpp +++ b/src/simplnx/Pipeline/AbstractPipelineNode.hpp @@ -122,7 +122,7 @@ class SIMPLNX_EXPORT AbstractPipelineNode * @param data * @return bool */ - virtual bool preflight(DataStructure& data, const std::atomic_bool& shouldCancel) = 0; + virtual bool preflight(DataStructure& dataStructure, const std::atomic_bool& shouldCancel) = 0; /** * @brief Attempts to preflight the node using the provided DataStructure. @@ -134,7 +134,7 @@ class SIMPLNX_EXPORT AbstractPipelineNode * @param allowRenaming * @return bool */ - virtual bool preflight(DataStructure& data, RenamedPaths& renamedPaths, const std::atomic_bool& shouldCancel, bool allowRenaming) = 0; + virtual bool preflight(DataStructure& dataStructure, RenamedPaths& renamedPaths, const std::atomic_bool& shouldCancel, bool allowRenaming) = 0; /** * @brief Attempts to execute the node using the provided DataStructure. @@ -142,7 +142,7 @@ class SIMPLNX_EXPORT AbstractPipelineNode * @param data * @return bool */ - virtual bool execute(DataStructure& data, const std::atomic_bool& shouldCancel) = 0; + virtual bool execute(DataStructure& dataStructure, const std::atomic_bool& shouldCancel) = 0; /** * @brief Creates and returns a unique pointer to a copy of the node. diff --git a/src/simplnx/Pipeline/PipelineFilter.cpp b/src/simplnx/Pipeline/PipelineFilter.cpp index 9abf792cbc..b882bcb106 100644 --- a/src/simplnx/Pipeline/PipelineFilter.cpp +++ b/src/simplnx/Pipeline/PipelineFilter.cpp @@ -133,13 +133,13 @@ void PipelineFilter::setComments(const std::string& comments) } // ----------------------------------------------------------------------------- -bool PipelineFilter::preflight(DataStructure& data, const std::atomic_bool& shouldCancel) +bool PipelineFilter::preflight(DataStructure& dataStructure, const std::atomic_bool& shouldCancel) { RenamedPaths renamedPaths; - return preflight(data, renamedPaths, shouldCancel, true); + return preflight(dataStructure, renamedPaths, shouldCancel, true); } -bool PipelineFilter::preflight(DataStructure& data, RenamedPaths& renamedPaths, const std::atomic_bool& shouldCancel, bool allowRenaming) +bool PipelineFilter::preflight(DataStructure& dataStructure, RenamedPaths& renamedPaths, const std::atomic_bool& shouldCancel, bool allowRenaming) { sendFilterRunStateMessage(m_Index, RunState::Preflighting); @@ -152,13 +152,13 @@ bool PipelineFilter::preflight(DataStructure& data, RenamedPaths& renamedPaths, { m_Errors.push_back(Error{-10, "This filter is just a placeholder! The original filter could not be found. See the filter comments for more details."}); setHasErrors(); - setPreflightStructure(data, false); + setPreflightStructure(dataStructure, false); sendFilterFaultMessage(m_Index, getFaultState()); sendFilterFaultDetailMessage(m_Index, m_Warnings, m_Errors); return false; } - IFilter::PreflightResult result = m_Filter->preflight(data, getArguments(), messageHandler, shouldCancel); + IFilter::PreflightResult result = m_Filter->preflight(dataStructure, getArguments(), messageHandler, shouldCancel); m_Warnings = std::move(result.outputActions.warnings()); setHasWarnings(!m_Warnings.empty()); m_PreflightValues = std::move(result.outputValues); @@ -167,7 +167,7 @@ bool PipelineFilter::preflight(DataStructure& data, RenamedPaths& renamedPaths, { m_Errors = std::move(result.outputActions.errors()); setHasErrors(); - setPreflightStructure(data, false); + setPreflightStructure(dataStructure, false); sendFilterFaultMessage(m_Index, getFaultState()); sendFilterFaultDetailMessage(m_Index, m_Warnings, m_Errors); return false; @@ -175,7 +175,7 @@ bool PipelineFilter::preflight(DataStructure& data, RenamedPaths& renamedPaths, m_Errors.clear(); - Result<> actionsResult = result.outputActions.value().applyAll(data, IDataAction::Mode::Preflight); + Result<> actionsResult = result.outputActions.value().applyAll(dataStructure, IDataAction::Mode::Preflight); for(auto&& warning : actionsResult.warnings()) { @@ -185,7 +185,7 @@ bool PipelineFilter::preflight(DataStructure& data, RenamedPaths& renamedPaths, if(actionsResult.invalid()) { m_Errors = std::move(actionsResult.errors()); - setPreflightStructure(data, false); + setPreflightStructure(dataStructure, false); setHasErrors(); sendFilterFaultMessage(m_Index, getFaultState()); sendFilterFaultDetailMessage(m_Index, m_Warnings, m_Errors); @@ -216,7 +216,7 @@ bool PipelineFilter::preflight(DataStructure& data, RenamedPaths& renamedPaths, m_CreatedPaths = newCreatedPaths; m_DataModifiedActions = result.outputActions.value().modifiedActions; - setPreflightStructure(data); + setPreflightStructure(dataStructure); sendFilterFaultMessage(m_Index, getFaultState()); if(!m_Warnings.empty() || !m_Errors.empty()) { @@ -234,7 +234,7 @@ bool PipelineFilter::preflight(DataStructure& data, RenamedPaths& renamedPaths, } // ----------------------------------------------------------------------------- -bool PipelineFilter::execute(DataStructure& data, const std::atomic_bool& shouldCancel) +bool PipelineFilter::execute(DataStructure& dataStructure, const std::atomic_bool& shouldCancel) { this->sendFilterRunStateMessage(m_Index, nx::core::RunState::Executing); this->sendFilterUpdateMessage(m_Index, "Begin"); @@ -253,7 +253,7 @@ bool PipelineFilter::execute(DataStructure& data, const std::atomic_bool& should IFilter::ExecuteResult result; if(m_Filter != nullptr) { - result = m_Filter->execute(data, getArguments(), this, messageHandler, shouldCancel); + result = m_Filter->execute(dataStructure, getArguments(), this, messageHandler, shouldCancel); m_Warnings = result.result.warnings(); m_PreflightValues = std::move(result.outputValues); if(result.result.invalid()) @@ -268,7 +268,7 @@ bool PipelineFilter::execute(DataStructure& data, const std::atomic_bool& should setHasWarnings(!m_Warnings.empty()); setHasErrors(!m_Errors.empty()); - endExecution(data); + endExecution(dataStructure); if(!m_Warnings.empty() || !m_Errors.empty()) { diff --git a/src/simplnx/Pipeline/PipelineFilter.hpp b/src/simplnx/Pipeline/PipelineFilter.hpp index a6599f5c94..09a032e2bf 100644 --- a/src/simplnx/Pipeline/PipelineFilter.hpp +++ b/src/simplnx/Pipeline/PipelineFilter.hpp @@ -125,7 +125,7 @@ class SIMPLNX_EXPORT PipelineFilter : public AbstractPipelineFilter * @param renamedPaths Collection of renamed output paths. * @return bool */ - bool preflight(DataStructure& data, const std::atomic_bool& shouldCancel) override; + bool preflight(DataStructure& dataStructure, const std::atomic_bool& shouldCancel) override; /** * @brief Attempts to preflight the node using the provided DataStructure. @@ -134,7 +134,7 @@ class SIMPLNX_EXPORT PipelineFilter : public AbstractPipelineFilter * @param renamedPaths Collection of renamed output paths. * @return bool */ - bool preflight(DataStructure& data, RenamedPaths& renamedPaths, const std::atomic_bool& shouldCancel, bool allowRenaming) override; + bool preflight(DataStructure& dataStructure, RenamedPaths& renamedPaths, const std::atomic_bool& shouldCancel, bool allowRenaming) override; /** * @brief Attempts to execute the node using the provided DataStructure. @@ -142,7 +142,7 @@ class SIMPLNX_EXPORT PipelineFilter : public AbstractPipelineFilter * @param data * @return bool */ - bool execute(DataStructure& data, const std::atomic_bool& shouldCancel) override; + bool execute(DataStructure& dataStructure, const std::atomic_bool& shouldCancel) override; /** * @brief Returns a vector of DataPaths created when preflighting the node. diff --git a/src/simplnx/Pipeline/PlaceholderFilter.cpp b/src/simplnx/Pipeline/PlaceholderFilter.cpp index 6f5b5111b0..5a652e0d18 100644 --- a/src/simplnx/Pipeline/PlaceholderFilter.cpp +++ b/src/simplnx/Pipeline/PlaceholderFilter.cpp @@ -17,17 +17,17 @@ PlaceholderFilter::PlaceholderFilter(nlohmann::json json) PlaceholderFilter::~PlaceholderFilter() noexcept = default; -bool PlaceholderFilter::preflight(DataStructure& data, const std::atomic_bool& shouldCancel) +bool PlaceholderFilter::preflight(DataStructure& dataStructure, const std::atomic_bool& shouldCancel) { return true; } -bool PlaceholderFilter::preflight(DataStructure& data, RenamedPaths& renamedPaths, const std::atomic_bool& shouldCancel, bool allowRenaming) +bool PlaceholderFilter::preflight(DataStructure& dataStructure, RenamedPaths& renamedPaths, const std::atomic_bool& shouldCancel, bool allowRenaming) { return true; } -bool PlaceholderFilter::execute(DataStructure& data, const std::atomic_bool& shouldCancel) +bool PlaceholderFilter::execute(DataStructure& dataStructure, const std::atomic_bool& shouldCancel) { return true; } diff --git a/src/simplnx/Pipeline/PlaceholderFilter.hpp b/src/simplnx/Pipeline/PlaceholderFilter.hpp index eb3bb14be9..a09e5c6e0b 100644 --- a/src/simplnx/Pipeline/PlaceholderFilter.hpp +++ b/src/simplnx/Pipeline/PlaceholderFilter.hpp @@ -43,7 +43,7 @@ class SIMPLNX_EXPORT PlaceholderFilter : public AbstractPipelineFilter * @param shouldCancel * @return bool */ - bool preflight(DataStructure& data, const std::atomic_bool& shouldCancel) override; + bool preflight(DataStructure& dataStructure, const std::atomic_bool& shouldCancel) override; /** * @brief Attempts to preflight the node using the provided DataStructure. @@ -54,7 +54,7 @@ class SIMPLNX_EXPORT PlaceholderFilter : public AbstractPipelineFilter * @param allowRenaming * @return bool */ - bool preflight(DataStructure& data, RenamedPaths& renamedPaths, const std::atomic_bool& shouldCancel, bool allowRenaming) override; + bool preflight(DataStructure& dataStructure, RenamedPaths& renamedPaths, const std::atomic_bool& shouldCancel, bool allowRenaming) override; /** * @brief Attempts to execute the node using the provided DataStructure. @@ -63,7 +63,7 @@ class SIMPLNX_EXPORT PlaceholderFilter : public AbstractPipelineFilter * @param shouldCancel * @return bool */ - bool execute(DataStructure& data, const std::atomic_bool& shouldCancel) override; + bool execute(DataStructure& dataStructure, const std::atomic_bool& shouldCancel) override; /** * @brief Creates and returns a unique pointer to a copy of the node. diff --git a/src/simplnx/Utilities/AlignSections.cpp b/src/simplnx/Utilities/AlignSections.cpp index ee6bbabaa4..a7549d2dc4 100644 --- a/src/simplnx/Utilities/AlignSections.cpp +++ b/src/simplnx/Utilities/AlignSections.cpp @@ -103,8 +103,8 @@ class AlignSectionsTransferDataImpl } // namespace // ----------------------------------------------------------------------------- -AlignSections::AlignSections(DataStructure& data, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler) -: m_DataStructure(data) +AlignSections::AlignSections(DataStructure& dataStructure, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler) +: m_DataStructure(dataStructure) , m_ShouldCancel(shouldCancel) , m_MessageHandler(mesgHandler) { diff --git a/src/simplnx/Utilities/AlignSections.hpp b/src/simplnx/Utilities/AlignSections.hpp index 9c3bbe8fe8..3a478954e3 100644 --- a/src/simplnx/Utilities/AlignSections.hpp +++ b/src/simplnx/Utilities/AlignSections.hpp @@ -16,7 +16,7 @@ class IGridGeometry; class SIMPLNX_EXPORT AlignSections { public: - AlignSections(DataStructure& data, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler); + AlignSections(DataStructure& dataStructure, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler); virtual ~AlignSections() noexcept; AlignSections(const AlignSections&) = delete; // Copy Constructor Not Implemented diff --git a/src/simplnx/Utilities/DataArrayUtilities.hpp b/src/simplnx/Utilities/DataArrayUtilities.hpp index 75e22b17cf..7fe4266b21 100644 --- a/src/simplnx/Utilities/DataArrayUtilities.hpp +++ b/src/simplnx/Utilities/DataArrayUtilities.hpp @@ -581,9 +581,9 @@ DataArray* ArrayFromPath(DataStructure& dataStructure, const DataPath& path) * @return */ template -DataArray& ArrayRefFromPath(DataStructure& data, const DataPath& path) +DataArray& ArrayRefFromPath(DataStructure& dataStructure, const DataPath& path) { - DataObject* object = data.getData(path); + DataObject* object = dataStructure.getData(path); auto* dataArray = dynamic_cast*>(object); if(dataArray == nullptr) { diff --git a/src/simplnx/Utilities/SampleSurfaceMesh.cpp b/src/simplnx/Utilities/SampleSurfaceMesh.cpp index f44d17bcb4..9f012bb602 100644 --- a/src/simplnx/Utilities/SampleSurfaceMesh.cpp +++ b/src/simplnx/Utilities/SampleSurfaceMesh.cpp @@ -156,8 +156,8 @@ class SampleSurfaceMeshImplByPoints } // namespace // ----------------------------------------------------------------------------- -SampleSurfaceMesh::SampleSurfaceMesh(DataStructure& data, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler) -: m_DataStructure(data) +SampleSurfaceMesh::SampleSurfaceMesh(DataStructure& dataStructure, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler) +: m_DataStructure(dataStructure) , m_ShouldCancel(shouldCancel) , m_MessageHandler(mesgHandler) { diff --git a/src/simplnx/Utilities/SampleSurfaceMesh.hpp b/src/simplnx/Utilities/SampleSurfaceMesh.hpp index 13a11fbb48..2eb2c7d135 100644 --- a/src/simplnx/Utilities/SampleSurfaceMesh.hpp +++ b/src/simplnx/Utilities/SampleSurfaceMesh.hpp @@ -22,7 +22,7 @@ struct SIMPLNX_EXPORT SampleSurfaceMeshInputValues class SIMPLNX_EXPORT SampleSurfaceMesh { public: - SampleSurfaceMesh(DataStructure& data, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler); + SampleSurfaceMesh(DataStructure& dataStructure, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler); virtual ~SampleSurfaceMesh() noexcept; SampleSurfaceMesh(const SampleSurfaceMesh&) = delete; // Copy Constructor Not Implemented diff --git a/src/simplnx/Utilities/SegmentFeatures.cpp b/src/simplnx/Utilities/SegmentFeatures.cpp index d43d8add08..b97491e73c 100644 --- a/src/simplnx/Utilities/SegmentFeatures.cpp +++ b/src/simplnx/Utilities/SegmentFeatures.cpp @@ -5,8 +5,8 @@ using namespace nx::core; // ----------------------------------------------------------------------------- -SegmentFeatures::SegmentFeatures(DataStructure& data, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler) -: m_DataStructure(data) +SegmentFeatures::SegmentFeatures(DataStructure& dataStructure, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler) +: m_DataStructure(dataStructure) , m_ShouldCancel(shouldCancel) , m_MessageHandler(mesgHandler) { diff --git a/src/simplnx/Utilities/SegmentFeatures.hpp b/src/simplnx/Utilities/SegmentFeatures.hpp index f3818ae6b8..0f97abf25b 100644 --- a/src/simplnx/Utilities/SegmentFeatures.hpp +++ b/src/simplnx/Utilities/SegmentFeatures.hpp @@ -22,7 +22,7 @@ class SIMPLNX_EXPORT SegmentFeatures using SeedGenerator = std::mt19937_64; using Int64Distribution = std::uniform_int_distribution; - SegmentFeatures(DataStructure& data, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler); + SegmentFeatures(DataStructure& dataStructure, const std::atomic_bool& shouldCancel, const IFilter::MessageHandler& mesgHandler); virtual ~SegmentFeatures(); diff --git a/wrapping/python/CxPybind/CxPybind/CxPybind.hpp b/wrapping/python/CxPybind/CxPybind/CxPybind.hpp index 3a4fe6571b..43ab064cbe 100644 --- a/wrapping/python/CxPybind/CxPybind/CxPybind.hpp +++ b/wrapping/python/CxPybind/CxPybind/CxPybind.hpp @@ -591,7 +591,7 @@ class PyFilter : public IFilter } protected: - PreflightResult preflightImpl(const DataStructure& data, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override + PreflightResult preflightImpl(const DataStructure& dataStructure, const Arguments& args, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override { try { @@ -599,8 +599,9 @@ class PyFilter : public IFilter Parameters params = parameters(); auto shouldCancelProxy = std::make_shared(shouldCancel); auto guard = MakeAtomicBoolProxyGuard(shouldCancelProxy); - auto result = m_Object.attr("preflight_impl")(py::cast(data, py::return_value_policy::reference), ConvertArgsToDict(Internals::Instance(), params, args), messageHandler, shouldCancelProxy) - .cast(); + auto result = + m_Object.attr("preflight_impl")(py::cast(dataStructure, py::return_value_policy::reference), ConvertArgsToDict(Internals::Instance(), params, args), messageHandler, shouldCancelProxy) + .cast(); return result; } catch(const py::error_already_set& pyException) { @@ -611,7 +612,8 @@ class PyFilter : public IFilter } } - Result<> executeImpl(DataStructure& data, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, const std::atomic_bool& shouldCancel) const override + Result<> executeImpl(DataStructure& dataStructure, const Arguments& args, const PipelineFilter* pipelineNode, const MessageHandler& messageHandler, + const std::atomic_bool& shouldCancel) const override { try { @@ -619,10 +621,10 @@ class PyFilter : public IFilter Parameters params = parameters(); auto shouldCancelProxy = std::make_shared(shouldCancel); auto guard = MakeAtomicBoolProxyGuard(shouldCancelProxy); - auto result = - m_Object - .attr("execute_impl")(py::cast(data, py::return_value_policy::reference), ConvertArgsToDict(Internals::Instance(), params, args), /* pipelineNode,*/ messageHandler, shouldCancelProxy) - .cast>(); + auto result = m_Object + .attr("execute_impl")(py::cast(dataStructure, py::return_value_policy::reference), ConvertArgsToDict(Internals::Instance(), params, args), /* pipelineNode,*/ messageHandler, + shouldCancelProxy) + .cast>(); return result; } catch(const py::error_already_set& pyException) {