• Main Page
  • Namespaces
  • Classes
  • Files
  • File List
  • File Members

BCMTFChannel.h

Go to the documentation of this file.
00001 #ifndef __BCMTFCHANNEL__H
00002 #define __BCMTFCHANNEL__H
00003 
00018 /*
00019  * Copyright (C) 2008-2012, Daniel Kollar and Kevin Kroeninger.
00020  * All rights reserved.
00021  *
00022  * For the licensing terms see doc/COPYING.
00023  */
00024 
00025 // ---------------------------------------------------------
00026 
00027 #include <string>
00028 #include <vector>
00029 
00030 class BCMTFTemplate;
00031 class BCMTFSystematicVariation;
00032 
00033 // ---------------------------------------------------------
00034 class BCMTFChannel
00035 {
00036 
00037    public:
00038 
00039       // Constructors and destructor
00040       BCMTFChannel(const char * name);
00041       ~BCMTFChannel();
00042 
00043       // setters
00044 
00045       // set name
00046       void SetName(const char * name)
00047          { fName = name; };
00048 
00049       // set data
00050       void SetData(BCMTFTemplate * bctemplate)
00051          { fData = bctemplate; };
00052 
00053       // set a flag for using this channel or not
00054       void SetFlagChannelActive(bool flag)
00055          { fFlagChannelActive = flag; };
00056 
00057       // getters
00058       std::string GetName()
00059          { return fName; };
00060 
00061       // return a template
00062       BCMTFTemplate * GetTemplate(int index)
00063          { return fTemplateContainer.at(index); };
00064 
00065       // return a systematicvariation
00066       BCMTFSystematicVariation * GetSystematicVariation(int index)
00067          { return fSystematicVariationContainer.at(index); };
00068 
00069       // return the data
00070       BCMTFTemplate * GetData()
00071          { return fData; };
00072 
00073       // return flag
00074       bool GetFlagChannelActive()
00075          { return fFlagChannelActive; };
00076 
00077       // misc
00078 
00079       // add a template
00080       void AddTemplate(BCMTFTemplate * bctemplate)
00081          { fTemplateContainer.push_back(bctemplate); };
00082 
00083       // add a systematic variation
00084       void AddSystematicVariation(BCMTFSystematicVariation * variation)
00085          { fSystematicVariationContainer.push_back(variation); };
00086 
00087       // print templates
00088       void PrintTemplates(const char * filename);
00089 
00090       // print template with systematics
00091       void PrintTemplate(int index, const char * filename);
00092 
00093  private:
00094 
00095       // name of the channel
00096       std::string fName;
00097 
00098       // the data set
00099       BCMTFTemplate * fData;
00100 
00101       // a container of templates
00102       std::vector<BCMTFTemplate *> fTemplateContainer;
00103 
00104       // a container of systematics
00105       std::vector<BCMTFSystematicVariation *> fSystematicVariationContainer;
00106 
00107       // flag: channel is used (true) or not (false) in fit
00108       bool fFlagChannelActive;
00109 
00110 };
00111 // ---------------------------------------------------------
00112 
00113 #endif
00114 

Generated by  doxygen 1.7.1