This file is indexed.

/usr/include/root/TTreeCloner.h is in libroot-tree-dev 5.34.14-1build1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
// @(#)root/tree:$Id$
// Author: Philippe Canal 07/11/2005

/*************************************************************************
 * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers.               *
 * All rights reserved.                                                  *
 *                                                                       *
 * For the licensing terms see $ROOTSYS/LICENSE.                         *
 * For the list of contributors see $ROOTSYS/README/CREDITS.             *
 *************************************************************************/

#ifndef ROOT_TTreeCloner
#define ROOT_TTreeCloner

//////////////////////////////////////////////////////////////////////////
//                                                                      //
// TTreeCloner                                                          //
//                                                                      //
// Class implementing or helping  the various TTree cloning method      //
//                                                                      //
//////////////////////////////////////////////////////////////////////////

#ifndef ROOT_TObjArray
#include "TObjArray.h"
#endif

#include <vector>

#ifdef R__OLDHPACC
namespace std {
   using ::string;
   using ::vector;
}
#endif

class TBranch;
class TTree;

class TTreeCloner {
   TString    fWarningMsg;       //Text of the error message lead to an 'invalid' state

   Bool_t     fIsValid;
   Bool_t     fNeedConversion;   //True if the fast merge is not possible but a slow merge might possible.
   UInt_t     fOptions;
   TTree     *fFromTree;
   TTree     *fToTree;
   Option_t  *fMethod;
   TObjArray  fFromBranches;
   TObjArray  fToBranches;

   UInt_t     fMaxBaskets;
   UInt_t    *fBasketBranchNum;  //[fMaxBaskets] Index of the branch(es) of the basket.
   UInt_t    *fBasketNum;        //[fMaxBaskets] index of the basket within the branch.

   Long64_t  *fBasketSeek;       //[fMaxBaskets] list of basket position to be read.
   Long64_t  *fBasketEntry;      //[fMaxBaskets] list of basket start entries.
   UInt_t    *fBasketIndex;      //[fMaxBaskets] ordered list of basket indices to be written.

   UShort_t   fPidOffset;        //Offset to be added to the copied key/basket.

   UInt_t     fCloneMethod;      //Indicates which cloning method was selected.
   Long64_t   fToStartEntries;   //Number of entries in the target tree before any addition.

   enum ECloneMethod {
      kDefault             = 0,
      kSortBasketsByBranch = 1,
      kSortBasketsByOffset = 2,
      kSortBasketsByEntry  = 3
   };

   class CompareSeek {
      TTreeCloner *fObject;
   public:
      CompareSeek(TTreeCloner *obj) : fObject(obj) {}
      Bool_t operator()(UInt_t i1, UInt_t i2);
   };

   class CompareEntry {
      TTreeCloner *fObject;
   public:
      CompareEntry(TTreeCloner *obj) : fObject(obj) {}
      Bool_t operator()(UInt_t i1, UInt_t i2);
   };

   friend class CompareSeek;
   friend class CompareEntry;
   
   void ImportClusterRanges();

private:
   TTreeCloner(const TTreeCloner&);            // Not implemented.
   TTreeCloner &operator=(const TTreeCloner&); // Not implemented.

public:
   enum EClonerOptions {
      kNone       = 0,
      kNoWarnings = BIT(1),
      kIgnoreMissingTopLevel = BIT(2)
   };

   TTreeCloner(TTree *from, TTree *to, Option_t *method, UInt_t options = kNone);
   virtual ~TTreeCloner();

   void   CloseOutWriteBaskets();
   UInt_t CollectBranches(TBranch *from, TBranch *to);
   UInt_t CollectBranches(TObjArray *from, TObjArray *to);
   UInt_t CollectBranches();
   void   CollectBaskets();
   void   CopyMemoryBaskets();
   void   CopyStreamerInfos();
   void   CopyProcessIds();
   const char *GetWarning() const { return fWarningMsg; }
   Bool_t Exec();
   Bool_t IsValid() { return fIsValid; }
   Bool_t NeedConversion() { return fNeedConversion; }
   void   SortBaskets();
   void   WriteBaskets();

   ClassDef(TTreeCloner,0); // helper used for the fast cloning of TTrees.
};

#endif