file_mfPlugin.cc
Go to the documentation of this file.
1 // vim: set sw=2 expandtab :
2 
3 #include "private/FileConfig.h"
4 
6 
12 
13 #include <fstream>
14 #include <memory>
15 
16 using namespace std;
18 using namespace mf::service;
19 
20 namespace mf {
21 
23  struct Config {
26  };
27 
29  };
30 
31 } // namespace mf
32 
33 namespace {
34 
35  auto
36  makePlugin_(mf::file_mfPluginConfig::Parameters const& ps)
37  {
38  ostream_handle osh{ps().file_config().filename(),
39  ps().file_config().append() ? ios::app : ios::trunc};
40  return make_unique<ELostreamOutput>(ps().ostream_dest(), move(osh));
41  }
42 
43 } // unnamed namespace
44 
46 {
47  return makePlugin_(pset);
48 }
50 
STL namespace.
fhicl::TableFragment< priv::FileConfig > file_config
def move(depos, offset)
Definition: depos.py:107
#define MAKE_PLUGIN_END
static constexpr double ps
Definition: Units.h:99
MAKE_MFPLUGIN_START(, pset)
fhicl::TableFragment< ELostreamOutput::Config > ostream_dest
#define FHICL_PROVIDE_ALLOWED_CONFIGURATION(klass)