ATLAS Offline Software
Loading...
Searching...
No Matches
VertexAnalysis.h
Go to the documentation of this file.
1/* emacs: this is -*- c++ -*- */
10
11
12#ifndef VERTEXANALYSIS_H
13#define VERTEXANALYSIS_H
14
15#include <iostream>
16
17
18#include "TH1.h"
19#include "TProfile.h"
20
23
24
26
27public:
28
29 VertexAnalysis( const std::string& n ) : m_name(n) { }
30
31 virtual ~VertexAnalysis() { }
32
33 const std::string& name() const { return m_name; }
34
35 virtual void initialise() = 0;
36
37 virtual void execute( const std::vector<TIDA::Vertex*>& vtx0,
38 const std::vector<TIDA::Vertex*>& vtx1,
39 const TIDA::Event* te=0 ) = 0;
40
41 virtual void finalise() = 0;
42
43 void addHistogram( TH1* h ) { m_histos.push_back( h ); }
44
45 void addHistogram( TProfile* h ) { m_profs.push_back( h ); }
46
47 const std::vector<TH1*>& objects() const { return m_histos; }
48 const std::vector<TProfile*>& profs() const { return m_profs; }
49
50protected:
51
52 std::vector<TH1*> m_histos;
53 std::vector<TProfile*> m_profs;
54
55private:
56
57 std::string m_name;
58
59};
60
61inline std::ostream& operator<<( std::ostream& s, const VertexAnalysis& v ) {
62 return s << v.name();
63}
64
65
66#endif // VERTEXANALYSIS_H
67
68
69
70
71
72
73
74
75
76
Basic event class to contain a vector of chains for trigger analysis.
std::ostream & operator<<(std::ostream &s, const VertexAnalysis &v)
Header file for AthHistogramAlgorithm.
void addHistogram(TProfile *h)
virtual void finalise()=0
std::string m_name
virtual void initialise()=0
const std::vector< TProfile * > & profs() const
VertexAnalysis(const std::string &n)
std::vector< TProfile * > m_profs
virtual void execute(const std::vector< TIDA::Vertex * > &vtx0, const std::vector< TIDA::Vertex * > &vtx1, const TIDA::Event *te=0)=0
const std::string & name() const
const std::vector< TH1 * > & objects() const
virtual ~VertexAnalysis()
std::vector< TH1 * > m_histos
void addHistogram(TH1 *h)