2 Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
7 * @file D3PDMakerInterfaces/IAddVariable.icc
8 * @author scott snyder <snyder@bnl.gov>
10 * @brief Template implementations for IAddVariable.
18 * @brief Add a variable to the tuple.
19 * @param name The name of the variable.
20 * @param ptr Pointer to the type of the variable.
21 * The pointer need not be initialized;
22 * the D3PD software will set the pointer
23 * prior to calling @c fill().
24 * @param docstring Documentation string for this variable.
25 * (Presently unimplemented!)
27 * If called from the constructor, the only effect is to clear @c ptr.
30 StatusCode IAddVariable::addVariable (const std::string& name,
32 const std::string& docstring /*= ""*/)
34 return addVariable (name,
36 reinterpret_cast<void*&>(ptr),
42 * @brief Add a variable to the tuple.
43 * @param name The name of the variable.
44 * @param ptr Pointer to the type of the variable.
45 * The pointer need not be initialized;
46 * the D3PD software will set the pointer
47 * prior to calling @c fill().
48 * @param docstring Documentation string for this variable.
49 * (Presently unimplemented!)
50 * @param defval Pointer to the default value to use for this variable.
51 * Only works for basic types.
53 * If called from the constructor, the only effect is to clear @c ptr.
55 template <class T, class U>
56 StatusCode IAddVariable::addVariable (const std::string& name,
58 const std::string& docstring,
62 return addVariable (name,
64 reinterpret_cast<void*&>(ptr),
71 * @brief Add a variable to the tuple.
72 * @param name The name of the variable.
73 * @param ptr Pointer to the type of the variable.
74 * The pointer need not be initialized;
75 * the D3PD software will set the pointer
76 * prior to calling @c fill().
77 * @param dim Dimension for the variable.
78 * (Presently unimplemented!)
79 * @param docstring Documentation string for this variable.
80 * (Presently unimplemented!)
82 * If called from the constructor, the only effect is to clear @c ptr.
86 IAddVariable::addDimensionedVariable (const std::string& name,
88 const std::string& dim,
89 const std::string& docstring /*= ""*/)
91 return addDimensionedVariable (name,
93 reinterpret_cast<void*&>(ptr),
100 * @brief Add a variable to the tuple.
101 * @param name The name of the variable.
102 * @param ptr Pointer to the type of the variable.
103 * The pointer need not be initialized;
104 * the D3PD software will set the pointer
105 * prior to calling @c fill().
106 * @param dim Dimension for the variable.
107 * (Presently unimplemented!)
108 * @param docstring Documentation string for this variable.
109 * (Presently unimplemented!)
110 * @param defval Pointer to the default value to use for this variable.
111 * Only works for basic types.
113 * If called from the constructor, the only effect is to clear @c ptr.
115 template <class T, class U>
117 IAddVariable::addDimensionedVariable (const std::string& name,
119 const std::string& dim,
120 const std::string& docstring,
124 return addDimensionedVariable (name,
126 reinterpret_cast<void*&>(ptr),