LHEF
3.0(beta)
|
This is the base class of all classes representing xml tags. More...
#include <LHEF.h>
Public Types | |
typedef XMLTag::AttributeMap | AttributeMap |
Convenient typedef. | |
Public Member Functions | |
TagBase () | |
Default constructor does nothing. | |
TagBase (const AttributeMap &attr, std::string conts=std::string()) | |
Main constructor stores the attributes and contents of a tag. | |
bool | getattr (std::string n, double &v, bool erase=true) |
Find an attribute named n and set the double variable v to the corresponding value. | |
bool | getattr (std::string n, bool &v, bool erase=true) |
Find an attribute named n and set the bool variable v to true if the corresponding value is "yes". | |
bool | getattr (std::string n, long &v, bool erase=true) |
Find an attribute named n and set the long variable v to the corresponding value. | |
bool | getattr (std::string n, int &v, bool erase=true) |
Find an attribute named n and set the long variable v to the corresponding value. | |
bool | getattr (std::string n, std::string &v, bool erase=true) |
Find an attribute named n and set the string variable v to the corresponding value. | |
void | printattrs (std::ostream &file) const |
print out ' name="value"' for all unparsed attributes. | |
void | closetag (std::ostream &file, std::string tag) const |
Print out end of tag marker. | |
Static Public Member Functions | |
static std::string | yes () |
Static string token for truth values. | |
Public Attributes | |
XMLTag::AttributeMap | attributes |
The attributes of this tag;. | |
std::string | contents |
The contents of this tag. | |
|
inline |
Print out end of tag marker.
Print contents if not empty else print simple close tag.
Definition at line 436 of file LHEF.h.
References contents.
Referenced by LHEF::Generator::print(), LHEF::XSecInfo::print(), LHEF::ProcInfo::print(), LHEF::MergeInfo::print(), LHEF::WeightInfo::print(), and LHEF::Scales::print().
|
inline |
Find an attribute named n and set the double variable v to the corresponding value.
Remove the correspondig attribute from the list if found and erase is true.
Definition at line 359 of file LHEF.h.
References attributes.
Referenced by LHEF::Clus::Clus(), LHEF::Cut::Cut(), LHEF::Generator::Generator(), LHEF::HEPEUP::HEPEUP(), LHEF::MergeInfo::MergeInfo(), LHEF::PDFInfo::PDFInfo(), LHEF::ProcInfo::ProcInfo(), LHEF::Scales::Scales(), LHEF::Weight::Weight(), LHEF::WeightGroup::WeightGroup(), LHEF::WeightInfo::WeightInfo(), and LHEF::XSecInfo::XSecInfo().
|
inline |
Find an attribute named n and set the bool variable v to true if the corresponding value is "yes".
Remove the correspondig attribute from the list if found and erase is true.
Definition at line 373 of file LHEF.h.
References attributes.
|
inline |
Find an attribute named n and set the long variable v to the corresponding value.
Remove the correspondig attribute from the list if found and erase is true.
Definition at line 387 of file LHEF.h.
References attributes.
|
inline |
Find an attribute named n and set the long variable v to the corresponding value.
Remove the correspondig attribute from the list if found and erase is true.
Definition at line 401 of file LHEF.h.
References attributes.
|
inline |
Find an attribute named n and set the string variable v to the corresponding value.
Remove the correspondig attribute from the list if found and erase is true.
Definition at line 415 of file LHEF.h.
References attributes.