MPQC  3.0.0-alpha
sc::Keyword Class Reference

#include <util/keyval/keyval.h>

Public Member Functions

 Keyword (const Ref< KeyVal > &kv, const std::string &key)
 
const Ref< KeyVal > & keyval () const
 
const std::string & key () const
 
template<typename Value , typename Alloc >
Keywordoperator>> (std::vector< Value, Alloc > &vec)
 fills up std::vector using KeyVal object of the following form key = [ value0 value1 value2 .... More...
 
template<typename Key , typename Compare , typename Alloc >
Keywordoperator>> (std::set< Key, Compare, Alloc > &c)
 fills up std::set using KeyVal object of the following form key = [ key0 key1 key2 .... More...
 
template<typename Key , typename Data , typename Compare , typename Alloc >
Keywordoperator>> (std::map< Key, Data, Compare, Alloc > &c)
 fills up std::map using KeyVal object of the following form key = [ [key0 value0] [key1 value1] [key2 value2] .... More...
 

Detailed Description

Provides convenient way to fill standard containers from KeyVal

Member Function Documentation

◆ operator>>() [1/3]

template<typename Key , typename Data , typename Compare , typename Alloc >
Keyword& sc::Keyword::operator>> ( std::map< Key, Data, Compare, Alloc > &  c)
inline

fills up std::map using KeyVal object of the following form key = [ [key0 value0] [key1 value1] [key2 value2] ....

]

◆ operator>>() [2/3]

template<typename Key , typename Compare , typename Alloc >
Keyword& sc::Keyword::operator>> ( std::set< Key, Compare, Alloc > &  c)
inline

fills up std::set using KeyVal object of the following form key = [ key0 key1 key2 ....

. ]

◆ operator>>() [3/3]

template<typename Value , typename Alloc >
Keyword& sc::Keyword::operator>> ( std::vector< Value, Alloc > &  vec)
inline

fills up std::vector using KeyVal object of the following form key = [ value0 value1 value2 ....

]


The documentation for this class was generated from the following file:

Generated at Sun Jan 26 2020 23:24:06 for MPQC 3.0.0-alpha using the documentation package Doxygen 1.8.16.