ATLAS Offline Software
|
Get tag-value pairs from a file. More...
#include <ReadCards.h>
Public Member Functions | |
ReadCards () | |
ReadCards (const std::string &filename) | |
~ReadCards () | |
int | GetNValues () const |
bool | isTagDefined (const string &tag) const |
const std::vector< double > | GetVector (unsigned i) const |
string | GetValueString (unsigned i) const |
double | GetValue (const string &tag) const |
double | GetValue (int i) const |
std::string | GetString (const std::string &tag) const |
std::string | GetString (const unsigned i) const |
const std::vector< double > | GetVector (const std::string &tag) const |
const std::vector< int > | GetIntVector (const std::string &tag) const |
std::vector< std::string > | GetStringVector (const std::string &tag) const |
void | Set (const string &tag, double &value) const |
void | Set (const string &tag, int &value) const |
void | Set (const std::string &tag, std::string &value) const |
void | Set (const string &tag, std::vector< double > &value) const |
void | Set (const string &tag, std::vector< int > &value) const |
void | Set (const std::string &tag, std::vector< std::string > &value) const |
void | print () |
std::vector< string > | Tags (const std::string &pattern="") const |
template<class T > | |
void | declareProperty (const std::string &key, T &t) |
template<class T > | |
void | declareProperty (const std::string &key, std::vector< T > &t) |
void | declareProperty (const std::string &key, std::string &t) |
void | declareProperty (const std::string &key, std::vector< std::string > &t) |
Private Member Functions | |
void | ReadParam () |
void | clean () |
remove comments and whitespace More... | |
int | GetIndex (const std::string &tag) const |
bool | AddTag (const string &tag, const vector< string > &values) |
void | Construct (const std::string &filename) |
check for file in cwd or if not, check in the RESPLOTDIR, then read the file More... | |
void | CreatePath () |
void | parse () |
parse the remaining cleaned input string More... | |
string | parseleft (string &s) |
vector< string > | parseright (string &s) |
void | error (const std::string &s) |
double | handle (const std::string &s, const std::string &="") const |
Private Attributes | |
std::string | m_FileName |
ifstream | m_File |
std::string | m_String |
std::vector< Value > | m_Values |
std::vector< int > | m_ValuesFlag |
Static Private Attributes | |
static std::vector< std::string > | m_Path |
Get tag-value pairs from a file.
Reads in all the tag-value pairs from a file (values can actually be a vector of values) and
makes them available by tagname.
Definition at line 50 of file ReadCards.h.
|
inline |
Definition at line 54 of file ReadCards.h.
|
inline |
Definition at line 55 of file ReadCards.h.
|
inline |
Definition at line 57 of file ReadCards.h.
Definition at line 203 of file ReadCards.h.
|
private |
|
private |
check for file in cwd or if not, check in the RESPLOTDIR, then read the file
Definition at line 62 of file ReadCards.cxx.
|
private |
Definition at line 45 of file ReadCards.cxx.
|
inline |
Definition at line 182 of file ReadCards.h.
|
inline |
Definition at line 186 of file ReadCards.h.
|
inline |
Definition at line 176 of file ReadCards.h.
|
inline |
Definition at line 171 of file ReadCards.h.
|
inlineprivate |
Definition at line 240 of file ReadCards.h.
|
inlineprivate |
Definition at line 196 of file ReadCards.h.
|
inline |
Definition at line 59 of file ReadCards.h.
|
inline |
Definition at line 93 of file ReadCards.h.
|
inline |
|
inline |
Definition at line 115 of file ReadCards.h.
|
inline |
Definition at line 84 of file ReadCards.h.
|
inline |
Definition at line 88 of file ReadCards.h.
|
inline |
Definition at line 102 of file ReadCards.h.
|
inline |
Definition at line 246 of file ReadCards.h.
|
inline |
Definition at line 61 of file ReadCards.h.
|
private |
parse the remaining cleaned input string
aha !!! cannot split on "=" in case they might be in a string !!.
Definition at line 198 of file ReadCards.cxx.
|
private |
|
private |
Definition at line 427 of file ReadCards.cxx.
void ReadCards::print | ( | ) |
Definition at line 484 of file ReadCards.cxx.
|
private |
Definition at line 474 of file ReadCards.cxx.
|
inline |
Definition at line 130 of file ReadCards.h.
|
inline |
Definition at line 147 of file ReadCards.h.
|
inline |
Definition at line 122 of file ReadCards.h.
|
inline |
Definition at line 126 of file ReadCards.h.
|
inline |
Definition at line 134 of file ReadCards.h.
|
inline |
|
inline |
Definition at line 154 of file ReadCards.h.
|
private |
Definition at line 219 of file ReadCards.h.
|
private |
Definition at line 217 of file ReadCards.h.
|
staticprivate |
Definition at line 226 of file ReadCards.h.
|
private |
Definition at line 221 of file ReadCards.h.
|
private |
Definition at line 223 of file ReadCards.h.
|
private |
Definition at line 224 of file ReadCards.h.