preCICE
Loading...
Searching...
No Matches
ExportContext.hpp
Go to the documentation of this file.
1#ifndef PRECICE_IO_EXPORTCONTEXT_HPP_
2#define PRECICE_IO_EXPORTCONTEXT_HPP_
3
4#include <memory>
5#include <string>
6#include <utility>
7#include "io/Export.hpp"
8
9namespace precice::io {
10
12 // @brief Path to export location.
13 std::string location;
14
15 // @brief Exporting every N time windows (equals -1 when not set).
17
18 // @brief If true, export is done in every iteration (also implicit).
19 bool everyIteration = false;
20
21 // @brief If true, updates the series file after every export. Otherwise only at the end
22 bool updateSeries = false;
23
24 // @brief type of the exporter (e.g. vtk).
25 std::string type;
26
27 // @brief Configured mesh name to export (empty means export all meshes).
28 std::string configuredMeshName;
29};
30
32 // @brief Exporters performing the actual export.
33 std::unique_ptr<Export> exporter;
34
35 // @brief Name of the mesh to export.
36 std::string meshName;
37};
38
40inline ExportContext makeExportContext(ConfiguredExport config, std::unique_ptr<io::Export> exporter, std::string meshName)
41{
42 return {std::move(config), std::move(exporter), std::move(meshName)};
43}
44
45} // namespace precice::io
46
47#endif /* PRECICE_IO_EXPORTCONTEXT_HPP_ */
provides Import and Export of the coupling mesh and data.
ExportContext makeExportContext(ConfiguredExport config, std::unique_ptr< io::Export > exporter, std::string meshName)
Creates an ExportContext from configuration and mesh name.
std::unique_ptr< Export > exporter