CMS 3D CMS Logo

GPFRecHit Class Reference

#include <RecoParticleFlow/PFRootEvent/interface/GPFRecHit.h>

Inheritance diagram for GPFRecHit:

GPFBase

List of all members.

Public Member Functions

virtual void draw ()
virtual void ExecuteEvent (Int_t event, Int_t px, Int_t py)
double getEnergy ()
std::string getOption ()
 GPFRecHit (DisplayManager *dm, int view, int ident, reco::PFRecHit *hit, int size, double *x, double *y, int color, std::string option)
virtual void Print ()
void setColor (int newcolor)
void setColor ()
void setInitialColor ()
void setNewSize ()
void setNewStyle ()
virtual ~GPFRecHit ()

Private Attributes

double en_
 energy
std::string option_
 root draw option
reco::PFRecHitrecHit_


Detailed Description

Definition at line 15 of file GPFRecHit.h.


Constructor & Destructor Documentation

GPFRecHit::GPFRecHit ( DisplayManager dm,
int  view,
int  ident,
reco::PFRecHit hit,
int  size,
double *  x,
double *  y,
int  color,
std::string  option 
)

Definition at line 10 of file GPFRecHit.cc.

References GPFBase::color_, en_, reco::PFRecHit::energy(), and recHit_.

00013   : GPFBase(display,view,ident, color),
00014     TGraph(size,x,y),
00015     recHit_(rechit), option_(option)
00016 {
00017   ResetBit(kCanDelete);
00018   
00019   en_=recHit_->energy();  
00020     
00021   SetLineColor(color_);
00022   SetFillColor(color_);
00023   
00024 }                    

virtual GPFRecHit::~GPFRecHit (  )  [inline, virtual]

Definition at line 20 of file GPFRecHit.h.

00020 {}


Member Function Documentation

void GPFRecHit::draw (  )  [virtual]

Reimplemented from GPFBase.

Definition at line 46 of file GPFRecHit.cc.

References option_.

00047 {
00048   TGraph::Draw(option_.data());
00049 }

void GPFRecHit::ExecuteEvent ( Int_t  event,
Int_t  px,
Int_t  py 
) [virtual]

Definition at line 31 of file GPFRecHit.cc.

References GPFBase::display_, DisplayManager::findAndDraw(), GPFBase::origId_, and Print().

00032 {
00033   // Execute action corresponding to a mouse click 
00034   //on a GPFRecHit object in the window
00035 
00036   gPad->SetCursor(kHand);
00037   switch (event) {
00038   case kButton1Down:
00039     Print();
00040     display_->findAndDraw(origId_);
00041     break;
00042   default:break;
00043   }    
00044 }

double GPFRecHit::getEnergy (  )  [inline, virtual]

Reimplemented from GPFBase.

Definition at line 23 of file GPFRecHit.h.

References en_.

00023 { return en_;}

std::string GPFRecHit::getOption (  )  [inline]

Definition at line 24 of file GPFRecHit.h.

References option_.

00024 { return option_;}

void GPFRecHit::Print (  )  [virtual]

Definition at line 26 of file GPFRecHit.cc.

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

Referenced by ExecuteEvent().

00027 {
00028   std::cout<<*recHit_<<std::endl;
00029 }

void GPFRecHit::setColor ( int  newcolor  )  [virtual]

Implements GPFBase.

Definition at line 51 of file GPFRecHit.cc.

References option_.

00052 {
00053   if (option_=="f") SetFillColor(color);
00054   else              SetLineColor(color);
00055 }

void GPFRecHit::setColor (  )  [virtual]

Implements GPFBase.

Definition at line 63 of file GPFRecHit.cc.

References GPFBase::color_, and option_.

00064 {
00065   if (option_=="f") SetFillColor(color_);
00066   else              SetLineColor(color_);
00067 }

void GPFRecHit::setInitialColor (  )  [virtual]

Implements GPFBase.

Definition at line 57 of file GPFRecHit.cc.

References GPFBase::color_, and option_.

00058 {
00059   if (option_=="f") SetFillColor(color_);
00060   else              SetLineColor(color_);
00061 }

void GPFRecHit::setNewSize (  )  [virtual]

Implements GPFBase.

Definition at line 70 of file GPFRecHit.cc.

00071 {
00072   //not implemented
00073 }

void GPFRecHit::setNewStyle (  )  [virtual]

Implements GPFBase.

Definition at line 75 of file GPFRecHit.cc.

00076 {
00077   //not implemented
00078 }


Member Data Documentation

double GPFRecHit::en_ [private]

energy

Definition at line 39 of file GPFRecHit.h.

Referenced by getEnergy(), and GPFRecHit().

std::string GPFRecHit::option_ [private]

root draw option

Definition at line 42 of file GPFRecHit.h.

Referenced by draw(), getOption(), setColor(), and setInitialColor().

reco::PFRecHit* GPFRecHit::recHit_ [private]

Definition at line 36 of file GPFRecHit.h.

Referenced by GPFRecHit(), and Print().


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