#include "RooFit.h"
#include "RooArgSet.h"
#include "RooArgSet.h"
#include "RooAbsHiddenReal.h"
#include "RooCategory.h"
ClassImp(RooAbsHiddenReal)
;
RooCategory* RooAbsHiddenReal::_dummyBlindState = 0;
RooAbsHiddenReal::RooAbsHiddenReal(const char *name, const char *title, const char* unit)
: RooAbsReal(name,title,unit),
_state("state","Blinding state",this,dummyBlindState())
{
}
RooAbsHiddenReal::RooAbsHiddenReal(const char *name, const char *title, RooAbsCategory& blindState, const char* unit)
: RooAbsReal(name,title,unit),
_state("state","Blinding state",this,blindState)
{
}
RooAbsHiddenReal::RooAbsHiddenReal(const RooAbsHiddenReal& other, const char* name) :
RooAbsReal(other, name),
_state("state",this,other._state)
{
}
RooAbsHiddenReal::~RooAbsHiddenReal()
{
}
void RooAbsHiddenReal::printToStream(ostream& os, PrintOption opt, TString indent) const
{
if (isHidden()) {
os << indent << "RooAbsHiddenReal: " << GetName() << " : (value hidden) " ;
if(!_unit.IsNull()) os << ' ' << _unit;
printAttribList(os) ;
os << endl ;
} else {
RooAbsReal::printToStream(os,opt,indent) ;
}
}
Bool_t RooAbsHiddenReal::readFromStream(istream& is, Bool_t compact, Bool_t verbose)
{
if (isHidden()) {
cout << "RooAbsHiddenReal::readFromStream(" << GetName() << "): not allowed" << endl ;
return kTRUE ;
} else {
return readFromStream(is,compact,verbose) ;
}
}
void RooAbsHiddenReal::writeToStream(ostream& os, Bool_t compact) const
{
if (isHidden()) {
cout << "RooAbsHiddenReal::writeToStream(" << GetName() << "): not allowed" << endl ;
} else {
RooAbsReal::writeToStream(os,compact) ;
}
}
RooAbsCategory& RooAbsHiddenReal::dummyBlindState() const
{
if (!_dummyBlindState) {
_dummyBlindState = new RooCategory("dummyBlindState","dummy blinding state") ;
_dummyBlindState->defineType("Normal",0) ;
_dummyBlindState->defineType("Blind",1) ;
_dummyBlindState->setIndex(1) ;
}
return *_dummyBlindState ;
}
ROOT page - Class index - Class Hierarchy - Top of the page
This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.