Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
ROOT::TreeUtils::RFriendInfo Struct Reference

Information about friend trees of a certain TTree or TChain object.

Definition at line 42 of file RFriendInfo.hxx.

Public Member Functions

 RFriendInfo ()=default
 
 RFriendInfo (const RFriendInfo &)
 
 RFriendInfo (RFriendInfo &&)=default
 
 RFriendInfo (std::vector< std::pair< std::string, std::string > > friendNames, std::vector< std::vector< std::string > > friendFileNames, std::vector< std::vector< std::string > > friendChainSubNames, std::vector< std::vector< Long64_t > > nEntriesPerTreePerFriend, std::vector< std::unique_ptr< TVirtualIndex > > treeIndexInfos)
 Construct a RFriendInfo object from its components.
 
void AddFriend (const std::string &treeName, const std::string &fileNameGlob, const std::string &alias="", Long64_t nEntries=TTree::kMaxEntries, TVirtualIndex *indexInfo=nullptr)
 Add information of a single friend.
 
void AddFriend (const std::string &treeName, const std::vector< std::string > &fileNameGlobs, const std::string &alias="", const std::vector< Long64_t > &nEntriesVec={}, TVirtualIndex *indexInfo=nullptr)
 Add information of a single friend.
 
void AddFriend (const std::vector< std::pair< std::string, std::string > > &treeAndFileNameGlobs, const std::string &alias="", const std::vector< Long64_t > &nEntriesVec={}, TVirtualIndex *indexInfo=nullptr)
 Add information of a single friend.
 
RFriendInfooperator= (const RFriendInfo &)
 
RFriendInfooperator= (RFriendInfo &&)=default
 

Public Attributes

std::vector< std::vector< std::string > > fFriendChainSubNames
 Names of the subtrees of a friend TChain.
 
std::vector< std::vector< std::string > > fFriendFileNames
 Names of the files where each friend is stored.
 
std::vector< std::pair< std::string, std::string > > fFriendNames
 Pairs of names and aliases of each friend tree/chain.
 
std::vector< std::vector< Long64_t > > fNEntriesPerTreePerFriend
 Number of entries contained in each tree of each friend.
 
std::vector< std::unique_ptr< TVirtualIndex > > fTreeIndexInfos
 Information on the friend's TTreeIndexes.
 

#include <ROOT/RFriendInfo.hxx>

Constructor & Destructor Documentation

◆ RFriendInfo() [1/4]

ROOT::TreeUtils::RFriendInfo::RFriendInfo ( )
default

◆ RFriendInfo() [2/4]

ROOT::TreeUtils::RFriendInfo::RFriendInfo ( const RFriendInfo other)

Definition at line 15 of file RFriendInfo.cxx.

◆ RFriendInfo() [3/4]

ROOT::TreeUtils::RFriendInfo::RFriendInfo ( RFriendInfo &&  )
default

◆ RFriendInfo() [4/4]

ROOT::TreeUtils::RFriendInfo::RFriendInfo ( std::vector< std::pair< std::string, std::string > >  friendNames,
std::vector< std::vector< std::string > >  friendFileNames,
std::vector< std::vector< std::string > >  friendChainSubNames,
std::vector< std::vector< Long64_t > >  nEntriesPerTreePerFriend,
std::vector< std::unique_ptr< TVirtualIndex > >  treeIndexInfos 
)

Construct a RFriendInfo object from its components.

Definition at line 34 of file RFriendInfo.cxx.

Member Function Documentation

◆ AddFriend() [1/3]

void ROOT::TreeUtils::RFriendInfo::AddFriend ( const std::string &  treeName,
const std::string &  fileNameGlob,
const std::string &  alias = "",
Long64_t  nEntries = TTree::kMaxEntries,
TVirtualIndex indexInfo = nullptr 
)

Add information of a single friend.

