44 #define G4AnyMethod_h 1
53 virtual const char*
what()
const throw() {
54 return "G4BadArgument: failed operator()";
58 #if defined(G4USE_STD11) || defined(G4USE_STD14)
59 #include <type_traits>
60 using std::remove_reference;
61 using std::remove_const;
74 template<
typename T>
struct remove_const<const
T> {
typedef T type;};
142 const std::type_info&
ArgType(
size_t n = 0)
const {
153 virtual void operator()(
void*,
const std::string&) = 0;
154 virtual const std::type_info&
ArgType(
size_t)
const = 0;
169 virtual const std::type_info&
ArgType(
size_t)
const {
176 typedef typename remove_const<typename remove_reference<A0>::type>::type
nakedA0;
185 std::stringstream strs(s0);
192 virtual const std::type_info&
ArgType(
size_t)
const {
199 typedef typename remove_const<typename remove_reference<A0>::type>::type
nakedA0;
200 typedef typename remove_const<typename remove_reference<A1>::type>::type
nakedA1;
210 std::stringstream strs(s0);
217 virtual const std::type_info&
ArgType(
size_t i)
const {
218 return i == 0 ?
typeid(A0) :
typeid(A1);