1 #ifndef FWCore_ParameterSet_ParameterSet_h
2 #define FWCore_ParameterSet_ParameterSet_h
82 void insert(
bool ok_to_replace,
char const* ,
Entry const&);
185 std::vector<std::string>
names = getParameterNamesForType<T>(trackiness);
186 return std::find(names.begin(), names.end(), parameterName) != names.end();
193 std::vector<std::string>
result;
197 Entry type_translator(
"", value, trackiness);
198 char type_code = type_translator.
typeCode();
228 bool trackiness =
true)
const;
236 bool trackiness=
true)
const;
251 typedef std::map<std::string, Entry>
table;
254 typedef std::map<std::string, ParameterSetEntry>
psettable;
257 typedef std::map<std::string, VParameterSetEntry>
vpsettable;
265 bool isTracked =
false;
313 std::vector<std::string>&
output)
const;
353 ParameterSet::getParameter<std::vector<int> >(
std::string const&
name)
const;
363 std::vector<long long>
364 ParameterSet::getParameter<std::vector<long long> >(
std::string const&
name)
const;
371 ParameterSet::getParameter<unsigned int>(
std::string const&
name)
const;
374 std::vector<unsigned int>
375 ParameterSet::getParameter<std::vector<unsigned int> >(
std::string const&
name)
const;
382 ParameterSet::getParameter<unsigned long long>(
std::string const&
name)
const;
385 std::vector<unsigned long long>
386 ParameterSet::getParameter<std::vector<unsigned long long> >(
std::string const&
name)
const;
397 ParameterSet::getParameter<std::vector<double> >(
std::string const&
name)
const;
404 ParameterSet::getParameter<std::string>(
std::string const&
name)
const;
407 std::vector<std::string>
408 ParameterSet::getParameter<std::vector<std::string> >(
std::string const&
name)
const;
420 std::vector<std::string>
421 ParameterSet::getParameterNamesForType<FileInPath>(
bool trackiness)
const;
434 std::vector<InputTag>
435 ParameterSet::getParameter<std::vector<InputTag> >(
std::string const&
name)
const;
448 std::vector<ESInputTag>
449 ParameterSet::getParameter<std::vector<ESInputTag> >(
std::string const&
name)
const;
463 ParameterSet::getParameter<std::vector<EventID> >(
std::string const&
name)
const;
470 ParameterSet::getParameter<LuminosityBlockID>(
std::string const&
name)
const;
476 std::vector<LuminosityBlockID>
477 ParameterSet::getParameter<std::vector<LuminosityBlockID> >(
std::string const&
name)
const;
490 std::vector<EventRange>
491 ParameterSet::getParameter<std::vector<EventRange> >(
std::string const&
name)
const;
498 ParameterSet::getParameter<LuminosityBlockRange>(
std::string const&
name)
const;
504 std::vector<LuminosityBlockRange>
505 ParameterSet::getParameter<std::vector<LuminosityBlockRange> >(
std::string const&
name)
const;
512 ParameterSet::getParameter<ParameterSet>(
std::string const&
name)
const;
516 ParameterSet::getParameter<VParameterSet>(
std::string const&
name)
const;
557 ParameterSet::getUntrackedParameter<bool>(
std::string const&
name,
bool const& defaultValue)
const;
561 ParameterSet::getUntrackedParameter<bool>(
std::string const&
name)
const;
568 ParameterSet::getUntrackedParameter<int>(
std::string const&
name,
int const& defaultValue)
const;
572 ParameterSet::getUntrackedParameter<int>(
std::string const&
name)
const;
576 ParameterSet::getUntrackedParameter<std::vector<int> >(
std::string const&
name, std::vector<int>
const& defaultValue)
const;
580 ParameterSet::getUntrackedParameter<std::vector<int> >(
std::string const&
name)
const;
587 ParameterSet::getUntrackedParameter<unsigned int>(
std::string const&
name,
unsigned int const& defaultValue)
const;
591 ParameterSet::getUntrackedParameter<unsigned int>(
std::string const&
name)
const;
594 std::vector<unsigned int>
595 ParameterSet::getUntrackedParameter<std::vector<unsigned int> >(
std::string const&
name, std::vector<unsigned int>
const& defaultValue)
const;
598 std::vector<unsigned int>
599 ParameterSet::getUntrackedParameter<std::vector<unsigned int> >(
std::string const&
name)
const;
606 ParameterSet::getUntrackedParameter<unsigned long long>(
std::string const&
name,
unsigned long long const& defaultValue)
const;
610 ParameterSet::getUntrackedParameter<unsigned long long>(
std::string const&
name)
const;
613 std::vector<unsigned long long>
614 ParameterSet::getUntrackedParameter<std::vector<unsigned long long> >(
std::string const&
name, std::vector<unsigned long long>
const& defaultValue)
const;
617 std::vector<unsigned long long>
618 ParameterSet::getUntrackedParameter<std::vector<unsigned long long> >(
std::string const&
name)
const;
625 ParameterSet::getUntrackedParameter<long long>(
std::string const&
name,
long long const& defaultValue)
const;
629 ParameterSet::getUntrackedParameter<long long>(
std::string const&
name)
const;
632 std::vector<long long>
633 ParameterSet::getUntrackedParameter<std::vector<long long> >(
std::string const&
name, std::vector<long long>
const& defaultValue)
const;
636 std::vector<long long>
637 ParameterSet::getUntrackedParameter<std::vector<long long> >(
std::string const&
name)
const;
644 ParameterSet::getUntrackedParameter<double>(
std::string const&
name,
double const& defaultValue)
const;
648 ParameterSet::getUntrackedParameter<double>(
std::string const&
name)
const;
652 ParameterSet::getUntrackedParameter<std::vector<double> >(
std::string const&
name, std::vector<double>
const& defaultValue)
const;
656 ParameterSet::getUntrackedParameter<std::vector<double> >(
std::string const&
name)
const;
667 ParameterSet::getUntrackedParameter<std::string>(
std::string const&
name)
const;
670 std::vector<std::string>
671 ParameterSet::getUntrackedParameter<std::vector<std::string> >(
std::string const&
name, std::vector<std::string>
const& defaultValue)
const;
674 std::vector<std::string>
675 ParameterSet::getUntrackedParameter<std::vector<std::string> >(
std::string const&
name)
const;
686 ParameterSet::getUntrackedParameter<FileInPath>(
std::string const&
name)
const;
693 ParameterSet::getUntrackedParameter<InputTag>(
std::string const&
name, InputTag
const& defaultValue)
const;
697 ParameterSet::getUntrackedParameter<InputTag>(
std::string const&
name)
const;
700 std::vector<InputTag>
701 ParameterSet::getUntrackedParameter<std::vector<InputTag> >(
std::string const&
name,
702 std::vector<InputTag>
const& defaultValue)
const;
705 std::vector<InputTag>
706 ParameterSet::getUntrackedParameter<std::vector<InputTag> >(
std::string const&
name)
const;
713 ParameterSet::getUntrackedParameter<EventID>(
std::string const&
name, EventID
const& defaultValue)
const;
717 ParameterSet::getUntrackedParameter<EventID>(
std::string const&
name)
const;
721 ParameterSet::getUntrackedParameter<std::vector<EventID> >(
std::string const&
name,
722 std::vector<EventID>
const& defaultValue)
const;
725 ParameterSet::getUntrackedParameter<std::vector<EventID> >(
std::string const&
name)
const;
732 ParameterSet::getUntrackedParameter<LuminosityBlockID>(
std::string const&
name, LuminosityBlockID
const& defaultValue)
const;
736 ParameterSet::getUntrackedParameter<LuminosityBlockID>(
std::string const&
name)
const;
739 std::vector<LuminosityBlockID>
740 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockID> >(
std::string const&
name,
741 std::vector<LuminosityBlockID>
const& defaultValue)
const;
743 std::vector<LuminosityBlockID>
744 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockID> >(
std::string const&
name)
const;
751 ParameterSet::getUntrackedParameter<EventRange>(
std::string const&
name, EventRange
const& defaultValue)
const;
755 ParameterSet::getUntrackedParameter<EventRange>(
std::string const&
name)
const;
758 std::vector<EventRange>
759 ParameterSet::getUntrackedParameter<std::vector<EventRange> >(
std::string const&
name,
760 std::vector<EventRange>
const& defaultValue)
const;
762 std::vector<EventRange>
763 ParameterSet::getUntrackedParameter<std::vector<EventRange> >(
std::string const&
name)
const;
774 ParameterSet::getUntrackedParameter<LuminosityBlockRange>(
std::string const&
name)
const;
777 std::vector<LuminosityBlockRange>
778 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockRange> >(
std::string const&
name,
779 std::vector<LuminosityBlockRange>
const& defaultValue)
const;
781 std::vector<LuminosityBlockRange>
782 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockRange> >(
std::string const&
name)
const;
790 ParameterSet::getParameter<bool>(
char const*
name)
const;
797 ParameterSet::getParameter<int>(
char const*
name)
const;
801 ParameterSet::getParameter<std::vector<int> >(
char const*
name)
const;
808 ParameterSet::getParameter<long long>(
char const*
name)
const;
811 std::vector<long long>
812 ParameterSet::getParameter<std::vector<long long> >(
char const*
name)
const;
819 ParameterSet::getParameter<unsigned int>(
char const*
name)
const;
822 std::vector<unsigned int>
823 ParameterSet::getParameter<std::vector<unsigned int> >(
char const*
name)
const;
830 ParameterSet::getParameter<unsigned long long>(
char const*
name)
const;
833 std::vector<unsigned long long>
834 ParameterSet::getParameter<std::vector<unsigned long long> >(
char const*
name)
const;
841 ParameterSet::getParameter<double>(
char const*
name)
const;
845 ParameterSet::getParameter<std::vector<double> >(
char const*
name)
const;
852 ParameterSet::getParameter<std::string>(
char const*
name)
const;
855 std::vector<std::string>
856 ParameterSet::getParameter<std::vector<std::string> >(
char const*
name)
const;
863 ParameterSet::getParameter<FileInPath>(
char const*
name)
const;
870 ParameterSet::getParameter<InputTag>(
char const*
name)
const;
876 std::vector<InputTag>
877 ParameterSet::getParameter<std::vector<InputTag> >(
char const*
name)
const;
884 ParameterSet::getParameter<EventID>(
char const*
name)
const;
891 ParameterSet::getParameter<std::vector<EventID> >(
char const*
name)
const;
898 ParameterSet::getParameter<LuminosityBlockID>(
char const*
name)
const;
904 std::vector<LuminosityBlockID>
905 ParameterSet::getParameter<std::vector<LuminosityBlockID> >(
char const*
name)
const;
912 ParameterSet::getParameter<EventRange>(
char const*
name)
const;
918 std::vector<EventRange>
919 ParameterSet::getParameter<std::vector<EventRange> >(
char const*
name)
const;
926 ParameterSet::getParameter<LuminosityBlockRange>(
char const*
name)
const;
932 std::vector<LuminosityBlockRange>
933 ParameterSet::getParameter<std::vector<LuminosityBlockRange> >(
char const*
name)
const;
940 ParameterSet::getParameter<ParameterSet>(
char const*
name)
const;
944 ParameterSet::getParameter<VParameterSet>(
char const*
name)
const;
953 ParameterSet::getUntrackedParameter<bool>(
char const*
name,
bool const& defaultValue)
const;
957 ParameterSet::getUntrackedParameter<bool>(
char const*
name)
const;
964 ParameterSet::getUntrackedParameter<int>(
char const*
name,
int const& defaultValue)
const;
968 ParameterSet::getUntrackedParameter<int>(
char const*
name)
const;
972 ParameterSet::getUntrackedParameter<std::vector<int> >(
char const*
name, std::vector<int>
const& defaultValue)
const;
976 ParameterSet::getUntrackedParameter<std::vector<int> >(
char const*
name)
const;
983 ParameterSet::getUntrackedParameter<unsigned int>(
char const*
name,
unsigned int const& defaultValue)
const;
987 ParameterSet::getUntrackedParameter<unsigned int>(
char const*
name)
const;
990 std::vector<unsigned int>
991 ParameterSet::getUntrackedParameter<std::vector<unsigned int> >(
char const*
name, std::vector<unsigned int>
const& defaultValue)
const;
994 std::vector<unsigned int>
995 ParameterSet::getUntrackedParameter<std::vector<unsigned int> >(
char const*
name)
const;
1002 ParameterSet::getUntrackedParameter<unsigned long long>(
char const*
name,
unsigned long long const& defaultValue)
const;
1006 ParameterSet::getUntrackedParameter<unsigned long long>(
char const*
name)
const;
1009 std::vector<unsigned long long>
1010 ParameterSet::getUntrackedParameter<std::vector<unsigned long long> >(
char const*
name, std::vector<unsigned long long>
const& defaultValue)
const;
1013 std::vector<unsigned long long>
1014 ParameterSet::getUntrackedParameter<std::vector<unsigned long long> >(
char const*
name)
const;
1021 ParameterSet::getUntrackedParameter<long long>(
char const*
name,
long long const& defaultValue)
const;
1025 ParameterSet::getUntrackedParameter<long long>(
char const*
name)
const;
1028 std::vector<long long>
1029 ParameterSet::getUntrackedParameter<std::vector<long long> >(
char const*
name, std::vector<long long>
const& defaultValue)
const;
1032 std::vector<long long>
1033 ParameterSet::getUntrackedParameter<std::vector<long long> >(
char const*
name)
const;
1040 ParameterSet::getUntrackedParameter<double>(
char const*
name,
double const& defaultValue)
const;
1044 ParameterSet::getUntrackedParameter<double>(
char const*
name)
const;
1048 ParameterSet::getUntrackedParameter<std::vector<double> >(
char const*
name, std::vector<double>
const& defaultValue)
const;
1052 ParameterSet::getUntrackedParameter<std::vector<double> >(
char const*
name)
const;
1059 ParameterSet::getUntrackedParameter<std::string>(
char const*
name,
std::string const& defaultValue)
const;
1063 ParameterSet::getUntrackedParameter<std::string>(
char const*
name)
const;
1066 std::vector<std::string>
1067 ParameterSet::getUntrackedParameter<std::vector<std::string> >(
char const*
name, std::vector<std::string>
const& defaultValue)
const;
1070 std::vector<std::string>
1071 ParameterSet::getUntrackedParameter<std::vector<std::string> >(
char const*
name)
const;
1078 ParameterSet::getUntrackedParameter<FileInPath>(
char const*
name,
FileInPath const& defaultValue)
const;
1082 ParameterSet::getUntrackedParameter<FileInPath>(
char const*
name)
const;
1089 ParameterSet::getUntrackedParameter<InputTag>(
char const*
name, InputTag
const& defaultValue)
const;
1093 ParameterSet::getUntrackedParameter<InputTag>(
char const*
name)
const;
1096 std::vector<InputTag>
1097 ParameterSet::getUntrackedParameter<std::vector<InputTag> >(
char const*
name,
1098 std::vector<InputTag>
const& defaultValue)
const;
1101 std::vector<InputTag>
1102 ParameterSet::getUntrackedParameter<std::vector<InputTag> >(
char const*
name)
const;
1109 ParameterSet::getUntrackedParameter<EventID>(
char const*
name, EventID
const& defaultValue)
const;
1113 ParameterSet::getUntrackedParameter<EventID>(
char const*
name)
const;
1116 std::vector<EventID>
1117 ParameterSet::getUntrackedParameter<std::vector<EventID> >(
char const*
name,
1118 std::vector<EventID>
const& defaultValue)
const;
1120 std::vector<EventID>
1121 ParameterSet::getUntrackedParameter<std::vector<EventID> >(
char const*
name)
const;
1128 ParameterSet::getUntrackedParameter<LuminosityBlockID>(
char const*
name, LuminosityBlockID
const& defaultValue)
const;
1132 ParameterSet::getUntrackedParameter<LuminosityBlockID>(
char const*
name)
const;
1135 std::vector<LuminosityBlockID>
1136 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockID> >(
char const*
name,
1137 std::vector<LuminosityBlockID>
const& defaultValue)
const;
1139 std::vector<LuminosityBlockID>
1140 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockID> >(
char const*
name)
const;
1147 ParameterSet::getUntrackedParameter<EventRange>(
char const*
name, EventRange
const& defaultValue)
const;
1151 ParameterSet::getUntrackedParameter<EventRange>(
char const*
name)
const;
1154 std::vector<EventRange>
1155 ParameterSet::getUntrackedParameter<std::vector<EventRange> >(
char const*
name,
1156 std::vector<EventRange>
const& defaultValue)
const;
1158 std::vector<EventRange>
1159 ParameterSet::getUntrackedParameter<std::vector<EventRange> >(
char const*
name)
const;
1166 ParameterSet::getUntrackedParameter<LuminosityBlockRange>(
char const*
name,
LuminosityBlockRange const& defaultValue)
const;
1170 ParameterSet::getUntrackedParameter<LuminosityBlockRange>(
char const*
name)
const;
1173 std::vector<LuminosityBlockRange>
1174 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockRange> >(
char const*
name,
1175 std::vector<LuminosityBlockRange>
const& defaultValue)
const;
1177 std::vector<LuminosityBlockRange>
1178 ParameterSet::getUntrackedParameter<std::vector<LuminosityBlockRange> >(
char const*
name)
const;
1185 ParameterSet::getUntrackedParameter<ParameterSet>(
char const*
name,
ParameterSet const& defaultValue)
const;
1193 ParameterSet::getUntrackedParameter<ParameterSet>(
char const*
name)
const;
1197 ParameterSet::getUntrackedParameter<ParameterSet>(
std::string const&
name)
const;
1201 ParameterSet::getUntrackedParameter<VParameterSet>(
char const*
name,
VParameterSet const& defaultValue)
const;
1205 ParameterSet::getUntrackedParameter<VParameterSet>(
char const*
name)
const;
1213 ParameterSet::getUntrackedParameter<VParameterSet>(
std::string const&
name)
const;
1216 std::vector<std::string>
1217 ParameterSet::getParameterNamesForType<ParameterSet>(
bool trackiness)
const;
1220 std::vector<std::string>
1221 ParameterSet::getParameterNamesForType<VParameterSet>(
bool trackiness)
const;
void setID(ParameterSetID const &id)
T getParameter(std::string const &) const
Entry const & retrieve(char const *) const
std::string toString() const
T getUntrackedParameter(std::string const &, T const &) const
VParameterSet const & getParameterSetVector(std::string const &name) const
ParameterSetEntry const & retrieveParameterSet(std::string const &) const
Entry const * getEntryPointerOrThrow_(std::string const &name) 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
std::map< std::string, ParameterSetEntry > psettable
static const HistoName names[]
ParameterSetEntry const * retrieveUntrackedParameterSet(std::string const &) const
bool fromString(std::string const &)
std::string dump(unsigned int indent=0) 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)
bool exists(std::string const ¶meterName) const
checks if a parameter exists
bool operator!=(debugging_allocator< X > const &, debugging_allocator< Y > const &)
void toStringImp(std::string &, bool useAll) const
void insert(bool ok_to_replace, char const *, Entry const &)
void addUntrackedParameter(char const *name, T const &value)
ParameterSet getUntrackedParameterSet(std::string const &name, ParameterSet const &defaultValue) const
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
void swap(Association< C > &lhs, Association< C > &rhs)
ParameterSet trackedPart() const
void augment(ParameterSet const &from)
void eraseOrSetUntrackedParameterSet(std::string const &name)
void swap(ParameterSet &other)
std::vector< std::string > getParameterNamesForType(bool trackiness=true) const
std::vector< FileInPath >::size_type getAllFileInPaths(std::vector< FileInPath > &output) const
void copyFrom(ParameterSet const &from, std::string const &name)
VParameterSetEntry * getPSetVectorForUpdate(std::string const &name)
void addParameter(std::string const &name, T const &value)
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)
std::auto_ptr< ParameterSet > popParameterSet(std::string const &name)
VParameterSetEntry const * retrieveUnknownVParameterSet(std::string const &) const
std::vector< std::string > getParameterNames() const
void eraseSimpleParameter(std::string const &name)
void copyForModify(ParameterSet const &other)
bool isRegistered() const
Hash< ParameterSetType > ParameterSetID
void invalidateRegistration(std::string const &nameOfTracked)
friend std::ostream & operator<<(std::ostream &os, ParameterSet const &pset)
static void registerFromString(std::string const &rep)
std::string getParameterAsString(std::string const &name) const
psettable const & psetTable() const
void deprecatedInputTagWarning(std::string const &name, std::string const &label) const
void addParameter(char const *name, T const &value)
ParameterSet const & getParameterSet(std::string const &) const
void addUntrackedParameter(std::string const &name, T const &value)
std::auto_ptr< ParameterDescriptionNode > operator&&(ParameterDescriptionNode const &node_left, ParameterDescriptionNode const &node_right)
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
ParameterSetID trackedID() const
VParameterSetEntry const & retrieveVParameterSet(std::string const &) const
std::map< std::string, Entry > table
void allToString(std::string &result) const
ParameterSet & operator=(ParameterSet const &other)
std::map< std::string, VParameterSetEntry > vpsettable
vpsettable const & vpsetTable() const
VParameterSet getUntrackedParameterSetVector(std::string const &name, VParameterSet const &defaultValue) const
Entry const * retrieveUntracked(char const *) const
size_t getParameterSetNames(std::vector< std::string > &output, bool trackiness=true) const
Entry const * retrieveUnknown(char const *) const
table const & tbl() const
static ParameterSetID emptyParameterSetID()
ParameterSet const & registerIt()
bool isTransientEqual(ParameterSet const &a, ParameterSet const &b)
ParameterSet * getPSetForUpdate(std::string const &name)
ParameterSet * getPSetForUpdate(std::string const &name, bool &isTracked)