CMS 3D CMS Logo

FunctionWithDict.h
Go to the documentation of this file.
1 #ifndef FWCore_Reflection_FunctionWithDict_h
2 #define FWCore_Reflection_FunctionWithDict_h
3 
4 /*----------------------------------------------------------------------
5 
6 FunctionWithDict: A holder for a class member function
7 
8 ----------------------------------------------------------------------*/
9 
11 
12 #include "TMethod.h"
13 #include "TMethodArg.h"
14 #include "TInterpreter.h"
15 
16 #include <cassert>
17 #include <cstdlib>
18 #include <cstdio>
19 #include <string>
20 #include <vector>
21 
22 namespace edm {
23 
24  class ObjectWithDict;
25  class TypeWithDict;
26 
28  private:
29  TMethod* function_;
30  TInterpreter::CallFuncIFacePtr_t funcptr_;
31 
32  public:
34  explicit FunctionWithDict(TMethod*);
35  explicit operator bool() const;
36  std::string name() const;
37  std::string typeName() const;
39  bool isConst() const;
40  bool isConstructor() const;
41  bool isDestructor() const;
42  bool isOperator() const;
43  bool isPublic() const;
44  bool isStatic() const;
46  size_t functionParameterSize(bool required = false) const;
47  size_t size() const;
48  void invoke(ObjectWithDict const& obj,
49  ObjectWithDict* ret = nullptr,
50  std::vector<void*> const& values = std::vector<void*>()) const;
51  void invoke(ObjectWithDict* ret = nullptr, std::vector<void*> const& values = std::vector<void*>()) const;
54  };
55 
56 } // namespace edm
57 
58 #endif // FWCore_Reflection_FunctionWithDict_h
runTheMatrix.ret
ret
prodAgent to be discontinued
Definition: runTheMatrix.py:543
edm::FunctionWithDict::function_
TMethod * function_
Definition: FunctionWithDict.h:29
electrons_cff.bool
bool
Definition: electrons_cff.py:366
edm::FunctionWithDict::end
IterWithDict< TMethodArg > end() const
Definition: FunctionWithDict.cc:105
edm::FunctionWithDict::functionParameterSize
size_t functionParameterSize(bool required=false) const
Definition: FunctionWithDict.cc:64
edm
HLT enums.
Definition: AlignableModifier.h:19
edm::FunctionWithDict::declaringType
TypeWithDict declaringType() const
Definition: FunctionWithDict.cc:50
edm::ObjectWithDict
Definition: ObjectWithDict.h:17
edm::FunctionWithDict::invoke
void invoke(ObjectWithDict const &obj, ObjectWithDict *ret=nullptr, std::vector< void * > const &values=std::vector< void * >()) const
Call a member function.
Definition: FunctionWithDict.cc:74
edm::FunctionWithDict::begin
IterWithDict< TMethodArg > begin() const
Definition: FunctionWithDict.cc:98
edm::FunctionWithDict::isStatic
bool isStatic() const
Definition: FunctionWithDict.cc:62
edm::IterWithDict
Definition: IterWithDict.h:30
edm::FunctionWithDict::isDestructor
bool isDestructor() const
Definition: FunctionWithDict.cc:56
edm::FunctionWithDict::size
size_t size() const
Definition: FunctionWithDict.cc:71
edm::FunctionWithDict::isConst
bool isConst() const
Definition: FunctionWithDict.cc:52
contentValuesCheck.values
values
Definition: contentValuesCheck.py:38
edm::FunctionWithDict::typeName
std::string typeName() const
Definition: FunctionWithDict.cc:38
edm::FunctionWithDict::isOperator
bool isOperator() const
Definition: FunctionWithDict.cc:58
getGTfromDQMFile.obj
obj
Definition: getGTfromDQMFile.py:32
IterWithDict.h
edm::TypeWithDict
Definition: TypeWithDict.h:38
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
edm::FunctionWithDict::funcptr_
TInterpreter::CallFuncIFacePtr_t funcptr_
Definition: FunctionWithDict.h:30
writedatasetfile.required
required
Definition: writedatasetfile.py:8
edm::FunctionWithDict
Definition: FunctionWithDict.h:27
edm::FunctionWithDict::isConstructor
bool isConstructor() const
Definition: FunctionWithDict.cc:54
edm::FunctionWithDict::name
std::string name() const
Definition: FunctionWithDict.cc:36
edm::FunctionWithDict::FunctionWithDict
FunctionWithDict()
Definition: FunctionWithDict.cc:19
edm::FunctionWithDict::finalReturnType
TypeWithDict finalReturnType() const
Definition: FunctionWithDict.cc:40
edm::FunctionWithDict::isPublic
bool isPublic() const
Definition: FunctionWithDict.cc:60