CMS 3D CMS Logo

pos::PixelTBMChannel Class Reference

Simple class to hold either "A" or "B" for the TBM channel. More...

#include <interface/PixelTBMChannel.h>

List of all members.

Public Member Functions

const bool operator< (const PixelTBMChannel &aTBMChannel) const
const bool operator== (const PixelTBMChannel &aTBMChannel) const
 PixelTBMChannel (std::string TBMChannel)
 PixelTBMChannel ()
std::string string () const

Private Attributes

bool isChannelB_

Friends

std::ostream & operator<< (std::ostream &s, const PixelTBMChannel &TBMChannel)


Detailed Description

Simple class to hold either "A" or "B" for the TBM channel.

A longer explanation will be placed here later

Definition at line 18 of file PixelTBMChannel.h.


Constructor & Destructor Documentation

pos::PixelTBMChannel::PixelTBMChannel (  )  [inline]

Definition at line 22 of file PixelTBMChannel.h.

00022 {;}

PixelTBMChannel::PixelTBMChannel ( std::string  TBMChannel  ) 

Definition at line 6 of file PixelTBMChannel.cc.

References GenMuonPlsPt100GeV_cfg::cout, lat::endl(), and isChannelB_.

00007 {
00008         if      ( TBMChannel=="A" ) isChannelB_ = false;
00009         else if ( TBMChannel=="B" ) isChannelB_ = true;
00010         else
00011         {
00012                 std::cout << "ERROR in PixelTBMChannel: TBM channel must be A or B, but input value was "<<TBMChannel<<std::endl;
00013                 assert(0);
00014         }
00015 }


Member Function Documentation

const bool pos::PixelTBMChannel::operator< ( const PixelTBMChannel aTBMChannel  )  const [inline]

Definition at line 29 of file PixelTBMChannel.h.

References isChannelB_.

00029                                                                   {
00030       return ( isChannelB_ == false && aTBMChannel.isChannelB_ == true );
00031     }

const bool pos::PixelTBMChannel::operator== ( const PixelTBMChannel aTBMChannel  )  const [inline]

Definition at line 33 of file PixelTBMChannel.h.

References isChannelB_.

00033                                                                    {
00034       return isChannelB_==aTBMChannel.isChannelB_;
00035     }

std::string PixelTBMChannel::string (  )  const

Definition at line 17 of file PixelTBMChannel.cc.

References isChannelB_.

Referenced by pos::operator<<(), and pos::PixelChannel::TBMChannelString().

00018 {
00019         if ( isChannelB_ ) return "B";
00020         else              return "A";
00021 }


Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  s,
const PixelTBMChannel TBMChannel 
) [friend]

Definition at line 23 of file PixelTBMChannel.cc.

00024 {
00025         s << TBMChannel.string();
00026         return s;
00027 }


Member Data Documentation

bool pos::PixelTBMChannel::isChannelB_ [private]

Definition at line 38 of file PixelTBMChannel.h.

Referenced by operator<(), operator==(), PixelTBMChannel(), and string().


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:50:37 2009 for CMSSW by  doxygen 1.5.4