artdaq
v3_12_02
Return to top level
Main Page
Namespaces
Classes
Files
File List
File Members
PolicyMacros.hh
1
#ifndef artdaq_Application_Routing_PolicyMacros_hh
2
#define artdaq_Application_Routing_PolicyMacros_hh
3
4
#include "artdaq/RoutingPolicies/RoutingManagerPolicy.hh"
5
#include "cetlib/compiler_macros.h"
6
7
namespace
fhicl {
8
class
ParameterSet;
9
}
10
11
#include <memory>
12
13
namespace
artdaq {
19
typedef
std::unique_ptr<artdaq::RoutingManagerPolicy>
makeFunc_t
(fhicl::ParameterSet
const
& ps);
20
}
// namespace artdaq
21
22
#ifndef EXTERN_C_FUNC_DECLARE_START
23
#define EXTERN_C_FUNC_DECLARE_START extern "C" {
24
#endif
25
26
#define DEFINE_ARTDAQ_ROUTING_POLICY(klass) \
27
EXTERN_C_FUNC_DECLARE_START \
28
std::unique_ptr<artdaq::RoutingManagerPolicy> \
29
make(fhicl::ParameterSet const& ps) \
30
{ \
31
return std::unique_ptr<artdaq::RoutingManagerPolicy>(new klass(ps)); \
32
} \
33
}
34
35
#endif
/* artdaq_Application_Routing_PolicyMacros_hh */
artdaq::makeFunc_t
std::unique_ptr< artdaq::CommandableFragmentGenerator > makeFunc_t(fhicl::ParameterSet const &ps)
Constructs a CommandableFragmentGenerator instance, and returns a pointer to it.
Definition:
GeneratorMacros.hh:20
src
artdaq
RoutingPolicies
PolicyMacros.hh
Generated on Mon Jan 9 2023 16:46:10 for artdaq by
1.8.5