CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
TTULogicUnit Class Reference

#include <TTULogicUnit.h>

Inheritance diagram for TTULogicUnit:
RPCLogicUnit

Public Member Functions

bool initialise ()
 
bool isTriggered ()
 
void run (const TTUInput &)
 
void run (const TTUInput &, int)
 
void setBoardSpecs (const TTUBoardSpecs::TTUBoardConfig &)
 
void setlogic (const char *)
 
 TTULogicUnit ()
 Standard constructor. More...
 
 TTULogicUnit (const char *)
 
- Public Member Functions inherited from RPCLogicUnit
 RPCLogicUnit ()
 Standard constructor. More...
 
 RPCLogicUnit (int, int, int)
 
virtual ~RPCLogicUnit ()
 Destructor. More...
 

Private Attributes

bool m_debug
 
std::unique_ptr< TTULogicm_logic
 
std::string m_logtype
 

Additional Inherited Members

- Public Attributes inherited from RPCLogicUnit
int m_propA
 
int m_propB
 
int m_propC
 

Detailed Description

Author
Andres Osorio
Date
2008-10-25

Definition at line 21 of file TTULogicUnit.h.

Constructor & Destructor Documentation

◆ TTULogicUnit() [1/2]

TTULogicUnit::TTULogicUnit ( )

Standard constructor.

Definition at line 15 of file TTULogicUnit.cc.

15 : RPCLogicUnit() { m_debug = false; }

References m_debug.

◆ TTULogicUnit() [2/2]

TTULogicUnit::TTULogicUnit ( const char *  logic_type)

Definition at line 17 of file TTULogicUnit.cc.

17  : RPCLogicUnit() {
18  m_logtype = std::string(logic_type);
19  m_debug = false;
20 }

References m_debug, m_logtype, and AlCaHLTBitMon_QueryRunRegistry::string.

Member Function Documentation

◆ initialise()

bool TTULogicUnit::initialise ( )

Definition at line 23 of file TTULogicUnit.cc.

23  {
24  LogicTool<TTULogic> logtool;
25  m_logic = logtool.retrieve(m_logtype);
26 
27  if (!m_logic) {
28  if (m_debug)
29  std::cout << "TTULogicUnit> No logic found \n";
30  return false;
31  };
32 
33  return true;
34 }

References gather_cfg::cout, m_debug, m_logic, m_logtype, and LogicTool< GenLogic >::retrieve().

Referenced by TTUBasicConfig::initialise().

◆ isTriggered()

bool TTULogicUnit::isTriggered ( )
inline

Definition at line 38 of file TTULogicUnit.h.

38 { return m_logic->m_triggersignal; };

◆ run() [1/2]

void TTULogicUnit::run ( const TTUInput input)

Definition at line 40 of file TTULogicUnit.cc.

40  {
41  //... check the thresholds
42 
43  //... by Sector
44 
45  //... by Tower
46 
47  //... by Wheel
48 
49  m_logic->process(input);
50 
51  //m_logic->m_triggersignal = false;
52 }

References input, and m_logic.

◆ run() [2/2]

void TTULogicUnit::run ( const TTUInput input,
int  option 
)

Definition at line 54 of file TTULogicUnit.cc.

54  {
55  m_logic->setOption(option);
56  m_logic->process(input);
57 
58  //m_logic->m_triggersignal = false;
59 }

References input, m_logic, and fileinputsource_cfi::option.

◆ setBoardSpecs()

void TTULogicUnit::setBoardSpecs ( const TTUBoardSpecs::TTUBoardConfig boardSpcs)

Definition at line 38 of file TTULogicUnit.cc.

38 { m_logic->setBoardSpecs(boardSpcs); }

References m_logic.

Referenced by TTUBasicConfig::initialise().

◆ setlogic()

void TTULogicUnit::setlogic ( const char *  logic)

Definition at line 36 of file TTULogicUnit.cc.

36 { m_logtype = std::string(logic); }

References m_logtype, and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by TTUBasicConfig::initialise().

Member Data Documentation

◆ m_debug

bool TTULogicUnit::m_debug
private

Definition at line 46 of file TTULogicUnit.h.

Referenced by initialise(), and TTULogicUnit().

◆ m_logic

std::unique_ptr<TTULogic> TTULogicUnit::m_logic
private

Definition at line 44 of file TTULogicUnit.h.

Referenced by initialise(), run(), and setBoardSpecs().

◆ m_logtype

std::string TTULogicUnit::m_logtype
private

Definition at line 38 of file TTULogicUnit.h.

Referenced by initialise(), setlogic(), and TTULogicUnit().

TTULogicUnit::m_logic
std::unique_ptr< TTULogic > m_logic
Definition: TTULogicUnit.h:44
input
static const std::string input
Definition: EdmProvDump.cc:48
TTULogicUnit::m_debug
bool m_debug
Definition: TTULogicUnit.h:46
gather_cfg.cout
cout
Definition: gather_cfg.py:144
TTULogicUnit::m_logtype
std::string m_logtype
Definition: TTULogicUnit.h:38
fileinputsource_cfi.option
option
Definition: fileinputsource_cfi.py:87
LogicTool
Definition: LogicTool.h:22
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
RPCLogicUnit::RPCLogicUnit
RPCLogicUnit()
Standard constructor.
Definition: RPCLogicUnit.h:16
LogicTool::retrieve
std::unique_ptr< GenLogic > retrieve(const std::string &_logic_name)
...
Definition: LogicTool.h:29