The Gaudi Framework  v30r3 (a5ef0a68)
DODBasicMapper.cpp
Go to the documentation of this file.
1 // Include files
2 
3 #include "GaudiKernel/HashMap.h"
4 #include "GaudiKernel/Parsers.h"
5 // Local implementation of parsers from HashMap
6 namespace Gaudi
7 {
8  namespace Parsers
9  {
12  template <typename K, typename V>
14  {
16  StatusCode sc = parse( tmp, input );
17  if ( sc.isSuccess() ) {
18  result.clear();
19  result.insert( tmp.begin(), tmp.end() );
20  }
21  return sc;
22  }
23  }
24 }
25 
26 // local
27 #include "DODBasicMapper.h"
28 
29 // ----------------------------------------------------------------------------
30 // Implementation file for class: DODBasicMapper
31 //
32 // 16/01/2012: Marco Clemencic
33 // ----------------------------------------------------------------------------
35 
36 Gaudi::Utils::TypeNameString DODBasicMapper::algorithmForPath( const std::string& path )
37 {
38  auto alg = m_algMap.find( path );
39  return ( alg != m_algMap.end() ) ? alg->second : "";
40 }
41 
43 {
44  auto node = m_nodeMap.find( path );
45  return ( node != m_nodeMap.end() ) ? node->second : "";
46 }
47 
48 // ============================================================================
Default implementation of a DataOnDemand mapper.
The declaration of major parsing functions used e.g for (re)implementation of new extended properties...
bool isSuccess() const
Definition: StatusCode.h:287
STL namespace.
StatusCode parse(GaudiUtils::HashMap< K, V > &result, const std::string &input)
Basic parser for the types of HashMap used in DODBasicMapper.
T end(T...args)
std::string nodeTypeForPath(const std::string &path) override
STL class.
#define DECLARE_COMPONENT(type)
std::pair< iterator, bool > insert(ValueType &&val)
Definition: Map.h:174
This class is used for returning status codes from appropriate routines.
Definition: StatusCode.h:51
T find(T...args)
T begin(T...args)
Common class providing an architecture-independent hash map.
Definition: HashMap.h:74
void clear()
Definition: Map.h:195
Helper functions to set/get the application return code.
Definition: __init__.py:1