CMS 3D CMS Logo

Public Member Functions | Public Attributes | Private Attributes

TTUInput Class Reference

#include <interface/TTUInput.h>

List of all members.

Public Member Functions

void force (const std::vector< int > &)
void mask (const std::vector< int > &)
TTUInputoperator= (const TTUInput &rhs)
void reset ()
 TTUInput ()
 Standard constructor.
 TTUInput (const TTUInput &in)
virtual ~TTUInput ()

Public Attributes

std::bitset< 6 > * input_sec
int m_bx
bool m_hasHits
std::bitset< 12 > m_rbcDecision
int m_wheelId

Private Attributes

bool m_debug

Detailed Description

Author:
Andres Osorio

email: aosorio@uniandes.edu.co

Date:
2008-10-16

Definition at line 18 of file TTUInput.h.


Constructor & Destructor Documentation

TTUInput::TTUInput ( )

Standard constructor.

Destructor

Definition at line 19 of file TTUInput.cc.

References i, input_sec, m_bx, m_debug, m_hasHits, m_rbcDecision, m_wheelId, and reset().

                     {

  m_bx = 0;
  m_wheelId = 0;
  m_hasHits = false;
  input_sec = new std::bitset<6>[12];
  m_rbcDecision.reset();
  
  for(int i=0; i < 12; ++i)
    input_sec[i].reset();
  
  m_debug = false;

}
TTUInput::~TTUInput ( ) [virtual]

Definition at line 36 of file TTUInput.cc.

References input_sec, and m_hasHits.

                    {

  m_hasHits = false;
  if ( input_sec ) delete[] input_sec;

} 
TTUInput::TTUInput ( const TTUInput in) [inline]

Definition at line 27 of file TTUInput.h.

References i, input_sec, m_bx, m_hasHits, m_rbcDecision, and m_wheelId.

  {
    m_bx = in.m_bx;
    m_wheelId = in.m_wheelId;
    m_hasHits = in.m_hasHits;
    m_rbcDecision = in.m_rbcDecision;
    input_sec = new std::bitset<6>[12];
    for(int i=0; i < 12; ++i) 
      input_sec[i] = in.input_sec[i];
  };

Member Function Documentation

void TTUInput::force ( const std::vector< int > &  forcevec)

Definition at line 69 of file TTUInput.cc.

{
  
  //if( m_debug ) std::cout << forcevec.size() << std::endl;
  
  //std::bitset<15> tmp;
  
  //for(int i=0; i < 15; ++i)
  //  tmp.set(i,forcevec[i]);
  
  //... operate on the first sector
  //input_sec[0]|=tmp;
  //tmp.reset();
  
  //for(int i=15; i < 30; ++i)
  //  tmp.set( (i-15),forcevec[i]);
  
  //input_sec[1]|=tmp;
  
  //tmp.reset();
  
}
void TTUInput::mask ( const std::vector< int > &  maskvec)

Definition at line 58 of file TTUInput.cc.

Referenced by TTUBasicConfig::preprocess().

{
  
  //for(int i=0; i < 15; ++i) 
  //  if ( maskvec[i] ) input_sec[0].set(i,0);
  
  //for(int i=15; i < 30; ++i)
  //  if ( maskvec[i] ) input_sec[1].set( (i-15),0);
  
}
TTUInput& TTUInput::operator= ( const TTUInput rhs) [inline]

Definition at line 38 of file TTUInput.h.

References i, input_sec, m_bx, m_hasHits, m_rbcDecision, and m_wheelId.

  {
    if (this == &rhs) return (*this);
    (*this).m_bx = rhs.m_bx;
    (*this).m_wheelId = rhs.m_wheelId;
    (*this).m_hasHits = rhs.m_hasHits;
    (*this).input_sec = new std::bitset<6>[12];
    (*this).m_rbcDecision = rhs.m_rbcDecision;
    for(int i=0; i < 12; ++i)
      (*this).input_sec[i] = rhs.input_sec[i];
    return (*this);
  };
void TTUInput::reset ( void  )

Definition at line 44 of file TTUInput.cc.

References i, input_sec, m_bx, m_hasHits, m_rbcDecision, and m_wheelId.

Referenced by RPCWheel::retrieveWheelMap(), and TTUInput().

{
  
  m_bx = 0;
  m_wheelId = 0;
  m_hasHits = false;
  
  for(int i=0; i < 12; ++i)
    input_sec[i].reset();

  m_rbcDecision.reset();
    
}

Member Data Documentation

std::bitset<6>* TTUInput::input_sec
bool TTUInput::m_debug [private]

Definition at line 69 of file TTUInput.h.

Referenced by TTUInput().

Definition at line 57 of file TTUInput.h.

Referenced by operator=(), RPCWheelMap::prepareData(), reset(), TTUInput(), and ~TTUInput().

std::bitset<12> TTUInput::m_rbcDecision