48#define G4AnyMethod_hh 1
57 virtual const char*
what()
const throw()
59 return "G4BadArgument: failed operator()";
64using std::remove_const;
65using std::remove_reference;
76 template <
class S,
class T>
82 template <
class S,
class T,
class A0>
89 template <
class S,
class T,
class A0,
class A1>
114 template <
class S,
class T>
122 template <
class S,
class T,
class A0>
129 template <
class S,
class T,
class A0,
class A1>
176 virtual const std::type_info&
ArgType(
size_t)
const = 0;
179 template <
class S,
class T>
192 virtual const std::type_info&
ArgType(std::size_t)
const
199 template <
class S,
class T,
class A0>
203 typename remove_const<typename remove_reference<A0>::type>::type
nakedA0;
213 std::stringstream strs(
s0);
218 virtual const std::type_info&
ArgType(
size_t)
const {
return typeid(A0); }
222 template <
class S,
class T,
class A0,
class A1>
226 typename remove_const<typename remove_reference<A0>::type>::type
nakedA0;
228 typename remove_const<typename remove_reference<A1>::type>::type
nakedA1;
239 std::stringstream strs(
s0);
241 ((T*) obj->*
fRef)(
a0, a1);
244 virtual const std::type_info&
ArgType(
size_t i)
const
246 return i == 0 ?
typeid(A0) :
typeid(A1);
G4double S(G4double temp)
virtual void operator()(void *)=0
virtual Placeholder * Clone() const =0
virtual const std::type_info & ArgType(size_t) const =0
virtual void operator()(void *, const std::string &)=0
G4AnyMethod(S(T::*f)(A0, A1))
G4AnyMethod & Swap(G4AnyMethod &rhs)
void operator()(void *obj)
const std::type_info & ArgType(size_t n=0) const
G4AnyMethod & operator=(S(T::*f)(A0, A1))
G4AnyMethod(S(T::*f)(A0))
G4AnyMethod(const G4AnyMethod &other)
G4AnyMethod & operator=(const G4AnyMethod &rhs)
G4AnyMethod & operator=(S(T::*f)(A0))
void operator()(void *obj, const std::string &a0)
G4AnyMethod & operator=(S(T::*f)())
virtual const char * what() const
virtual void operator()(void *obj, const std::string &s0)
remove_const< typenameremove_reference< A0 >::type >::type nakedA0
virtual const std::type_info & ArgType(size_t) const
virtual void operator()(void *)
virtual Placeholder * Clone() const
virtual const std::type_info & ArgType(size_t i) const
virtual void operator()(void *obj, const std::string &s0)
remove_const< typenameremove_reference< A0 >::type >::type nakedA0
remove_const< typenameremove_reference< A1 >::type >::type nakedA1
virtual Placeholder * Clone() const
FuncRef2(S(T::*f)(A0, A1))
virtual void operator()(void *)
virtual Placeholder * Clone() const
virtual void operator()(void *obj)
virtual const std::type_info & ArgType(std::size_t) const
virtual void operator()(void *, const std::string &)