CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Private Member Functions | Private Attributes
cond::OMSServiceResultRef Class Reference

#include <OMSAccess.h>

Public Member Functions

bool empty ()
 
template<typename T >
T get (const std::string &attributeName)
 
template<typename primitive >
std::vector< primitive > getArray (const std::string &attributeName)
 
 OMSServiceResultRef ()=delete
 
 OMSServiceResultRef (const boost::property_tree::ptree *row)
 

Private Member Functions

std::string getAttribute (const std::string &attributeName)
 

Private Attributes

const boost::property_tree::ptree * m_row = nullptr
 

Detailed Description

Definition at line 99 of file OMSAccess.h.

Constructor & Destructor Documentation

cond::OMSServiceResultRef::OMSServiceResultRef ( )
delete
cond::OMSServiceResultRef::OMSServiceResultRef ( const boost::property_tree::ptree *  row)

Definition at line 7 of file OMSAccess.cc.

7 : m_row(row) {}
const boost::property_tree::ptree * m_row
Definition: OMSAccess.h:123

Member Function Documentation

bool cond::OMSServiceResultRef::empty ( )

Definition at line 9 of file OMSAccess.cc.

References m_row.

9 { return m_row == nullptr; }
const boost::property_tree::ptree * m_row
Definition: OMSAccess.h:123
template<typename T >
T cond::OMSServiceResultRef::get ( const std::string &  attributeName)
inline
template<typename primitive >
std::vector<primitive> cond::OMSServiceResultRef::getArray ( const std::string &  attributeName)
inline

Definition at line 113 of file OMSAccess.h.

References B2GTnPMonitor_cfi::item, m_row, funct::primitive(), and runTheMatrix::ret.

113  {
114  std::vector<primitive> ret;
115  for (auto& item : m_row->get_child(attributeName)) {
116  ret.push_back(item.second.get_value<primitive>());
117  }
118  return ret;
119  }
tuple ret
prodAgent to be discontinued
Primitive< F, X >::type primitive(const F &f)
Definition: Primitive.h:41
const boost::property_tree::ptree * m_row
Definition: OMSAccess.h:123
std::string cond::OMSServiceResultRef::getAttribute ( const std::string &  attributeName)
private

Definition at line 11 of file OMSAccess.cc.

References m_row, and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by get().

11  {
12  return m_row->get<std::string>(attributeName);
13  }
const boost::property_tree::ptree * m_row
Definition: OMSAccess.h:123

Member Data Documentation

const boost::property_tree::ptree* cond::OMSServiceResultRef::m_row = nullptr
private

Definition at line 123 of file OMSAccess.h.

Referenced by empty(), getArray(), and getAttribute().