Medical Imaging Interaction Toolkit  2024.06.00
Medical Imaging Interaction Toolkit
QmitkXnatTreeModel.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 QmitkXnatTreeModel_h
14 #define QmitkXnatTreeModel_h
15 
16 // CTK includes
17 #include <ctkXnatTreeModel.h>
18 
19 // MITK includes
20 #include "MitkXNATExports.h"
21 
22 namespace mitk
23 {
24  class DataNode;
25 }
26 
27 class MITKXNAT_EXPORT QmitkXnatTreeModel : public ctkXnatTreeModel
28 {
29  Q_OBJECT
30 
31 public:
33 
34  QVariant data(const QModelIndex &index, int role) const override;
35 
36  bool dropMimeData(
37  const QMimeData *data, Qt::DropAction action, int row, int column, const QModelIndex &parent) override;
38 
39  using QAbstractItemModel::supportedDropActions;
40  virtual Qt::DropActions supportedDropActions();
41 
42  Qt::ItemFlags flags(const QModelIndex &index) const override;
43 
44  ctkXnatObject *GetXnatObjectFromUrl(const QString &);
45 
46  void fetchMore(const QModelIndex &index) override;
47 
48  QModelIndexList match(
49  const QModelIndex &start, int role, const QVariant &value, int hits, Qt::MatchFlags flags) const override;
50 
51 signals:
52  void Error(const QModelIndex &idx);
53  void ResourceDropped(const QList<mitk::DataNode *> &, ctkXnatObject *, const QModelIndex &);
54 
55 private:
56  ctkXnatObject *InternalGetXnatObjectFromUrl(const QString &xnatObjectType, const QString &url, ctkXnatObject *parent);
57 };
58 
59 #endif
MitkXNATExports.h
mitk
Find image slices visible on a given plane.
Definition: RenderingTests.dox:1
QmitkXnatTreeModel
Definition: QmitkXnatTreeModel.h:27
MITKXNAT_EXPORT
#define MITKXNAT_EXPORT
Definition: MitkXNATExports.h:15