FairRoot/PandaRoot
RhoMinusParticleSelector.cxx
Go to the documentation of this file.
1 // //
3 // RhoMinusParticleSelector //
4 // //
5 // Selector classes for particle selection //
6 // //
7 // Author List: //
8 // Marcel Kunze, RUB, Feb. 99 //
9 // Copyright (C) 1999-2001, Ruhr-University Bochum. //
10 // Ralf Kliemt, HIM/GSI Feb.2013 (Cleanup & Restructuring) //
11 // //
13 
14 #include <math.h>
15 #include "TDatabasePDG.h"
16 
18 #include "RhoBase/RhoCandidate.h"
19 #include "PndPidCandidate.h"
20 
21 
22 
23 
25 
26 TBuffer& operator>> ( TBuffer& buf, RhoMinusParticleSelector *&obj )
27 {
28  obj = ( RhoMinusParticleSelector* ) buf.ReadObject ( RhoMinusParticleSelector::Class() );
29  return buf;
30 }
31 
32 RhoMinusParticleSelector::RhoMinusParticleSelector ( const char* name, const char* type ) :
33  RhoParticleSelectorBase ( name,type )
34 {}
35 
37 {
38  if ( b == 0 ) { return kFALSE; }
39  if ( b->GetCharge() >0 ) { return kFALSE; }
40  SetTypeAndMass ( b );
41 
42  return kTRUE;
43 }
44 
46 {
47  Bool_t decision = kFALSE;
48  if ( b == 0 ) { return kFALSE; }
49  if ( b->GetCharge() ==-1 ) { decision = kTRUE; }
50  return decision;
51 }
52 
Int_t GetCharge() const
RhoMinusParticleSelector(const char *name="RhoMinusParticleSelector", const char *type=0)
Double_t GetCharge() const
Definition: RhoCandidate.h:183
TTree * b
virtual Bool_t Accept(RhoCandidate *b)
void SetTypeAndMass(RhoCandidate *b)
TString name
ClassImp(PndAnaContFact)