Parameters
[in]treeNameName of the tree.
[in]fileNameGlobPath to the file. Refer to TChain::Add for globbing rules.
[in]aliasAlias for this friend.
[in]nEntriesNumber of entries for this friend.
[in]indexInfoTree index info for this friend.

Definition at line 55 of file RFriendInfo.cxx.

◆ AddFriend() [2/3]

void ROOT::TreeUtils::RFriendInfo::AddFriend ( const std::string &  treeName,
const std::vector< std::string > &  fileNameGlobs,
const std::string &  alias = "",
const std::vector< Long64_t > &  nEntriesVec = {},
TVirtualIndex indexInfo = nullptr 
)

Add information of a single friend.

Parameters
[in]treeNameName of the tree.
[in]fileNameGlobsPaths to the files. Refer to TChain::Add for globbing rules.
[in]aliasAlias for this friend.
[in]nEntriesVecNumber of entries for each file of this friend.
[in]indexInfoTree index info for this friend.

Definition at line 73 of file RFriendInfo.cxx.

◆ AddFriend() [3/3]

void ROOT::TreeUtils::RFriendInfo::AddFriend ( const std::vector< std::pair< std::string, std::string > > &  treeAndFileNameGlobs,
const std::string &  alias = "",
const std::vector< Long64_t > &  nEntriesVec = {},
TVirtualIndex indexInfo = nullptr 
)

Add information of a single friend.

Parameters
[in]treeAndFileNameGlobsPairs of (treename, filename). Refer to TChain::Add for globbing rules.
[in]aliasAlias for this friend.
[in]nEntriesVecNumber of entries for each file of this friend.
[in]indexInfoTree index info for this friend.

Definition at line 93 of file RFriendInfo.cxx.

◆ operator=() [1/2]

RFriendInfo & ROOT::TreeUtils::RFriendInfo::operator= ( const RFriendInfo other)

Definition at line 20 of file RFriendInfo.cxx.

◆ operator=() [2/2]

RFriendInfo & ROOT::TreeUtils::RFriendInfo::operator= ( RFriendInfo &&  )
default

Member Data Documentation

◆ fFriendChainSubNames

std::vector<std::vector<std::string> > ROOT::TreeUtils::RFriendInfo::fFriendChainSubNames

Names of the subtrees of a friend TChain.

fFriendChainSubNames[i] is the list of names of the trees that make a friend TChain whose information is stored at fFriendNames[i] and fFriendFileNames[i]. If instead the friend tree at position i is a TTree, fFriendChainSubNames[i] will be an empty vector.

Definition at line 60 of file RFriendInfo.hxx.

◆ fFriendFileNames

std::vector<std::vector<std::string> > ROOT::TreeUtils::RFriendInfo::fFriendFileNames

Names of the files where each friend is stored.

fFriendFileNames[i] is the list of files for friend with name fFriendNames[i].

Definition at line 52 of file RFriendInfo.hxx.

◆ fFriendNames

std::vector<std::pair<std::string, std::string> > ROOT::TreeUtils::RFriendInfo::fFriendNames

Pairs of names and aliases of each friend tree/chain.

Definition at line 47 of file RFriendInfo.hxx.

◆ fNEntriesPerTreePerFriend

std::vector<std::vector<Long64_t> > ROOT::TreeUtils::RFriendInfo::fNEntriesPerTreePerFriend

Number of entries contained in each tree of each friend.

The outer dimension of the vector tracks the n-th friend tree/chain, the inner dimension tracks the number of entries of each tree in the current friend.

Definition at line 66 of file RFriendInfo.hxx.

◆ fTreeIndexInfos

std::vector<std::unique_ptr<TVirtualIndex> > ROOT::TreeUtils::RFriendInfo::fTreeIndexInfos

Information on the friend's TTreeIndexes.

Definition at line 71 of file RFriendInfo.hxx.

Collaboration diagram for ROOT::TreeUtils::RFriendInfo:
[legend]

The documentation for this struct was generated from the following files: