Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
QmitkDicomLocalStorageWidget.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 #ifndef QmitkDicomLocalStorageWidget_h
14 #define QmitkDicomLocalStorageWidget_h
15 
16 #include <MitkDICOMUIExports.h>
17 #include <QWidget>
18 #include <memory>
19 
20 class ctkDICOMDatabase;
21 class ctkDICOMIndexer;
22 
23 namespace Ui
24 {
26 }
27 
40 {
41  Q_OBJECT
42 
43 public:
48  explicit QmitkDicomLocalStorageWidget(QWidget* parent = nullptr);
49 
52 
67  QSharedPointer<ctkDICOMDatabase> SetDatabaseDirectory(const QString& databaseDirectory);
68 
69 signals:
74 
80  void ViewSeries(const std::vector<std::pair<std::string, std::optional<std::string>>>& series);
81 
82 public slots:
92  void OnImport(const QStringList &files);
93 
94 private slots:
95  void OnViewButtonClicked();
96  void OnDeleteButtonClicked();
97  void OnAnySelectionChanged();
98 
99 private:
100  void showEvent(QShowEvent* event) override;
101 
102  bool DeletePatients();
103  bool DeleteStudies();
104  bool DeleteSeries();
105 
106  QSharedPointer<ctkDICOMDatabase> m_LocalDatabase;
107  std::unique_ptr<ctkDICOMIndexer> m_LocalIndexer;
108  std::unique_ptr<Ui::QmitkDicomLocalStorageWidget> m_Ui;
109 };
110 
111 #endif
#define MITKDICOMUI_EXPORT
Widget for managing a persistent local DICOM storage database.
QSharedPointer< ctkDICOMDatabase > SetDatabaseDirectory(const QString &databaseDirectory)
Sets the directory for the local storage DICOM database.
void OnImport(const QStringList &files)
Imports the given DICOM files into the local database.
~QmitkDicomLocalStorageWidget() override
Destructor.
QmitkDicomLocalStorageWidget(QWidget *parent=nullptr)
Constructor.
void ViewSeries(const std::vector< std::pair< std::string, std::optional< std::string >>> &series)
Emitted when the View button is clicked to load selected series.
void IndexingComplete()
Emitted when the indexing of newly imported DICOM data is complete.