BornAgain  1.19.0
Simulate and fit neutron and x-ray scattering at grazing incidence
projectmanagerinterface.h
Go to the documentation of this file.
1 // ************************************************************************************************
2 //
3 // qt-mvvm: Model-view-view-model framework for large GUI applications
4 //
5 //! @file mvvm/model/mvvm/interfaces/projectmanagerinterface.h
6 //! @brief Defines class CLASS?
7 //!
8 //! @homepage http://www.bornagainproject.org
9 //! @license GNU General Public License v3 or higher (see COPYING)
10 //! @copyright Forschungszentrum Jülich GmbH 2020
11 //! @authors Gennady Pospelov et al, Scientific Computing Group at MLZ (see CITATION, AUTHORS)
12 //
13 // ************************************************************************************************
14 
15 #ifndef BORNAGAIN_MVVM_MODEL_MVVM_INTERFACES_PROJECTMANAGERINTERFACE_H
16 #define BORNAGAIN_MVVM_MODEL_MVVM_INTERFACES_PROJECTMANAGERINTERFACE_H
17 
18 #include "mvvm/model_export.h"
19 #include <string>
20 
21 namespace ModelView {
22 
23 //! Interface class for ProjectManager family.
24 
25 //! Responsible for handling new/save/save-as/close Project logic, where the Project represents
26 //! a collection of serialized application models in the project directory.
27 
28 class MVVM_MODEL_EXPORT ProjectManagerInterface {
29 public:
30  virtual ~ProjectManagerInterface() = default;
31  virtual bool createNewProject(const std::string& dirname = {}) = 0;
32 
33  virtual bool saveCurrentProject() = 0;
34 
35  virtual bool saveProjectAs(const std::string& dirname = {}) = 0;
36 
37  virtual bool openExistingProject(const std::string& dirname = {}) = 0;
38 
39  virtual std::string currentProjectDir() const = 0;
40 
41  virtual bool isModified() const = 0;
42 
43  virtual bool closeCurrentProject() const = 0;
44 };
45 
46 } // namespace ModelView
47 
48 #endif // BORNAGAIN_MVVM_MODEL_MVVM_INTERFACES_PROJECTMANAGERINTERFACE_H
Interface class for ProjectManager family.
virtual std::string currentProjectDir() const =0
virtual bool closeCurrentProject() const =0
virtual bool saveProjectAs(const std::string &dirname={})=0
virtual ~ProjectManagerInterface()=default
virtual bool createNewProject(const std::string &dirname={})=0
virtual bool openExistingProject(const std::string &dirname={})=0
virtual bool isModified() const =0
materialitems.h Collection of materials to populate MaterialModel.