From 01c3bcaf494354ac0ed20eda32d5cce29a7ebb79 Mon Sep 17 00:00:00 2001 From: Dmitri Naumov <github@naumov.de> Date: Sat, 15 Apr 2017 21:51:45 +0200 Subject: [PATCH] Use 'override' for all virtual member functions. --- .../DataExplorer/Base/CheckboxDelegate.h | 8 ++- .../DataExplorer/Base/ColorPickerPushButton.h | 2 +- .../Base/QNonScalableGraphicsTextItem.h | 8 ++- Applications/DataExplorer/Base/RecentFiles.h | 2 +- .../DataExplorer/Base/StrictDoubleValidator.h | 2 +- .../DataExplorer/Base/StrictIntValidator.h | 2 +- Applications/DataExplorer/Base/TreeModel.h | 24 ++++--- .../DataView/AddLayerToMeshDialog.h | 4 +- .../DataExplorer/DataView/ColorTableModel.h | 12 ++-- .../DataExplorer/DataView/ColorTableView.h | 7 +- .../DataView/CondFromRasterDialog.h | 6 +- .../DataView/CreateStructuredGridDialog.h | 4 +- .../DataView/DataExplorerSettingsDialog.h | 8 +-- .../DataView/DiagramView/DetailWindow.h | 2 +- .../DataView/DiagramView/DiagramPrefsDialog.h | 6 +- .../DataView/DiagramView/DiagramScene.h | 2 +- .../DataView/DiagramView/DiagramView.h | 8 +-- .../DataView/DiagramView/QArrow.h | 7 +- .../DataView/DiagramView/QGraphicsGrid.h | 8 ++- .../DataExplorer/DataView/ElementTreeModel.h | 2 +- .../DataExplorer/DataView/ElementTreeView.h | 3 +- .../DataExplorer/DataView/GEOModels.h | 2 +- .../DataExplorer/DataView/GMSHPrefsDialog.h | 6 +- .../DataExplorer/DataView/GeoObjectListItem.h | 6 +- .../DataView/GeoOnMeshMappingDialog.h | 7 +- .../DataExplorer/DataView/GeoTreeItem.h | 2 +- .../DataExplorer/DataView/GeoTreeModel.h | 2 +- .../DataExplorer/DataView/GeoTreeView.h | 5 +- .../DataExplorer/DataView/LicenseDialog.h | 2 +- .../DataExplorer/DataView/LineEditDialog.h | 6 +- .../DataExplorer/DataView/LinearEditDialog.h | 6 +- .../DataView/MergeGeometriesDialog.h | 6 +- .../DataView/MeshAnalysisDialog.h | 2 +- .../DataView/MeshElementRemovalDialog.h | 6 +- .../DataView/MeshLayerEditDialog.h | 6 +- .../DataView/MeshMapping2DDialog.h | 4 +- .../DataView/MeshQualitySelectionDialog.h | 6 +- .../DataView/MeshValueEditDialog.h | 6 +- .../DataExplorer/DataView/ModelTreeItem.h | 3 +- Applications/DataExplorer/DataView/MshItem.h | 2 +- Applications/DataExplorer/DataView/MshModel.h | 2 +- Applications/DataExplorer/DataView/MshView.h | 7 +- .../DataView/NetCdfConfigureDialog.h | 6 +- .../DataExplorer/DataView/SHPImportDialog.h | 6 +- .../DataExplorer/DataView/SaveMeshDialog.h | 6 +- .../DataExplorer/DataView/SelectMeshDialog.h | 6 +- .../DataExplorer/DataView/SetNameDialog.h | 6 +- .../DataExplorer/DataView/StationTreeModel.h | 5 +- .../DataExplorer/DataView/StationTreeView.h | 5 +- .../DataView/StratView/StratBar.h | 8 ++- .../DataView/StratView/StratScene.h | 2 +- .../DataView/StratView/StratView.h | 14 ++-- .../DataView/StratView/StratWindow.h | 2 +- .../DataView/SurfaceExtractionDialog.h | 6 +- .../VtkVis/MeshFromRasterDialog.h | 6 +- .../DataExplorer/VtkVis/QVtkDataSetMapper.h | 4 +- .../DataExplorer/VtkVis/VisualizationWidget.h | 2 +- .../VtkVis/VtkAlgorithmProperties.h | 2 +- .../VtkVis/VtkAlgorithmPropertyCheckbox.h | 2 +- .../VtkVis/VtkAlgorithmPropertyLineEdit.h | 2 +- .../VtkVis/VtkAlgorithmPropertyVectorEdit.h | 2 +- .../VtkVis/VtkAppendArrayFilter.h | 2 +- .../DataExplorer/VtkVis/VtkBGImageSource.h | 4 +- .../VtkVis/VtkColorByHeightFilter.h | 4 +- .../DataExplorer/VtkVis/VtkColorLookupTable.h | 2 +- .../VtkVis/VtkCompositeColorByHeightFilter.h | 6 +- .../VtkCompositeColormapToImageFilter.h | 9 ++- .../VtkVis/VtkCompositeContourFilter.h | 6 +- .../VtkCompositeElementSelectionFilter.h | 6 +- .../DataExplorer/VtkVis/VtkCompositeFilter.h | 2 +- .../VtkVis/VtkCompositeGeoObjectFilter.h | 4 +- .../VtkCompositeImageToCylindersFilter.h | 6 +- .../VtkVis/VtkCompositeLineToTubeFilter.h | 6 +- .../VtkVis/VtkCompositeNodeSelectionFilter.h | 4 +- .../VtkVis/VtkCompositePointToGlyphFilter.h | 6 +- .../VtkCompositeTextureOnSurfaceFilter.h | 6 +- .../VtkVis/VtkCompositeThresholdFilter.h | 6 +- .../VtkVis/VtkConsoleOutputWindow.h | 4 +- .../VtkVis/VtkCustomInteractorStyle.h | 12 ++-- .../DataExplorer/VtkVis/VtkGeoImageSource.h | 7 +- .../VtkVis/VtkImageDataToLinePolyDataFilter.h | 11 ++- .../DataExplorer/VtkVis/VtkPickCallback.h | 3 +- .../DataExplorer/VtkVis/VtkPointsSource.h | 4 +- .../DataExplorer/VtkVis/VtkPolylinesSource.h | 4 +- .../DataExplorer/VtkVis/VtkStationSource.h | 2 +- .../DataExplorer/VtkVis/VtkSurfacesSource.h | 4 +- .../VtkVis/VtkTextureOnSurfaceFilter.h | 4 +- .../DataExplorer/VtkVis/VtkVisImageItem.h | 11 +-- .../DataExplorer/VtkVis/VtkVisPipeline.h | 5 +- .../DataExplorer/VtkVis/VtkVisPipelineItem.h | 6 +- .../DataExplorer/VtkVis/VtkVisPipelineView.h | 7 +- .../DataExplorer/VtkVis/VtkVisPointSetItem.h | 19 +++--- Applications/DataExplorer/mainwindow.h | 2 +- Applications/FileIO/CsvInterface.h | 2 +- .../FileIO/Gmsh/GMSHAdaptiveMeshDensity.h | 8 +-- .../FileIO/Gmsh/GMSHFixedMeshDensity.h | 8 +-- Applications/FileIO/Gmsh/GMSHInterface.h | 4 +- Applications/FileIO/Gmsh/GMSHPoint.h | 3 +- Applications/FileIO/Gmsh/GMSHPolygonTree.h | 2 +- .../FileIO/XmlIO/Qt/XmlGspInterface.h | 11 +-- .../FileIO/XmlIO/Qt/XmlNumInterface.h | 12 ++-- .../Utils/OGSFileConverter/FileListDialog.h | 7 +- .../Utils/OGSFileConverter/OGSFileConverter.h | 2 +- BaseLib/IO/XmlIO/XMLInterface.h | 2 +- BaseLib/LogogSimpleFormatter.h | 2 +- BaseLib/Subdivision.h | 4 +- BaseLib/TemplateLogogFormatterSuppressedGCC.h | 5 +- GeoLib/IO/XmlIO/Boost/BoostXmlGmlInterface.h | 6 +- GeoLib/IO/XmlIO/Qt/XmlGmlInterface.h | 11 +-- GeoLib/IO/XmlIO/Qt/XmlStnInterface.h | 9 ++- GeoLib/Point.h | 2 +- GeoLib/Polygon.h | 2 +- GeoLib/PolygonWithSegmentMarker.h | 4 +- GeoLib/Polyline.h | 5 +- GeoLib/PolylineWithSegmentMarker.h | 4 +- GeoLib/Station.h | 2 +- GeoLib/StationBorehole.h | 2 +- GeoLib/Surface.h | 2 +- MaterialLib/Adsorption/Adsorption.h | 8 ++- MaterialLib/Adsorption/Density100MPa.h | 8 +-- MaterialLib/Adsorption/DensityConst.h | 8 +-- MaterialLib/Adsorption/DensityCook.h | 8 +-- MaterialLib/Adsorption/DensityDubinin.h | 8 +-- MaterialLib/Adsorption/DensityHauer.h | 8 +-- MaterialLib/Adsorption/DensityLegacy.h | 8 +-- MaterialLib/Adsorption/DensityMette.h | 8 +-- MaterialLib/Adsorption/DensityNunez.h | 8 +-- .../FractureModels/LinearElasticIsotropic.h | 2 +- .../SolidModels/LinearElasticIsotropic.h | 2 +- MeshLib/Elements/TemplateElement.h | 67 ++++++++++--------- MeshLib/IO/Legacy/MeshIO.h | 4 +- MeshLib/MeshGenerators/LayeredVolume.h | 12 ++-- MeshLib/MeshGenerators/MeshLayerMapper.h | 8 ++- MeshLib/MeshQuality/AngleSkewMetric.h | 2 +- MeshLib/MeshQuality/EdgeRatioMetric.h | 4 +- MeshLib/MeshQuality/ElementSizeMetric.h | 4 +- MeshLib/MeshQuality/RadiusEdgeRatioMetric.h | 4 +- MeshLib/MeshQuality/SizeDifferenceMetric.h | 4 +- MeshLib/PropertyVector.h | 7 +- MeshLib/Vtk/VtkMeshNodalCoordinatesTemplate.h | 4 +- NumLib/DOF/SimpleMatrixVectorProvider.h | 2 +- .../LocalLinearLeastSquaresExtrapolator.h | 2 +- .../LinearInterpolationAlongPolyline.h | 2 +- .../Function/LinearInterpolationOnSurface.h | 2 +- NumLib/Function/TemplateSpatialFunction.h | 2 +- NumLib/ODESolver/MatrixTranslator.h | 2 +- NumLib/ODESolver/TimeDiscretization.h | 8 +-- NumLib/ODESolver/TimeDiscretizedODESystem.h | 4 +- ...IterationNumberBasedAdaptiveTimeStepping.h | 19 +++--- .../HeatConduction/HeatConductionProcess.h | 2 +- .../HydroMechanicsLocalAssemblerInterface.h | 17 +++-- .../HydroMechanicsLocalAssemblerMatrix.h | 11 ++- .../SmallDeformationLocalAssemblerInterface.h | 18 +++-- ProcessLib/Parameter/Parameter.h | 3 +- ProcessLib/Process.h | 16 ++--- ProcessLib/TES/TESLocalAssembler.h | 2 +- Tests/BaseLib/TestQuicksort.cpp | 2 +- Tests/FileIO/TestCsvReader.cpp | 5 +- Tests/GeoLib/IO/TestGLIReader.cpp | 5 +- Tests/GeoLib/TestOctTree.cpp | 2 +- Tests/GeoLib/TestPolygon.cpp | 2 +- Tests/GeoLib/TestSimplePolygonTree.cpp | 2 +- Tests/MeshLib/MeshProperties.cpp | 6 +- Tests/MeshLib/TestBoundaryElementSearch.cpp | 2 +- Tests/MeshLib/TestLineMesh.cpp | 6 +- Tests/MeshLib/TestMeshNodeSearch.cpp | 10 +-- Tests/MeshLib/TestQuadMesh.cpp | 6 +- Tests/MeshLib/TestTriLineMesh.cpp | 2 +- Tests/MeshLib/TestVtkMappedMeshSource.cpp | 6 +- .../LocalToGlobalIndexMapMultiComponent.cpp | 2 +- Tests/NumLib/TestCoordinatesMapping.cpp | 2 +- Tests/NumLib/TestFe.cpp | 6 +- Tests/NumLib/TestMeshComponentMap.cpp | 2 +- 173 files changed, 500 insertions(+), 494 deletions(-) diff --git a/Applications/DataExplorer/Base/CheckboxDelegate.h b/Applications/DataExplorer/Base/CheckboxDelegate.h index 2e4d8cd4be7..89aedb2ec57 100644 --- a/Applications/DataExplorer/Base/CheckboxDelegate.h +++ b/Applications/DataExplorer/Base/CheckboxDelegate.h @@ -35,13 +35,15 @@ public: /// \brief Paints a checkbox. This overrides the default painting of a combo box. void paint(QPainter* painter, const QStyleOptionViewItem& option, - const QModelIndex& index) const; + const QModelIndex& index) const override; /// \brief Handles the click events and sets the model data. bool editorEvent(QEvent* event, QAbstractItemModel* model, - const QStyleOptionViewItem &option, const QModelIndex &index); + const QStyleOptionViewItem& option, + const QModelIndex& index) override; - QSize sizeHint (const QStyleOptionViewItem & option, const QModelIndex & index) const; + QSize sizeHint(const QStyleOptionViewItem& option, + const QModelIndex& index) const override; private: QRect checkboxRect(const QStyleOptionViewItem& viewItemStyleOptions) const; diff --git a/Applications/DataExplorer/Base/ColorPickerPushButton.h b/Applications/DataExplorer/Base/ColorPickerPushButton.h index 3cb466406e7..1f298bba4d0 100644 --- a/Applications/DataExplorer/Base/ColorPickerPushButton.h +++ b/Applications/DataExplorer/Base/ColorPickerPushButton.h @@ -34,7 +34,7 @@ public: public slots: /// Calls the QColorDialog - void mouseReleaseEvent(QMouseEvent* e); + void mouseReleaseEvent(QMouseEvent* e) override; /// Sets the color. void setColor(QColor color); diff --git a/Applications/DataExplorer/Base/QNonScalableGraphicsTextItem.h b/Applications/DataExplorer/Base/QNonScalableGraphicsTextItem.h index 2db5bdb0fbd..f8014011968 100644 --- a/Applications/DataExplorer/Base/QNonScalableGraphicsTextItem.h +++ b/Applications/DataExplorer/Base/QNonScalableGraphicsTextItem.h @@ -27,8 +27,10 @@ public: QNonScalableGraphicsTextItem(QGraphicsItem* parent = nullptr); QNonScalableGraphicsTextItem(const QString& text, QGraphicsItem* parent = nullptr); - ~QNonScalableGraphicsTextItem(); + ~QNonScalableGraphicsTextItem() override; - void paint(QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget); - virtual QRectF boundingRect() const; + void paint(QPainter* painter, + const QStyleOptionGraphicsItem* option, + QWidget* widget) override; + QRectF boundingRect() const override; }; diff --git a/Applications/DataExplorer/Base/RecentFiles.h b/Applications/DataExplorer/Base/RecentFiles.h index ec8d6b5456f..06aeeb2dd0a 100644 --- a/Applications/DataExplorer/Base/RecentFiles.h +++ b/Applications/DataExplorer/Base/RecentFiles.h @@ -49,7 +49,7 @@ public: * \param settingsName The setting key */ RecentFiles(QObject* parent, const char* slot, QString settingsName); - ~RecentFiles(); + ~RecentFiles() override; /// Returns the created menu. Add this menu to your QMainWindow menu. QMenu* menu(); diff --git a/Applications/DataExplorer/Base/StrictDoubleValidator.h b/Applications/DataExplorer/Base/StrictDoubleValidator.h index bb3cd3b1050..19273c5948a 100644 --- a/Applications/DataExplorer/Base/StrictDoubleValidator.h +++ b/Applications/DataExplorer/Base/StrictDoubleValidator.h @@ -30,7 +30,7 @@ public: QDoubleValidator( parent) {} - QValidator::State validate(QString & input, int &pos) const + QValidator::State validate(QString& input, int& pos) const override { if (input.isEmpty() || input == "." || input == "-") return Intermediate; diff --git a/Applications/DataExplorer/Base/StrictIntValidator.h b/Applications/DataExplorer/Base/StrictIntValidator.h index 677fea754fa..a4ee5f54e50 100644 --- a/Applications/DataExplorer/Base/StrictIntValidator.h +++ b/Applications/DataExplorer/Base/StrictIntValidator.h @@ -27,7 +27,7 @@ public: : QIntValidator(min, max, parent) {} - QValidator::State validate(QString & input, int &pos) const + QValidator::State validate(QString& input, int& pos) const override { if (input.isEmpty()) return Intermediate; diff --git a/Applications/DataExplorer/Base/TreeModel.h b/Applications/DataExplorer/Base/TreeModel.h index 94ce0218234..b0bc52b9fdb 100644 --- a/Applications/DataExplorer/Base/TreeModel.h +++ b/Applications/DataExplorer/Base/TreeModel.h @@ -32,19 +32,21 @@ class TreeModel : public QAbstractItemModel public: TreeModel(QObject* parent = nullptr); - virtual ~TreeModel(); + ~TreeModel() override; - QVariant data(const QModelIndex &index, int role) const; - bool setData(const QModelIndex &index, const QVariant &value, int role /* = Qt::EditRole */); - Qt::ItemFlags flags(const QModelIndex &index) const; + QVariant data(const QModelIndex& index, int role) const override; + bool setData(const QModelIndex& index, const QVariant& value, + int role /* = Qt::EditRole */) override; + Qt::ItemFlags flags(const QModelIndex& index) const override; TreeItem* getItem(const QModelIndex &index) const; - QVariant headerData(int section, Qt::Orientation orientation, int role = - Qt::DisplayRole) const; - QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const; - QModelIndex parent(const QModelIndex &index) const; - bool removeRows(int row, int count, const QModelIndex & parent); - int rowCount(const QModelIndex &parent = QModelIndex()) const; - int columnCount(const QModelIndex &parent = QModelIndex()) const; + QVariant headerData(int section, Qt::Orientation orientation, + int role = Qt::DisplayRole) const override; + QModelIndex index(int row, int column, + const QModelIndex& parent = QModelIndex()) const override; + QModelIndex parent(const QModelIndex& index) const override; + bool removeRows(int row, int count, const QModelIndex& parent) override; + int rowCount(const QModelIndex& parent = QModelIndex()) const override; + int columnCount(const QModelIndex& parent = QModelIndex()) const override; TreeItem* rootItem() const; diff --git a/Applications/DataExplorer/DataView/AddLayerToMeshDialog.h b/Applications/DataExplorer/DataView/AddLayerToMeshDialog.h index 1563895a211..08a3c6504dc 100644 --- a/Applications/DataExplorer/DataView/AddLayerToMeshDialog.h +++ b/Applications/DataExplorer/DataView/AddLayerToMeshDialog.h @@ -40,8 +40,8 @@ public: private slots: /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); + void reject() override; }; diff --git a/Applications/DataExplorer/DataView/ColorTableModel.h b/Applications/DataExplorer/DataView/ColorTableModel.h index d8e69a8e097..cb44582e7e9 100644 --- a/Applications/DataExplorer/DataView/ColorTableModel.h +++ b/Applications/DataExplorer/DataView/ColorTableModel.h @@ -30,20 +30,20 @@ public: ColorTableModel( const std::map<std::string, DataHolderLib::Color*>& colorLookupTable, QObject* parent = nullptr); - ~ColorTableModel(); + ~ColorTableModel() override; - int columnCount(const QModelIndex& parent = QModelIndex()) const; + int columnCount(const QModelIndex& parent = QModelIndex()) const override; - QVariant data( const QModelIndex& index, int role ) const; + QVariant data(const QModelIndex& index, int role) const override; - int rowCount(const QModelIndex& parent = QModelIndex()) const + int rowCount(const QModelIndex& parent = QModelIndex()) const override { Q_UNUSED (parent); return _listOfPairs.size(); } - QVariant headerData( int section, Qt::Orientation orientation, - int role /*= Qt::DisplayRole*/ ) const; + QVariant headerData(int section, Qt::Orientation orientation, + int role /*= Qt::DisplayRole*/) const override; private: bool buildTable( const std::map<std::string, DataHolderLib::Color*> &colorLookupTable ); diff --git a/Applications/DataExplorer/DataView/ColorTableView.h b/Applications/DataExplorer/DataView/ColorTableView.h index 47ae8b2b7dc..0d51773824d 100644 --- a/Applications/DataExplorer/DataView/ColorTableView.h +++ b/Applications/DataExplorer/DataView/ColorTableView.h @@ -39,8 +39,9 @@ public: /// Constructor ColorTableViewDelegate(QWidget* parent = nullptr) : QItemDelegate(parent) {} /// Overwrites the paint-method to set user-defined properties instead of the default properties. - void paint(QPainter* painter, const QStyleOptionViewItem &option, - const QModelIndex &index) const; + void paint(QPainter* painter, const QStyleOptionViewItem& option, + const QModelIndex& index) const override; - QSize sizeHint( const QStyleOptionViewItem &option, const QModelIndex &index ) const; + QSize sizeHint(const QStyleOptionViewItem& option, + const QModelIndex& index) const override; }; diff --git a/Applications/DataExplorer/DataView/CondFromRasterDialog.h b/Applications/DataExplorer/DataView/CondFromRasterDialog.h index 9de5003574a..d3a291ff4d6 100644 --- a/Applications/DataExplorer/DataView/CondFromRasterDialog.h +++ b/Applications/DataExplorer/DataView/CondFromRasterDialog.h @@ -33,7 +33,7 @@ class CondFromRasterDialog : public QDialog, private Ui_CondFromRaster public: CondFromRasterDialog(std::vector<MeshLib::Mesh*> msh_vec, QDialog* parent = nullptr); - ~CondFromRasterDialog(void); + ~CondFromRasterDialog(void) override; private: const std::vector<MeshLib::Mesh*> _msh_vec; @@ -44,10 +44,10 @@ private slots: void on_selectButton_pressed(); /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); + void reject() override; signals: void directNodesWritten(std::string); diff --git a/Applications/DataExplorer/DataView/CreateStructuredGridDialog.h b/Applications/DataExplorer/DataView/CreateStructuredGridDialog.h index 89f061a014a..e150c5590c1 100644 --- a/Applications/DataExplorer/DataView/CreateStructuredGridDialog.h +++ b/Applications/DataExplorer/DataView/CreateStructuredGridDialog.h @@ -39,10 +39,10 @@ private slots: void on_elemExtentButton_toggled(); /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject() { this->done(QDialog::Rejected); }; + void reject() override { this->done(QDialog::Rejected); }; private: void enable2dWidgets() const; diff --git a/Applications/DataExplorer/DataView/DataExplorerSettingsDialog.h b/Applications/DataExplorer/DataView/DataExplorerSettingsDialog.h index 7fcc38b4e1d..3259d38b4dd 100644 --- a/Applications/DataExplorer/DataView/DataExplorerSettingsDialog.h +++ b/Applications/DataExplorer/DataView/DataExplorerSettingsDialog.h @@ -26,16 +26,14 @@ class DataExplorerSettingsDialog : public QDialog, private Ui_DataExplorerSettin public: DataExplorerSettingsDialog(QDialog* parent = nullptr); - ~DataExplorerSettingsDialog(void); - + ~DataExplorerSettingsDialog(void) override; private slots: void on_gmshPathButton_clicked(); /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject() { this->done(QDialog::Rejected); }; - + void reject() override { this->done(QDialog::Rejected); }; }; diff --git a/Applications/DataExplorer/DataView/DiagramView/DetailWindow.h b/Applications/DataExplorer/DataView/DiagramView/DetailWindow.h index c5dcb6ac8c7..230c6370d02 100644 --- a/Applications/DataExplorer/DataView/DiagramView/DetailWindow.h +++ b/Applications/DataExplorer/DataView/DiagramView/DetailWindow.h @@ -44,7 +44,7 @@ public: DetailWindow(std::vector<std::size_t> data, QWidget* parent = nullptr); - ~DetailWindow(void); + ~DetailWindow(void) override; /** * Adds another plot to window. Axes are automatically resized, a random color is used. diff --git a/Applications/DataExplorer/DataView/DiagramView/DiagramPrefsDialog.h b/Applications/DataExplorer/DataView/DiagramView/DiagramPrefsDialog.h index d14723ef7cc..b2570c79e13 100644 --- a/Applications/DataExplorer/DataView/DiagramView/DiagramPrefsDialog.h +++ b/Applications/DataExplorer/DataView/DiagramView/DiagramPrefsDialog.h @@ -71,7 +71,7 @@ public: DetailWindow* window = nullptr, QDialog* parent = nullptr); - ~DiagramPrefsDialog(void); + ~DiagramPrefsDialog(void) override; private: /** @@ -104,10 +104,10 @@ private: private slots: /// Instructions if the OK-Button has been pressed. /// Note: Clicking the "Load from file"-button overrides the database input! - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); + void reject() override; /// Instructions if the "Load File"-Button has been pressed. void on_loadFileButton_clicked(); diff --git a/Applications/DataExplorer/DataView/DiagramView/DiagramScene.h b/Applications/DataExplorer/DataView/DiagramView/DiagramScene.h index 1453dadc5ba..ef7f40cc431 100644 --- a/Applications/DataExplorer/DataView/DiagramView/DiagramScene.h +++ b/Applications/DataExplorer/DataView/DiagramView/DiagramScene.h @@ -30,7 +30,7 @@ class DiagramScene : public QGraphicsScene public: DiagramScene(QObject* parent = nullptr); DiagramScene(DiagramList* list, QObject* parent = nullptr); - ~DiagramScene(); + ~DiagramScene() override; QArrow* addArrow(float length, float angle, QPen &pen); void addGraph(DiagramList* list); diff --git a/Applications/DataExplorer/DataView/DiagramView/DiagramView.h b/Applications/DataExplorer/DataView/DiagramView/DiagramView.h index 968bf3cdaf7..d43065b4122 100644 --- a/Applications/DataExplorer/DataView/DiagramView/DiagramView.h +++ b/Applications/DataExplorer/DataView/DiagramView/DiagramView.h @@ -38,7 +38,7 @@ public: * \param parent The parent QWidget. */ DiagramView(DiagramList* list, QWidget* parent = nullptr); - ~DiagramView(); + ~DiagramView() override; /// Adds a new graph to the scene. void addGraph(DiagramList* list); @@ -49,13 +49,13 @@ public: protected: /// Resizes the scene. - void resizeEvent(QResizeEvent* event); + void resizeEvent(QResizeEvent* event) override; private: void initialize(); void keepItemAspectRatio(); - QSize minimumSizeHint() const; - QSize sizeHint() const; + QSize minimumSizeHint() const override; + QSize sizeHint() const override; void update(); DiagramScene* _scene; diff --git a/Applications/DataExplorer/DataView/DiagramView/QArrow.h b/Applications/DataExplorer/DataView/DiagramView/QArrow.h index 4731222866c..1db5b959a5c 100644 --- a/Applications/DataExplorer/DataView/DiagramView/QArrow.h +++ b/Applications/DataExplorer/DataView/DiagramView/QArrow.h @@ -28,12 +28,13 @@ public: QArrow(float l, float a, float hl, float hw, QPen& pen, QGraphicsItem* parent = nullptr); QArrow(float l, float a, QPen& pen, QGraphicsItem* parent = nullptr); - ~QArrow(); + ~QArrow() override; double getLength(); double getAngle(); - void paint(QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget); - QRectF boundingRect() const; + void paint(QPainter* painter, const QStyleOptionGraphicsItem* option, + QWidget* widget) override; + QRectF boundingRect() const override; void setAngle(double a); void setLength(double l); diff --git a/Applications/DataExplorer/DataView/DiagramView/QGraphicsGrid.h b/Applications/DataExplorer/DataView/DiagramView/QGraphicsGrid.h index 3518d07edda..df90d639ee7 100644 --- a/Applications/DataExplorer/DataView/DiagramView/QGraphicsGrid.h +++ b/Applications/DataExplorer/DataView/DiagramView/QGraphicsGrid.h @@ -51,10 +51,12 @@ public: bool ticks, QPen pen, QGraphicsItem* parent = nullptr); - ~QGraphicsGrid(); + ~QGraphicsGrid() override; - QRectF boundingRect() const; - void paint(QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget); + QRectF boundingRect() const override; + void paint(QPainter* painter, + const QStyleOptionGraphicsItem* option, + QWidget* widget) override; void setNumberOfXCells(int xCells); void setNumberOfYCells(int yCells); void setRect(QRectF rect); diff --git a/Applications/DataExplorer/DataView/ElementTreeModel.h b/Applications/DataExplorer/DataView/ElementTreeModel.h index dfac4a60e2f..3ce6059b58d 100644 --- a/Applications/DataExplorer/DataView/ElementTreeModel.h +++ b/Applications/DataExplorer/DataView/ElementTreeModel.h @@ -33,7 +33,7 @@ class ElementTreeModel : public TreeModel public: ElementTreeModel(QObject* parent = nullptr); - ~ElementTreeModel(); + ~ElementTreeModel() override; vtkUnstructuredGridAlgorithm const* getSource() const { return _mesh_source; }; diff --git a/Applications/DataExplorer/DataView/ElementTreeView.h b/Applications/DataExplorer/DataView/ElementTreeView.h index cdd048901f1..af980f1c31c 100644 --- a/Applications/DataExplorer/DataView/ElementTreeView.h +++ b/Applications/DataExplorer/DataView/ElementTreeView.h @@ -33,7 +33,8 @@ public slots: protected slots: /// Is called when the selection of this view changes. - void selectionChanged(const QItemSelection &selected, const QItemSelection &deselected); + void selectionChanged(const QItemSelection& selected, + const QItemSelection& deselected) override; signals: void nodeSelected(vtkUnstructuredGridAlgorithm const*const, unsigned, bool); diff --git a/Applications/DataExplorer/DataView/GEOModels.h b/Applications/DataExplorer/DataView/GEOModels.h index eebcf35cba6..54981a89ab2 100644 --- a/Applications/DataExplorer/DataView/GEOModels.h +++ b/Applications/DataExplorer/DataView/GEOModels.h @@ -39,7 +39,7 @@ class GEOModels : public QObject public: GEOModels(GeoLib::GEOObjects& geo_objects, QObject* parent = nullptr); - ~GEOModels(); + ~GEOModels() override; GeoTreeModel* getGeoModel() { return _geoModel; } StationTreeModel* getStationModel() { return _stationModel; } diff --git a/Applications/DataExplorer/DataView/GMSHPrefsDialog.h b/Applications/DataExplorer/DataView/GMSHPrefsDialog.h index 768b7d68862..80ba02e8afc 100644 --- a/Applications/DataExplorer/DataView/GMSHPrefsDialog.h +++ b/Applications/DataExplorer/DataView/GMSHPrefsDialog.h @@ -33,7 +33,7 @@ class GMSHPrefsDialog : public QDialog, private Ui_GMSHPrefs public: GMSHPrefsDialog(GeoLib::GEOObjects const& geoObjects, QDialog* parent = nullptr); - ~GMSHPrefsDialog(void); + ~GMSHPrefsDialog(void) override; private: std::vector<std::string> getSelectedObjects(QStringList list); @@ -47,10 +47,10 @@ private slots: void on_radioAdaptive_toggled(bool isTrue); /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); + void reject() override; signals: void requestMeshing(std::vector<std::string> &, unsigned, double, double, double, bool); diff --git a/Applications/DataExplorer/DataView/GeoObjectListItem.h b/Applications/DataExplorer/DataView/GeoObjectListItem.h index 99c5e667894..9f5655e21a4 100644 --- a/Applications/DataExplorer/DataView/GeoObjectListItem.h +++ b/Applications/DataExplorer/DataView/GeoObjectListItem.h @@ -75,11 +75,7 @@ public: static_cast<VtkSurfacesSource*>(_vtkSource)->SetName(geo_name + " - Surfaces"); } - ~GeoObjectListItem() - { - _vtkSource->Delete(); - } - + ~GeoObjectListItem() override { _vtkSource->Delete(); } /// Returns the type of geo-objects contained in the subtree of this item. GeoLib::GEOTYPE getType() { return _type; } diff --git a/Applications/DataExplorer/DataView/GeoOnMeshMappingDialog.h b/Applications/DataExplorer/DataView/GeoOnMeshMappingDialog.h index 5977fb06031..40c0efa1477 100644 --- a/Applications/DataExplorer/DataView/GeoOnMeshMappingDialog.h +++ b/Applications/DataExplorer/DataView/GeoOnMeshMappingDialog.h @@ -34,7 +34,7 @@ public: GeoOnMeshMappingDialog( std::vector<std::unique_ptr<MeshLib::Mesh>> const& mesh_vec, QDialog* parent = nullptr); - ~GeoOnMeshMappingDialog(void); + ~GeoOnMeshMappingDialog(void) override; std::string const& getNewGeoName() const { return _new_geo_name; }; int getDataSetChoice() const; @@ -48,9 +48,8 @@ private slots: void on_meshNameComboBox_currentIndexChanged(int idx); /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject() { this->done(QDialog::Rejected); }; - + void reject() override { this->done(QDialog::Rejected); }; }; diff --git a/Applications/DataExplorer/DataView/GeoTreeItem.h b/Applications/DataExplorer/DataView/GeoTreeItem.h index 2b18702bc47..52011079b1c 100644 --- a/Applications/DataExplorer/DataView/GeoTreeItem.h +++ b/Applications/DataExplorer/DataView/GeoTreeItem.h @@ -38,7 +38,7 @@ public: : TreeItem(data, parent), _item(item) { } - ~GeoTreeItem() = default; + ~GeoTreeItem() override = default; /// Returns the geo-object associated with this item (i.e. a point, polyline or surface). const GeoLib::GeoObject* getGeoObject() const { return _item; } diff --git a/Applications/DataExplorer/DataView/GeoTreeModel.h b/Applications/DataExplorer/DataView/GeoTreeModel.h index 253090f33c4..8135af2dc1c 100644 --- a/Applications/DataExplorer/DataView/GeoTreeModel.h +++ b/Applications/DataExplorer/DataView/GeoTreeModel.h @@ -43,7 +43,7 @@ class GeoTreeModel : public TreeModel public: GeoTreeModel(QObject* parent = nullptr); - ~GeoTreeModel(); + ~GeoTreeModel() override; /** * Inserts a new subtree under _rootItem for a geometry with the given name along with a subtree named "Points" for that new geometry. diff --git a/Applications/DataExplorer/DataView/GeoTreeView.h b/Applications/DataExplorer/DataView/GeoTreeView.h index 98a94e39642..ed096bf84af 100644 --- a/Applications/DataExplorer/DataView/GeoTreeView.h +++ b/Applications/DataExplorer/DataView/GeoTreeView.h @@ -38,7 +38,8 @@ public: protected slots: /// Instructions if the selection of items in the view has changed. - void selectionChanged(const QItemSelection &selected, const QItemSelection &deselected); + void selectionChanged(const QItemSelection& selected, + const QItemSelection& deselected) override; /// Instructions if the selection of items in the view has changed by events outside the view (i.e. by actions made in the visualisation). void selectionChangedFromOutside(const QItemSelection &selected, @@ -46,7 +47,7 @@ protected slots: private: /// Actions to be taken after a right mouse click is performed in the station view. - void contextMenuEvent( QContextMenuEvent* e ); + void contextMenuEvent(QContextMenuEvent* e) override; /// Calls a FEMConditionSetupDialog. void setElementAsCondition(bool set_on_points = false); diff --git a/Applications/DataExplorer/DataView/LicenseDialog.h b/Applications/DataExplorer/DataView/LicenseDialog.h index 582af9f6c02..08f88f5e178 100644 --- a/Applications/DataExplorer/DataView/LicenseDialog.h +++ b/Applications/DataExplorer/DataView/LicenseDialog.h @@ -26,7 +26,7 @@ class LicenseDialog : public QDialog, private Ui_License public: LicenseDialog(QDialog* parent = nullptr); - ~LicenseDialog() = default; + ~LicenseDialog() override = default; ; private: diff --git a/Applications/DataExplorer/DataView/LineEditDialog.h b/Applications/DataExplorer/DataView/LineEditDialog.h index f2a444e12bc..ff0da51b8c8 100644 --- a/Applications/DataExplorer/DataView/LineEditDialog.h +++ b/Applications/DataExplorer/DataView/LineEditDialog.h @@ -33,7 +33,7 @@ class LineEditDialog : public QDialog, private Ui_LineEdit public: LineEditDialog(const GeoLib::PolylineVec& ply_vec, QDialog* parent = nullptr); - ~LineEditDialog(void); + ~LineEditDialog(void) override; private: std::vector<std::size_t> getSelectedIndeces(QStringList list); @@ -50,10 +50,10 @@ private slots: void on_deselectPlyButton_pressed(); /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); + void reject() override; signals: void connectPolylines(const std::string&, diff --git a/Applications/DataExplorer/DataView/LinearEditDialog.h b/Applications/DataExplorer/DataView/LinearEditDialog.h index a94039ec128..8c35c7d5c9a 100644 --- a/Applications/DataExplorer/DataView/LinearEditDialog.h +++ b/Applications/DataExplorer/DataView/LinearEditDialog.h @@ -31,7 +31,7 @@ public: const std::vector<std::size_t>& dis_nodes, const std::vector<double>& dis_values, QDialog* parent = nullptr); - ~LinearEditDialog(void); + ~LinearEditDialog(void) override; private: void setupDialog(const std::vector<std::size_t> &dis_nodes, const std::vector<double> &dis_values); @@ -42,10 +42,10 @@ private slots: void on_comboBox_currentIndexChanged(int index); /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); + void reject() override; signals: void transmitDisValues(std::vector< std::pair<std::size_t,double> >); diff --git a/Applications/DataExplorer/DataView/MergeGeometriesDialog.h b/Applications/DataExplorer/DataView/MergeGeometriesDialog.h index c8dcc161a25..5c1462e4b9c 100644 --- a/Applications/DataExplorer/DataView/MergeGeometriesDialog.h +++ b/Applications/DataExplorer/DataView/MergeGeometriesDialog.h @@ -34,7 +34,7 @@ class MergeGeometriesDialog : public QDialog, private Ui_MergeGeometries public: MergeGeometriesDialog(GeoLib::GEOObjects& geoObjects, QDialog* parent = nullptr); - ~MergeGeometriesDialog(void); + ~MergeGeometriesDialog(void) override; /// Returns a vector of selected geometries std::vector<std::string> const getSelectedGeometries() const; @@ -52,8 +52,8 @@ private slots: void on_deselectGeoButton_pressed(); /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); + void reject() override; }; diff --git a/Applications/DataExplorer/DataView/MeshAnalysisDialog.h b/Applications/DataExplorer/DataView/MeshAnalysisDialog.h index 7fde240dc43..d6c0180eebf 100644 --- a/Applications/DataExplorer/DataView/MeshAnalysisDialog.h +++ b/Applications/DataExplorer/DataView/MeshAnalysisDialog.h @@ -36,7 +36,7 @@ public: MeshAnalysisDialog( std::vector<std::unique_ptr<MeshLib::Mesh>> const& mesh_vec, QDialog* parent = nullptr); - ~MeshAnalysisDialog(void); + ~MeshAnalysisDialog(void) override; private: /// Prepares the output for the node message window diff --git a/Applications/DataExplorer/DataView/MeshElementRemovalDialog.h b/Applications/DataExplorer/DataView/MeshElementRemovalDialog.h index edd0cf89fab..2a4b5fb8380 100644 --- a/Applications/DataExplorer/DataView/MeshElementRemovalDialog.h +++ b/Applications/DataExplorer/DataView/MeshElementRemovalDialog.h @@ -38,7 +38,7 @@ class MeshElementRemovalDialog : public QDialog, private Ui_MeshElementRemoval public: MeshElementRemovalDialog(DataHolderLib::Project const& project, QDialog* parent = nullptr); - ~MeshElementRemovalDialog(void); + ~MeshElementRemovalDialog(void) override; private slots: void on_boundingBoxCheckBox_toggled(bool is_checked); @@ -51,8 +51,8 @@ private slots: void on_yMaxEdit_textChanged() { aabb_edits[3] = true; } void on_zMinEdit_textChanged() { aabb_edits[4] = true; } void on_zMaxEdit_textChanged() { aabb_edits[5] = true; } - void accept(); - void reject(); + void accept() override; + void reject() override; private: DataHolderLib::Project const& _project; diff --git a/Applications/DataExplorer/DataView/MeshLayerEditDialog.h b/Applications/DataExplorer/DataView/MeshLayerEditDialog.h index 83f443134d7..32d8850dbdf 100644 --- a/Applications/DataExplorer/DataView/MeshLayerEditDialog.h +++ b/Applications/DataExplorer/DataView/MeshLayerEditDialog.h @@ -40,7 +40,7 @@ class MeshLayerEditDialog : public QDialog, private Ui_MeshLayerEdit public: MeshLayerEditDialog(const MeshLib::Mesh* mesh, QDialog* parent = nullptr); - ~MeshLayerEditDialog(void); + ~MeshLayerEditDialog(void) override; private: void createMeshToolSelection(); @@ -72,10 +72,10 @@ private slots: void createStatic(); /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); + void reject() override; signals: void mshEditFinished(MeshLib::Mesh*); diff --git a/Applications/DataExplorer/DataView/MeshMapping2DDialog.h b/Applications/DataExplorer/DataView/MeshMapping2DDialog.h index 7702cd357b4..f113ec3bcc2 100644 --- a/Applications/DataExplorer/DataView/MeshMapping2DDialog.h +++ b/Applications/DataExplorer/DataView/MeshMapping2DDialog.h @@ -37,8 +37,8 @@ private slots: void on_rasterSelectButton_pressed(); /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject() { this->done(QDialog::Rejected); } + void reject() override { this->done(QDialog::Rejected); } }; diff --git a/Applications/DataExplorer/DataView/MeshQualitySelectionDialog.h b/Applications/DataExplorer/DataView/MeshQualitySelectionDialog.h index 9160253fa49..32e907707db 100644 --- a/Applications/DataExplorer/DataView/MeshQualitySelectionDialog.h +++ b/Applications/DataExplorer/DataView/MeshQualitySelectionDialog.h @@ -29,7 +29,7 @@ class MeshQualitySelectionDialog : public QDialog, private Ui_MeshQualitySelecti public: MeshQualitySelectionDialog(QDialog* parent = nullptr); - ~MeshQualitySelectionDialog(void); + ~MeshQualitySelectionDialog(void) override; /// Returns selected metric MeshLib::MeshQualityType getSelectedMetric() const { return _metric; } @@ -48,6 +48,6 @@ private slots: void on_histogramCheckBox_toggled(bool is_checked) const; void on_histogramPathButton_pressed(); - void accept(); - void reject(); + void accept() override; + void reject() override; }; diff --git a/Applications/DataExplorer/DataView/MeshValueEditDialog.h b/Applications/DataExplorer/DataView/MeshValueEditDialog.h index 518981d079e..fbbf2d7bc44 100644 --- a/Applications/DataExplorer/DataView/MeshValueEditDialog.h +++ b/Applications/DataExplorer/DataView/MeshValueEditDialog.h @@ -33,17 +33,17 @@ public: /// Constructor for creating a new FEM condition. MeshValueEditDialog(MeshLib::Mesh* mesh, QDialog* parent = nullptr); - ~MeshValueEditDialog(void); + ~MeshValueEditDialog(void) override; private: MeshLib::Mesh* _mesh; private slots: /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); + void reject() override; void on_replaceButton_toggled(bool isSelected); diff --git a/Applications/DataExplorer/DataView/ModelTreeItem.h b/Applications/DataExplorer/DataView/ModelTreeItem.h index a2e664e9fb8..c33f9b988a1 100644 --- a/Applications/DataExplorer/DataView/ModelTreeItem.h +++ b/Applications/DataExplorer/DataView/ModelTreeItem.h @@ -34,8 +34,7 @@ public: */ ModelTreeItem(const QList<QVariant>& data, TreeItem* parent, BaseItem* item = nullptr); - ~ModelTreeItem() { delete _item; } - + ~ModelTreeItem() override { delete _item; } /// Returns the station object from which this item has been constructed GeoLib::Station* getStation() { return _stn; } diff --git a/Applications/DataExplorer/DataView/MshItem.h b/Applications/DataExplorer/DataView/MshItem.h index be5eb456eca..a88201ccc7a 100644 --- a/Applications/DataExplorer/DataView/MshItem.h +++ b/Applications/DataExplorer/DataView/MshItem.h @@ -36,7 +36,7 @@ public: /// \param mesh The mesh associated with this item MshItem(const QList<QVariant>& data, TreeItem* parent, const MeshLib::Mesh* mesh); - ~MshItem(); + ~MshItem() override; /// Returns the mesh. MeshLib::Mesh const* getMesh() const { return _mesh_source->GetMesh(); } diff --git a/Applications/DataExplorer/DataView/MshModel.h b/Applications/DataExplorer/DataView/MshModel.h index 2013e855daf..d18de697467 100644 --- a/Applications/DataExplorer/DataView/MshModel.h +++ b/Applications/DataExplorer/DataView/MshModel.h @@ -45,7 +45,7 @@ public: void addMesh(std::unique_ptr<MeshLib::Mesh> mesh); /// Returns the number of columns used for the data list - int columnCount(const QModelIndex& parent = QModelIndex()) const; + int columnCount(const QModelIndex& parent = QModelIndex()) const override; public slots: /// Adds a new mesh (using no unique_ptr as this interferes with Qt's signal/slot policy) diff --git a/Applications/DataExplorer/DataView/MshView.h b/Applications/DataExplorer/DataView/MshView.h index 8cdde7798e0..a0c43ba3205 100644 --- a/Applications/DataExplorer/DataView/MshView.h +++ b/Applications/DataExplorer/DataView/MshView.h @@ -38,14 +38,15 @@ class MshView : public QTreeView public: MshView(QWidget* parent = nullptr); - ~MshView(); + ~MshView() override; public slots: void updateView(); protected slots: /// Is called when the selection of this view changes. - void selectionChanged(const QItemSelection &selected, const QItemSelection &deselected); + void selectionChanged(const QItemSelection& selected, + const QItemSelection& deselected) override; private: struct MeshAction @@ -55,7 +56,7 @@ private: unsigned max_dim; }; - void contextMenuEvent( QContextMenuEvent* event ); + void contextMenuEvent(QContextMenuEvent* event) override; private slots: /// Opens a dialog for mapping 2d meshes. diff --git a/Applications/DataExplorer/DataView/NetCdfConfigureDialog.h b/Applications/DataExplorer/DataView/NetCdfConfigureDialog.h index 8be5093a210..bbfbdf3be08 100644 --- a/Applications/DataExplorer/DataView/NetCdfConfigureDialog.h +++ b/Applications/DataExplorer/DataView/NetCdfConfigureDialog.h @@ -35,14 +35,14 @@ class NetCdfConfigureDialog : public QDialog, private Ui_NetCdfConfigure public: NetCdfConfigureDialog(const std::string& fileName, QDialog* parent = nullptr); - ~NetCdfConfigureDialog(void); + ~NetCdfConfigureDialog(void) override; MeshLib::Mesh* getMesh() { return _currentMesh; }; std::string getName(); VtkGeoImageSource* getRaster() { return _currentRaster; }; private slots: - void accept(); - void reject(); + void accept() override; + void reject() override; void on_comboBoxVariable_currentIndexChanged(int id); void on_comboBoxDim1_currentIndexChanged(int id); void on_comboBoxDim2_currentIndexChanged(int id); diff --git a/Applications/DataExplorer/DataView/SHPImportDialog.h b/Applications/DataExplorer/DataView/SHPImportDialog.h index 2b67a363c5d..06005556061 100644 --- a/Applications/DataExplorer/DataView/SHPImportDialog.h +++ b/Applications/DataExplorer/DataView/SHPImportDialog.h @@ -43,7 +43,7 @@ public: /// Constructor SHPImportDialog(std::string filename, GeoLib::GEOObjects& geo_objects, QDialog* parent = nullptr); - ~SHPImportDialog(); + ~SHPImportDialog() override; QDialogButtonBox* _buttonBox; /// The buttons used in this dialog. @@ -62,10 +62,10 @@ private: private slots: /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); + void reject() override; signals: void shpLoaded(QString); diff --git a/Applications/DataExplorer/DataView/SaveMeshDialog.h b/Applications/DataExplorer/DataView/SaveMeshDialog.h index fe86351d5d9..0f58d56ecf0 100644 --- a/Applications/DataExplorer/DataView/SaveMeshDialog.h +++ b/Applications/DataExplorer/DataView/SaveMeshDialog.h @@ -30,7 +30,7 @@ class SaveMeshDialog : public QDialog, private Ui_SaveMesh public: SaveMeshDialog(MeshLib::Mesh const& mesh, QDialog* parent = nullptr); - ~SaveMeshDialog() = default; + ~SaveMeshDialog() override = default; private slots: /// Selection of path to save file @@ -39,10 +39,10 @@ private slots: void on_dataModeBox_currentIndexChanged(int index); /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject() { this->done(QDialog::Rejected); }; + void reject() override { this->done(QDialog::Rejected); }; private: MeshLib::Mesh const& _mesh; diff --git a/Applications/DataExplorer/DataView/SelectMeshDialog.h b/Applications/DataExplorer/DataView/SelectMeshDialog.h index 57da27a82f8..434aab877a5 100644 --- a/Applications/DataExplorer/DataView/SelectMeshDialog.h +++ b/Applications/DataExplorer/DataView/SelectMeshDialog.h @@ -37,7 +37,7 @@ public: SelectMeshDialog(const GeoLib::GeoObject* geo_object, const std::list<std::string>& msh_names, QDialog* parent = nullptr); - ~SelectMeshDialog(); + ~SelectMeshDialog() override; QDialogButtonBox* _buttonBox; /// The buttons used in this dialog. @@ -53,10 +53,10 @@ private: private slots: /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); + void reject() override; signals: //void requestNameChange(const std::string&, const GeoLib::GEOTYPE, std::size_t, std::string); diff --git a/Applications/DataExplorer/DataView/SetNameDialog.h b/Applications/DataExplorer/DataView/SetNameDialog.h index 4cca4829ae8..fea7b06c955 100644 --- a/Applications/DataExplorer/DataView/SetNameDialog.h +++ b/Applications/DataExplorer/DataView/SetNameDialog.h @@ -34,7 +34,7 @@ public: /// Constructor SetNameDialog(const std::string& geo_object_type, std::size_t id, const std::string& old_name, QDialog* parent = nullptr); - ~SetNameDialog(); + ~SetNameDialog() override; std::string getNewName(); @@ -49,8 +49,8 @@ private: private slots: /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); + void reject() override; }; diff --git a/Applications/DataExplorer/DataView/StationTreeModel.h b/Applications/DataExplorer/DataView/StationTreeModel.h index f4257527c62..9197fffb5fc 100644 --- a/Applications/DataExplorer/DataView/StationTreeModel.h +++ b/Applications/DataExplorer/DataView/StationTreeModel.h @@ -44,11 +44,12 @@ class StationTreeModel : public TreeModel public: StationTreeModel(QObject* parent = nullptr); - ~StationTreeModel(); + ~StationTreeModel() override; void addStationList(QString listName, const std::vector<GeoLib::Point*>* stations); const std::vector<ModelTreeItem*> &getLists() { return _lists; } - QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const; + QModelIndex index(int row, int column, + const QModelIndex& parent = QModelIndex()) const override; //BaseItem* itemFromIndex( const QModelIndex& index ) const; void removeStationList(QModelIndex index); void removeStationList(const std::string &name); diff --git a/Applications/DataExplorer/DataView/StationTreeView.h b/Applications/DataExplorer/DataView/StationTreeView.h index 567eb536b60..f2155fd7c7c 100644 --- a/Applications/DataExplorer/DataView/StationTreeView.h +++ b/Applications/DataExplorer/DataView/StationTreeView.h @@ -41,7 +41,8 @@ public slots: protected slots: /// Instructions if the selection of items in the view has changed. - void selectionChanged(const QItemSelection &selected, const QItemSelection &deselected); + void selectionChanged(const QItemSelection& selected, + const QItemSelection& deselected) override; /// Instructions if the selection of items in the view has changed by events outside the view (i.e. by actions made in the visualisation). void selectionChangedFromOutside(const QItemSelection &selected, @@ -49,7 +50,7 @@ protected slots: private: /// Actions to be taken after a right mouse click is performed in the station view. - void contextMenuEvent( QContextMenuEvent* e ); + void contextMenuEvent(QContextMenuEvent* e) override; /// Create image files from all stratigraphies in a borehole vector void writeStratigraphiesAsImages(QString listName); diff --git a/Applications/DataExplorer/DataView/StratView/StratBar.h b/Applications/DataExplorer/DataView/StratView/StratBar.h index 97111408dbc..1362a7a9368 100644 --- a/Applications/DataExplorer/DataView/StratView/StratBar.h +++ b/Applications/DataExplorer/DataView/StratView/StratBar.h @@ -38,13 +38,15 @@ public: StratBar(GeoLib::StationBorehole* station, std::map<std::string, DataHolderLib::Color>* stratColors = nullptr, QGraphicsItem* parent = nullptr); - ~StratBar(); + ~StratBar() override; /// Returns the bounding rectangle of the bar. - QRectF boundingRect() const; + QRectF boundingRect() const override; /// Paints the bar. - void paint(QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget); + void paint(QPainter* painter, + const QStyleOptionGraphicsItem* option, + QWidget* widget) override; private: /** diff --git a/Applications/DataExplorer/DataView/StratView/StratScene.h b/Applications/DataExplorer/DataView/StratView/StratScene.h index 47612198c1e..8bcf28e3e29 100644 --- a/Applications/DataExplorer/DataView/StratView/StratScene.h +++ b/Applications/DataExplorer/DataView/StratView/StratScene.h @@ -33,7 +33,7 @@ public: GeoLib::StationBorehole* station, std::map<std::string, DataHolderLib::Color>* stratColors = nullptr, QObject* parent = nullptr); - ~StratScene(); + ~StratScene() override; /// The margin between the boundary of the scene and the bounding box of all items within the scene static const int MARGIN = 50; diff --git a/Applications/DataExplorer/DataView/StratView/StratView.h b/Applications/DataExplorer/DataView/StratView/StratView.h index fde63435e95..d405a8fc944 100644 --- a/Applications/DataExplorer/DataView/StratView/StratView.h +++ b/Applications/DataExplorer/DataView/StratView/StratView.h @@ -35,7 +35,7 @@ public: * Creates an empty view. */ StratView(QWidget* parent = nullptr) : _scene(nullptr) { Q_UNUSED(parent); } - ~StratView(); + ~StratView() override; /// Sets the Borehole whose data should be visualised. void setStation(GeoLib::StationBorehole* station, @@ -51,17 +51,23 @@ public: protected: /// Resizes the scene. - void resizeEvent(QResizeEvent* event); + void resizeEvent(QResizeEvent* event) override; private: /// Initialises the view. void initialize(); /// The minimum size of the window. - QSize minimumSizeHint() const { return QSize(3 * _scene->MARGIN,2 * _scene->MARGIN); } + QSize minimumSizeHint() const override + { + return QSize(3 * _scene->MARGIN, 2 * _scene->MARGIN); + } /// The default size of the window. - QSize sizeHint() const { return QSize(6 * _scene->MARGIN, 4 * _scene->MARGIN); } + QSize sizeHint() const override + { + return QSize(6 * _scene->MARGIN, 4 * _scene->MARGIN); + } /// Updates the view automatically when a Borehole is added or when the window containing the view changes its state. void update(); diff --git a/Applications/DataExplorer/DataView/StratView/StratWindow.h b/Applications/DataExplorer/DataView/StratView/StratWindow.h index 40bf8cdf72a..741e382a197 100644 --- a/Applications/DataExplorer/DataView/StratView/StratWindow.h +++ b/Applications/DataExplorer/DataView/StratView/StratWindow.h @@ -40,7 +40,7 @@ public: GeoLib::StationBorehole* station, std::map<std::string, DataHolderLib::Color>* stratColors = nullptr, QWidget* parent = nullptr); - ~StratWindow(void) { this->destroy(); } + ~StratWindow(void) override { this->destroy(); } private: /// Automatically resize window based on the measurements of the borehole. diff --git a/Applications/DataExplorer/DataView/SurfaceExtractionDialog.h b/Applications/DataExplorer/DataView/SurfaceExtractionDialog.h index 13e7742d90c..c395fe0dfbd 100644 --- a/Applications/DataExplorer/DataView/SurfaceExtractionDialog.h +++ b/Applications/DataExplorer/DataView/SurfaceExtractionDialog.h @@ -32,17 +32,17 @@ class SurfaceExtractionDialog : public QDialog, private Ui_SurfaceExtraction public: SurfaceExtractionDialog(QDialog* parent = nullptr); - ~SurfaceExtractionDialog() = default; + ~SurfaceExtractionDialog() override = default; int getTolerance() const { return _tolerance; } MathLib::Vector3 const& getNormal() const { return _dir; } private slots: /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject() { this->done(QDialog::Rejected); }; + void reject() override { this->done(QDialog::Rejected); }; private: int _tolerance; diff --git a/Applications/DataExplorer/VtkVis/MeshFromRasterDialog.h b/Applications/DataExplorer/VtkVis/MeshFromRasterDialog.h index 474b9649699..2933ef04c09 100644 --- a/Applications/DataExplorer/VtkVis/MeshFromRasterDialog.h +++ b/Applications/DataExplorer/VtkVis/MeshFromRasterDialog.h @@ -35,7 +35,7 @@ class MeshFromRasterDialog : public QDialog, private Ui_MeshFromRaster public: /// Constructor MeshFromRasterDialog(QDialog* parent = nullptr); - ~MeshFromRasterDialog(void); + ~MeshFromRasterDialog(void) override; std::string getMeshName() const { return _mesh_name; } std::string getArrayName() const { return _array_name; } @@ -44,10 +44,10 @@ public: private slots: /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); + void reject() override; private: std::string _mesh_name; diff --git a/Applications/DataExplorer/VtkVis/QVtkDataSetMapper.h b/Applications/DataExplorer/VtkVis/QVtkDataSetMapper.h index 99d2fc1ffb3..b1be9f97073 100644 --- a/Applications/DataExplorer/VtkVis/QVtkDataSetMapper.h +++ b/Applications/DataExplorer/VtkVis/QVtkDataSetMapper.h @@ -34,7 +34,7 @@ public: public slots: /// @brief Sets the scalar visibility on this mapper. virtual void SetScalarVisibility(bool on); - virtual void SetScalarVisibility(int on) override + void SetScalarVisibility(int on) override { SetScalarVisibility(static_cast<bool>(on)); } @@ -44,7 +44,7 @@ protected: QVtkDataSetMapper(); /// @brief Destructor. - virtual ~QVtkDataSetMapper(); + ~QVtkDataSetMapper() override; private: QVtkDataSetMapper(const QVtkDataSetMapper&); // Not implemented. diff --git a/Applications/DataExplorer/VtkVis/VisualizationWidget.h b/Applications/DataExplorer/VtkVis/VisualizationWidget.h index 68c9ae3e56e..4689cb336c5 100644 --- a/Applications/DataExplorer/VtkVis/VisualizationWidget.h +++ b/Applications/DataExplorer/VtkVis/VisualizationWidget.h @@ -35,7 +35,7 @@ public: VisualizationWidget(QWidget* parent = nullptr); /// @brief Destructor. - ~VisualizationWidget(); + ~VisualizationWidget() override; /// @brief Returns the VtkCustomInteractorStyle. VtkCustomInteractorStyle* interactorStyle() const; diff --git a/Applications/DataExplorer/VtkVis/VtkAlgorithmProperties.h b/Applications/DataExplorer/VtkVis/VtkAlgorithmProperties.h index 418682932ad..e78dafe30bc 100644 --- a/Applications/DataExplorer/VtkVis/VtkAlgorithmProperties.h +++ b/Applications/DataExplorer/VtkVis/VtkAlgorithmProperties.h @@ -142,7 +142,7 @@ public: /// Constructor (sets default values) VtkAlgorithmProperties(QObject* parent = nullptr); - virtual ~VtkAlgorithmProperties(); + ~VtkAlgorithmProperties() override; /// @brief Returns the vtk properties vtkProperty* GetProperties() const { return _property; } diff --git a/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyCheckbox.h b/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyCheckbox.h index 5d4026ca40a..1ea61b6c950 100644 --- a/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyCheckbox.h +++ b/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyCheckbox.h @@ -35,7 +35,7 @@ public: QWidget* parent = nullptr); /// @brief Destructor. - virtual ~VtkAlgorithmPropertyCheckbox(); + ~VtkAlgorithmPropertyCheckbox() override; private: const QString _name; diff --git a/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyLineEdit.h b/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyLineEdit.h index b628d77f3c1..d34ab370662 100644 --- a/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyLineEdit.h +++ b/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyLineEdit.h @@ -38,7 +38,7 @@ public: QVariant::Type type, VtkAlgorithmProperties* algProps, QWidget* parent = nullptr); - virtual ~VtkAlgorithmPropertyLineEdit(); + ~VtkAlgorithmPropertyLineEdit() override; private: const QString _name; diff --git a/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyVectorEdit.h b/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyVectorEdit.h index 9242c3ebfd6..04223b83f88 100644 --- a/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyVectorEdit.h +++ b/Applications/DataExplorer/VtkVis/VtkAlgorithmPropertyVectorEdit.h @@ -38,7 +38,7 @@ public: QVariant::Type type, VtkAlgorithmProperties* algProps, QWidget* parent = nullptr); - virtual ~VtkAlgorithmPropertyVectorEdit(); + ~VtkAlgorithmPropertyVectorEdit() override; private: const QString _name; diff --git a/Applications/DataExplorer/VtkVis/VtkAppendArrayFilter.h b/Applications/DataExplorer/VtkVis/VtkAppendArrayFilter.h index 46e04876f82..176b040572d 100644 --- a/Applications/DataExplorer/VtkVis/VtkAppendArrayFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkAppendArrayFilter.h @@ -46,7 +46,7 @@ public: protected: VtkAppendArrayFilter(); - ~VtkAppendArrayFilter(); + ~VtkAppendArrayFilter() override; /// @brief The filter logic. int RequestData(vtkInformation* request, diff --git a/Applications/DataExplorer/VtkVis/VtkBGImageSource.h b/Applications/DataExplorer/VtkVis/VtkBGImageSource.h index 897122f87ee..5c5b8d49b2f 100644 --- a/Applications/DataExplorer/VtkVis/VtkBGImageSource.h +++ b/Applications/DataExplorer/VtkVis/VtkBGImageSource.h @@ -36,11 +36,11 @@ public: /// Sets the raster/image to be used as a texture map void SetRaster(vtkImageAlgorithm *img, double x0, double y0, double scalingFactor); - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; protected: VtkBGImageSource(); - ~VtkBGImageSource(); + ~VtkBGImageSource() override; private: diff --git a/Applications/DataExplorer/VtkVis/VtkColorByHeightFilter.h b/Applications/DataExplorer/VtkVis/VtkColorByHeightFilter.h index e23e3beaec3..76e738a44cf 100644 --- a/Applications/DataExplorer/VtkVis/VtkColorByHeightFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkColorByHeightFilter.h @@ -49,7 +49,7 @@ public: vtkGetObjectMacro(ColorLookupTable,VtkColorLookupTable); /// @brief This filter gets updated when the color look-up table was modified. - virtual vtkMTimeType GetMTime() override; + vtkMTimeType GetMTime() override; /// @brief Sets user properties. void SetUserProperty(QString name, QVariant value) override @@ -67,7 +67,7 @@ public: protected: VtkColorByHeightFilter(); - ~VtkColorByHeightFilter(); + ~VtkColorByHeightFilter() override; /// @brief The filter logic. int RequestData(vtkInformation* request, diff --git a/Applications/DataExplorer/VtkVis/VtkColorLookupTable.h b/Applications/DataExplorer/VtkVis/VtkColorLookupTable.h index 7745fb88384..9fe7fc48ec0 100644 --- a/Applications/DataExplorer/VtkVis/VtkColorLookupTable.h +++ b/Applications/DataExplorer/VtkVis/VtkColorLookupTable.h @@ -82,7 +82,7 @@ protected: VtkColorLookupTable(); /// Destructor - ~VtkColorLookupTable(); + ~VtkColorLookupTable() override; private: /// Interpolates values linearly. diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeColorByHeightFilter.h b/Applications/DataExplorer/VtkVis/VtkCompositeColorByHeightFilter.h index fd190650dbd..05e8788b2ee 100644 --- a/Applications/DataExplorer/VtkVis/VtkCompositeColorByHeightFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkCompositeColorByHeightFilter.h @@ -23,11 +23,11 @@ class VtkCompositeColorByHeightFilter : public VtkCompositeFilter { public: VtkCompositeColorByHeightFilter(vtkAlgorithm* inputAlgorithm); - virtual ~VtkCompositeColorByHeightFilter() = default; + ~VtkCompositeColorByHeightFilter() override = default; - virtual void init() override; + void init() override; - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; protected: }; diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeColormapToImageFilter.h b/Applications/DataExplorer/VtkVis/VtkCompositeColormapToImageFilter.h index 2b139b2f651..c2b69f90a47 100644 --- a/Applications/DataExplorer/VtkVis/VtkCompositeColormapToImageFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkCompositeColormapToImageFilter.h @@ -21,14 +21,13 @@ class VtkCompositeColormapToImageFilter : public VtkCompositeFilter { public: VtkCompositeColormapToImageFilter(vtkAlgorithm* inputAlgorithm); - virtual ~VtkCompositeColormapToImageFilter(); + ~VtkCompositeColormapToImageFilter() override; - virtual void init() override; + void init() override; - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; - virtual void SetUserVectorProperty(QString name, - QList<QVariant> values) override; + void SetUserVectorProperty(QString name, QList<QVariant> values) override; private: }; diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeContourFilter.h b/Applications/DataExplorer/VtkVis/VtkCompositeContourFilter.h index ee979efe806..79747df7e6d 100644 --- a/Applications/DataExplorer/VtkVis/VtkCompositeContourFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkCompositeContourFilter.h @@ -23,11 +23,11 @@ class VtkCompositeContourFilter : public VtkCompositeFilter { public: VtkCompositeContourFilter(vtkAlgorithm* inputAlgorithm); - virtual ~VtkCompositeContourFilter(); + ~VtkCompositeContourFilter() override; - virtual void init() override; + void init() override; - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; void SetUserVectorProperty(QString name, QList<QVariant> values) override; diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeElementSelectionFilter.h b/Applications/DataExplorer/VtkVis/VtkCompositeElementSelectionFilter.h index 65c9dec140b..72085bcfc7c 100644 --- a/Applications/DataExplorer/VtkVis/VtkCompositeElementSelectionFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkCompositeElementSelectionFilter.h @@ -27,16 +27,16 @@ class VtkCompositeElementSelectionFilter : public VtkCompositeFilter { public: VtkCompositeElementSelectionFilter(vtkAlgorithm* inputAlgorithm); - virtual ~VtkCompositeElementSelectionFilter() = default; + ~VtkCompositeElementSelectionFilter() override = default; - virtual void init(); + void init() override; // Sets the range for the quality measure (default is [0,1] but this may vary for area- and volume-metrics). void setRange(double min_val, double max_val) { _range = std::make_pair(min_val, max_val); } void setSelectionArray(const std::string &selection_name, const std::vector<double> &selection = std::vector<double>()); - virtual void SetUserVectorProperty(QString name, QList<QVariant> values); + void SetUserVectorProperty(QString name, QList<QVariant> values) override; private: /// Returns a colour lookup table optimised for quality measures diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeFilter.h b/Applications/DataExplorer/VtkVis/VtkCompositeFilter.h index d475240b919..061977926d7 100644 --- a/Applications/DataExplorer/VtkVis/VtkCompositeFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkCompositeFilter.h @@ -46,7 +46,7 @@ public: VtkCompositeFilter(vtkAlgorithm* inputAlgorithm); /// @brief Destructor. - virtual ~VtkCompositeFilter(); + ~VtkCompositeFilter() override; /// @return the type of the data input. /// Can be compared with diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeGeoObjectFilter.h b/Applications/DataExplorer/VtkVis/VtkCompositeGeoObjectFilter.h index 10545a299b3..7187f293f2e 100644 --- a/Applications/DataExplorer/VtkVis/VtkCompositeGeoObjectFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkCompositeGeoObjectFilter.h @@ -24,9 +24,9 @@ class VtkCompositeGeoObjectFilter : public VtkCompositeFilter { public: VtkCompositeGeoObjectFilter(vtkAlgorithm* inputAlgorithm); - virtual ~VtkCompositeGeoObjectFilter(); + ~VtkCompositeGeoObjectFilter() override; - virtual void init() override; + void init() override; /// @brief Sets user properties. void SetUserProperty(QString name, QVariant value) override diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeImageToCylindersFilter.h b/Applications/DataExplorer/VtkVis/VtkCompositeImageToCylindersFilter.h index 19ba34e4bb7..d9377af952c 100644 --- a/Applications/DataExplorer/VtkVis/VtkCompositeImageToCylindersFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkCompositeImageToCylindersFilter.h @@ -25,11 +25,11 @@ class VtkCompositeImageToCylindersFilter : public VtkCompositeFilter { public: VtkCompositeImageToCylindersFilter(vtkAlgorithm* inputAlgorithm); - virtual ~VtkCompositeImageToCylindersFilter(); + ~VtkCompositeImageToCylindersFilter() override; - virtual void init() override; + void init() override; - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; void SetUserVectorProperty(QString name, QList<QVariant> values) override; diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeLineToTubeFilter.h b/Applications/DataExplorer/VtkVis/VtkCompositeLineToTubeFilter.h index 6d4dda3ab49..11ab5d1d69e 100644 --- a/Applications/DataExplorer/VtkVis/VtkCompositeLineToTubeFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkCompositeLineToTubeFilter.h @@ -21,11 +21,11 @@ class VtkCompositeLineToTubeFilter : public VtkCompositeFilter { public: VtkCompositeLineToTubeFilter(vtkAlgorithm* inputAlgorithm); - virtual ~VtkCompositeLineToTubeFilter(); + ~VtkCompositeLineToTubeFilter() override; - virtual void init() override; + void init() override; - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; private: diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeNodeSelectionFilter.h b/Applications/DataExplorer/VtkVis/VtkCompositeNodeSelectionFilter.h index d3dce1d7d43..7c87da97441 100644 --- a/Applications/DataExplorer/VtkVis/VtkCompositeNodeSelectionFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkCompositeNodeSelectionFilter.h @@ -24,9 +24,9 @@ class VtkCompositeNodeSelectionFilter : public VtkCompositeFilter { public: VtkCompositeNodeSelectionFilter(vtkAlgorithm* inputAlgorithm); - virtual ~VtkCompositeNodeSelectionFilter(); + ~VtkCompositeNodeSelectionFilter() override; - virtual void init(); + void init() override; /// Sets the point indeces to be highlighted void setSelectionArray(const std::vector<unsigned> &point_indeces); diff --git a/Applications/DataExplorer/VtkVis/VtkCompositePointToGlyphFilter.h b/Applications/DataExplorer/VtkVis/VtkCompositePointToGlyphFilter.h index 003f20d9798..f2c9eba1f26 100644 --- a/Applications/DataExplorer/VtkVis/VtkCompositePointToGlyphFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkCompositePointToGlyphFilter.h @@ -23,11 +23,11 @@ class VtkCompositePointToGlyphFilter : public VtkCompositeFilter { public: VtkCompositePointToGlyphFilter(vtkAlgorithm* inputAlgorithm); - virtual ~VtkCompositePointToGlyphFilter(); + ~VtkCompositePointToGlyphFilter() override; - virtual void init() override; + void init() override; - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; private: vtkSphereSource* _glyphSource; diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeTextureOnSurfaceFilter.h b/Applications/DataExplorer/VtkVis/VtkCompositeTextureOnSurfaceFilter.h index 779ff87fcce..63570b3b79b 100644 --- a/Applications/DataExplorer/VtkVis/VtkCompositeTextureOnSurfaceFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkCompositeTextureOnSurfaceFilter.h @@ -23,11 +23,11 @@ class VtkCompositeTextureOnSurfaceFilter : public VtkCompositeFilter { public: VtkCompositeTextureOnSurfaceFilter(vtkAlgorithm* inputAlgorithm); - virtual ~VtkCompositeTextureOnSurfaceFilter(); + ~VtkCompositeTextureOnSurfaceFilter() override; - virtual void init() override; + void init() override; - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; private: }; diff --git a/Applications/DataExplorer/VtkVis/VtkCompositeThresholdFilter.h b/Applications/DataExplorer/VtkVis/VtkCompositeThresholdFilter.h index aa7109ed3e7..0d4017bd2e1 100644 --- a/Applications/DataExplorer/VtkVis/VtkCompositeThresholdFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkCompositeThresholdFilter.h @@ -23,11 +23,11 @@ class VtkCompositeThresholdFilter : public VtkCompositeFilter { public: VtkCompositeThresholdFilter(vtkAlgorithm* inputAlgorithm); - virtual ~VtkCompositeThresholdFilter(); + ~VtkCompositeThresholdFilter() override; - virtual void init() override; + void init() override; - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; void SetUserVectorProperty(QString name, QList<QVariant> values) override; diff --git a/Applications/DataExplorer/VtkVis/VtkConsoleOutputWindow.h b/Applications/DataExplorer/VtkVis/VtkConsoleOutputWindow.h index 701987ef1a2..c7689a6669c 100644 --- a/Applications/DataExplorer/VtkVis/VtkConsoleOutputWindow.h +++ b/Applications/DataExplorer/VtkVis/VtkConsoleOutputWindow.h @@ -23,11 +23,11 @@ public: void PrintSelf(ostream& os, vtkIndent indent) override; static VtkConsoleOutputWindow * New(); - virtual void DisplayText(const char*) override; + void DisplayText(const char*) override; protected: VtkConsoleOutputWindow(); - virtual ~VtkConsoleOutputWindow(); + ~VtkConsoleOutputWindow() override; private: VtkConsoleOutputWindow(const VtkConsoleOutputWindow &); // Not implemented. diff --git a/Applications/DataExplorer/VtkVis/VtkCustomInteractorStyle.h b/Applications/DataExplorer/VtkVis/VtkCustomInteractorStyle.h index 5d401560856..44d087f98a6 100644 --- a/Applications/DataExplorer/VtkVis/VtkCustomInteractorStyle.h +++ b/Applications/DataExplorer/VtkVis/VtkCustomInteractorStyle.h @@ -41,19 +41,19 @@ public: vtkTypeMacro (VtkCustomInteractorStyle, vtkInteractorStyleTrackballCamera); /// @brief Handles key press events. - virtual void OnChar() override; + void OnChar() override; /// @brief Handles key down events. - virtual void OnKeyDown() override; + void OnKeyDown() override; /// @brief Handles key up events. - virtual void OnKeyUp() override; + void OnKeyUp() override; /// @brief Handles left mouse button events (picking). - virtual void OnLeftButtonDown() override; + void OnLeftButtonDown() override; /// @brief Handles middle mouse button events (rotation point picking). - virtual void OnRightButtonDown() override; + void OnRightButtonDown() override; public slots: void highlightActor(vtkProp3D* prop); @@ -68,7 +68,7 @@ public slots: protected: VtkCustomInteractorStyle(); - virtual ~VtkCustomInteractorStyle(); + ~VtkCustomInteractorStyle() override; /// @brief The vtk object to pick. vtkDataObject* _data; diff --git a/Applications/DataExplorer/VtkVis/VtkGeoImageSource.h b/Applications/DataExplorer/VtkVis/VtkGeoImageSource.h index 2b445096b25..dd0d06cbad0 100644 --- a/Applications/DataExplorer/VtkVis/VtkGeoImageSource.h +++ b/Applications/DataExplorer/VtkVis/VtkGeoImageSource.h @@ -56,18 +56,17 @@ public: /// @brief Returns the spacing between two pixels. double getSpacing() const; - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; protected: /// @brief Constructor. VtkGeoImageSource(); /// @brief Destructor. - virtual ~VtkGeoImageSource(); + ~VtkGeoImageSource() override; /// @brief Filter execution. - virtual void SimpleExecute(vtkImageData* input, - vtkImageData* output) override; + void SimpleExecute(vtkImageData* input, vtkImageData* output) override; private: VtkGeoImageSource(const VtkGeoImageSource&); // Not implemented. diff --git a/Applications/DataExplorer/VtkVis/VtkImageDataToLinePolyDataFilter.h b/Applications/DataExplorer/VtkVis/VtkImageDataToLinePolyDataFilter.h index 09467990091..d9a2da8887c 100644 --- a/Applications/DataExplorer/VtkVis/VtkImageDataToLinePolyDataFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkImageDataToLinePolyDataFilter.h @@ -39,7 +39,7 @@ public: ogsUserPropertyMacro(LengthScaleFactor,double); /// @brief Sets a user property. - virtual void SetUserProperty(QString name, QVariant value) override + void SetUserProperty(QString name, QVariant value) override { if (name.compare("LengthScaleFactor") == 0) SetLengthScaleFactor(value.toDouble()); @@ -53,15 +53,14 @@ protected: VtkImageDataToLinePolyDataFilter(); /// @brief Destructor. - virtual ~VtkImageDataToLinePolyDataFilter(); + ~VtkImageDataToLinePolyDataFilter() override; /// @brief Sets input port to vtkImageData. - virtual int FillInputPortInformation(int port, - vtkInformation* info) override; + int FillInputPortInformation(int port, vtkInformation* info) override; /// @brief Converts the image data to lines - virtual int RequestData(vtkInformation* request, vtkInformationVector** inputVector, - vtkInformationVector* outputVector) override; + int RequestData(vtkInformation* request, vtkInformationVector** inputVector, + vtkInformationVector* outputVector) override; /// @brief The spacing of the image double ImageSpacing; diff --git a/Applications/DataExplorer/VtkVis/VtkPickCallback.h b/Applications/DataExplorer/VtkVis/VtkPickCallback.h index baaaf9e8b9c..5038fa7cbae 100644 --- a/Applications/DataExplorer/VtkVis/VtkPickCallback.h +++ b/Applications/DataExplorer/VtkVis/VtkPickCallback.h @@ -32,7 +32,8 @@ class VtkPickCallback : public QObject, public vtkCommand public: static VtkPickCallback* New(); - void Execute(vtkObject* caller, unsigned long eventId, void* callData); + void Execute(vtkObject* caller, unsigned long eventId, + void* callData) override; protected: VtkPickCallback(); diff --git a/Applications/DataExplorer/VtkVis/VtkPointsSource.h b/Applications/DataExplorer/VtkVis/VtkPointsSource.h index 797d5684ffe..410924c5c32 100644 --- a/Applications/DataExplorer/VtkVis/VtkPointsSource.h +++ b/Applications/DataExplorer/VtkVis/VtkPointsSource.h @@ -39,11 +39,11 @@ public: /// Prints its data on a stream. void PrintSelf(ostream& os, vtkIndent indent) override; - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; protected: VtkPointsSource(); - ~VtkPointsSource() = default; + ~VtkPointsSource() override = default; /// Computes the polygonal data object. int RequestData(vtkInformation* request, diff --git a/Applications/DataExplorer/VtkVis/VtkPolylinesSource.h b/Applications/DataExplorer/VtkVis/VtkPolylinesSource.h index 689878e5e01..22a9508d92f 100644 --- a/Applications/DataExplorer/VtkVis/VtkPolylinesSource.h +++ b/Applications/DataExplorer/VtkVis/VtkPolylinesSource.h @@ -42,11 +42,11 @@ public: /// Prints its data on a stream. void PrintSelf(ostream& os, vtkIndent indent) override; - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; protected: VtkPolylinesSource(); - ~VtkPolylinesSource(); + ~VtkPolylinesSource() override; /// Computes the polygonal data object. int RequestData(vtkInformation* request, diff --git a/Applications/DataExplorer/VtkVis/VtkStationSource.h b/Applications/DataExplorer/VtkVis/VtkStationSource.h index b4d3acd2907..da95c5e5382 100644 --- a/Applications/DataExplorer/VtkVis/VtkStationSource.h +++ b/Applications/DataExplorer/VtkVis/VtkStationSource.h @@ -50,7 +50,7 @@ public: /// Prints its data on a stream. void PrintSelf(ostream& os, vtkIndent indent) override; - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; protected: VtkStationSource(); diff --git a/Applications/DataExplorer/VtkVis/VtkSurfacesSource.h b/Applications/DataExplorer/VtkVis/VtkSurfacesSource.h index c79fc621b26..d0c4ae6c83c 100644 --- a/Applications/DataExplorer/VtkVis/VtkSurfacesSource.h +++ b/Applications/DataExplorer/VtkVis/VtkSurfacesSource.h @@ -43,11 +43,11 @@ public: */ //ogsUserPropertyMacro(ColorBySurface,bool); - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; protected: VtkSurfacesSource(); - ~VtkSurfacesSource() = default; + ~VtkSurfacesSource() override = default; /// Computes the polygonal data object. int RequestData(vtkInformation* request, diff --git a/Applications/DataExplorer/VtkVis/VtkTextureOnSurfaceFilter.h b/Applications/DataExplorer/VtkVis/VtkTextureOnSurfaceFilter.h index 718e2e073cf..c3aff14a3df 100644 --- a/Applications/DataExplorer/VtkVis/VtkTextureOnSurfaceFilter.h +++ b/Applications/DataExplorer/VtkVis/VtkTextureOnSurfaceFilter.h @@ -48,11 +48,11 @@ public: /// Sets the raster/image to be used as a texture map void SetRaster(vtkImageAlgorithm* img, double x0, double y0, double scalingFactor); - virtual void SetUserProperty(QString name, QVariant value) override; + void SetUserProperty(QString name, QVariant value) override; protected: VtkTextureOnSurfaceFilter(); - ~VtkTextureOnSurfaceFilter(); + ~VtkTextureOnSurfaceFilter() override; /// Copies the input data and calculates texture coordinates (this requires that SetRaster() has /// been called before this method is executed. diff --git a/Applications/DataExplorer/VtkVis/VtkVisImageItem.h b/Applications/DataExplorer/VtkVis/VtkVisImageItem.h index e24a9098d94..984725de330 100644 --- a/Applications/DataExplorer/VtkVis/VtkVisImageItem.h +++ b/Applications/DataExplorer/VtkVis/VtkVisImageItem.h @@ -45,19 +45,20 @@ public: VtkVisImageItem(VtkCompositeFilter* compositeFilter, TreeItem* parentItem, const QList<QVariant> data = QList<QVariant>()); - ~VtkVisImageItem(); + ~VtkVisImageItem() override; /// @brief Initializes vtkMapper and vtkActor necessary for visualization of /// the item and sets the item's properties. - void Initialize(vtkRenderer* renderer); + void Initialize(vtkRenderer* renderer) override; - void setTranslation(double x, double y, double z) const; + void setTranslation(double x, double y, double z) const override; - vtkAlgorithm* transformFilter() const; + vtkAlgorithm* transformFilter() const override; protected: /// Selects the appropriate VTK-Writer object and writes the object to a file with the given name. - virtual int callVTKWriter(vtkAlgorithm* algorithm, const std::string &filename) const; + int callVTKWriter(vtkAlgorithm* algorithm, + const std::string& filename) const override; void setVtkProperties(VtkAlgorithmProperties* vtkProps); private: diff --git a/Applications/DataExplorer/VtkVis/VtkVisPipeline.h b/Applications/DataExplorer/VtkVis/VtkVisPipeline.h index fad5e1cfede..40846f9846d 100644 --- a/Applications/DataExplorer/VtkVis/VtkVisPipeline.h +++ b/Applications/DataExplorer/VtkVis/VtkVisPipeline.h @@ -60,7 +60,8 @@ public: VtkVisPipeline(vtkRenderer* renderer, QObject* parent = nullptr); /// \brief Emits vtkVisPipelineChanged() and calls base class method. - bool setData(const QModelIndex &index, const QVariant &value, int role = Qt::EditRole); + bool setData(const QModelIndex& index, const QVariant& value, + int role = Qt::EditRole) override; /// \brief Adds a light to the scene at the given coordinates. void addLight(const GeoLib::Point &pos); @@ -81,7 +82,7 @@ public: /// is the given one. QModelIndex getIndex(vtkProp3D* actor); - Qt::ItemFlags flags( const QModelIndex &index ) const; + Qt::ItemFlags flags(const QModelIndex& index) const override; /// \brief Loads a vtk object from the given file and adds it to the pipeline. void loadFromFile(QString filename); diff --git a/Applications/DataExplorer/VtkVis/VtkVisPipelineItem.h b/Applications/DataExplorer/VtkVis/VtkVisPipelineItem.h index e0393d886a0..489bb4d091c 100644 --- a/Applications/DataExplorer/VtkVis/VtkVisPipelineItem.h +++ b/Applications/DataExplorer/VtkVis/VtkVisPipelineItem.h @@ -56,7 +56,7 @@ public: VtkVisPipelineItem(VtkCompositeFilter* compositeFilter, TreeItem* parentItem, const QList<QVariant> data = QList<QVariant>()); - ~VtkVisPipelineItem(); + ~VtkVisPipelineItem() override; /// @brief Returns a VtkVisPipelineItem. VtkVisPipelineItem* child(int row) const; @@ -65,8 +65,8 @@ public: /// the item and sets the item's properties. virtual void Initialize(vtkRenderer* renderer) = 0; - QVariant data(int column) const; - bool setData(int column, const QVariant &value); + QVariant data(int column) const override; + bool setData(int column, const QVariant& value) override; /// @brief Returns the algorithm object vtkAlgorithm* algorithm() const { return _algorithm; } diff --git a/Applications/DataExplorer/VtkVis/VtkVisPipelineView.h b/Applications/DataExplorer/VtkVis/VtkVisPipelineView.h index 6f8c9e15800..64f8ecbef4b 100644 --- a/Applications/DataExplorer/VtkVis/VtkVisPipelineView.h +++ b/Applications/DataExplorer/VtkVis/VtkVisPipelineView.h @@ -43,17 +43,18 @@ public: VtkVisPipelineView(QWidget* parent = nullptr); /// @brief Overridden to set model specific header properties. - virtual void setModel(QAbstractItemModel* model); + void setModel(QAbstractItemModel* model) override; protected slots: /// Emits itemSelected() signals when an items was selected. - void selectionChanged(const QItemSelection &selected, const QItemSelection &deselected); + void selectionChanged(const QItemSelection& selected, + const QItemSelection& deselected) override; void selectItem(vtkProp3D* actor); void selectItem(const QModelIndex &index); private: /// Creates a menu on right-clicking on an item. - void contextMenuEvent(QContextMenuEvent* event); + void contextMenuEvent(QContextMenuEvent* event) override; private slots: /// Adds a color lookup table to the current scalar array of the selected pipeline item. diff --git a/Applications/DataExplorer/VtkVis/VtkVisPointSetItem.h b/Applications/DataExplorer/VtkVis/VtkVisPointSetItem.h index 3c5e37d15ea..d487f76dc3b 100644 --- a/Applications/DataExplorer/VtkVis/VtkVisPointSetItem.h +++ b/Applications/DataExplorer/VtkVis/VtkVisPointSetItem.h @@ -49,31 +49,31 @@ public: VtkVisPointSetItem(VtkCompositeFilter* compositeFilter, TreeItem* parentItem, const QList<QVariant> data = QList<QVariant>()); - ~VtkVisPointSetItem(); + ~VtkVisPointSetItem() override; /// @brief Gets the last selected attribute. - const QString GetActiveAttribute() const; + const QString GetActiveAttribute() const override; /// @brief Get the scalar range for the active attribute void GetRangeForActiveAttribute(double range[2]) const; /// @brief Initializes vtkMapper and vtkActor necessary for visualization of /// the item and sets the item's properties. - void Initialize(vtkRenderer* renderer); + void Initialize(vtkRenderer* renderer) override; - vtkAlgorithm* transformFilter() const; + vtkAlgorithm* transformFilter() const override; /// @brief Sets the selected attribute array for the visualisation of the data set. - void SetActiveAttribute(const QString& name); + void SetActiveAttribute(const QString& name) override; /// @brief Scales the data in visualisation-space. - void setScale(double x, double y, double z) const; + void setScale(double x, double y, double z) const override; /// @brief Translates the item in visualisation-space. - void setTranslation(double x, double y, double z) const; + void setTranslation(double x, double y, double z) const override; /// @brief Enables / disables backface culling. - void setBackfaceCulling(bool enable) const; + void setBackfaceCulling(bool enable) const override; protected: QVtkDataSetMapper* _mapper; @@ -82,7 +82,8 @@ protected: std::string _activeArrayName; /// Selects the appropriate VTK-Writer object and writes the object to a file with the given name. - virtual int callVTKWriter(vtkAlgorithm* algorithm, const std::string &filename) const; + int callVTKWriter(vtkAlgorithm* algorithm, + const std::string& filename) const override; void SetScalarVisibility(bool on); diff --git a/Applications/DataExplorer/mainwindow.h b/Applications/DataExplorer/mainwindow.h index 8a72d833ffd..f1ce0b3d151 100644 --- a/Applications/DataExplorer/mainwindow.h +++ b/Applications/DataExplorer/mainwindow.h @@ -52,7 +52,7 @@ public: void loadFileOnStartUp(const QString &fileName); protected: - void closeEvent( QCloseEvent* event ); + void closeEvent(QCloseEvent* event) override; protected slots: void showGeoDockWidget( bool show ); diff --git a/Applications/FileIO/CsvInterface.h b/Applications/FileIO/CsvInterface.h index fe87228764e..2103e73306c 100644 --- a/Applications/FileIO/CsvInterface.h +++ b/Applications/FileIO/CsvInterface.h @@ -80,7 +80,7 @@ public: } /// Writes the CSV file. - bool write(); + bool write() override; /** * Reads 3D points from a CSV file. It is assumed that the file has a header diff --git a/Applications/FileIO/Gmsh/GMSHAdaptiveMeshDensity.h b/Applications/FileIO/Gmsh/GMSHAdaptiveMeshDensity.h index 3b3680eff77..93de9473ba9 100644 --- a/Applications/FileIO/Gmsh/GMSHAdaptiveMeshDensity.h +++ b/Applications/FileIO/Gmsh/GMSHAdaptiveMeshDensity.h @@ -33,11 +33,11 @@ public: GMSHAdaptiveMeshDensity(double pnt_density, double station_density, std::size_t max_pnts_per_leaf); - virtual ~GMSHAdaptiveMeshDensity(); - void initialize(std::vector<GeoLib::Point const*> const& pnts); - double getMeshDensityAtPoint(GeoLib::Point const* const pnt) const; + ~GMSHAdaptiveMeshDensity() override; + void initialize(std::vector<GeoLib::Point const*> const& pnts) override; + double getMeshDensityAtPoint(GeoLib::Point const* const pnt) const override; void addPoints(std::vector<GeoLib::Point const*> const& pnts); - double getMeshDensityAtStation(GeoLib::Point const* const) const; + double getMeshDensityAtStation(GeoLib::Point const* const) const override; void getSteinerPoints (std::vector<GeoLib::Point*> & pnts, std::size_t additional_levels = 0) const; #ifndef NDEBUG diff --git a/Applications/FileIO/Gmsh/GMSHFixedMeshDensity.h b/Applications/FileIO/Gmsh/GMSHFixedMeshDensity.h index 7eb5bd887d8..a9b927c942c 100644 --- a/Applications/FileIO/Gmsh/GMSHFixedMeshDensity.h +++ b/Applications/FileIO/Gmsh/GMSHFixedMeshDensity.h @@ -21,10 +21,10 @@ class GMSHFixedMeshDensity : public GMSHMeshDensityStrategy { public: GMSHFixedMeshDensity(double mesh_density); - void initialize(std::vector<GeoLib::Point const*> const& vec); - double getMeshDensityAtPoint(GeoLib::Point const*const) const; - double getMeshDensityAtStation(GeoLib::Point const*const) const; - virtual ~GMSHFixedMeshDensity() = default; + void initialize(std::vector<GeoLib::Point const*> const& vec) override; + double getMeshDensityAtPoint(GeoLib::Point const* const) const override; + double getMeshDensityAtStation(GeoLib::Point const* const) const override; + ~GMSHFixedMeshDensity() override = default; private: double _mesh_density; diff --git a/Applications/FileIO/Gmsh/GMSHInterface.h b/Applications/FileIO/Gmsh/GMSHInterface.h index ef6a7dc5c59..ae356a1a87d 100644 --- a/Applications/FileIO/Gmsh/GMSHInterface.h +++ b/Applications/FileIO/Gmsh/GMSHInterface.h @@ -75,10 +75,10 @@ public: GMSHInterface& operator=(GMSHInterface const&) = delete; GMSHInterface& operator=(GMSHInterface &&) = delete; - ~GMSHInterface(); + ~GMSHInterface() override; protected: - bool write(); + bool write() override; private: /** diff --git a/Applications/FileIO/Gmsh/GMSHPoint.h b/Applications/FileIO/Gmsh/GMSHPoint.h index f1a4f11c1d9..5de076664f9 100644 --- a/Applications/FileIO/Gmsh/GMSHPoint.h +++ b/Applications/FileIO/Gmsh/GMSHPoint.h @@ -21,7 +21,8 @@ class GMSHPoint final : public GeoLib::Point { public: GMSHPoint(GeoLib::Point const& pnt, std::size_t id, double mesh_density); - void write(std::ostream &os) const; + void write(std::ostream& os) const override; + private: double _mesh_density; }; diff --git a/Applications/FileIO/Gmsh/GMSHPolygonTree.h b/Applications/FileIO/Gmsh/GMSHPolygonTree.h index 0ed605482b7..dac4afa61ab 100644 --- a/Applications/FileIO/Gmsh/GMSHPolygonTree.h +++ b/Applications/FileIO/Gmsh/GMSHPolygonTree.h @@ -37,7 +37,7 @@ public: GMSHPolygonTree(GeoLib::PolygonWithSegmentMarker* polygon, GMSHPolygonTree * parent, GeoLib::GEOObjects &geo_objs, std::string const& geo_name, GMSHMeshDensityStrategy * mesh_density_strategy); - virtual ~GMSHPolygonTree(); + ~GMSHPolygonTree() override; /** Mark the segments shared by several polygons. */ void markSharedSegments(); diff --git a/Applications/FileIO/XmlIO/Qt/XmlGspInterface.h b/Applications/FileIO/XmlIO/Qt/XmlGspInterface.h index 6cd73a1d0d7..d7283805ece 100644 --- a/Applications/FileIO/XmlIO/Qt/XmlGspInterface.h +++ b/Applications/FileIO/XmlIO/Qt/XmlGspInterface.h @@ -36,18 +36,21 @@ class XmlGspInterface : public BaseLib::IO::XMLInterface, public: XmlGspInterface(DataHolderLib::Project &project); - virtual ~XmlGspInterface() = default; + ~XmlGspInterface() override = default; /// Reads an xml-file containing a GeoSys project. /// Project files currently cover only geo-, msh- and station-data. This will be expanded in the future. - int readFile(const QString &fileName); + int readFile(const QString& fileName) override; - bool readFile(std::string const& fname) { return readFile(QString(fname.c_str())) != 0; } + bool readFile(std::string const& fname) override + { + return readFile(QString(fname.c_str())) != 0; + } int writeToFile(const std::string& filename); protected: - bool write(); + bool write() override; private: std::string _filename; diff --git a/Applications/FileIO/XmlIO/Qt/XmlNumInterface.h b/Applications/FileIO/XmlIO/Qt/XmlNumInterface.h index 054717882d6..18e260f4968 100644 --- a/Applications/FileIO/XmlIO/Qt/XmlNumInterface.h +++ b/Applications/FileIO/XmlIO/Qt/XmlNumInterface.h @@ -25,18 +25,20 @@ class XmlNumInterface : public BaseLib::IO::XMLInterface, public BaseLib::IO::XM public: XmlNumInterface(); - virtual ~XmlNumInterface() = default; + ~XmlNumInterface() override = default; - int readFile(QString const& fileName); + int readFile(QString const& fileName) override; - bool readFile(std::string const& fname) { return readFile(QString(fname.c_str())) != 0; } + bool readFile(std::string const& fname) override + { + return readFile(QString(fname.c_str())) != 0; + } protected: void readLinearSolverConfiguration(QDomElement const& lin_root); void readIterationScheme(QDomElement const& iteration_root); void readConvergenceCriteria(QDomElement const& convergence_root); - bool write(); - + bool write() override; }; } diff --git a/Applications/Utils/OGSFileConverter/FileListDialog.h b/Applications/Utils/OGSFileConverter/FileListDialog.h index cfe7b079250..81783da7a5b 100644 --- a/Applications/Utils/OGSFileConverter/FileListDialog.h +++ b/Applications/Utils/OGSFileConverter/FileListDialog.h @@ -37,7 +37,7 @@ public: /// Constructor FileListDialog(FileType input, FileType output, QWidget* parent = nullptr); /// Destructor - ~FileListDialog(void); + ~FileListDialog(void) override; /// Returns list of all selected files const QStringList getInputFileList() const { return _allFiles.stringList(); }; @@ -61,9 +61,8 @@ private slots: void on_browseButton_pressed(); /// Instructions if the OK-Button has been pressed. - void accept(); + void accept() override; /// Instructions if the Cancel-Button has been pressed. - void reject(); - + void reject() override; }; diff --git a/Applications/Utils/OGSFileConverter/OGSFileConverter.h b/Applications/Utils/OGSFileConverter/OGSFileConverter.h index 99f6ed02271..af516b82d93 100644 --- a/Applications/Utils/OGSFileConverter/OGSFileConverter.h +++ b/Applications/Utils/OGSFileConverter/OGSFileConverter.h @@ -28,7 +28,7 @@ public: /// Constructor OGSFileConverter(QWidget* parent = nullptr); /// Destructor - ~OGSFileConverter(void); + ~OGSFileConverter(void) override; private: /// Checks if a given file already exists diff --git a/BaseLib/IO/XmlIO/XMLInterface.h b/BaseLib/IO/XmlIO/XMLInterface.h index 065b1655cd5..ba6ccc07f08 100644 --- a/BaseLib/IO/XmlIO/XMLInterface.h +++ b/BaseLib/IO/XmlIO/XMLInterface.h @@ -29,7 +29,7 @@ class XMLInterface : public BaseLib::IO::Writer { public: XMLInterface(); - virtual ~XMLInterface() = default; + ~XMLInterface() override = default; void setNameForExport(std::string const& name) { _exportName = name; } virtual bool readFile(std::string const& fname) = 0; diff --git a/BaseLib/LogogSimpleFormatter.h b/BaseLib/LogogSimpleFormatter.h index eeaab28468e..98051eb2d0f 100644 --- a/BaseLib/LogogSimpleFormatter.h +++ b/BaseLib/LogogSimpleFormatter.h @@ -25,7 +25,7 @@ namespace BaseLib **/ class LogogSimpleFormatter : public logog::FormatterMSVC { - virtual TOPIC_FLAGS GetTopicFlags(const logog::Topic& topic) + TOPIC_FLAGS GetTopicFlags(const logog::Topic& topic) override { return (logog::Formatter::GetTopicFlags(topic) & ~(TOPIC_FILE_NAME_FLAG | TOPIC_LINE_NUMBER_FLAG)); diff --git a/BaseLib/Subdivision.h b/BaseLib/Subdivision.h index 7955e7ac1f4..625c1efe768 100644 --- a/BaseLib/Subdivision.h +++ b/BaseLib/Subdivision.h @@ -41,7 +41,7 @@ public: : _length(length), _n_subdivision(n_subdivision) {} /// Returns a vector of subdivided points - std::vector<double> operator()() const + std::vector<double> operator()() const override { std::vector<double> x; x.reserve(_n_subdivision+1); @@ -77,7 +77,7 @@ public: : _length(L), _dL0(dL0), _max_dL(max_dL), _multiplier(multiplier) {} /// Returns a vector of subdivided points - std::vector<double> operator()() const + std::vector<double> operator()() const override { std::vector<double> vec_x; diff --git a/BaseLib/TemplateLogogFormatterSuppressedGCC.h b/BaseLib/TemplateLogogFormatterSuppressedGCC.h index 52730d867da..09366315162 100644 --- a/BaseLib/TemplateLogogFormatterSuppressedGCC.h +++ b/BaseLib/TemplateLogogFormatterSuppressedGCC.h @@ -38,13 +38,14 @@ public: TemplateLogogFormatterSuppressedGCC(MPI_Comm mpi_comm = MPI_COMM_WORLD); #endif - virtual TOPIC_FLAGS GetTopicFlags( const logog::Topic &topic ) + TOPIC_FLAGS GetTopicFlags(const logog::Topic& topic) override { return ( logog::Formatter::GetTopicFlags( topic ) & ~( T_SUPPPRESS_TOPIC_FLAG )); } - virtual LOGOG_STRING &Format( const logog::Topic &topic, const logog::Target &target ); + LOGOG_STRING& Format(const logog::Topic& topic, + const logog::Target& target) override; private: #ifdef USE_MPI diff --git a/GeoLib/IO/XmlIO/Boost/BoostXmlGmlInterface.h b/GeoLib/IO/XmlIO/Boost/BoostXmlGmlInterface.h index d94093d6827..f2fdf6a6825 100644 --- a/GeoLib/IO/XmlIO/Boost/BoostXmlGmlInterface.h +++ b/GeoLib/IO/XmlIO/Boost/BoostXmlGmlInterface.h @@ -36,14 +36,14 @@ class BoostXmlGmlInterface : public BaseLib::IO::XMLInterface { public: BoostXmlGmlInterface(GeoLib::GEOObjects& geo_objs); - virtual ~BoostXmlGmlInterface() = default; + ~BoostXmlGmlInterface() override = default; /// Reads an xml-file containing OGS geometry - bool readFile(const std::string &fname); + bool readFile(const std::string& fname) override; protected: /// Required method for writing geometry. This is not implemented here, use the Qt class for writing. - bool write(); + bool write() override; private: /// Reads GeoLib::Point-objects from an xml-file diff --git a/GeoLib/IO/XmlIO/Qt/XmlGmlInterface.h b/GeoLib/IO/XmlIO/Qt/XmlGmlInterface.h index 0f4d52bc3ea..18aa35dab14 100644 --- a/GeoLib/IO/XmlIO/Qt/XmlGmlInterface.h +++ b/GeoLib/IO/XmlIO/Qt/XmlGmlInterface.h @@ -35,15 +35,18 @@ class XmlGmlInterface : public BaseLib::IO::XMLInterface, public: XmlGmlInterface(GeoLib::GEOObjects& geo_objs); - virtual ~XmlGmlInterface() = default; + ~XmlGmlInterface() override = default; /// Reads an xml-file containing geometric object definitions into the GEOObjects used in the contructor - int readFile(const QString &fileName); + int readFile(const QString& fileName) override; - bool readFile(std::string const& fname) { return readFile(QString(fname.c_str())) != 0; } + bool readFile(std::string const& fname) override + { + return readFile(QString(fname.c_str())) != 0; + } protected: - bool write(); + bool write() override; private: /// Reads GeoLib::Point-objects from an xml-file diff --git a/GeoLib/IO/XmlIO/Qt/XmlStnInterface.h b/GeoLib/IO/XmlIO/Qt/XmlStnInterface.h index c9e0bff0d8d..5266a1301c8 100644 --- a/GeoLib/IO/XmlIO/Qt/XmlStnInterface.h +++ b/GeoLib/IO/XmlIO/Qt/XmlStnInterface.h @@ -39,15 +39,18 @@ public: XmlStnInterface(GeoLib::GEOObjects& geo_objs); /// Reads an xml-file containing station object definitions into the GEOObjects used in the contructor (requires Qt) - int readFile(const QString &fileName); + int readFile(const QString& fileName) override; - bool readFile(std::string const& fname) { return readFile(QString(fname.c_str())) != 0; } + bool readFile(std::string const& fname) override + { + return readFile(QString(fname.c_str())) != 0; + } /// Reads an xml-file using the RapidXML parser integrated in the source code (i.e. this function is usable without Qt) int rapidReadFile(const std::string &fileName); protected: - bool write(); + bool write() override; private: /// Reads GeoLib::Station- or StationBorehole-objects from an xml-file diff --git a/GeoLib/Point.h b/GeoLib/Point.h index 3d61d4ee2b1..c0a8fd6a3e3 100644 --- a/GeoLib/Point.h +++ b/GeoLib/Point.h @@ -52,7 +52,7 @@ public: {} /// return a geometry type - virtual GEOTYPE getGeoType() const {return GEOTYPE::POINT;} + GEOTYPE getGeoType() const override { return GEOTYPE::POINT; } protected: friend PointVec; diff --git a/GeoLib/Polygon.h b/GeoLib/Polygon.h index 08a7267f4b8..ed6593176dc 100644 --- a/GeoLib/Polygon.h +++ b/GeoLib/Polygon.h @@ -54,7 +54,7 @@ public: Polygon(Polygon const& other); Polygon& operator=(Polygon const& rhs) = delete; - virtual ~Polygon(); + ~Polygon() override; bool initialise (); diff --git a/GeoLib/PolygonWithSegmentMarker.h b/GeoLib/PolygonWithSegmentMarker.h index 6d91c215ad8..b42a46c2e26 100644 --- a/GeoLib/PolygonWithSegmentMarker.h +++ b/GeoLib/PolygonWithSegmentMarker.h @@ -38,14 +38,14 @@ public: * corresponding line segment. * @see Polyline::addPoint() */ - virtual bool addPoint(std::size_t pnt_id) override; + bool addPoint(std::size_t pnt_id) override; /** * Method calls the @see Polyline::insertPoint() and initializes the inserted line * segment with the same value the previous line segment had. * @see Polyline::insertPoint() */ - virtual bool insertPoint(std::size_t pos, std::size_t pnt_id) override; + bool insertPoint(std::size_t pos, std::size_t pnt_id) override; private: std::vector<bool> _marker; diff --git a/GeoLib/Polyline.h b/GeoLib/Polyline.h index b754b38f9fd..e71ce75a629 100644 --- a/GeoLib/Polyline.h +++ b/GeoLib/Polyline.h @@ -101,11 +101,10 @@ public: Polyline(const Polyline& ply); Polyline& operator=(Polyline const& other) = delete; - virtual ~Polyline() = default; + ~Polyline() override = default; /// return a geometry type - virtual GEOTYPE getGeoType() const {return GEOTYPE::POLYLINE;} - + GEOTYPE getGeoType() const override { return GEOTYPE::POLYLINE; } /** write the points to the stream */ void write(std::ostream &os) const; diff --git a/GeoLib/PolylineWithSegmentMarker.h b/GeoLib/PolylineWithSegmentMarker.h index a7f72b4da0d..a751a48c911 100644 --- a/GeoLib/PolylineWithSegmentMarker.h +++ b/GeoLib/PolylineWithSegmentMarker.h @@ -44,14 +44,14 @@ public: * corresponding line segment. * @see Polyline::addPoint() */ - virtual bool addPoint(std::size_t pnt_id) override; + bool addPoint(std::size_t pnt_id) override; /** * Method calls the @see Polyline::insertPoint() and initializes the inserted line segment with the same * value the previous line segment had. * @see Polyline::insertPoint() */ - virtual bool insertPoint(std::size_t pos, std::size_t pnt_id) override; + bool insertPoint(std::size_t pos, std::size_t pnt_id) override; private: std::vector<bool> _marker; diff --git a/GeoLib/Station.h b/GeoLib/Station.h index aa131162090..05cf9e70bd4 100644 --- a/GeoLib/Station.h +++ b/GeoLib/Station.h @@ -65,7 +65,7 @@ public: */ Station(Station const& src); - virtual ~Station(); + ~Station() override; /// Returns the name of the station. std::string const& getName() const { return _name; } diff --git a/GeoLib/StationBorehole.h b/GeoLib/StationBorehole.h index 725d62c80f6..fbb2ea47140 100644 --- a/GeoLib/StationBorehole.h +++ b/GeoLib/StationBorehole.h @@ -33,7 +33,7 @@ class StationBorehole : public Station public: /** constructor initialises the borehole with the given coordinates */ StationBorehole(double x = 0.0, double y = 0.0, double z = 0.0, const std::string &name = ""); - ~StationBorehole(void); + ~StationBorehole(void) override; /// Creates a StationBorehole-object from a string (assuming the string has the right format) static StationBorehole* createStation(const std::string &line); diff --git a/GeoLib/Surface.h b/GeoLib/Surface.h index 0dccba5e65b..54f3a455cde 100644 --- a/GeoLib/Surface.h +++ b/GeoLib/Surface.h @@ -36,7 +36,7 @@ class Surface final : public GeoObject public: explicit Surface(const std::vector<Point*>& pnt_vec); Surface(Surface const& src); - ~Surface(); + ~Surface() override; Surface(Surface && src) = delete; Surface& operator=(Surface const& src) = delete; diff --git a/MaterialLib/Adsorption/Adsorption.h b/MaterialLib/Adsorption/Adsorption.h index 685d6bbfc41..2ab89082a44 100644 --- a/MaterialLib/Adsorption/Adsorption.h +++ b/MaterialLib/Adsorption/Adsorption.h @@ -34,9 +34,11 @@ public: double getEquilibriumLoading(const double p_Ads, const double T_Ads, const double M_Ads) const override; - virtual double getEnthalpy(const double p_Ads, const double T_Ads, const double M_Ads) const override; - virtual double getReactionRate(const double p_Ads, const double T_Ads, - const double M_Ads, const double loading) const override; + double getEnthalpy(const double p_Ads, const double T_Ads, + const double M_Ads) const override; + double getReactionRate(const double p_Ads, const double T_Ads, + const double M_Ads, + const double loading) const override; /** * @brief get_d_reaction_rate * @param p_Ads diff --git a/MaterialLib/Adsorption/Density100MPa.h b/MaterialLib/Adsorption/Density100MPa.h index ecd5d099abf..6921c89c300 100644 --- a/MaterialLib/Adsorption/Density100MPa.h +++ b/MaterialLib/Adsorption/Density100MPa.h @@ -17,10 +17,10 @@ namespace Adsorption class Density100MPa : public AdsorptionReaction { public: - double getAdsorbateDensity(const double T_Ads) const; - double getAlphaT(const double T_Ads) const; - double characteristicCurve(const double A) const; - double dCharacteristicCurve(const double A) const; + double getAdsorbateDensity(const double T_Ads) const override; + double getAlphaT(const double T_Ads) const override; + double characteristicCurve(const double A) const override; + double dCharacteristicCurve(const double A) const override; }; } diff --git a/MaterialLib/Adsorption/DensityConst.h b/MaterialLib/Adsorption/DensityConst.h index 97a20104426..1bc60c77b8d 100644 --- a/MaterialLib/Adsorption/DensityConst.h +++ b/MaterialLib/Adsorption/DensityConst.h @@ -17,10 +17,10 @@ namespace Adsorption class DensityConst : public AdsorptionReaction { public: - double getAdsorbateDensity(const double T_Ads) const; - double getAlphaT(const double T_Ads) const; - double characteristicCurve(const double A) const; - double dCharacteristicCurve(const double A) const; + double getAdsorbateDensity(const double T_Ads) const override; + double getAlphaT(const double T_Ads) const override; + double characteristicCurve(const double A) const override; + double dCharacteristicCurve(const double A) const override; }; } diff --git a/MaterialLib/Adsorption/DensityCook.h b/MaterialLib/Adsorption/DensityCook.h index 35722161f6c..b9215f8dc1c 100644 --- a/MaterialLib/Adsorption/DensityCook.h +++ b/MaterialLib/Adsorption/DensityCook.h @@ -17,10 +17,10 @@ namespace Adsorption class DensityCook : public AdsorptionReaction { public: - double getAdsorbateDensity(const double T_Ads) const; - double getAlphaT(const double T_Ads) const; - double characteristicCurve(const double A) const; - double dCharacteristicCurve(const double A) const; + double getAdsorbateDensity(const double T_Ads) const override; + double getAlphaT(const double T_Ads) const override; + double characteristicCurve(const double A) const override; + double dCharacteristicCurve(const double A) const override; }; inline double rhoWaterDean(const double T_Ads) diff --git a/MaterialLib/Adsorption/DensityDubinin.h b/MaterialLib/Adsorption/DensityDubinin.h index a66bb696bb8..5cbb239d561 100644 --- a/MaterialLib/Adsorption/DensityDubinin.h +++ b/MaterialLib/Adsorption/DensityDubinin.h @@ -17,10 +17,10 @@ namespace Adsorption class DensityDubinin : public AdsorptionReaction { public: - double getAdsorbateDensity(const double T_Ads) const; - double getAlphaT(const double T_Ads) const; - double characteristicCurve(const double A) const; - double dCharacteristicCurve(const double A) const; + double getAdsorbateDensity(const double T_Ads) const override; + double getAlphaT(const double T_Ads) const override; + double characteristicCurve(const double A) const override; + double dCharacteristicCurve(const double A) const override; }; } diff --git a/MaterialLib/Adsorption/DensityHauer.h b/MaterialLib/Adsorption/DensityHauer.h index 1bf9d1995c5..5b47e5cec28 100644 --- a/MaterialLib/Adsorption/DensityHauer.h +++ b/MaterialLib/Adsorption/DensityHauer.h @@ -18,10 +18,10 @@ namespace Adsorption class DensityHauer : public AdsorptionReaction { public: - double getAdsorbateDensity(const double T_Ads) const; - double getAlphaT(const double T_Ads) const; - double characteristicCurve(const double A) const; - double dCharacteristicCurve(const double A) const; + double getAdsorbateDensity(const double T_Ads) const override; + double getAlphaT(const double T_Ads) const override; + double characteristicCurve(const double A) const override; + double dCharacteristicCurve(const double A) const override; }; inline double rhoWaterHauer(const double T_Ads) diff --git a/MaterialLib/Adsorption/DensityLegacy.h b/MaterialLib/Adsorption/DensityLegacy.h index b75632a8393..a818e73f206 100644 --- a/MaterialLib/Adsorption/DensityLegacy.h +++ b/MaterialLib/Adsorption/DensityLegacy.h @@ -17,10 +17,10 @@ namespace Adsorption class DensityLegacy : public AdsorptionReaction { public: - double getAdsorbateDensity(const double T_Ads) const; - double getAlphaT(const double T_Ads) const; - double characteristicCurve(const double A) const; - double dCharacteristicCurve(const double A) const; + double getAdsorbateDensity(const double T_Ads) const override; + double getAlphaT(const double T_Ads) const override; + double characteristicCurve(const double A) const override; + double dCharacteristicCurve(const double A) const override; }; } diff --git a/MaterialLib/Adsorption/DensityMette.h b/MaterialLib/Adsorption/DensityMette.h index 0ec144f1f57..27e4a702d21 100644 --- a/MaterialLib/Adsorption/DensityMette.h +++ b/MaterialLib/Adsorption/DensityMette.h @@ -17,10 +17,10 @@ namespace Adsorption class DensityMette : public AdsorptionReaction { public: - double getAdsorbateDensity(const double T_Ads) const; - double getAlphaT(const double T_Ads) const; - double characteristicCurve(const double A) const; - double dCharacteristicCurve(const double A) const; + double getAdsorbateDensity(const double T_Ads) const override; + double getAlphaT(const double T_Ads) const override; + double characteristicCurve(const double A) const override; + double dCharacteristicCurve(const double A) const override; }; } diff --git a/MaterialLib/Adsorption/DensityNunez.h b/MaterialLib/Adsorption/DensityNunez.h index 7e4e4e71b88..ad7e2a0c24f 100644 --- a/MaterialLib/Adsorption/DensityNunez.h +++ b/MaterialLib/Adsorption/DensityNunez.h @@ -17,10 +17,10 @@ namespace Adsorption class DensityNunez : public AdsorptionReaction { public: - double getAdsorbateDensity(const double T_Ads) const; - double getAlphaT(const double T_Ads) const; - double characteristicCurve(const double A) const; - double dCharacteristicCurve(const double A) const; + double getAdsorbateDensity(const double T_Ads) const override; + double getAlphaT(const double T_Ads) const override; + double characteristicCurve(const double A) const override; + double dCharacteristicCurve(const double A) const override; }; } diff --git a/MaterialLib/FractureModels/LinearElasticIsotropic.h b/MaterialLib/FractureModels/LinearElasticIsotropic.h index 2bc3037dac0..5ff80779689 100644 --- a/MaterialLib/FractureModels/LinearElasticIsotropic.h +++ b/MaterialLib/FractureModels/LinearElasticIsotropic.h @@ -43,7 +43,7 @@ public: struct MaterialStateVariables : public FractureModelBase<DisplacementDim>::MaterialStateVariables { - void pushBackState() {} + void pushBackState() override {} }; std::unique_ptr< diff --git a/MaterialLib/SolidModels/LinearElasticIsotropic.h b/MaterialLib/SolidModels/LinearElasticIsotropic.h index 9e6357f40f7..7bd96a7f28d 100644 --- a/MaterialLib/SolidModels/LinearElasticIsotropic.h +++ b/MaterialLib/SolidModels/LinearElasticIsotropic.h @@ -56,7 +56,7 @@ public: struct MaterialStateVariables : public MechanicsBase<DisplacementDim>::MaterialStateVariables { - void pushBackState() {} + void pushBackState() override {} }; std::unique_ptr< diff --git a/MeshLib/Elements/TemplateElement.h b/MeshLib/Elements/TemplateElement.h index 8ed60a5e551..413f25cbe2f 100644 --- a/MeshLib/Elements/TemplateElement.h +++ b/MeshLib/Elements/TemplateElement.h @@ -60,51 +60,53 @@ public: TemplateElement(const TemplateElement &e); /// Destructor - virtual ~TemplateElement() = default; + ~TemplateElement() override = default; /// Returns a copy of this object. - virtual Element* clone() const - { - return new TemplateElement(*this); - } - - virtual Element* clone(Node** nodes, std::size_t id) const + Element* clone() const override { return new TemplateElement(*this); } + Element* clone(Node** nodes, std::size_t id) const override { return new TemplateElement(nodes, id); } /// Get dimension of the mesh element. - unsigned getDimension() const { return dimension; } - + unsigned getDimension() const override { return dimension; } /// Returns the edge i of the element. - const Element* getEdge(unsigned i) const { return ELEMENT_RULE::EdgeReturn::getEdge(this, i); } + const Element* getEdge(unsigned i) const override + { + return ELEMENT_RULE::EdgeReturn::getEdge(this, i); + } /// Returns the face i of the element. - const Element* getFace(unsigned i) const { return ELEMENT_RULE::getFace(this, i); } + const Element* getFace(unsigned i) const override + { + return ELEMENT_RULE::getFace(this, i); + } /// Get the number of edges for this element. - unsigned getNumberOfEdges() const { return ELEMENT_RULE::n_edges; } - + unsigned getNumberOfEdges() const override { return ELEMENT_RULE::n_edges; } /// Get the number of faces for this element. - unsigned getNumberOfFaces() const { return ELEMENT_RULE::n_faces; } - + unsigned getNumberOfFaces() const override { return ELEMENT_RULE::n_faces; } /// Get the number of neighbors for this element. - unsigned getNumberOfNeighbors() const { return ELEMENT_RULE::n_neighbors; } + unsigned getNumberOfNeighbors() const override + { + return ELEMENT_RULE::n_neighbors; + } /// Get the number of linear nodes for this element. - virtual unsigned getNumberOfBaseNodes() const { return n_base_nodes; } - + unsigned getNumberOfBaseNodes() const override { return n_base_nodes; } /// Get the number of all nodes for this element. - virtual unsigned getNumberOfNodes() const { return n_all_nodes; } - + unsigned getNumberOfNodes() const override { return n_all_nodes; } /// Get the type of this element. - virtual MeshElemType getGeomType() const { return ELEMENT_RULE::mesh_elem_type; } + MeshElemType getGeomType() const override + { + return ELEMENT_RULE::mesh_elem_type; + } /// Get the FEM type of this element. - virtual CellType getCellType() const { return ELEMENT_RULE::cell_type; } - + CellType getCellType() const override { return ELEMENT_RULE::cell_type; } /// Returns true if these two indices form an edge and false otherwise - bool isEdge(unsigned idx1, unsigned idx2) const; + bool isEdge(unsigned idx1, unsigned idx2) const override; /** * \copydoc MeshLib::Element::isPntInElement() @@ -112,7 +114,9 @@ public: * This is actually calling the correct implementation of this function * passing the element's nodes. */ - bool isPntInElement(MathLib::Point3d const& pnt, double eps = std::numeric_limits<double>::epsilon()) const + bool isPntInElement( + MathLib::Point3d const& pnt, + double eps = std::numeric_limits<double>::epsilon()) const override { return ELEMENT_RULE::isPntInElement(this->_nodes, pnt, eps); } @@ -120,22 +124,25 @@ public: /** * Tests if the element is geometrically valid. */ - virtual ElementErrorCode validate() const + ElementErrorCode validate() const override { return ELEMENT_RULE::validate(this); } /// Returns the ID of a face given an array of nodes. - unsigned identifyFace(Node* nodes[3]) const + unsigned identifyFace(Node* nodes[3]) const override { return ELEMENT_RULE::identifyFace(this->_nodes, nodes); } /// Calculates the volume of a convex hexahedron by partitioning it into six tetrahedra. - virtual double computeVolume() {return ELEMENT_RULE::computeVolume(this->_nodes);} + double computeVolume() override + { + return ELEMENT_RULE::computeVolume(this->_nodes); + } /// Return a specific edge node. - virtual inline Node* getEdgeNode(unsigned edge_id, unsigned node_id) const + inline Node* getEdgeNode(unsigned edge_id, unsigned node_id) const override { if (getNumberOfEdges()>0) return const_cast<Node*>(this->_nodes[ELEMENT_RULE::edge_nodes[edge_id][node_id]]); @@ -147,7 +154,7 @@ public: * Checks if the node order of an element is correct by testing surface normals. * For 1D elements this always returns true. */ - virtual bool testElementNodeOrder() const + bool testElementNodeOrder() const override { return ELEMENT_RULE::testElementNodeOrder(this); } diff --git a/MeshLib/IO/Legacy/MeshIO.h b/MeshLib/IO/Legacy/MeshIO.h index 86646c47adf..9571e84f5e4 100644 --- a/MeshLib/IO/Legacy/MeshIO.h +++ b/MeshLib/IO/Legacy/MeshIO.h @@ -39,7 +39,7 @@ public: /// Constructor. MeshIO(); - virtual ~MeshIO() = default; + ~MeshIO() override = default; /// Read mesh from file. MeshLib::Mesh* loadMeshFromFile(const std::string& fileName); @@ -49,7 +49,7 @@ public: protected: /// Write mesh to stream. - bool write(); + bool write() override; private: void writeElements(std::vector<MeshLib::Element*> const& ele_vec, diff --git a/MeshLib/MeshGenerators/LayeredVolume.h b/MeshLib/MeshGenerators/LayeredVolume.h index 34424ad9812..9557a930a5e 100644 --- a/MeshLib/MeshGenerators/LayeredVolume.h +++ b/MeshLib/MeshGenerators/LayeredVolume.h @@ -32,7 +32,7 @@ class LayeredVolume : public LayeredMeshGenerator { public: LayeredVolume() = default; - ~LayeredVolume() = default; + ~LayeredVolume() override = default; /** * Constructs a subsurface representation of a mesh using only 2D elements @@ -53,10 +53,10 @@ public: * @result true if the subsurface representation has been created, false if * there was an error */ - bool createRasterLayers(const MeshLib::Mesh &mesh, - const std::vector<GeoLib::Raster const*> &rasters, + bool createRasterLayers(const MeshLib::Mesh& mesh, + const std::vector<GeoLib::Raster const*>& rasters, double minimum_thickness, - double noDataReplacementValue = 0.0); + double noDataReplacementValue = 0.0) override; /// Returns the region attribute vector necessary for assigning region /// attributes via TetGen @@ -67,7 +67,9 @@ public: private: /// Adds another layer to the subsurface mesh - void addLayerToMesh(const MeshLib::Mesh &mesh_layer, unsigned layer_id, GeoLib::Raster const& raster); + void addLayerToMesh(const MeshLib::Mesh& mesh_layer, + unsigned layer_id, + GeoLib::Raster const& raster) override; /// Creates boundary surfaces between the mapped layers to make the volumes watertight void addLayerBoundaries(const MeshLib::Mesh &layer, std::size_t nLayers); diff --git a/MeshLib/MeshGenerators/MeshLayerMapper.h b/MeshLib/MeshGenerators/MeshLayerMapper.h index 382826b405e..e82c48adbe2 100644 --- a/MeshLib/MeshGenerators/MeshLayerMapper.h +++ b/MeshLib/MeshGenerators/MeshLayerMapper.h @@ -25,7 +25,7 @@ namespace MeshLib class MeshLayerMapper : public LayeredMeshGenerator { public: - virtual ~MeshLayerMapper() = default; + ~MeshLayerMapper() override = default; /** * Based on a 2D triangle-or quad mesh this method creates a 3D mesh with a given number of prism- or hex-layers @@ -52,7 +52,7 @@ public: bool createRasterLayers(MeshLib::Mesh const& mesh, std::vector<GeoLib::Raster const*> const& rasters, double minimum_thickness, - double noDataReplacementValue = 0.0); + double noDataReplacementValue = 0.0) override; /** * Maps the elevation of nodes of a given 2D mesh according to the raster. At @@ -66,7 +66,9 @@ public: private: /// Adds another layer to a subsurface mesh - void addLayerToMesh(const MeshLib::Mesh &mesh_layer, unsigned layer_id, GeoLib::Raster const& raster); + void addLayerToMesh(const MeshLib::Mesh& mesh_layer, + unsigned layer_id, + GeoLib::Raster const& raster) override; }; } // end namespace MeshLib diff --git a/MeshLib/MeshQuality/AngleSkewMetric.h b/MeshLib/MeshQuality/AngleSkewMetric.h index c7eee5a98e7..8cd75df3098 100644 --- a/MeshLib/MeshQuality/AngleSkewMetric.h +++ b/MeshLib/MeshQuality/AngleSkewMetric.h @@ -27,7 +27,7 @@ class AngleSkewMetric final : public ElementQualityMetric public: AngleSkewMetric(Mesh const& mesh); - void calculateQuality(); + void calculateQuality() override; private: double checkTriangle(Element const& elem) const; diff --git a/MeshLib/MeshQuality/EdgeRatioMetric.h b/MeshLib/MeshQuality/EdgeRatioMetric.h index 4ebb3948258..e8c9a025c07 100644 --- a/MeshLib/MeshQuality/EdgeRatioMetric.h +++ b/MeshLib/MeshQuality/EdgeRatioMetric.h @@ -27,9 +27,9 @@ class EdgeRatioMetric : public ElementQualityMetric { public: EdgeRatioMetric(Mesh const& mesh); - virtual ~EdgeRatioMetric() = default; + ~EdgeRatioMetric() override = default; - virtual void calculateQuality (); + void calculateQuality() override; private: double checkTriangle (MathLib::Point3d const& a, diff --git a/MeshLib/MeshQuality/ElementSizeMetric.h b/MeshLib/MeshQuality/ElementSizeMetric.h index 3387bfecae6..6f1dadb4e15 100644 --- a/MeshLib/MeshQuality/ElementSizeMetric.h +++ b/MeshLib/MeshQuality/ElementSizeMetric.h @@ -26,9 +26,9 @@ class ElementSizeMetric : public ElementQualityMetric { public: ElementSizeMetric(Mesh const& mesh); - virtual ~ElementSizeMetric() = default; + ~ElementSizeMetric() override = default; - virtual void calculateQuality (); + void calculateQuality() override; private: std::size_t calc1dQuality(); diff --git a/MeshLib/MeshQuality/RadiusEdgeRatioMetric.h b/MeshLib/MeshQuality/RadiusEdgeRatioMetric.h index 2ee2e36c88a..f872557c4f6 100644 --- a/MeshLib/MeshQuality/RadiusEdgeRatioMetric.h +++ b/MeshLib/MeshQuality/RadiusEdgeRatioMetric.h @@ -27,8 +27,8 @@ class RadiusEdgeRatioMetric : public ElementQualityMetric { public: RadiusEdgeRatioMetric(Mesh const& mesh); - virtual ~RadiusEdgeRatioMetric() = default; + ~RadiusEdgeRatioMetric() override = default; - virtual void calculateQuality (); + void calculateQuality() override; }; } diff --git a/MeshLib/MeshQuality/SizeDifferenceMetric.h b/MeshLib/MeshQuality/SizeDifferenceMetric.h index cf6c553da39..b2470c33166 100644 --- a/MeshLib/MeshQuality/SizeDifferenceMetric.h +++ b/MeshLib/MeshQuality/SizeDifferenceMetric.h @@ -27,8 +27,8 @@ class SizeDifferenceMetric : public ElementQualityMetric { public: SizeDifferenceMetric(Mesh const& mesh); - virtual ~SizeDifferenceMetric() = default; + ~SizeDifferenceMetric() override = default; - virtual void calculateQuality (); + void calculateQuality() override; }; } diff --git a/MeshLib/PropertyVector.h b/MeshLib/PropertyVector.h index 3b33ab3e68f..a7ed674afee 100644 --- a/MeshLib/PropertyVector.h +++ b/MeshLib/PropertyVector.h @@ -85,7 +85,7 @@ public: } PropertyVectorBase* clone( - std::vector<std::size_t> const& exclude_positions) const + std::vector<std::size_t> const& exclude_positions) const override { auto* t(new PropertyVector<PROP_VAL_TYPE>( _property_name, _mesh_item_type, _n_components)); @@ -144,7 +144,7 @@ class PropertyVector<T*> : public std::vector<std::size_t>, friend class Properties; public: /// Destructor ensures the deletion of the heap-constructed objects. - ~PropertyVector() + ~PropertyVector() override { for (auto v : _values) delete [] v; @@ -195,7 +195,8 @@ public: return _n_components * std::vector<std::size_t>::size(); } - PropertyVectorBase* clone(std::vector<std::size_t> const& exclude_positions) const + PropertyVectorBase* clone( + std::vector<std::size_t> const& exclude_positions) const override { // create new PropertyVector with modified mapping PropertyVector<T*> *t(new PropertyVector<T*> diff --git a/MeshLib/Vtk/VtkMeshNodalCoordinatesTemplate.h b/MeshLib/Vtk/VtkMeshNodalCoordinatesTemplate.h index 350736b8f0b..6aaa36d5225 100644 --- a/MeshLib/Vtk/VtkMeshNodalCoordinatesTemplate.h +++ b/MeshLib/Vtk/VtkMeshNodalCoordinatesTemplate.h @@ -47,7 +47,7 @@ public: vtkMappedDataArrayNewInstanceMacro(VtkMeshNodalCoordinatesTemplate<Scalar>); #endif // vtk version static VtkMeshNodalCoordinatesTemplate *New(); - virtual void PrintSelf(std::ostream &os, vtkIndent indent) override; + void PrintSelf(std::ostream& os, vtkIndent indent) override; /// Pass the nodes from OGS mesh void SetNodes(std::vector<MeshLib::Node*> const & nodes); @@ -117,7 +117,7 @@ public: protected: VtkMeshNodalCoordinatesTemplate(); - ~VtkMeshNodalCoordinatesTemplate(); + ~VtkMeshNodalCoordinatesTemplate() override; const std::vector<MeshLib::Node*>* _nodes; diff --git a/NumLib/DOF/SimpleMatrixVectorProvider.h b/NumLib/DOF/SimpleMatrixVectorProvider.h index c288742d200..8f4ade72e7d 100644 --- a/NumLib/DOF/SimpleMatrixVectorProvider.h +++ b/NumLib/DOF/SimpleMatrixVectorProvider.h @@ -57,7 +57,7 @@ public: void releaseMatrix(GlobalMatrix const& A) override; - ~SimpleMatrixVectorProvider(); + ~SimpleMatrixVectorProvider() override; private: template<bool do_search, typename... Args> diff --git a/NumLib/Extrapolation/LocalLinearLeastSquaresExtrapolator.h b/NumLib/Extrapolation/LocalLinearLeastSquaresExtrapolator.h index a5f58e2910b..aa8929267d4 100644 --- a/NumLib/Extrapolation/LocalLinearLeastSquaresExtrapolator.h +++ b/NumLib/Extrapolation/LocalLinearLeastSquaresExtrapolator.h @@ -71,7 +71,7 @@ public: return _residuals; } - ~LocalLinearLeastSquaresExtrapolator() + ~LocalLinearLeastSquaresExtrapolator() override { NumLib::GlobalVectorProvider::provider.releaseVector( _nodal_values); diff --git a/NumLib/Function/LinearInterpolationAlongPolyline.h b/NumLib/Function/LinearInterpolationAlongPolyline.h index 1e214df96f6..db1143bbc05 100644 --- a/NumLib/Function/LinearInterpolationAlongPolyline.h +++ b/NumLib/Function/LinearInterpolationAlongPolyline.h @@ -56,7 +56,7 @@ public: * @return interpolated value. A default value is returned if the given point * is not located on a polyline */ - double operator()(const MathLib::Point3d& pnt) const; + double operator()(const MathLib::Point3d& pnt) const override; private: /// construct an interpolation algorithm diff --git a/NumLib/Function/LinearInterpolationOnSurface.h b/NumLib/Function/LinearInterpolationOnSurface.h index 6529d273985..fb7c94f65d9 100644 --- a/NumLib/Function/LinearInterpolationOnSurface.h +++ b/NumLib/Function/LinearInterpolationOnSurface.h @@ -55,7 +55,7 @@ public: * @return interpolated value. A default value is returned if the given point * is not located on a surface */ - double operator()(const MathLib::Point3d& pnt) const; + double operator()(const MathLib::Point3d& pnt) const override; private: /// rotate a triangle to XY plane diff --git a/NumLib/Function/TemplateSpatialFunction.h b/NumLib/Function/TemplateSpatialFunction.h index 4f640cb5cc4..20900768792 100644 --- a/NumLib/Function/TemplateSpatialFunction.h +++ b/NumLib/Function/TemplateSpatialFunction.h @@ -38,7 +38,7 @@ public: * @param pnt a point object * @return evaluated value */ - virtual double operator()(const MathLib::Point3d& pnt) const + double operator()(const MathLib::Point3d& pnt) const override { return _f(pnt.getCoords()); } diff --git a/NumLib/ODESolver/MatrixTranslator.h b/NumLib/ODESolver/MatrixTranslator.h index f4edf65943b..7565730d762 100644 --- a/NumLib/ODESolver/MatrixTranslator.h +++ b/NumLib/ODESolver/MatrixTranslator.h @@ -224,7 +224,7 @@ public: { } - ~MatrixTranslatorCrankNicolson() + ~MatrixTranslatorCrankNicolson() override { NumLib::GlobalMatrixProvider::provider.releaseMatrix( _M_bar); diff --git a/NumLib/ODESolver/TimeDiscretization.h b/NumLib/ODESolver/TimeDiscretization.h index ea6dd2ec6b6..0db170d920e 100644 --- a/NumLib/ODESolver/TimeDiscretization.h +++ b/NumLib/ODESolver/TimeDiscretization.h @@ -211,7 +211,7 @@ public: { } - ~BackwardEuler() + ~BackwardEuler() override { NumLib::GlobalVectorProvider::provider.releaseVector(_x_old); } @@ -260,7 +260,7 @@ public: { } - ~ForwardEuler() + ~ForwardEuler() override { NumLib::GlobalVectorProvider::provider.releaseVector(_x_old); } @@ -335,7 +335,7 @@ public: { } - ~CrankNicolson() + ~CrankNicolson() override { NumLib::GlobalVectorProvider::provider.releaseVector(_x_old); } @@ -422,7 +422,7 @@ public: _xs_old.reserve(num_steps); } - ~BackwardDifferentiationFormula() + ~BackwardDifferentiationFormula() override { for (auto* x : _xs_old) NumLib::GlobalVectorProvider::provider.releaseVector(*x); diff --git a/NumLib/ODESolver/TimeDiscretizedODESystem.h b/NumLib/ODESolver/TimeDiscretizedODESystem.h index 4aa4fcb345c..122803064fa 100644 --- a/NumLib/ODESolver/TimeDiscretizedODESystem.h +++ b/NumLib/ODESolver/TimeDiscretizedODESystem.h @@ -84,7 +84,7 @@ public: */ explicit TimeDiscretizedODESystem(ODE& ode, TimeDisc& time_discretization); - ~TimeDiscretizedODESystem(); + ~TimeDiscretizedODESystem() override; void assemble(const GlobalVector& x_new_timestep, ProcessLib::StaggeredCouplingTerm const& coupling_term) @@ -178,7 +178,7 @@ public: */ explicit TimeDiscretizedODESystem(ODE& ode, TimeDisc& time_discretization); - ~TimeDiscretizedODESystem(); + ~TimeDiscretizedODESystem() override; void assemble(const GlobalVector& x_new_timestep, ProcessLib::StaggeredCouplingTerm const& coupling_term) diff --git a/NumLib/TimeStepping/Algorithms/IterationNumberBasedAdaptiveTimeStepping.h b/NumLib/TimeStepping/Algorithms/IterationNumberBasedAdaptiveTimeStepping.h index b0c20f7e380..38058e29d31 100644 --- a/NumLib/TimeStepping/Algorithms/IterationNumberBasedAdaptiveTimeStepping.h +++ b/NumLib/TimeStepping/Algorithms/IterationNumberBasedAdaptiveTimeStepping.h @@ -84,25 +84,26 @@ public: std::vector<double> multiplier_vector); - virtual ~IterationNumberBasedAdaptiveTimeStepping() = default; + ~IterationNumberBasedAdaptiveTimeStepping() override = default; /// return the beginning of time steps - virtual double begin() const {return _t_initial;} - + double begin() const override { return _t_initial; } /// return the end of time steps - virtual double end() const {return _t_end;} - + double end() const override { return _t_end; } /// return current time step - virtual const TimeStep getTimeStep() const; + const TimeStep getTimeStep() const override; /// move to the next time step - virtual bool next(); + bool next() override; /// return if the current step is accepted - virtual bool accepted() const; + bool accepted() const override; /// return a history of time step sizes - virtual const std::vector<double>& getTimeStepSizeHistory() const {return this->_dt_vector;} + const std::vector<double>& getTimeStepSizeHistory() const override + { + return this->_dt_vector; + } /// set the number of iterations void setNIterations(std::size_t n_itr) {this->_iter_times = n_itr;} diff --git a/ProcessLib/HeatConduction/HeatConductionProcess.h b/ProcessLib/HeatConduction/HeatConductionProcess.h index ca7c77a8330..55d2d7c151a 100644 --- a/ProcessLib/HeatConduction/HeatConductionProcess.h +++ b/ProcessLib/HeatConduction/HeatConductionProcess.h @@ -46,7 +46,7 @@ public: const double delta_t) override; // Get the solution of the previous time step. - virtual GlobalVector* getPreviousTimeStepSolution() const override + GlobalVector* getPreviousTimeStepSolution() const override { return _x_previous_timestep.get(); } diff --git a/ProcessLib/LIE/HydroMechanics/LocalAssembler/HydroMechanicsLocalAssemblerInterface.h b/ProcessLib/LIE/HydroMechanics/LocalAssembler/HydroMechanicsLocalAssemblerInterface.h index 98dfcd584c3..d7dc8167217 100644 --- a/ProcessLib/LIE/HydroMechanics/LocalAssembler/HydroMechanicsLocalAssemblerInterface.h +++ b/ProcessLib/LIE/HydroMechanics/LocalAssembler/HydroMechanicsLocalAssemblerInterface.h @@ -55,15 +55,14 @@ public: "implemented."); } - virtual void assembleWithJacobian( - double const t, - std::vector<double> const& local_x_, - std::vector<double> const& local_xdot_, - const double /*dxdot_dx*/, const double /*dx_dx*/, - std::vector<double>& /*local_M_data*/, - std::vector<double>& /*local_K_data*/, - std::vector<double>& local_b_data, - std::vector<double>& local_Jac_data) override + void assembleWithJacobian(double const t, + std::vector<double> const& local_x_, + std::vector<double> const& local_xdot_, + const double /*dxdot_dx*/, const double /*dx_dx*/, + std::vector<double>& /*local_M_data*/, + std::vector<double>& /*local_K_data*/, + std::vector<double>& local_b_data, + std::vector<double>& local_Jac_data) override { auto const local_dof_size = local_x_.size(); diff --git a/ProcessLib/LIE/HydroMechanics/LocalAssembler/HydroMechanicsLocalAssemblerMatrix.h b/ProcessLib/LIE/HydroMechanics/LocalAssembler/HydroMechanicsLocalAssemblerMatrix.h index 1aed6ea753f..1854cb01d1f 100644 --- a/ProcessLib/LIE/HydroMechanics/LocalAssembler/HydroMechanicsLocalAssemblerMatrix.h +++ b/ProcessLib/LIE/HydroMechanics/LocalAssembler/HydroMechanicsLocalAssemblerMatrix.h @@ -63,12 +63,11 @@ public: } protected: - virtual void assembleWithJacobianConcrete( - double const t, - Eigen::VectorXd const& local_x, - Eigen::VectorXd const& local_x_dot, - Eigen::VectorXd& local_rhs, - Eigen::MatrixXd& local_Jac) override; + void assembleWithJacobianConcrete(double const t, + Eigen::VectorXd const& local_x, + Eigen::VectorXd const& local_x_dot, + Eigen::VectorXd& local_rhs, + Eigen::MatrixXd& local_Jac) override; void assembleBlockMatricesWithJacobian( double const t, diff --git a/ProcessLib/LIE/SmallDeformation/LocalAssembler/SmallDeformationLocalAssemblerInterface.h b/ProcessLib/LIE/SmallDeformation/LocalAssembler/SmallDeformationLocalAssemblerInterface.h index c7f6dfd91aa..9f3aaf7c43c 100644 --- a/ProcessLib/LIE/SmallDeformation/LocalAssembler/SmallDeformationLocalAssemblerInterface.h +++ b/ProcessLib/LIE/SmallDeformation/LocalAssembler/SmallDeformationLocalAssemblerInterface.h @@ -40,16 +40,14 @@ public: _local_J.resize(_local_u.size(), _local_u.size()); } - - virtual void assembleWithJacobian( - double const t, - std::vector<double> const& local_x_, - std::vector<double> const& /*local_xdot*/, - const double /*dxdot_dx*/, const double /*dx_dx*/, - std::vector<double>& /*local_M_data*/, - std::vector<double>& /*local_K_data*/, - std::vector<double>& local_b_data, - std::vector<double>& local_Jac_data) override + void assembleWithJacobian(double const t, + std::vector<double> const& local_x_, + std::vector<double> const& /*local_xdot*/, + const double /*dxdot_dx*/, const double /*dx_dx*/, + std::vector<double>& /*local_M_data*/, + std::vector<double>& /*local_K_data*/, + std::vector<double>& local_b_data, + std::vector<double>& local_Jac_data) override { auto const local_dof_size = local_x_.size(); diff --git a/ProcessLib/Parameter/Parameter.h b/ProcessLib/Parameter/Parameter.h index da183f3e7cd..73c94cf78f2 100644 --- a/ProcessLib/Parameter/Parameter.h +++ b/ProcessLib/Parameter/Parameter.h @@ -63,8 +63,7 @@ template <typename T> struct Parameter : public ParameterBase { Parameter(std::string const& name_) : ParameterBase(name_) {} - - virtual ~Parameter() = default; + ~Parameter() override = default; //! Returns the number of components this Parameter has at every position and //! point in time. diff --git a/ProcessLib/Process.h b/ProcessLib/Process.h index 674c898b132..7898b304856 100644 --- a/ProcessLib/Process.h +++ b/ProcessLib/Process.h @@ -56,37 +56,33 @@ public: /// Postprocessing after a complete timestep. void postTimestep(GlobalVector const& x); - void preIteration(const unsigned iter, - GlobalVector const& x) override final; + void preIteration(const unsigned iter, GlobalVector const& x) final; /// compute secondary variables for the coupled equations or for output. void computeSecondaryVariable(const double t, GlobalVector const& x, StaggeredCouplingTerm const& coupled_term); - NumLib::IterationResult postIteration(GlobalVector const& x) override final; + NumLib::IterationResult postIteration(GlobalVector const& x) final; void initialize(); void setInitialConditions(const double t, GlobalVector& x); - MathLib::MatrixSpecifications getMatrixSpecifications() - const override final; + MathLib::MatrixSpecifications getMatrixSpecifications() const final; void assemble(const double t, GlobalVector const& x, GlobalMatrix& M, GlobalMatrix& K, GlobalVector& b, - StaggeredCouplingTerm const& coupling_term) - override final; + StaggeredCouplingTerm const& coupling_term) final; void assembleWithJacobian(const double t, GlobalVector const& x, GlobalVector const& xdot, const double dxdot_dx, const double dx_dx, GlobalMatrix& M, GlobalMatrix& K, GlobalVector& b, GlobalMatrix& Jac, - StaggeredCouplingTerm const& coupling_term) - override final; + StaggeredCouplingTerm const& coupling_term) final; std::vector<NumLib::IndexValueVector<GlobalIndexType>> const* - getKnownSolutions(double const t) const override final + getKnownSolutions(double const t) const final { return _boundary_conditions.getKnownSolutions(t); } diff --git a/ProcessLib/TES/TESLocalAssembler.h b/ProcessLib/TES/TESLocalAssembler.h index f92efd53962..a69e42750aa 100644 --- a/ProcessLib/TES/TESLocalAssembler.h +++ b/ProcessLib/TES/TESLocalAssembler.h @@ -26,7 +26,7 @@ class TESLocalAssemblerInterface public NumLib::ExtrapolatableElement { public: - virtual ~TESLocalAssemblerInterface() = default; + ~TESLocalAssemblerInterface() override = default; virtual bool checkBounds(std::vector<double> const& local_x, std::vector<double> const& local_x_prev_ts) = 0; diff --git a/Tests/BaseLib/TestQuicksort.cpp b/Tests/BaseLib/TestQuicksort.cpp index 87e1947766a..56f287f7c02 100644 --- a/Tests/BaseLib/TestQuicksort.cpp +++ b/Tests/BaseLib/TestQuicksort.cpp @@ -29,7 +29,7 @@ namespace ac = autocheck; struct BaseLibQuicksort : public ::testing::Test { - virtual void SetUp() + void SetUp() override { cls.trivial([](const std::vector<int>& xs) { diff --git a/Tests/FileIO/TestCsvReader.cpp b/Tests/FileIO/TestCsvReader.cpp index f869ff36d11..20899151201 100644 --- a/Tests/FileIO/TestCsvReader.cpp +++ b/Tests/FileIO/TestCsvReader.cpp @@ -41,10 +41,7 @@ public: out.close(); } - ~CsvInterfaceTest() - { - std::remove(_file_name.c_str()); - } + ~CsvInterfaceTest() override { std::remove(_file_name.c_str()); } protected: int _result; diff --git a/Tests/GeoLib/IO/TestGLIReader.cpp b/Tests/GeoLib/IO/TestGLIReader.cpp index 07ded9b7bff..74e40697867 100644 --- a/Tests/GeoLib/IO/TestGLIReader.cpp +++ b/Tests/GeoLib/IO/TestGLIReader.cpp @@ -37,10 +37,7 @@ public: gli_out.close(); } - ~OGSIOVer4InterfaceTest() - { - std::remove(_gli_fname.c_str()); - } + ~OGSIOVer4InterfaceTest() override { std::remove(_gli_fname.c_str()); } protected: std::string _gli_fname; diff --git a/Tests/GeoLib/TestOctTree.cpp b/Tests/GeoLib/TestOctTree.cpp index 816862ea272..420f286b638 100644 --- a/Tests/GeoLib/TestOctTree.cpp +++ b/Tests/GeoLib/TestOctTree.cpp @@ -21,7 +21,7 @@ public: using VectorOfPoints = std::vector<GeoLib::Point*>; GeoLibOctTree() = default; - ~GeoLibOctTree() + ~GeoLibOctTree() override { for (auto p : ps_ptr) { delete p; diff --git a/Tests/GeoLib/TestPolygon.cpp b/Tests/GeoLib/TestPolygon.cpp index 1dff53f6f72..5070f65c72b 100644 --- a/Tests/GeoLib/TestPolygon.cpp +++ b/Tests/GeoLib/TestPolygon.cpp @@ -64,7 +64,7 @@ public: _polygon = new GeoLib::Polygon(ply); } - ~PolygonTest() + ~PolygonTest() override { delete _polygon; for (auto & _pnt : _pnts) diff --git a/Tests/GeoLib/TestSimplePolygonTree.cpp b/Tests/GeoLib/TestSimplePolygonTree.cpp index cbef784f4da..8ab47d9ae1c 100644 --- a/Tests/GeoLib/TestSimplePolygonTree.cpp +++ b/Tests/GeoLib/TestSimplePolygonTree.cpp @@ -86,7 +86,7 @@ public: _p3 = new GeoLib::Polygon(ply3); } - ~CreatePolygonTreesTest() + ~CreatePolygonTreesTest() override { delete _p0; delete _p1; diff --git a/Tests/MeshLib/MeshProperties.cpp b/Tests/MeshLib/MeshProperties.cpp index 9122dac48c0..8f4e8e5e99a 100644 --- a/Tests/MeshLib/MeshProperties.cpp +++ b/Tests/MeshLib/MeshProperties.cpp @@ -26,11 +26,7 @@ public: mesh = MeshLib::MeshGenerator::generateRegularHexMesh(1.0, mesh_size); } - ~MeshLibProperties() - { - delete mesh; - } - + ~MeshLibProperties() override { delete mesh; } static std::size_t const mesh_size = 5; MeshLib::Mesh * mesh; }; diff --git a/Tests/MeshLib/TestBoundaryElementSearch.cpp b/Tests/MeshLib/TestBoundaryElementSearch.cpp index ea2458c0913..4ee32928d47 100644 --- a/Tests/MeshLib/TestBoundaryElementSearch.cpp +++ b/Tests/MeshLib/TestBoundaryElementSearch.cpp @@ -47,7 +47,7 @@ public: _hex_mesh(MeshGenerator::generateRegularHexMesh(_geometric_size, _number_of_subdivisions_per_direction)) {} - ~MeshLibBoundaryElementSearchInSimpleHexMesh() + ~MeshLibBoundaryElementSearchInSimpleHexMesh() override { delete _hex_mesh; } diff --git a/Tests/MeshLib/TestLineMesh.cpp b/Tests/MeshLib/TestLineMesh.cpp index a26af03765c..82d0323f12d 100644 --- a/Tests/MeshLib/TestLineMesh.cpp +++ b/Tests/MeshLib/TestLineMesh.cpp @@ -22,11 +22,7 @@ class MeshLibLineMesh : public ::testing::Test mesh = MeshLib::MeshGenerator::generateLineMesh(extent, mesh_size); } - ~MeshLibLineMesh() - { - delete mesh; - } - + ~MeshLibLineMesh() override { delete mesh; } static std::size_t const mesh_size = 9; double extent = 1.0; MeshLib::Mesh const* mesh; diff --git a/Tests/MeshLib/TestMeshNodeSearch.cpp b/Tests/MeshLib/TestMeshNodeSearch.cpp index 007974c9bbe..c5e51901829 100644 --- a/Tests/MeshLib/TestMeshNodeSearch.cpp +++ b/Tests/MeshLib/TestMeshNodeSearch.cpp @@ -34,10 +34,7 @@ public: _quad_mesh(MeshGenerator::generateRegularQuadMesh(_geometric_size, _number_of_subdivisions_per_direction)) {} - ~MeshLibMeshNodeSearchInSimpleQuadMesh() - { - delete _quad_mesh; - } + ~MeshLibMeshNodeSearchInSimpleQuadMesh() override { delete _quad_mesh; } protected: const double _geometric_size; @@ -53,10 +50,7 @@ public: _hex_mesh(MeshGenerator::generateRegularHexMesh(_geometric_size, _number_of_subdivisions_per_direction)) {} - ~MeshLibMeshNodeSearchInSimpleHexMesh() - { - delete _hex_mesh; - } + ~MeshLibMeshNodeSearchInSimpleHexMesh() override { delete _hex_mesh; } protected: const double _geometric_size; diff --git a/Tests/MeshLib/TestQuadMesh.cpp b/Tests/MeshLib/TestQuadMesh.cpp index c64042441d4..a2bcf5120d7 100644 --- a/Tests/MeshLib/TestQuadMesh.cpp +++ b/Tests/MeshLib/TestQuadMesh.cpp @@ -23,11 +23,7 @@ class MeshLibQuadMesh : public ::testing::Test mesh = MeshLib::MeshGenerator::generateRegularQuadMesh(1.0, n_elements); } - ~MeshLibQuadMesh() - { - delete mesh; - } - + ~MeshLibQuadMesh() override { delete mesh; } static std::size_t const n_elements = 4; static std::size_t const n_nodes = n_elements + 1; static std::size_t const elements_stride = n_elements - 1; diff --git a/Tests/MeshLib/TestTriLineMesh.cpp b/Tests/MeshLib/TestTriLineMesh.cpp index 5d636af3753..13d38fd1261 100644 --- a/Tests/MeshLib/TestTriLineMesh.cpp +++ b/Tests/MeshLib/TestTriLineMesh.cpp @@ -45,7 +45,7 @@ class MeshLibTriLineMesh : public ::testing::Test mesh = new MeshLib::Mesh("M", nodes, elements); } - ~MeshLibTriLineMesh() + ~MeshLibTriLineMesh() override { /*std::remove_if(elements.begin(), elements.end(), [](MeshLib::Element* e) { delete e; return true; }); diff --git a/Tests/MeshLib/TestVtkMappedMeshSource.cpp b/Tests/MeshLib/TestVtkMappedMeshSource.cpp index deb5d6f879a..18dfde09c5b 100644 --- a/Tests/MeshLib/TestVtkMappedMeshSource.cpp +++ b/Tests/MeshLib/TestVtkMappedMeshSource.cpp @@ -128,11 +128,7 @@ class InSituMesh : public ::testing::Test material_id_properties->begin(), material_id_properties->end(), 1); } - ~InSituMesh() - { - delete mesh; - } - + ~InSituMesh() override { delete mesh; } MeshLib::Mesh * mesh; const std::size_t subdivisions = 5; const double length = 1.0; diff --git a/Tests/NumLib/LocalToGlobalIndexMapMultiComponent.cpp b/Tests/NumLib/LocalToGlobalIndexMapMultiComponent.cpp index 6777e610a70..908d622f288 100644 --- a/Tests/NumLib/LocalToGlobalIndexMapMultiComponent.cpp +++ b/Tests/NumLib/LocalToGlobalIndexMapMultiComponent.cpp @@ -71,7 +71,7 @@ public: mesh_items_all_nodes->getIntersectionByNodes(nodes)); } - ~NumLibLocalToGlobalIndexMapMultiDOFTest() + ~NumLibLocalToGlobalIndexMapMultiDOFTest() override { for (auto e : boundary_elements) delete e; diff --git a/Tests/NumLib/TestCoordinatesMapping.cpp b/Tests/NumLib/TestCoordinatesMapping.cpp index 679552adab4..e17a215119c 100644 --- a/Tests/NumLib/TestCoordinatesMapping.cpp +++ b/Tests/NumLib/TestCoordinatesMapping.cpp @@ -81,7 +81,7 @@ public: vec_nodes.push_back(e->getNode(i)); } - virtual ~NumLibFemNaturalCoordinatesMappingTest() + ~NumLibFemNaturalCoordinatesMappingTest() override { for (auto itr = vec_nodes.begin(); itr != vec_nodes.end(); ++itr) delete *itr; diff --git a/Tests/NumLib/TestFe.cpp b/Tests/NumLib/TestFe.cpp index 10a24912de9..13a71fefa27 100644 --- a/Tests/NumLib/TestFe.cpp +++ b/Tests/NumLib/TestFe.cpp @@ -135,11 +135,11 @@ class NumLibFemIsoTest : public ::testing::Test, public T::TestFeType vec_nodes.push_back(e->getNode(i)); } - virtual ~NumLibFemIsoTest() + ~NumLibFemIsoTest() override { - for (auto itr = vec_nodes.begin(); itr!=vec_nodes.end(); ++itr ) + for (auto itr = vec_nodes.begin(); itr != vec_nodes.end(); ++itr) delete *itr; - for (auto itr = vec_eles.begin(); itr!=vec_eles.end(); ++itr ) + for (auto itr = vec_eles.begin(); itr != vec_eles.end(); ++itr) delete *itr; } diff --git a/Tests/NumLib/TestMeshComponentMap.cpp b/Tests/NumLib/TestMeshComponentMap.cpp index ba7bef491e0..469a8229fb7 100644 --- a/Tests/NumLib/TestMeshComponentMap.cpp +++ b/Tests/NumLib/TestMeshComponentMap.cpp @@ -38,7 +38,7 @@ class NumLibMeshComponentMapTest : public ::testing::Test components.emplace_back(new MeshLib::MeshSubsets{nodesSubset}); } - ~NumLibMeshComponentMapTest() + ~NumLibMeshComponentMapTest() override { delete cmap; delete nodesSubset; -- GitLab