12#ifndef XAOD_STANDALONE
18std::string
getType (
const std::string& s)
20 std::string::size_type pos1 =
s.find(
'#');
21 if (pos1 == std::string::npos)
25 std::string::size_type pos2 =
s.find(
'/', pos1);
26 if (pos2 != std::string::npos)
27 return s.substr (pos1, pos2-pos1);
31std::string
getName (
const std::string& s)
33 std::string::size_type
pos =
s.find(
'/');
34 if (pos == std::string::npos)
36 return s.substr (pos+1, std::string::npos);
39const IInterface* getParent (
const std::string& s)
41 std::string::size_type
pos =
s.find(
'#');
42 if (pos == std::string::npos)
43 return Gaudi::svcLocator()->service(
"ToolSvc" );
45 std::string
ss =
s.substr (0, pos);
46 sscanf (
ss.c_str(),
"%p", &p);
48 return reinterpret_cast<IInterface*
>(
p);
49 return Gaudi::svcLocator()->service(
"ToolSvc" );
60#ifndef XAOD_STANDALONE
61 ::getType(name), ::
getName(name), ::getParent(name)
108#ifdef XAOD_STANDALONE
111 return evtStore()->event()->getName( ptr );
114 static const std::string dummy =
"";
115 return ( proxy ==
nullptr ? dummy : proxy->name() );
121#ifdef XAOD_STANDALONE
127 return ( proxy ==
nullptr ? 0 : proxy->sgkey() );
ServiceHandle< StoreGateSvc > & evtStore()
Wrapper for TEvent to make it look like StoreGate.
const std::string & name(Level lvl)
Convenience function for translating message levels to strings.
T getType(const char *cStr)
Return Ringer enumeration of type T identifying string type:
uint32_t sgkey_t
Type used for hashed StoreGate key+CLID pairs.