Import Geant4 6.2.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-09 10:56:29 +02:00
parent 1d812b78b1
commit e083ffb441
1415 changed files with 111223 additions and 21207 deletions
@@ -16,56 +16,53 @@ DefaultHepRepAttribute::~DefaultHepRepAttribute() {
for (map<string, HepRepAttValue*>::iterator i = attValues.begin(); i != attValues.end(); i++) {
delete (*i).second;
}
attList.clear();
}
vector<HepRepAttValue*>* DefaultHepRepAttribute::getAttValuesFromNode() {
attList.clear();
set<HepRepAttValue*> DefaultHepRepAttribute::getAttValuesFromNode() {
set<HepRepAttValue*> attSet;
for (map<string, HepRepAttValue*>::iterator i = attValues.begin(); i != attValues.end(); i++) {
if ((*i).first != "layer") attList.push_back((*i).second);
if ((*i).first != "layer") attSet.insert((*i).second);
}
return &attList;
return attSet;
}
bool DefaultHepRepAttribute::addAttValue(HepRepAttValue* hepRepAttValue) {
void DefaultHepRepAttribute::addAttValue(HepRepAttValue* hepRepAttValue) {
string lowerCaseName = hepRepAttValue->getLowerCaseName();
if (attValues[lowerCaseName] != NULL) delete attValues[lowerCaseName];
attValues[lowerCaseName] = hepRepAttValue;
return true;
}
bool DefaultHepRepAttribute::addAttValue(string key, char *value, int showLabel) {
return addAttValue(key, (std::string)value, showLabel);
void DefaultHepRepAttribute::addAttValue(string key, char *value, int showLabel) {
addAttValue(key, (std::string)value, showLabel);
}
bool DefaultHepRepAttribute::addAttValue(string key, string value, int showLabel) {
return addAttValue(new DefaultHepRepAttValue(key, value, showLabel));
void DefaultHepRepAttribute::addAttValue(string key, string value, int showLabel) {
addAttValue(new DefaultHepRepAttValue(key, value, showLabel));
}
bool DefaultHepRepAttribute::addAttValue(string key, int value, int showLabel) {
return addAttValue(new DefaultHepRepAttValue(key, value, showLabel));
void DefaultHepRepAttribute::addAttValue(string key, int value, int showLabel) {
addAttValue(new DefaultHepRepAttValue(key, value, showLabel));
}
bool DefaultHepRepAttribute::addAttValue(string key, double value, int showLabel) {
return addAttValue(new DefaultHepRepAttValue(key, value, showLabel));
void DefaultHepRepAttribute::addAttValue(string key, double value, int showLabel) {
addAttValue(new DefaultHepRepAttValue(key, value, showLabel));
}
bool DefaultHepRepAttribute::addAttValue(string key, bool value, int showLabel) {
return addAttValue(new DefaultHepRepAttValue(key, value, showLabel));
void DefaultHepRepAttribute::addAttValue(string key, bool value, int showLabel) {
addAttValue(new DefaultHepRepAttValue(key, value, showLabel));
}
bool DefaultHepRepAttribute::addAttValue(string key, vector<double> value, int showLabel) {
return addAttValue(new DefaultHepRepAttValue(key, value, showLabel));
void DefaultHepRepAttribute::addAttValue(string key, vector<double> value, int showLabel) {
addAttValue(new DefaultHepRepAttValue(key, value, showLabel));
}
bool DefaultHepRepAttribute::addAttValue(string key, double red, double green, double blue, double alpha, int showLabel) {
void DefaultHepRepAttribute::addAttValue(string key, double red, double green, double blue, double alpha, int showLabel) {
vector<double> color;
color.push_back(red);
color.push_back(green);
color.push_back(blue);
color.push_back(alpha);
return addAttValue(new DefaultHepRepAttValue(key, color, showLabel));
addAttValue(new DefaultHepRepAttValue(key, color, showLabel));
}
HepRepAttValue* DefaultHepRepAttribute::getAttValueFromNode(string name) {