PandaTree
SVDaughter.h
1 #ifndef PandaTree_Objects_SVDaughter_h
2 #define PandaTree_Objects_SVDaughter_h
3 #include "Constants.h"
4 #include "UnpackedPFCand.h"
5 #include "../../Framework/interface/Array.h"
6 #include "../../Framework/interface/Collection.h"
7 #include "../../Framework/interface/Ref.h"
8 #include "../../Framework/interface/RefVector.h"
9 
10 namespace panda {
11 
12  class SVDaughter : public UnpackedPFCand {
13  public:
16  ~datastore() { deallocate(); }
17 
18  /* PFCandBase
19  UChar_t* ptype{0};
20  ContainerBase const* vertexContainer_{0};
21  Short_t* vertex_{0}; ///< transient
22  ContainerBase const* trackContainer_{0};
23  Short_t* track_{0}; ///< transient
24  Float_t* hCalFrac{0};
25  */
26  /* UnpackedPFCand
27  Float_t* puppiW_{0};
28  Float_t* puppiWNoLep_{0};
29  */
30  Float_t* dxySV{0};
31  Float_t* dzSV{0};
32  Float_t* rawPhi{0};
33  Short_t* qtrk{0};
34  Float_t* ptAxis{0};
35  Float_t* plAxis{0};
36 
37  void allocate(UInt_t n) override;
38  void deallocate() override;
39  void setStatus(TTree&, TString const&, utils::BranchList const&) override;
40  utils::BranchList getStatus(TTree&, TString const&) const override;
41  utils::BranchList getBranchNames(TString const& = "") const override;
42  void setAddress(TTree&, TString const&, utils::BranchList const& = {"*"}, Bool_t setStatus = kTRUE) override;
43  void book(TTree&, TString const&, utils::BranchList const& = {"*"}, Bool_t dynamic = kTRUE) override;
44  void releaseTree(TTree&, TString const&) override;
45  void resizeVectors_(UInt_t) override;
46  };
47 
50 
51  typedef UnpackedPFCand base_type;
52 
53  SVDaughter(char const* name = "");
54  SVDaughter(SVDaughter const&);
55  SVDaughter(datastore&, UInt_t idx);
56  ~SVDaughter();
57  SVDaughter& operator=(SVDaughter const&);
58 
59  static char const* typeName() { return "SVDaughter"; }
60 
61  void print(std::ostream& = std::cout, UInt_t level = 1) const override;
62  void dump(std::ostream& = std::cout) const override;
63 
64  /* PFCandBase
65  UChar_t& ptype;
66  Ref<RecoVertex> vertex;
67  Ref<PackedTrack> track;
68  Float_t& hCalFrac;
69  */
70  Float_t& dxySV;
71  Float_t& dzSV;
72  Float_t& rawPhi;
73  Short_t& qtrk;
74  Float_t& ptAxis;
75  Float_t& plAxis;
76 
77  protected:
78  /* UnpackedPFCand
79  Float_t& puppiW_;
80  Float_t& puppiWNoLep_;
81  */
82 
83  public:
84  /* BEGIN CUSTOM SVDaughter.h.classdef */
85  /* END CUSTOM */
86 
87  static utils::BranchList getListOfBranches();
88 
89  void destructor(Bool_t recursive = kFALSE);
90 
91  protected:
93 
94  void doBook_(TTree&, TString const&, utils::BranchList const& = {"*"}) override;
95  void doInit_() override;
96  };
97 
102 
103  /* BEGIN CUSTOM SVDaughter.h.global */
104  /* END CUSTOM */
105 
106 }
107 
108 #endif
Base class for fixed-size containers.
Definition: ArrayBase.h:13
A reference to an element in a container.
Definition: Ref.h:20
Definition: SVDaughter.h:12
Base class for dynamic-size containers.
Definition: CollectionBase.h:16
Definition: UnpackedPFCand.h:15
Template class for fixed-size container implementations. Inherits from base_type::array_type of the e...
Definition: Array.h:20
List of branch names.
Definition: IOUtils.h:64
Definition: UnpackedPFCand.h:17
void print(std::ostream &=std::cout, UInt_t level=1) const override
Print the object content.
Definition: SVDaughter.cc:236
void resizeVectors_(UInt_t) override
Override when there are vector members.
Definition: SVDaughter.cc:115
Definition: SVDaughter.h:14
void dump(std::ostream &=std::cout) const override
Dump the object content.
Definition: SVDaughter.cc:244
Base class for elements of containers.
Definition: Element.h:32
Definition: Array.h:11
A vector of references to elements in a container.
Definition: RefVector.h:18