37 if(!nameOfTracked.empty()) {
39 LogInfo(
"ParameterSet") <<
"Warning: You have added a new tracked parameter\n"
40 <<
"'" << nameOfTracked <<
"' to a previously registered parameter set.\n"
41 <<
"This is a bad idea because the new parameter(s) will not be recorded.\n"
42 <<
"Use the forthcoming ParameterSetDescription facility instead.\n"
43 <<
"A warning is given only for the first such parameter in a pset.\n";
70 <<
"The encoded configuration string "
71 <<
"passed to a ParameterSet during construction is invalid:\n"
86 <<
"The encoded configuration string "
87 <<
"passed to a ParameterSet during construction is invalid:\n"
112 psetTable_(other.psetTable_),
113 vpsetTable_(other.vpsetTable_),
146 psettable::iterator it =
psetTable_.find(name);
149 std::swap(*pset, it->second.psetForUpdate());
156 table::iterator it =
tbl_.find(name);
163 psettable::iterator it =
psetTable_.find(name);
166 if (pset.isRegistered()) {
167 it->second.setIsTracked(
false);
177 std::auto_ptr<std::vector<ParameterSet> > vpset(
new std::vector<ParameterSet>);
178 std::swap(*vpset, it->second.vpsetForUpdate());
190 item.second.updateID();
195 i->second.registerPsetsAndUpdateIDs();
217 <<
"ParameterSet::id() called prematurely\n"
218 <<
"before ParameterSet::registerIt() has been called.\n";
241 <<
"The required parameter '" << name
242 <<
"' was not specified.\n";
246 template<
typename T,
typename U>
T first(std::pair<T, U>
const&
p) {
250 template<
typename T,
typename U> U
second(std::pair<T, U>
const&
p) {
261 table::const_iterator it =
tbl_.find(name);
262 if(it ==
tbl_.end()) {
264 <<
"Parameter '" << name
267 if(it->second.isTracked() ==
false) {
270 <<
"Framework Error: Parameter '" << name
271 <<
"' is incorrectly designated as tracked in the framework.";
274 <<
"Parameter '" << name
275 <<
"' is designated as tracked in the code,\n"
276 <<
"but is designated as untracked in the configuration file.\n"
277 <<
"Please remove 'untracked' from the configuration file for parameter '"<< name <<
"'.";
290 table::const_iterator it =
tbl_.find(name);
292 if(it ==
tbl_.end())
return 0;
293 if(it->second.isTracked()) {
296 <<
"Framework Error: Parameter '" << name
297 <<
"' is incorrectly designated as untracked in the framework.";
300 <<
"Parameter '" << name
301 <<
"' is designated as untracked in the code,\n"
302 <<
"but is not designated as untracked in the configuration file.\n"
303 <<
"Please change the configuration file to 'untracked <type> " << name <<
"'.";
311 psettable::const_iterator it =
psetTable_.find(name);
314 <<
"ParameterSet '" << name
317 if(it->second.isTracked() ==
false) {
320 <<
"Framework Error: ParameterSet '" << name
321 <<
"' is incorrectly designated as tracked in the framework.";
324 <<
"ParameterSet '" << name
325 <<
"' is designated as tracked in the code,\n"
326 <<
"but is designated as untracked in the configuration file.\n"
327 <<
"Please remove 'untracked' from the configuration file for parameter '"<< name <<
"'.";
335 psettable::const_iterator it =
psetTable_.find(name);
338 if(it->second.isTracked()) {
341 <<
"Framework Error: ParameterSet '" << name
342 <<
"' is incorrectly designated as untracked in the framework.";
345 <<
"ParameterSet '" << name
346 <<
"' is designated as untracked in the code,\n"
347 <<
"but is not designated as untracked in the configuration file.\n"
348 <<
"Please change the configuration file to 'untracked <type> " << name <<
"'.";
356 vpsettable::const_iterator it =
vpsetTable_.find(name);
359 <<
"VParameterSet '" << name
362 if(it->second.isTracked() ==
false) {
364 <<
"VParameterSet '" << name
365 <<
"' is designated as tracked in the code,\n"
366 <<
"but is designated as untracked in the configuration file.\n"
367 <<
"Please remove 'untracked' from the configuration file for parameter '"<< name <<
"'.";
374 vpsettable::const_iterator it =
vpsetTable_.find(name);
377 if(it->second.isTracked()) {
379 <<
"VParameterSet '" << name
380 <<
"' is designated as untracked in the code,\n"
381 <<
"but is not designated as untracked in the configuration file.\n"
382 <<
"Please change the configuration file to 'untracked <type> " << name <<
"'.";
394 table::const_iterator it =
tbl_.find(name);
395 if(it ==
tbl_.end()) {
403 psettable::const_iterator it =
psetTable_.find(name);
412 vpsettable::const_iterator it =
vpsetTable_.find(name);
424 if(existsAs<ParameterSet>(name)) {
427 else if(
existsAs<std::vector<ParameterSet> >(name)) {
435 <<
"Cannot find parameter " << name <<
" in " << *
this;
451 table::iterator it =
tbl_.find(name);
453 if(it ==
tbl_.end()) {
454 if(!
tbl_.insert(std::make_pair(name, value)).second)
456 <<
"cannot insert " << name
457 <<
" into a ParameterSet\n";
459 else if(okay_to_replace) {
467 psettable::iterator it =
psetTable_.find(name);
470 if(!
psetTable_.insert(std::make_pair(name, entry)).second)
472 <<
"cannot insert " << name
473 <<
" into a ParameterSet\n";
474 }
else if(okay_to_replace) {
485 if(!
vpsetTable_.insert(std::make_pair(name, entry)).second)
487 <<
"cannot insert " << name
488 <<
" into a VParameterSet\n";
489 }
else if(okay_to_replace) {
502 for(table::const_iterator
b = from.
tbl_.begin(),
e = from.
tbl_.end();
b !=
e; ++
b) {
503 this->
insert(
false,
b->first,
b->second);
518 else if(from.
existsAs<std::vector<ParameterSet> >(name)) {
521 else if(from.
exists(name)) {
526 <<
"Cannot find parameter " << name <<
" in " << from;
534 psettable::iterator it =
psetTable_.find(name);
536 isTracked = it->second.isTracked();
537 return &it->second.psetForUpdate();
570 for(table::const_iterator
b =
tbl_.begin(),
e =
tbl_.end();
b !=
e; ++
b) {
571 if(useAll ||
b->second.isTracked()) {
573 size +=
b->first.size();
574 size +=
b->second.sizeOfString();
578 if(useAll ||
b->second.isTracked()) {
580 size +=
b->first.size();
581 size +=
b->first.size();
582 size +=
b->first.size();
587 if(useAll ||
b->second.isTracked()) {
589 size +=
b->first.size();
594 rep.reserve(rep.size()+
size);
598 for(table::const_iterator
b =
tbl_.begin(),
e =
tbl_.end();
b !=
e; ++
b) {
599 if(useAll ||
b->second.isTracked()) {
603 b->second.toString(rep);
608 if(useAll ||
b->second.isTracked()) {
612 b->second.toString(rep);
617 if(useAll ||
b->second.isTracked()) {
621 b->second.toString(rep);
632 bool started =
false;
633 for(table::const_iterator
b =
tbl_.begin(),
e =
tbl_.end();
b !=
e; ++
b) {
634 if(
b->second.isTracked()) {
639 b->second.toDigest(digest);
644 if(
b->second.isTracked()) {
649 b->second.toDigest(digest);
654 if(
b->second.isTracked()) {
659 b->second.toDigest(digest);
677 std::vector<std::string>
temp;
678 if(!
split(std::back_inserter(temp), from,
'<',
';',
'>'))
682 for(std::vector<std::string>::const_iterator
b = temp.begin(),
e = temp.end();
b !=
e; ++
b) {
699 if(!
psetTable_.insert(std::make_pair(name, psetEntry)).second) {
702 }
else if(
rep[1] ==
'q') {
704 if(!
vpsetTable_.insert(std::make_pair(name, vpsetEntry)).second) {
707 }
else if(
rep[1] ==
'P') {
710 if(!
psetTable_.insert(std::make_pair(name, psetEntry)).second) {
713 }
else if(
rep[1] ==
'p') {
716 if(!
vpsetTable_.insert(std::make_pair(name, vpsetEntry)).second) {
722 if(!
tbl_.insert(std::make_pair(name, value)).second) {
734 table::const_iterator it =
tbl_.begin();
735 table::const_iterator
end =
tbl_.end();
737 Entry const&
e = it->second;
747 std::vector<std::string>
749 using std::placeholders::_1;
750 std::vector<std::string> returnValue;
761 return(
tbl_.find(parameterName) !=
tbl_.end() ||
769 for(table::const_iterator tblItr =
tbl_.begin(); tblItr !=
tbl_.end(); ++tblItr) {
770 if(tblItr->second.isTracked()) {
771 result.
tbl_.insert(*tblItr);
774 for(psettable::const_iterator psetItr =
psetTable_.begin(); psetItr !=
psetTable_.end(); ++psetItr) {
775 if(psetItr->second.isTracked()) {
779 for(vpsettable::const_iterator vpsetItr =
vpsetTable_.begin(); vpsetItr !=
vpsetTable_.end(); ++vpsetItr) {
780 if(vpsetItr->second.isTracked()) {
782 std::vector<ParameterSet>
const& this_vpset = vpsetItr->second.vpset();
784 typedef std::vector<ParameterSet>::const_iterator Iter;
785 for (Iter
i = this_vpset.begin(),
e = this_vpset.end();
i !=
e; ++
i) {
786 vresult.push_back(
i->trackedPart());
807 bool trackiness)
const {
808 for(psettable::const_iterator psetItr =
psetTable_.begin();
810 if(psetItr->second.isTracked() == trackiness) {
811 output.push_back(psetItr->first);
814 return output.size();
819 bool trackiness)
const {
820 for(vpsettable::const_iterator vpsetItr =
vpsetTable_.begin();
822 if(vpsetItr->second.isTracked() == trackiness) {
823 output.push_back(vpsetItr->first);
826 return output.size();
832 std::vector<std::string>&
output)
const {
840 table::const_iterator it =
tbl_.begin();
841 table::const_iterator
end =
tbl_.end();
843 Entry const&
e = it->second;
847 output.push_back(it->first);
855 std::vector<std::string> ParameterSet::getParameterNamesForType<FileInPath>(
bool trackiness)
const {
856 std::vector<std::string>
result;
857 getNamesByCode_(
'F', trackiness, result);
863 return (a.
id() == b.
id());
869 if(a.
tbl().size() != b.
tbl().size()) {
878 typedef ParameterSet::table::const_iterator Ti;
879 for (Ti
i = a.
tbl().begin(),
e = a.
tbl().end(),
880 j = b.
tbl().begin(),
f = b.
tbl().end();
881 i !=
e &&
j !=
f; ++
i, ++
j) {
886 typedef ParameterSet::psettable::const_iterator
Pi;
889 i !=
e &&
j !=
f; ++
i, ++
j) {
890 if(
i->first !=
j->first) {
893 if(
i->second.isTracked() !=
j->second.isTracked()) {
900 typedef ParameterSet::vpsettable::const_iterator PVi;
903 i !=
e &&
j !=
f; ++
i, ++
j) {
904 if(
i->first !=
j->first) {
907 if(
i->second.isTracked() !=
j->second.isTracked()) {
910 std::vector<ParameterSet>
const& iv =
i->second.vpset();
911 std::vector<ParameterSet>
const& jv =
j->second.vpset();
912 if(iv.size() != jv.size()) {
915 for (
size_t k = 0;
k < iv.size(); ++
k) {
925 std::ostringstream os;
928 os <<
"{" << std::endl;
929 for(table::const_iterator
i =
tbl_.begin(),
e =
tbl_.end();
i !=
e; ++
i) {
930 os << indentation <<
" " <<
i->first <<
": " <<
i->second << std::endl;
936 os << indentation <<
" " << n <<
": " << pe.
dump(indent + 2) << std::endl;
942 os << indentation <<
" " << n <<
": " << pe.
dump(indent + 2) << std::endl;
944 os << indentation <<
"}";
959 <<
"Parameter Set ID '" <<
id <<
"' not found.";
971 LogWarning(
"Configuration") <<
"Warning:\n\tstring " << name
973 <<
"\"\nis deprecated, "
974 <<
"please update your config file to use\n\tInputTag "
975 << name <<
" = " <<
label;
985 return retrieve(
name).getBool();
994 return retrieve(
name).getInt32();
1000 return retrieve(
name).getVInt32();
1009 return retrieve(
name).getInt64();
1013 std::vector<long long>
1015 return retrieve(
name).getVInt64();
1024 return retrieve(
name).getUInt32();
1028 std::vector<unsigned int>
1030 return retrieve(
name).getVUInt32();
1039 return retrieve(
name).getUInt64();
1043 std::vector<unsigned long long>
1044 ParameterSet::getParameter<std::vector<unsigned long long> >(
std::string const&
name)
const {
1045 return retrieve(
name).getVUInt64();
1054 return retrieve(
name).getDouble();
1060 return retrieve(
name).getVDouble();
1069 return retrieve(
name).getString();
1073 std::vector<std::string>
1075 return retrieve(
name).getVString();
1084 return retrieve(
name).getFileInPath();
1099 deprecatedInputTagWarning(
name, label);
1103 <<
name <<
" is expected to be InputTag or string (deprecated)";
1111 std::vector<InputTag>
1113 return retrieve(
name).getVInputTag();
1122 return retrieve(
name).getESInputTag();
1129 std::vector<ESInputTag>
1131 return retrieve(
name).getVESInputTag();
1140 return retrieve(
name).getEventID();
1147 std::vector<EventID>
1149 return retrieve(
name).getVEventID();
1158 return retrieve(
name).getLuminosityBlockID();
1165 std::vector<LuminosityBlockID>
1166 ParameterSet::getParameter<std::vector<LuminosityBlockID> >(
std::string const&
name)
const {
1167 return retrieve(
name).getVLuminosityBlockID();
1176 return retrieve(
name).getEventRange();
1183 std::vector<EventRange>
1185 return retrieve(
name).getVEventRange();
1194 return retrieve(
name).getLuminosityBlockRange();
1201 std::vector<LuminosityBlockRange>
1202 ParameterSet::getParameter<std::vector<LuminosityBlockRange> >(
std::string const&
name)
const {
1203 return retrieve(
name).getVLuminosityBlockRange();
1218 return getParameterSetVector(
name);
1228 ParameterSet::getUntrackedParameter<bool>(
std::string const&
name,
bool const& defaultValue)
const {
1229 Entry const* entryPtr = retrieveUntracked(
name);
1230 return entryPtr == 0 ? defaultValue : entryPtr->
getBool();
1236 return getEntryPointerOrThrow_(
name)->getBool();
1244 ParameterSet::getUntrackedParameter<int>(
std::string const&
name,
int const& defaultValue)
const {
1245 Entry const* entryPtr = retrieveUntracked(
name);
1246 return entryPtr == 0 ? defaultValue : entryPtr->
getInt32();
1252 return getEntryPointerOrThrow_(
name)->getInt32();
1257 ParameterSet::getUntrackedParameter<std::vector<int> >(
std::string const&
name, std::vector<int>
const& defaultValue)
const {
1258 Entry const* entryPtr = retrieveUntracked(
name);
1259 return entryPtr == 0 ? defaultValue : entryPtr->
getVInt32();
1265 return getEntryPointerOrThrow_(
name)->getVInt32();
1273 ParameterSet::getUntrackedParameter<unsigned int>(
std::string const&
name,
unsigned int const& defaultValue)
const {
1274 Entry const* entryPtr = retrieveUntracked(
name);
1275 return entryPtr == 0 ? defaultValue : entryPtr->
getUInt32();
1281 return getEntryPointerOrThrow_(
name)->getUInt32();
1285 std::vector<unsigned int>
1286 ParameterSet::getUntrackedParameter<std::vector<unsigned int> >(
std::string const&
name, std::vector<unsigned int>
const& defaultValue)
const {
1287 Entry const* entryPtr = retrieveUntracked(
name);
1288 return entryPtr == 0 ? defaultValue : entryPtr->
getVUInt32();
1292 std::vector<unsigned int>
1293 ParameterSet::getUntrackedParameter<std::vector<unsigned int> >(
std::string const&
name)
const {
1294 return getEntryPointerOrThrow_(
name)->getVUInt32();
1302 ParameterSet::getUntrackedParameter<unsigned long long>(
std::string const&
name,
unsigned long long const& defaultValue)
const {
1303 Entry const* entryPtr = retrieveUntracked(
name);
1304 return entryPtr == 0 ? defaultValue : entryPtr->
getUInt64();
1310 return getEntryPointerOrThrow_(
name)->getUInt64();
1314 std::vector<unsigned long long>
1315 ParameterSet::getUntrackedParameter<std::vector<unsigned long long> >(
std::string const&
name, std::vector<unsigned long long>
const& defaultValue)
const {
1316 Entry const* entryPtr = retrieveUntracked(
name);
1317 return entryPtr == 0 ? defaultValue : entryPtr->
getVUInt64();
1321 std::vector<unsigned long long>
1322 ParameterSet::getUntrackedParameter<std::vector<unsigned long long> >(
std::string const&
name)
const {
1323 return getEntryPointerOrThrow_(
name)->getVUInt64();
1331 ParameterSet::getUntrackedParameter<long long>(
std::string const&
name,
long long const& defaultValue)
const {
1332 Entry const* entryPtr = retrieveUntracked(
name);
1333 return entryPtr == 0 ? defaultValue : entryPtr->
getInt64();
1339 return getEntryPointerOrThrow_(
name)->getInt64();
1343 std::vector<long long>
1344 ParameterSet::getUntrackedParameter<std::vector<long long> >(
std::string const&
name, std::vector<long long>
const& defaultValue)
const {
1345 Entry const* entryPtr = retrieveUntracked(
name);
1346 return entryPtr == 0 ? defaultValue : entryPtr->
getVInt64();
1350 std::vector<long long>
1351 ParameterSet::getUntrackedParameter<std::vector<long long> >(
std::string const&
name)
const {
1352 return getEntryPointerOrThrow_(
name)->getVInt64();
1360 ParameterSet::getUntrackedParameter<double>(
std::string const&
name,
double const& defaultValue)
const {
1361 Entry const* entryPtr = retrieveUntracked(
name);
1362 return entryPtr == 0 ? defaultValue : entryPtr->
getDouble();
1368 return getEntryPointerOrThrow_(
name)->getDouble();
1373 ParameterSet::getUntrackedParameter<std::vector<double> >(
std::string const&
name, std::vector<double>
const& defaultValue)
const {
1374 Entry const* entryPtr = retrieveUntracked(
name);
return entryPtr == 0 ? defaultValue : entryPtr->
getVDouble();
1379 ParameterSet::getUntrackedParameter<std::vector<double> >(
std::string const&
name)
const {
1380 return getEntryPointerOrThrow_(
name)->getVDouble();
1389 Entry const* entryPtr = retrieveUntracked(
name);
1390 return entryPtr == 0 ? defaultValue : entryPtr->
getString();
1396 return getEntryPointerOrThrow_(
name)->getString();
1400 std::vector<std::string>
1401 ParameterSet::getUntrackedParameter<std::vector<std::string> >(
std::string const&
name, std::vector<std::string>
const& defaultValue)
const {
1402 Entry const* entryPtr = retrieveUntracked(
name);
1403 return entryPtr == 0 ? defaultValue : entryPtr->
getVString();
1407 std::vector<std::string>
1408 ParameterSet::getUntrackedParameter<std::vector<std::string> >(
std::string const&
name)
const {
1409 return getEntryPointerOrThrow_(
name)->getVString();
1418 Entry const* entryPtr = retrieveUntracked(
name);
1419 return entryPtr == 0 ? defaultValue : entryPtr->
getFileInPath();
1425 return getEntryPointerOrThrow_(
name)->getFileInPath();
1434 Entry const* entryPtr = retrieveUntracked(
name);
1435 return entryPtr == 0 ? defaultValue : entryPtr->
getInputTag();
1441 return getEntryPointerOrThrow_(
name)->getInputTag();
1445 std::vector<InputTag>
1447 std::vector<InputTag>
const& defaultValue)
const {
1448 Entry const* entryPtr = retrieveUntracked(
name);
1449 return entryPtr == 0 ? defaultValue : entryPtr->
getVInputTag();
1453 std::vector<InputTag>
1454 ParameterSet::getUntrackedParameter<std::vector<InputTag> >(
std::string const&
name)
const {
1455 return getEntryPointerOrThrow_(
name)->getVInputTag();
1464 Entry const* entryPtr = retrieveUntracked(
name);
1465 return entryPtr == 0 ? defaultValue : entryPtr->
getESInputTag();
1471 return getEntryPointerOrThrow_(
name)->getESInputTag();
1475 std::vector<ESInputTag>
1477 std::vector<ESInputTag>
const& defaultValue)
const {
1478 Entry const* entryPtr = retrieveUntracked(
name);
1479 return entryPtr == 0 ? defaultValue : entryPtr->
getVESInputTag();
1483 std::vector<ESInputTag>
1484 ParameterSet::getUntrackedParameter<std::vector<ESInputTag> >(
std::string const&
name)
const {
1485 return getEntryPointerOrThrow_(
name)->getVESInputTag();
1494 Entry const* entryPtr = retrieveUntracked(
name);
1495 return entryPtr == 0 ? defaultValue : entryPtr->
getEventID();
1501 return getEntryPointerOrThrow_(
name)->getEventID();
1505 std::vector<EventID>
1507 std::vector<EventID>
const& defaultValue)
const {
1508 Entry const* entryPtr = retrieveUntracked(
name);
1509 return entryPtr == 0 ? defaultValue : entryPtr->
getVEventID();
1513 std::vector<EventID>
1514 ParameterSet::getUntrackedParameter<std::vector<EventID> >(
std::string const&
name)
const {
1515 return getEntryPointerOrThrow_(
name)->getVEventID();
1524 Entry const* entryPtr = retrieveUntracked(
name);
1531 return getEntryPointerOrThrow_(
name)->getLuminosityBlockID();
1535 std::vector<LuminosityBlockID>
1536 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockID> >(
std::string const&
name,
1537 std::vector<LuminosityBlockID>
const& defaultValue)
const {
1538 Entry const* entryPtr = retrieveUntracked(
name);
1543 std::vector<LuminosityBlockID>
1544 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockID> >(
std::string const&
name)
const {
1545 return getEntryPointerOrThrow_(
name)->getVLuminosityBlockID();
1554 Entry const* entryPtr = retrieveUntracked(
name);
1555 return entryPtr == 0 ? defaultValue : entryPtr->
getEventRange();
1561 return getEntryPointerOrThrow_(
name)->getEventRange();
1565 std::vector<EventRange>
1567 std::vector<EventRange>
const& defaultValue)
const {
1568 Entry const* entryPtr = retrieveUntracked(
name);
1569 return entryPtr == 0 ? defaultValue : entryPtr->
getVEventRange();
1573 std::vector<EventRange>
1574 ParameterSet::getUntrackedParameter<std::vector<EventRange> >(
std::string const&
name)
const {
1575 return getEntryPointerOrThrow_(
name)->getVEventRange();
1584 Entry const* entryPtr = retrieveUntracked(
name);
1590 ParameterSet::getUntrackedParameter<LuminosityBlockRange>(
std::string const&
name)
const {
1591 return getEntryPointerOrThrow_(
name)->getLuminosityBlockRange();
1595 std::vector<LuminosityBlockRange>
1596 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockRange> >(
std::string const&
name,
1597 std::vector<LuminosityBlockRange>
const& defaultValue)
const {
1598 Entry const* entryPtr = retrieveUntracked(
name);
1603 std::vector<LuminosityBlockRange>
1604 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockRange> >(
std::string const&
name)
const {
1605 return getEntryPointerOrThrow_(
name)->getVLuminosityBlockRange();
1614 ParameterSet::getParameter<bool>(
char const*
name)
const {
1615 return retrieve(
name).getBool();
1623 ParameterSet::getParameter<int>(
char const*
name)
const {
1624 return retrieve(
name).getInt32();
1629 ParameterSet::getParameter<std::vector<int> >(
char const*
name)
const {
1630 return retrieve(
name).getVInt32();
1638 ParameterSet::getParameter<long long>(
char const*
name)
const {
1639 return retrieve(
name).getInt64();
1643 std::vector<long long>
1644 ParameterSet::getParameter<std::vector<long long> >(
char const*
name)
const {
1645 return retrieve(
name).getVInt64();
1653 ParameterSet::getParameter<unsigned int>(
char const*
name)
const {
1654 return retrieve(
name).getUInt32();
1658 std::vector<unsigned int>
1659 ParameterSet::getParameter<std::vector<unsigned int> >(
char const*
name)
const {
1660 return retrieve(
name).getVUInt32();
1668 ParameterSet::getParameter<unsigned long long>(
char const*
name)
const {
1669 return retrieve(
name).getUInt64();
1673 std::vector<unsigned long long>
1674 ParameterSet::getParameter<std::vector<unsigned long long> >(
char const*
name)
const {
1675 return retrieve(
name).getVUInt64();
1683 ParameterSet::getParameter<double>(
char const*
name)
const {
1684 return retrieve(
name).getDouble();
1689 ParameterSet::getParameter<std::vector<double> >(
char const*
name)
const {
1690 return retrieve(
name).getVDouble();
1698 ParameterSet::getParameter<std::string>(
char const*
name)
const {
1699 return retrieve(
name).getString();
1703 std::vector<std::string>
1704 ParameterSet::getParameter<std::vector<std::string> >(
char const*
name)
const {
1705 return retrieve(
name).getVString();
1713 ParameterSet::getParameter<FileInPath>(
char const*
name)
const {
1714 return retrieve(
name).getFileInPath();
1722 ParameterSet::getParameter<InputTag>(
char const*
name)
const {
1729 deprecatedInputTagWarning(
name, label);
1733 <<
name <<
" is expected to be InputTag or string (deprecated)";
1740 std::vector<InputTag>
1741 ParameterSet::getParameter<std::vector<InputTag> >(
char const*
name)
const {
1742 return retrieve(
name).getVInputTag();
1750 ParameterSet::getParameter<ESInputTag>(
char const*
name)
const {
1751 return retrieve(
name).getESInputTag();
1758 std::vector<ESInputTag>
1759 ParameterSet::getParameter<std::vector<ESInputTag> >(
char const*
name)
const {
1760 return retrieve(
name).getVESInputTag();
1769 ParameterSet::getParameter<EventID>(
char const*
name)
const {
1770 return retrieve(
name).getEventID();
1777 std::vector<EventID>
1778 ParameterSet::getParameter<std::vector<EventID> >(
char const*
name)
const {
1779 return retrieve(
name).getVEventID();
1787 ParameterSet::getParameter<LuminosityBlockID>(
char const*
name)
const {
1788 return retrieve(
name).getLuminosityBlockID();
1795 std::vector<LuminosityBlockID>
1796 ParameterSet::getParameter<std::vector<LuminosityBlockID> >(
char const*
name)
const {
1797 return retrieve(
name).getVLuminosityBlockID();
1805 ParameterSet::getParameter<EventRange>(
char const*
name)
const {
1806 return retrieve(
name).getEventRange();
1813 std::vector<EventRange>
1814 ParameterSet::getParameter<std::vector<EventRange> >(
char const*
name)
const {
1815 return retrieve(
name).getVEventRange();
1823 ParameterSet::getParameter<LuminosityBlockRange>(
char const*
name)
const {
1824 return retrieve(
name).getLuminosityBlockRange();
1831 std::vector<LuminosityBlockRange>
1832 ParameterSet::getParameter<std::vector<LuminosityBlockRange> >(
char const*
name)
const {
1833 return retrieve(
name).getVLuminosityBlockRange();
1841 ParameterSet::getParameter<ParameterSet>(
char const*
name)
const {
1847 ParameterSet::getParameter<VParameterSet>(
char const*
name)
const {
1848 return getParameterSetVector(
name);
1858 ParameterSet::getUntrackedParameter<bool>(
char const*
name,
bool const& defaultValue)
const {
1859 Entry const* entryPtr = retrieveUntracked(
name);
1860 return entryPtr == 0 ? defaultValue : entryPtr->
getBool();
1865 ParameterSet::getUntrackedParameter<bool>(
char const*
name)
const {
1866 return getEntryPointerOrThrow_(
name)->getBool();
1874 ParameterSet::getUntrackedParameter<int>(
char const*
name,
int const& defaultValue)
const {
1875 Entry const* entryPtr = retrieveUntracked(
name);
1876 return entryPtr == 0 ? defaultValue : entryPtr->
getInt32();
1881 ParameterSet::getUntrackedParameter<int>(
char const*
name)
const {
1882 return getEntryPointerOrThrow_(
name)->getInt32();
1887 ParameterSet::getUntrackedParameter<std::vector<int> >(
char const*
name, std::vector<int>
const& defaultValue)
const {
1888 Entry const* entryPtr = retrieveUntracked(
name);
1889 return entryPtr == 0 ? defaultValue : entryPtr->
getVInt32();
1894 ParameterSet::getUntrackedParameter<std::vector<int> >(
char const*
name)
const {
1895 return getEntryPointerOrThrow_(
name)->getVInt32();
1903 ParameterSet::getUntrackedParameter<unsigned int>(
char const*
name,
unsigned int const& defaultValue)
const {
1904 Entry const* entryPtr = retrieveUntracked(
name);
1905 return entryPtr == 0 ? defaultValue : entryPtr->
getUInt32();
1910 ParameterSet::getUntrackedParameter<unsigned int>(
char const*
name)
const {
1911 return getEntryPointerOrThrow_(
name)->getUInt32();
1915 std::vector<unsigned int>
1916 ParameterSet::getUntrackedParameter<std::vector<unsigned int> >(
char const*
name, std::vector<unsigned int>
const& defaultValue)
const {
1917 Entry const* entryPtr = retrieveUntracked(
name);
1918 return entryPtr == 0 ? defaultValue : entryPtr->
getVUInt32();
1922 std::vector<unsigned int>
1923 ParameterSet::getUntrackedParameter<std::vector<unsigned int> >(
char const*
name)
const {
1924 return getEntryPointerOrThrow_(
name)->getVUInt32();
1932 ParameterSet::getUntrackedParameter<unsigned long long>(
char const*
name,
unsigned long long const& defaultValue)
const {
1933 Entry const* entryPtr = retrieveUntracked(
name);
1934 return entryPtr == 0 ? defaultValue : entryPtr->
getUInt64();
1939 ParameterSet::getUntrackedParameter<unsigned long long>(
char const*
name)
const {
1940 return getEntryPointerOrThrow_(
name)->getUInt64();
1944 std::vector<unsigned long long>
1945 ParameterSet::getUntrackedParameter<std::vector<unsigned long long> >(
char const*
name, std::vector<unsigned long long>
const& defaultValue)
const {
1946 Entry const* entryPtr = retrieveUntracked(
name);
1947 return entryPtr == 0 ? defaultValue : entryPtr->
getVUInt64();
1951 std::vector<unsigned long long>
1952 ParameterSet::getUntrackedParameter<std::vector<unsigned long long> >(
char const*
name)
const {
1953 return getEntryPointerOrThrow_(
name)->getVUInt64();
1961 ParameterSet::getUntrackedParameter<long long>(
char const*
name,
long long const& defaultValue)
const {
1962 Entry const* entryPtr = retrieveUntracked(
name);
1963 return entryPtr == 0 ? defaultValue : entryPtr->
getInt64();
1968 ParameterSet::getUntrackedParameter<long long>(
char const*
name)
const {
1969 return getEntryPointerOrThrow_(
name)->getInt64();
1973 std::vector<long long>
1974 ParameterSet::getUntrackedParameter<std::vector<long long> >(
char const*
name, std::vector<long long>
const& defaultValue)
const {
1975 Entry const* entryPtr = retrieveUntracked(
name);
1976 return entryPtr == 0 ? defaultValue : entryPtr->
getVInt64();
1980 std::vector<long long>
1981 ParameterSet::getUntrackedParameter<std::vector<long long> >(
char const*
name)
const {
1982 return getEntryPointerOrThrow_(
name)->getVInt64();
1990 ParameterSet::getUntrackedParameter<double>(
char const*
name,
double const& defaultValue)
const {
1991 Entry const* entryPtr = retrieveUntracked(
name);
1992 return entryPtr == 0 ? defaultValue : entryPtr->
getDouble();
1997 ParameterSet::getUntrackedParameter<double>(
char const*
name)
const {
1998 return getEntryPointerOrThrow_(
name)->getDouble();
2003 ParameterSet::getUntrackedParameter<std::vector<double> >(
char const*
name, std::vector<double>
const& defaultValue)
const {
2004 Entry const* entryPtr = retrieveUntracked(
name);
return entryPtr == 0 ? defaultValue : entryPtr->
getVDouble();
2009 ParameterSet::getUntrackedParameter<std::vector<double> >(
char const*
name)
const {
2010 return getEntryPointerOrThrow_(
name)->getVDouble();
2018 ParameterSet::getUntrackedParameter<std::string>(
char const*
name,
std::string const& defaultValue)
const {
2019 Entry const* entryPtr = retrieveUntracked(
name);
2020 return entryPtr == 0 ? defaultValue : entryPtr->
getString();
2025 ParameterSet::getUntrackedParameter<std::string>(
char const*
name)
const {
2026 return getEntryPointerOrThrow_(
name)->getString();
2030 std::vector<std::string>
2031 ParameterSet::getUntrackedParameter<std::vector<std::string> >(
char const*
name, std::vector<std::string>
const& defaultValue)
const {
2032 Entry const* entryPtr = retrieveUntracked(
name);
2033 return entryPtr == 0 ? defaultValue : entryPtr->
getVString();
2037 std::vector<std::string>
2038 ParameterSet::getUntrackedParameter<std::vector<std::string> >(
char const*
name)
const {
2039 return getEntryPointerOrThrow_(
name)->getVString();
2047 ParameterSet::getUntrackedParameter<FileInPath>(
char const*
name,
FileInPath const& defaultValue)
const {
2048 Entry const* entryPtr = retrieveUntracked(
name);
2049 return entryPtr == 0 ? defaultValue : entryPtr->
getFileInPath();
2054 ParameterSet::getUntrackedParameter<FileInPath>(
char const*
name)
const {
2055 return getEntryPointerOrThrow_(
name)->getFileInPath();
2063 ParameterSet::getUntrackedParameter<InputTag>(
char const*
name,
InputTag const& defaultValue)
const {
2064 Entry const* entryPtr = retrieveUntracked(
name);
2065 return entryPtr == 0 ? defaultValue : entryPtr->
getInputTag();
2070 ParameterSet::getUntrackedParameter<InputTag>(
char const*
name)
const {
2071 return getEntryPointerOrThrow_(
name)->getInputTag();
2075 std::vector<InputTag>
2076 ParameterSet::getUntrackedParameter<std::vector<InputTag> >(
char const*
name,
2077 std::vector<InputTag>
const& defaultValue)
const {
2078 Entry const* entryPtr = retrieveUntracked(
name);
2079 return entryPtr == 0 ? defaultValue : entryPtr->
getVInputTag();
2083 std::vector<InputTag>
2084 ParameterSet::getUntrackedParameter<std::vector<InputTag> >(
char const*
name)
const {
2085 return getEntryPointerOrThrow_(
name)->getVInputTag();
2093 ParameterSet::getUntrackedParameter<ESInputTag>(
char const*
name,
ESInputTag const& defaultValue)
const {
2094 Entry const* entryPtr = retrieveUntracked(
name);
2095 return entryPtr == 0 ? defaultValue : entryPtr->
getESInputTag();
2100 ParameterSet::getUntrackedParameter<ESInputTag>(
char const*
name)
const {
2101 return getEntryPointerOrThrow_(
name)->getESInputTag();
2105 std::vector<ESInputTag>
2106 ParameterSet::getUntrackedParameter<std::vector<ESInputTag> >(
char const*
name,
2107 std::vector<ESInputTag>
const& defaultValue)
const {
2108 Entry const* entryPtr = retrieveUntracked(
name);
2109 return entryPtr == 0 ? defaultValue : entryPtr->
getVESInputTag();
2113 std::vector<ESInputTag>
2114 ParameterSet::getUntrackedParameter<std::vector<ESInputTag> >(
char const*
name)
const {
2115 return getEntryPointerOrThrow_(
name)->getVESInputTag();
2123 ParameterSet::getUntrackedParameter<EventID>(
char const*
name,
EventID const& defaultValue)
const {
2124 Entry const* entryPtr = retrieveUntracked(
name);
2125 return entryPtr == 0 ? defaultValue : entryPtr->
getEventID();
2130 ParameterSet::getUntrackedParameter<EventID>(
char const*
name)
const {
2131 return getEntryPointerOrThrow_(
name)->getEventID();
2135 std::vector<EventID>
2136 ParameterSet::getUntrackedParameter<std::vector<EventID> >(
char const*
name,
2137 std::vector<EventID>
const& defaultValue)
const {
2138 Entry const* entryPtr = retrieveUntracked(
name);
2139 return entryPtr == 0 ? defaultValue : entryPtr->
getVEventID();
2143 std::vector<EventID>
2144 ParameterSet::getUntrackedParameter<std::vector<EventID> >(
char const*
name)
const {
2145 return getEntryPointerOrThrow_(
name)->getVEventID();
2154 Entry const* entryPtr = retrieveUntracked(
name);
2160 ParameterSet::getUntrackedParameter<LuminosityBlockID>(
char const*
name)
const {
2161 return getEntryPointerOrThrow_(
name)->getLuminosityBlockID();
2165 std::vector<LuminosityBlockID>
2166 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockID> >(
char const*
name,
2167 std::vector<LuminosityBlockID>
const& defaultValue)
const {
2168 Entry const* entryPtr = retrieveUntracked(
name);
2173 std::vector<LuminosityBlockID>
2174 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockID> >(
char const*
name)
const {
2175 return getEntryPointerOrThrow_(
name)->getVLuminosityBlockID();
2183 ParameterSet::getUntrackedParameter<EventRange>(
char const*
name,
EventRange const& defaultValue)
const {
2184 Entry const* entryPtr = retrieveUntracked(
name);
2185 return entryPtr == 0 ? defaultValue : entryPtr->
getEventRange();
2190 ParameterSet::getUntrackedParameter<EventRange>(
char const*
name)
const {
2191 return getEntryPointerOrThrow_(
name)->getEventRange();
2195 std::vector<EventRange>
2196 ParameterSet::getUntrackedParameter<std::vector<EventRange> >(
char const*
name,
2197 std::vector<EventRange>
const& defaultValue)
const {
2198 Entry const* entryPtr = retrieveUntracked(
name);
2199 return entryPtr == 0 ? defaultValue : entryPtr->
getVEventRange();
2203 std::vector<EventRange>
2204 ParameterSet::getUntrackedParameter<std::vector<EventRange> >(
char const*
name)
const {
2205 return getEntryPointerOrThrow_(
name)->getVEventRange();
2214 Entry const* entryPtr = retrieveUntracked(
name);
2220 ParameterSet::getUntrackedParameter<LuminosityBlockRange>(
char const*
name)
const {
2221 return getEntryPointerOrThrow_(
name)->getLuminosityBlockRange();
2225 std::vector<LuminosityBlockRange>
2226 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockRange> >(
char const*
name,
2227 std::vector<LuminosityBlockRange>
const& defaultValue)
const {
2228 Entry const* entryPtr = retrieveUntracked(
name);
2233 std::vector<LuminosityBlockRange>
2234 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockRange> >(
char const*
name)
const {
2235 return getEntryPointerOrThrow_(
name)->getVLuminosityBlockRange();
2243 ParameterSet::getUntrackedParameter<ParameterSet>(
char const*
name,
ParameterSet const& defaultValue)
const {
2244 return getUntrackedParameterSet(
name, defaultValue);
2249 ParameterSet::getUntrackedParameter<VParameterSet>(
char const*
name,
VParameterSet const& defaultValue)
const {
2250 return getUntrackedParameterSetVector(
name, defaultValue);
2256 return getUntrackedParameterSet(
name, defaultValue);
2262 return getUntrackedParameterSetVector(
name, defaultValue);
2267 ParameterSet::getUntrackedParameter<ParameterSet>(
char const*
name)
const {
2268 return getUntrackedParameterSet(
name);
2273 ParameterSet::getUntrackedParameter<VParameterSet>(
char const*
name)
const {
2274 return getUntrackedParameterSetVector(
name);
2280 return getUntrackedParameterSet(
name);
2286 return getUntrackedParameterSetVector(
name);
2295 invalidateRegistration(
name);
2302 invalidateRegistration(
name);
2309 invalidateRegistration(
name);
2316 invalidateRegistration(
name);
2348 std::vector<std::string>
2349 ParameterSet::getParameterNamesForType<ParameterSet>(
bool trackiness)
const {
2350 std::vector<std::string>
output;
2351 getParameterSetNames(output, trackiness);
2356 std::vector<std::string>
2357 ParameterSet::getParameterNamesForType<VParameterSet>(
bool trackiness)
const {
2358 std::vector<std::string>
output;
2359 getParameterSetVectorNames(output, trackiness);
2382 return defaultValue;
2384 return entryPtr->
pset();
2397 <<
"The required ParameterSet '" << name <<
"' was not specified.\n";
2398 return result->
pset();
2419 return entryPtr == 0 ? defaultValue : entryPtr->
vpset();
2432 <<
"The required ParameterSetVector '" << name <<
"' was not specified.\n";
2433 return result->
vpset();
std::vector< unsigned > getVUInt32() const
void setID(ParameterSetID const &id)
ParameterSetID const & mainParameterSetID() const
Entry const & retrieve(char const *) const
std::string toString() const
std::vector< double > getVDouble() const
VParameterSet const & getParameterSetVector(std::string const &name) const
ParameterSetEntry const & retrieveParameterSet(std::string const &) const
Entry const * getEntryPointerOrThrow_(std::string const &name) const
tuple start
Check for commandline option errors.
std::vector< unsigned long long > getVUInt64() const
std::vector< LuminosityBlockID > getVLuminosityBlockID() const
std::auto_ptr< std::vector< ParameterSet > > popVParameterSet(std::string const &name)
bool existsAs(std::string const ¶meterName, bool trackiness=true) const
checks if a parameter exists as a given type
ParameterSet getPSet() const
std::string dump(unsigned int indent=0) const
std::string dump(unsigned int indent=0) const
ParameterSetEntry const * retrieveUntrackedParameterSet(std::string const &) const
bool fromString(std::string const &)
std::string dump(unsigned int indent=0) const
unsigned getUInt32() const
ParameterSetID id() const
VParameterSetEntry const * retrieveUntrackedVParameterSet(std::string const &) const
std::vector< ParameterSet > VParameterSet
size_t getParameterSetVectorNames(std::vector< std::string > &output, bool trackiness=true) const
ParameterSet const & getParameterSet(ParameterSetID const &id)
std::vector< InputTag > getVInputTag() const
bool exists(std::string const ¶meterName) const
checks if a parameter exists
void toStringImp(std::string &, bool useAll) const
void insert(bool ok_to_replace, char const *, Entry const &)
ParameterSet getUntrackedParameterSet(std::string const &name, ParameterSet const &defaultValue) const
void swap(Hash< I > &other)
LuminosityBlockRange getLuminosityBlockRange() const
std::vector< EventID > getVEventID() const
ParameterSet const & getProcessParameterSetContainingModule(ModuleDescription const &moduleDescription)
ParameterSet trackedPart() const
void augment(ParameterSet const &from)
void eraseOrSetUntrackedParameterSet(std::string const &name)
void swap(ParameterSet &other)
U second(std::pair< T, U > const &p)
unsigned long long getUInt64() const
std::vector< FileInPath >::size_type getAllFileInPaths(std::vector< FileInPath > &output) const
ParameterSet const & pset() const
returns the PSet
void copyFrom(ParameterSet const &from, std::string const &name)
long long getInt64() const
VParameterSetEntry * getPSetVectorForUpdate(std::string const &name)
void swap(edm::DataFrameContainer &lhs, edm::DataFrameContainer &rhs)
void addParameter(std::string const &name, T const &value)
std::vector< ParameterSet > getVPSet() const
ParameterSetEntry const * retrieveUnknownParameterSet(std::string const &) const
bool operator==(debugging_allocator< X > const &, debugging_allocator< Y > const &)
void insertVParameterSet(bool okay_to_replace, std::string const &name, VParameterSetEntry const &entry)
InputTag getInputTag() const
std::auto_ptr< ParameterSet > popParameterSet(std::string const &name)
std::vector< ParameterSet > const & vpset() const
returns the VPSet
std::vector< long long > getVInt64() const
VParameterSetEntry const * retrieveUnknownVParameterSet(std::string const &) const
bool split(OutIter result, std::string const &string_to_split, char first, char sep, char last)
std::vector< ESInputTag > getVESInputTag() const
std::vector< std::string > getParameterNames() const
void eraseSimpleParameter(std::string const &name)
void copyForModify(ParameterSet const &other)
bool isRegistered() const
std::vector< EventRange > getVEventRange() const
Hash< ParameterSetType > ParameterSetID
void invalidateRegistration(std::string const &nameOfTracked)
std::string toString() const
static void registerFromString(std::string const &rep)
std::string getParameterAsString(std::string const &name) const
FileInPath getFileInPath() const
psettable const & psetTable() const
void deprecatedInputTagWarning(std::string const &name, std::string const &label) const
ForwardSequence::const_iterator find_in_all(ForwardSequence const &s, Datum const &d)
wrappers for std::find
ParameterSet const & getParameterSet(std::string const &) const
std::auto_ptr< ParameterDescriptionNode > operator&&(ParameterDescriptionNode const &node_left, ParameterDescriptionNode const &node_right)
std::string toString() const
size_t getNamesByCode_(char code, bool trackiness, std::vector< std::string > &output) const
void insertParameterSet(bool okay_to_replace, std::string const &name, ParameterSetEntry const &entry)
void toDigest(cms::Digest &digest) const
std::vector< int > getVInt32() const
std::string toString() const
VParameterSetEntry const & retrieveVParameterSet(std::string const &) const
LuminosityBlockID getLuminosityBlockID() const
void allToString(std::string &result) const
ParameterSet & operator=(ParameterSet const &other)
vpsettable const & vpsetTable() const
EventRange getEventRange() const
VParameterSet getUntrackedParameterSetVector(std::string const &name, VParameterSet const &defaultValue) const
std::vector< LuminosityBlockRange > getVLuminosityBlockRange() const
ESInputTag getESInputTag() const
Entry const * retrieveUntracked(char const *) const
size_t getParameterSetNames(std::vector< std::string > &output, bool trackiness=true) const
bool insertMapped(value_type const &v)
Entry const * retrieveUnknown(char const *) const
T first(std::pair< T, U > const &p)
table const & tbl() const
std::ostream & operator<<(std::ostream &ost, const HLTGlobalStatus &hlt)
Formatted printout of trigger tbale.
std::string toString() const
static ParameterSetID emptyParameterSetID()
ParameterSet const & registerIt()
bool isTransientEqual(ParameterSet const &a, ParameterSet const &b)
std::vector< std::string > getVString() const
tuple size
Write out results.
std::string getString() const
static Registry * instance()
void append(std::string const &s)
ParameterSet * getPSetForUpdate(std::string const &name, bool &isTracked)
EventID getEventID() const