CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
MixingInputConfig Class Reference

#include <MixingModuleConfig.h>

Public Member Functions

const double averageNumber () const
 
const int fixedOutOfTime () const
 
const int itype () const
 
int itype (std::string s) const
 
 MixingInputConfig ()
 
const int outOfTime () const
 
const std::vector< int > & probFunctionVariable () const
 
const std::vector< double > & probValue () const
 
void read (edm::ParameterSet &pset)
 
std::string type () const
 
virtual ~MixingInputConfig ()
 

Private Attributes

double an_
 
 COND_SERIALIZABLE
 
std::vector< double > dp_
 
std::vector< int > dpfv_
 
int ioot_
 
int moot_
 
int t_
 

Detailed Description

Definition at line 14 of file MixingModuleConfig.h.

Constructor & Destructor Documentation

MixingInputConfig::MixingInputConfig ( )

Definition at line 9 of file MixingModuleConfig.cc.

9 {}
virtual MixingInputConfig::~MixingInputConfig ( )
inlinevirtual

Definition at line 17 of file MixingModuleConfig.h.

17 {};

Member Function Documentation

const double MixingInputConfig::averageNumber ( ) const
inline

Definition at line 40 of file MixingModuleConfig.h.

References an_.

Referenced by edm::PileUp::reload().

40 { return an_;}
const int MixingInputConfig::fixedOutOfTime ( ) const
inline

Definition at line 45 of file MixingModuleConfig.h.

References ioot_.

Referenced by edm::PileUp::reload().

45 { return ioot_;}
const int MixingInputConfig::itype ( ) const
inline

Definition at line 19 of file MixingModuleConfig.h.

References t_.

Referenced by read().

19 {return t_;}
int MixingInputConfig::itype ( std::string  s) const
inline

Definition at line 31 of file MixingModuleConfig.h.

31  {
32  if (s=="none") return 0;
33  if (s=="fixed") return 1;
34  if (s=="poisson") return 2;
35  if (s=="histo") return 3;
36  if (s=="probFunction") return 4;
37  return 0;
38  }
const int MixingInputConfig::outOfTime ( ) const
inline

Definition at line 44 of file MixingModuleConfig.h.

References moot_.

Referenced by edm::PileUp::reload().

44 { return moot_;}
const std::vector<int>& MixingInputConfig::probFunctionVariable ( ) const
inline

Definition at line 42 of file MixingModuleConfig.h.

References dpfv_.

Referenced by edm::PileUp::reload().

42 { return dpfv_;}
std::vector< int > dpfv_
const std::vector<double>& MixingInputConfig::probValue ( ) const
inline

Definition at line 43 of file MixingModuleConfig.h.

References dp_.

Referenced by edm::PileUp::reload().

43 { return dp_;}
std::vector< double > dp_
void MixingInputConfig::read ( edm::ParameterSet pset)

Definition at line 34 of file MixingModuleConfig.cc.

References an_, dp_, dpfv_, edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), ioot_, itype(), moot_, AlCaHLTBitMon_QueryRunRegistry::string, and t_.

Referenced by Vispa.Plugins.EdmBrowser.EdmDataAccessor.EdmDataAccessor::goto(), and Vispa.Plugins.EdmBrowser.EdmDataAccessor.EdmDataAccessor::setFilterBranches().

34  {
35  t_=itype(pset.getParameter<std::string>("type"));
36  an_=0;
37  // ia_=0;
38  dpfv_.clear();
39  dp_.clear();
40  moot_=0;
41  ioot_=0;
42 
43  switch(t_){
44  case 1:
45  an_=pset.getParameter<double>("averageNumber");
46  break;
47  case 2:
48  an_=pset.getParameter<double>("averageNumber");
49  break;
50  case 3:
51  //not supposed to be valid
52  case 4:
53  dpfv_=pset.getParameter<edm::ParameterSet>("nbPileupEvents").getParameter<std::vector<int> >("probFunctionVariable");
54  dp_=pset.getParameter<edm::ParameterSet>("nbPileupEvents").getParameter<std::vector<double> >("probValue");
55  break;
56  }
57 
58  if (pset.getUntrackedParameter<bool>("manage_OOT"))
59  {
60  std::string OOT_type = pset.getUntrackedParameter<std::string>("OOT_type");
61 
62  if(OOT_type == "Poisson" || OOT_type == "poisson")
63  moot_=2;
64  else if (OOT_type == "Fixed" || OOT_type == "fixed") {
65  moot_=1;
66  ioot_=pset.getUntrackedParameter<int>("intFixed_OOT", -1);
67  }
68  }
69 }
T getParameter(std::string const &) const
T getUntrackedParameter(std::string const &, T const &) const
std::vector< double > dp_
std::vector< int > dpfv_
const int itype() const
std::string MixingInputConfig::type ( ) const
inline

Definition at line 20 of file MixingModuleConfig.h.

References t_.

Referenced by cuy.ValElement::__init__(), Vispa.Plugins.ConfigEditor.ConfigDataAccessor.ConfigDataAccessor::inputCommands(), operator<<(), Vispa.Plugins.ConfigEditor.ConfigDataAccessor.ConfigDataAccessor::outputCommands(), Vispa.Plugins.ConfigEditor.ConfigDataAccessor.ConfigDataAccessor::outputEventContent(), Vispa.Plugins.ConfigEditor.ConfigDataAccessor.ConfigDataAccessor::properties(), and edm::PileUp::reload().

20  {
21  switch(t_){
22  case 0: return "none";
23  case 1: return "fixed";
24  case 2: return "poisson";
25  case 3: return "histo";
26  case 4: return "probFunction";
27  // FIX ME: add default
28  }
29  return "";
30  }

Member Data Documentation

double MixingInputConfig::an_
private

Definition at line 51 of file MixingModuleConfig.h.

Referenced by averageNumber(), and read().

MixingInputConfig::COND_SERIALIZABLE
private

Definition at line 59 of file MixingModuleConfig.h.

std::vector<double> MixingInputConfig::dp_
private

Definition at line 54 of file MixingModuleConfig.h.

Referenced by probValue(), and read().

std::vector<int> MixingInputConfig::dpfv_
private

Definition at line 53 of file MixingModuleConfig.h.

Referenced by probFunctionVariable(), and read().

int MixingInputConfig::ioot_
private

Definition at line 56 of file MixingModuleConfig.h.

Referenced by fixedOutOfTime(), and read().

int MixingInputConfig::moot_
private

Definition at line 55 of file MixingModuleConfig.h.

Referenced by outOfTime(), and read().

int MixingInputConfig::t_
private

Definition at line 50 of file MixingModuleConfig.h.

Referenced by itype(), read(), and type().