CbmRoot
Loading...
Searching...
No Matches
CbmQaPie.h
Go to the documentation of this file.
1/* Copyright (C) 2020 GSI Helmholtzzentrum fuer Schwerionenforschung, Darmstadt
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Sergey Gorbunov [committer] */
4
9
10#ifndef CbmQaPie_H
11#define CbmQaPie_H
12
13#include "TPie.h"
14#include "TPieSlice.h"
15
16#include <vector>
17
18class TBrowser;
19
22class CbmQaPieSlice : public TPieSlice {
23 public:
25 CbmQaPieSlice& operator=(const TPieSlice& inp) { return (*this = (const CbmQaPieSlice&) (inp)); }
27 void SetPie(TPie* p) { fPie = p; }
28
30};
31
40class CbmQaPie : public TPie {
41 public:
43 template<typename... Types>
44 CbmQaPie(Types... args) : TPie(args...)
45 {
46 }
47
49 CbmQaPie(const CbmQaPie& cpy);
50
53
55 void Browse(TBrowser* b);
56
58 void Draw(Option_t* option = "l");
59
60 private:
62 std::vector<CbmQaPieSlice> fSliceStore;
63
65};
66
67#endif
CbmQaPieSlice & operator=(const TPieSlice &inp)
assignment operator
Definition CbmQaPie.h:25
ClassDef(CbmQaPieSlice, 1)
void SetPie(TPie *p)
set a TPie pointer
Definition CbmQaPie.h:27
void Browse(TBrowser *b)
Draw TPie by a mouse click in the TBrowser.
Definition CbmQaPie.cxx:33
std::vector< CbmQaPieSlice > fSliceStore
a vector for slice streaming. It replaces the original array of pointers.
Definition CbmQaPie.h:62
~CbmQaPie()
Destructor.
Definition CbmQaPie.h:52
void Draw(Option_t *option="l")
Prevents original TPie::Draw() from crashing when there are no entries.
Definition CbmQaPie.cxx:40
ClassDef(CbmQaPie, 1)
CbmQaPie(Types... args)
Reimplementation of any existing TPie constructor.
Definition CbmQaPie.h:44