The Gaudi Framework  master (594c33fa)
Gaudi::PluginService::v1::Factory< R, Args > Class Template Reference

Class wrapping the signature for a factory with any number of arguments. More...

#include </builds/gaudi/Gaudi/GaudiPluginService/include/Gaudi/PluginServiceV1.h>

Public Types

typedef R ReturnType
 
typedef R(* FuncType) (Args &&...)
 

Static Public Member Functions

static ReturnType create (const std::string &id, Args... args)
 
template<typename T >
static ReturnType create (const T &id, Args... args)
 

Detailed Description

template<typename R, typename... Args>
class Gaudi::PluginService::v1::Factory< R, Args >

Class wrapping the signature for a factory with any number of arguments.

Definition at line 55 of file PluginServiceV1.h.

Member Typedef Documentation

◆ FuncType

template<typename R , typename... Args>
typedef R( * Gaudi::PluginService::v1::Factory< R, Args >::FuncType) (Args &&...)

Definition at line 58 of file PluginServiceV1.h.

◆ ReturnType

template<typename R , typename... Args>
typedef R Gaudi::PluginService::v1::Factory< R, Args >::ReturnType

Definition at line 57 of file PluginServiceV1.h.

Member Function Documentation

◆ create() [1/2]

template<typename R , typename... Args>
static ReturnType Gaudi::PluginService::v1::Factory< R, Args >::create ( const std::string id,
Args...  args 
)
inlinestatic

Definition at line 60 of file PluginServiceV1.h.

60  {
61  const FuncType c = Details::getCreator<FuncType>( id );
62  return c ? ( *c )( std::forward<Args>( args )... ) : 0;
63  }

◆ create() [2/2]

template<typename R , typename... Args>
template<typename T >
static ReturnType Gaudi::PluginService::v1::Factory< R, Args >::create ( const T &  id,
Args...  args 
)
inlinestatic

Definition at line 66 of file PluginServiceV1.h.

66  {
68  o << id;
69  return create( o.str(), std::forward<Args>( args )... );
70  }

The documentation for this class was generated from the following file:
Gaudi::PluginService::v1::Factory::create
static ReturnType create(const std::string &id, Args... args)
Definition: PluginServiceV1.h:60
gaudirun.c
c
Definition: gaudirun.py:525
GaudiPartProp.tests.id
id
Definition: tests.py:111
std::ostringstream
STL class.
gaudirun.args
args
Definition: gaudirun.py:336
Gaudi::PluginService::v1::Factory::FuncType
R(* FuncType)(Args &&...)
Definition: PluginServiceV1.h:58
std::ostringstream::str
T str(T... args)