Logo ROOT   6.18/05
Reference Guide
TParticleClassPDG.h
Go to the documentation of this file.
1// @(#)root/eg:$Id$
2// Author: Pasha Murat 12/02/99
3
4/*************************************************************************
5 * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6 * All rights reserved. *
7 * *
8 * For the licensing terms see $ROOTSYS/LICENSE. *
9 * For the list of contributors see $ROOTSYS/README/CREDITS. *
10 *************************************************************************/
11#ifndef TParticleClassPDG_hh
12#define TParticleClassPDG_hh
13
14#include "TNamed.h"
15#include "TObjArray.h"
16
17class TParticlePDG;
18
19class TParticleClassPDG : public TNamed {
20public:
21//------------------------------------------------------------------------------
22// data members
23//------------------------------------------------------------------------------
24protected:
25 TObjArray* fListOfParticles; // list of (non-owned) particles
26
29 {if(this!=&pcp) {TNamed::operator=(pcp); fListOfParticles=pcp.fListOfParticles;}
30 return *this;
31 }
32//------------------------------------------------------------------------------
33// functions
34//------------------------------------------------------------------------------
35public:
36 // ****** constructors and destructor
37
38 TParticleClassPDG(const char* name = 0);
39 virtual ~TParticleClassPDG();
40 // ****** access methods
41
44 }
45
47 return (TParticlePDG*) fListOfParticles->At(i);
48 }
49
51
52 // ****** modifiers
53
55
56 // ****** overloaded methods of TObject
57
58 virtual void Print(Option_t* opt="") const; // *MENU*
59
60 Bool_t IsFolder() const { return kTRUE; }
61 virtual void Browse(TBrowser* b);
62
63 ClassDef(TParticleClassPDG,1) // PDG static particle definition
64};
65
66#endif
#define b(i)
Definition: RSha256.hxx:100
int Int_t
Definition: RtypesCore.h:41
bool Bool_t
Definition: RtypesCore.h:59
const Bool_t kTRUE
Definition: RtypesCore.h:87
const char Option_t
Definition: RtypesCore.h:62
#define ClassDef(name, id)
Definition: Rtypes.h:326
char name[80]
Definition: TGX11.cxx:109
Using a TBrowser one can browse all ROOT objects.
Definition: TBrowser.h:37
The TNamed class is the base class for all named ROOT classes.
Definition: TNamed.h:29
TNamed & operator=(const TNamed &rhs)
TNamed assignment operator.
Definition: TNamed.cxx:51
An array of TObjects.
Definition: TObjArray.h:37
Int_t GetEntriesFast() const
Definition: TObjArray.h:64
void Add(TObject *obj)
Definition: TObjArray.h:74
TObject * At(Int_t idx) const
Definition: TObjArray.h:166
Mother of all ROOT objects.
Definition: TObject.h:37
Utility class used internally by TDatabasePDG.
TObjArray * GetListOfParticles()
TParticlePDG * GetParticle(Int_t i)
virtual ~TParticleClassPDG()
destructor, class doesn't own its particles...
TObjArray * fListOfParticles
void AddParticle(TObject *p)
Bool_t IsFolder() const
Returns kTRUE in case object contains browsable objects (like containers or lists of other objects).
virtual void Browse(TBrowser *b)
browse this particle class
virtual void Print(Option_t *opt="") const
Print the entire information of this kind of particle.
TParticleClassPDG & operator=(const TParticleClassPDG &pcp)
TParticleClassPDG(const TParticleClassPDG &pcp)
Description of the static properties of a particle.
Definition: TParticlePDG.h:19