NifTK  16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
niftkBaseWorkbenchAdvisor.h
Go to the documentation of this file.
1 /*=============================================================================
2 
3  NifTK: A software platform for medical image computing.
4 
5  Copyright (c) University College London (UCL). All rights reserved.
6 
7  This software is distributed WITHOUT ANY WARRANTY; without even
8  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
9  PURPOSE.
10 
11  See LICENSE.txt in the top level directory for details.
12 
13 =============================================================================*/
14 
15 #ifndef niftkBaseWorkbenchAdvisor_h
16 #define niftkBaseWorkbenchAdvisor_h
17 
18 #ifdef __MINGW32__
19 // We need to inlclude winbase.h here in order to declare
20 // atomic intrinsics like InterlockedIncrement correctly.
21 // Otherwhise, they would be declared wrong within qatomic_windows.h .
22 #include <windows.h>
23 #endif
24 
25 #include <uk_ac_ucl_cmic_commonapps_Export.h>
26 #include <berryQtWorkbenchAdvisor.h>
27 #include <berryIWorkbenchConfigurer.h>
28 
29 namespace mitk
30 {
31 class DataStorage;
32 }
33 
34 
35 namespace niftk
36 {
37 
38 class BaseWorkbenchWindowAdvisor;
39 
45 class COMMONAPPS_EXPORT BaseWorkbenchAdvisor: public berry::QtWorkbenchAdvisor
46 {
47 public:
48 
49  virtual void Initialize(berry::IWorkbenchConfigurer::Pointer configurer) override;
50 
55  virtual berry::WorkbenchWindowAdvisor* CreateWorkbenchWindowAdvisor(
56  berry::IWorkbenchWindowConfigurer::Pointer configurer) override;
57 
58  virtual void PostStartup() override;
59 
65  virtual bool PreShutdown() override;
66 
67 protected:
68 
73  virtual QString GetWindowIconResourcePath() const = 0;
74 
78  virtual BaseWorkbenchWindowAdvisor* CreateBaseWorkbenchWindowAdvisor(
79  berry::IWorkbenchWindowConfigurer::Pointer configurer);
80 
81  mitk::DataStorage* GetDataStorage();
82 
83 };
84 
85 }
86 
87 #endif
Abstract advisor class to set up an initial workbench.
Definition: niftkBaseWorkbenchAdvisor.h:45
Definition: ReceptorMemberCommandTest.cxx:25
Definition: niftkBaseWorkbenchWindowAdvisor.h:31
Definition: niftkExceptionObject.h:21