CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes
l1t::PrescalesVetosHelper Class Reference

#include <PrescalesVetosHelper.h>

Public Types

enum  { VERSION_ = 1 }
 

Public Member Functions

int bxMaskDefault () const
 
const L1TGlobalPrescalesVetosgetReadInstance () const
 
L1TGlobalPrescalesVetosgetWriteInstance ()
 
 PrescalesVetosHelper (L1TGlobalPrescalesVetos *w)
 
const std::vector< std::vector< int > > & prescaleTable () const
 
void setBxMaskDefault (int value)
 
void setPrescaleFactorTable (std::vector< std::vector< int > > value)
 
void setTriggerAlgoBxMask (std::map< int, std::vector< int > > value)
 
void setTriggerMaskVeto (std::vector< int > value)
 
const std::map< int, std::vector< int > > & triggerAlgoBxMask () const
 
const std::vector< int > & triggerMaskVeto () const
 
 ~PrescalesVetosHelper ()
 

Static Public Member Functions

static PrescalesVetosHelperreadAndWriteFromEventSetup (const L1TGlobalPrescalesVetos *es)
 
static const PrescalesVetosHelperreadFromEventSetup (const L1TGlobalPrescalesVetos *es)
 

Private Member Functions

void check_write ()
 
 PrescalesVetosHelper (const L1TGlobalPrescalesVetos *es)
 
void useCopy ()
 

Private Attributes

const L1TGlobalPrescalesVetosread_
 
bool we_own_write_
 
L1TGlobalPrescalesVetoswrite_
 

Detailed Description

Definition at line 34 of file PrescalesVetosHelper.h.

Member Enumeration Documentation

anonymous enum
Enumerator
VERSION_ 

Definition at line 36 of file PrescalesVetosHelper.h.

Constructor & Destructor Documentation

PrescalesVetosHelper::~PrescalesVetosHelper ( )

Definition at line 32 of file PrescalesVetosHelper.cc.

References we_own_write_, and write_.

32  {
33  if (we_own_write_ && write_) delete write_;
34 }
L1TGlobalPrescalesVetos * write_
PrescalesVetosHelper::PrescalesVetosHelper ( L1TGlobalPrescalesVetos w)
PrescalesVetosHelper::PrescalesVetosHelper ( const L1TGlobalPrescalesVetos es)
private

Definition at line 24 of file PrescalesVetosHelper.cc.

References NULL, read_, and write_.

24 {read_ = es; write_=NULL;}
#define NULL
Definition: scimark2.h:8
L1TGlobalPrescalesVetos * write_
const L1TGlobalPrescalesVetos * read_

Member Function Documentation

int l1t::PrescalesVetosHelper::bxMaskDefault ( ) const
inline

Definition at line 47 of file PrescalesVetosHelper.h.

References L1TGlobalPrescalesVetos::bxmask_default_, and read_.

47 { return read_->bxmask_default_; };
const L1TGlobalPrescalesVetos * read_
void l1t::PrescalesVetosHelper::check_write ( )
inlineprivate

Definition at line 65 of file PrescalesVetosHelper.h.

References write_.

Referenced by PrescalesVetosHelper(), setBxMaskDefault(), setPrescaleFactorTable(), setTriggerAlgoBxMask(), and setTriggerMaskVeto().

65 { assert(write_); }
L1TGlobalPrescalesVetos * write_
const L1TGlobalPrescalesVetos* l1t::PrescalesVetosHelper::getReadInstance ( ) const
inline

Definition at line 59 of file PrescalesVetosHelper.h.

References read_.

59 {return read_;}
const L1TGlobalPrescalesVetos * read_
L1TGlobalPrescalesVetos* l1t::PrescalesVetosHelper::getWriteInstance ( )
inline
const std::vector<std::vector<int> >& l1t::PrescalesVetosHelper::prescaleTable ( ) const
inline

Definition at line 50 of file PrescalesVetosHelper.h.

References L1TGlobalPrescalesVetos::prescale_table_, and read_.

Referenced by L1TGlobalProducer::produce(), and l1t::L1TGlobalUtil::retrieveL1Setup().

50 { return read_->prescale_table_; };
std::vector< std::vector< int > > prescale_table_
const L1TGlobalPrescalesVetos * read_
PrescalesVetosHelper * PrescalesVetosHelper::readAndWriteFromEventSetup ( const L1TGlobalPrescalesVetos es)
static

Definition at line 10 of file PrescalesVetosHelper.cc.

References PrescalesVetosHelper(), and useCopy().

10  {
12  x->useCopy();
13  return x;
14 }
PrescalesVetosHelper(L1TGlobalPrescalesVetos *w)
const PrescalesVetosHelper * PrescalesVetosHelper::readFromEventSetup ( const L1TGlobalPrescalesVetos es)
static

Definition at line 6 of file PrescalesVetosHelper.cc.

References PrescalesVetosHelper().

Referenced by l1t::L1TGlobalUtil::retrieveL1Setup().

6  {
7  return new PrescalesVetosHelper(es);
8 }
PrescalesVetosHelper(L1TGlobalPrescalesVetos *w)
void l1t::PrescalesVetosHelper::setBxMaskDefault ( int  value)
inline
void l1t::PrescalesVetosHelper::setPrescaleFactorTable ( std::vector< std::vector< int > >  value)
inline
void l1t::PrescalesVetosHelper::setTriggerAlgoBxMask ( std::map< int, std::vector< int > >  value)
inline
void l1t::PrescalesVetosHelper::setTriggerMaskVeto ( std::vector< int >  value)
inline
const std::map<int, std::vector<int> >& l1t::PrescalesVetosHelper::triggerAlgoBxMask ( ) const
inline

Definition at line 55 of file PrescalesVetosHelper.h.

References L1TGlobalPrescalesVetos::bxmask_map_, and read_.

Referenced by l1t::L1TGlobalUtil::retrieveL1Setup().

55 { return read_->bxmask_map_; };
std::map< int, std::vector< int > > bxmask_map_
const L1TGlobalPrescalesVetos * read_
const std::vector<int>& l1t::PrescalesVetosHelper::triggerMaskVeto ( ) const
inline

Definition at line 52 of file PrescalesVetosHelper.h.

References read_, and L1TGlobalPrescalesVetos::veto_.

Referenced by L1TGlobalProducer::produce().

52 { return read_->veto_; };
const L1TGlobalPrescalesVetos * read_
void PrescalesVetosHelper::useCopy ( )
private

Definition at line 26 of file PrescalesVetosHelper.cc.

References read_, we_own_write_, and write_.

Referenced by getWriteInstance(), and readAndWriteFromEventSetup().

26  {
28  we_own_write_ = true;
29  read_ = write_;
30 }
L1TGlobalPrescalesVetos * write_
const L1TGlobalPrescalesVetos * read_

Member Data Documentation

const L1TGlobalPrescalesVetos* l1t::PrescalesVetosHelper::read_
private
bool l1t::PrescalesVetosHelper::we_own_write_
private

Definition at line 69 of file PrescalesVetosHelper.h.

Referenced by PrescalesVetosHelper(), useCopy(), and ~PrescalesVetosHelper().

L1TGlobalPrescalesVetos* l1t::PrescalesVetosHelper::write_
private