BornAgain
1.19.0
Simulate and fit neutron and x-ray scattering at grazing incidence
|
Project represents content of all application models in a folder on disk. More...
Classes | |
struct | ProjectImpl |
Public Member Functions | |
Project (const ProjectContext &context) | |
~Project () | |
bool | isModified () const override |
bool | load (const std::string &dirname) override |
Loads all models from the given directory. More... | |
std::string | projectDir () const override |
Returns the full path to a project directory. More... | |
bool | save (const std::string &dirname) const override |
Saves all models to a given directory. More... | |
Private Attributes | |
std::unique_ptr< ProjectImpl > | p_impl |
Project represents content of all application models in a folder on disk.
Responsible for saving/loading application models to/from disk.
Project::Project | ( | const ProjectContext & | context | ) |
Definition at line 57 of file project.cpp.
|
default |
|
overridevirtual |
Implements ModelView::ProjectInterface.
Definition at line 83 of file project.cpp.
References p_impl.
|
overridevirtual |
Loads all models from the given directory.
Implements ModelView::ProjectInterface.
Definition at line 78 of file project.cpp.
References ModelView::ModelDocumentInterface::load(), and p_impl.
|
overridevirtual |
Returns the full path to a project directory.
It is a name where the project has been last time saved, or loaded from.
Implements ModelView::ProjectInterface.
Definition at line 64 of file project.cpp.
References p_impl.
|
overridevirtual |
Saves all models to a given directory.
Directory should exist. Provided name will become 'projectDir'.
Implements ModelView::ProjectInterface.
Definition at line 72 of file project.cpp.
References p_impl, and ModelView::ModelDocumentInterface::save().
|
private |
Definition at line 43 of file project.h.
Referenced by isModified(), load(), projectDir(), and save().