File: AnalysisHandler.h
Description:
The AnalysisHandler is the base class of all analysis
objects which may be handled by the
FullEventGenerator. The main function is the
virtual analyze method which which is called for each
analysis handler after each event. The method may be called several
times for each event - this may be checked by the analysis handler
by looking at the ieve, loop and
state arguments to the analyze method.
Initialization of histograms etc. should be made in the doinit
method, while writing out of histograms and analysis results should
be performed in the dofinish method.
See
also:
namespace Pythia7
CLASS
AnalysisHandler:
Base class:
Public members:
inline AnalysisHandler();
inline AnalysisHandler(const AnalysisHandler &);
virtual ~AnalysisHandler();
Standard ctors and dtor
virtual void analyze(tEventPtr event, long ieve, int loop, int state);
Analyse a given 'event'. 'ieve' is the event number, 'loop' is
the number of times this event has been presented. If loop is
negative, the event is now fully generated. 'state' is a number
different from zero if the event has been manipulated in some way
since it was last presented. Note that a fully generated event
may be presented several times, if it has been manipulated in
between. The default version of this function will call transform
to make a lorentz transformation of the whole event, then extract
all final state particles and call analyze(tPVector) of this
analysis object and those of all associated analysis objects. The
default version will not, however, do anything on events which
have not been fully generated, or have been manipulated in any
way.
virtual LorentzRotation transform(tEventPtr) const;
transform the event to the desired Lorentz frame and return the
used LorentzRotation. The default version does nothing and
returns the identity rotation.
virtual void analyze(const tPVector & particles);
Analyze the given vector of particles. The default version calls
analyze(tPPtr) for each of the particles.
virtual void analyze(tPPtr particle);
Analyze the given particle. The default version does nothing
void persistentOutput(PersistentOStream &) const;
void persistentInput(PersistentIStream &, int);
Standard functions for writing and reading from persistent streams.
static void Init();
Standard Init function used to initialize the interface.
Protected members:
virtual IBPtr clone() const;
Return a simple clone of this object. Should be implemented as
return new_ptr(*this); by a derived class.
inline virtual void doupdate() throw(UpdateException);
inline virtual void doinit() throw(InitException);
inline virtual void dofinish();
Standard Interfaced virtual functions.
inline virtual void rebind(const TranslationMap & trans)
throw(RebindException);
Change all pointers to Interfaced objects to corresponding clones.
inline virtual IVector getReferences();
Return pointers to all Interfaced objects refered to by this.
Private members:
AnalysisVector theSlaves;
A list of slave analysis objects which are called for the same
extracted particles as this one.
static ClassDescription<AnalysisHandler> initAnalysisHandler;
template <>
STRUCT
BaseClassTrait<AnalysisHandler,1>
Public members:
typedef HandlerBase NthBase;
template <>
STRUCT
ClassTraits<AnalysisHandler>:
Public members:
static string className() { return "/Pythia7/AnalysisHandler"; }
DEFINED MACROS
PYTHIA7_AnalysisHandler_H
INCLUDED FILES
HandlerBase.h
Pythia7/CLHEPWrap/LorentzRotation.h
stdexcept
AnalysisHandler.icc