Hyperiso
1.0.3
Modular flavour-physics calculations, Wilson coefficients and statistical inference
Loading...
Searching...
No Matches
MakeWriter.h
Go to the documentation of this file.
1
#include <memory>
2
#include "
CsvWriter.h
"
3
#include "
TerminalWriter.h
"
4
#include "
JsonWriter.h
"
5
6
inline
std::unique_ptr<IDataSetWriter>
make_writer
(
OutputFormat
fmt,
7
const
std::string& path_if_file)
8
{
9
switch
(fmt) {
10
case
OutputFormat::CSV
:
return
std::make_unique<CsvWriter>(path_if_file);
11
case
OutputFormat::JSON
:
return
std::make_unique<JsonWriter>(path_if_file);
12
case
OutputFormat::TERMINAL
:
return
std::make_unique<TerminalWriter>();
13
}
14
throw
std::runtime_error(
"Unknown OutputFormat"
);
15
}
CsvWriter.h
JsonWriter.h
make_writer
std::unique_ptr< IDataSetWriter > make_writer(OutputFormat fmt, const std::string &path_if_file)
Definition
MakeWriter.h:6
OutputFormat
OutputFormat
Definition
ObjectsOutputs.h:35
OutputFormat::JSON
@ JSON
OutputFormat::TERMINAL
@ TERMINAL
OutputFormat::CSV
@ CSV
TerminalWriter.h
Hyperiso
core
src
UserInterface
MakeWriter.h
Generated by
1.9.8