ifw-daq
3.0.0-pre2
IFW Data Acquisition modules
|
Implementation of daq::dpm::Workspace. More...
#include <workspace.hpp>
Public Member Functions | |
WorkspaceImpl (std::filesystem::path root) | |
Opens or creates workspace in the specified location, using that as a root. More... | |
auto | GetPath () const -> std::filesystem::path override |
auto | EnumerateDaqs () const -> std::vector< std::string > override |
Enumerates in-progress DAQs by querying file system. More... | |
auto | InitializeDaq (std::string const &daq_id) -> std::unique_ptr< DaqWorkspace > override |
Initializes new DAQ Workspace. More... | |
auto | LoadDaq (std::string const &daq_id) -> std::unique_ptr< DaqWorkspace > override |
Loads a previously initialized DAQ workspace. More... | |
void | RemoveDaq (std::string const &daq_id) override |
Removes workspace and all containing files for DAQ without archiving it. More... | |
auto | ArchiveDaq (std::string const &daq_id) -> std::filesystem::path override |
Archives specified DAQ witout deleting any files, typically by moving it to a specific location in the workspace. More... | |
auto | LoadQueue () const -> std::vector< std::string > override |
void | StoreQueue (std::vector< std::string > const &queue) const override |
virtual auto | QueryStorageStatus () const -> std::filesystem::space_info override |
Queries available storage for workspace. More... | |
Public Member Functions inherited from daq::dpm::Workspace | |
virtual | ~Workspace () |
Implementation of daq::dpm::Workspace.
Definition at line 175 of file workspace.hpp.
daq::dpm::WorkspaceImpl::WorkspaceImpl | ( | std::filesystem::path | root | ) |
Opens or creates workspace in the specified location, using that as a root.
If directory does not exist it will attempt to create it, including intermeditate parent directories and basic workspace structure:
If directories exist the necessary permissions for current user (rwx) is checked.
std::invalid_argument | if root exist and is not a directory. |
std::system_error | with permission denied if directories cannot be created or have the wrong permissions if they already exist. |
|
overridevirtual |
Archives specified DAQ witout deleting any files, typically by moving it to a specific location in the workspace.
Implements daq::dpm::Workspace.
Definition at line 167 of file workspace.cpp.
|
overridevirtual |
Enumerates in-progress DAQs by querying file system.
Implements daq::dpm::Workspace.
Definition at line 145 of file workspace.cpp.
|
inlineoverridevirtual |
Implements daq::dpm::Workspace.
Definition at line 194 of file workspace.hpp.
|
overridevirtual |
Initializes new DAQ Workspace.
Creates a private workspace for DAQ merging.
If workspace creation fails rollback of changes to filesystem will be attempted (deleting files and directories just created).
daq_id | Data Acquisition Id. |
Implements daq::dpm::Workspace.
Definition at line 153 of file workspace.cpp.
|
overridevirtual |
Loads a previously initialized DAQ workspace.
daq_id | Data Acquisition Id. |
Implements daq::dpm::Workspace.
Definition at line 158 of file workspace.cpp.
|
overridevirtual |
Implements daq::dpm::Workspace.
Definition at line 184 of file workspace.cpp.
|
overridevirtual |
Queries available storage for workspace.
@thread_safe
Implements daq::dpm::Workspace.
Definition at line 149 of file workspace.cpp.
|
overridevirtual |
Removes workspace and all containing files for DAQ without archiving it.
Workspace is e.g. removed either if user aborts a Data Acquisition or to roll back failed initialization of a workspace.
daq_id | Data Acquisition id. |
Implements daq::dpm::Workspace.
Definition at line 163 of file workspace.cpp.
|
overridevirtual |
Implements daq::dpm::Workspace.
Definition at line 196 of file workspace.cpp.