11#ifndef ROOT_CMDLINE_OBJTREE
12#define ROOT_CMDLINE_OBJTREE
119RootSource
GetMatchingPathsInFile(std::string_view fileName, std::string_view pattern, std::uint32_t flags);
137RootSource
ParseRootSource(std::string_view sourceRaw, std::uint32_t flags);
147std::vector<ROOT::CmdLine::RootSource>
148ParseRootSources(
const std::vector<std::string> &sourcesRaw, std::uint32_t flags);
The class is used as a return type for operations that can fail; wraps a value of type T or an RError...
Describe directory structure in memory.
A file, usually with extension .root, that stores data and code in the form of serialized objects in ...
Book space in a file, create I/O buffers, to fill them, (un)compress them.
virtual const char * GetClassName() const
Short_t GetCycle() const
Return cycle number associated to this key.
const char * GetName() const override
Returns name of object.
subroutine node(ivo, nuserm, iposp)
RootSource ParseRootSource(std::string_view sourceRaw, std::uint32_t flags)
Given a string like "file.root:dir/obj", converts it to a RootSource.
ROOT::RResult< std::pair< std::string_view, std::string_view > > SplitIntoFileNameAndPattern(std::string_view sourceRaw)
Given a string like "root://file.root:a/b/c", splits it into { "root://file.root",...
std::string NodeFullPath(const RootObjTree &tree, NodeIdx_t nodeIdx, ENodeFullPathOpt opt)
Given a node, returns its full path. If opt == kIncludeFilename, the path is prepended by "filename....
void PrintObjTree(const RootObjTree &tree, std::ostream &out=std::cout)
Prints out the structure of the object tree. Helpful for debugging.
@ kRecursive
Recurse into subdirectories when matching objects.
std::vector< ROOT::CmdLine::RootSource > ParseRootSources(const std::vector< std::string > &sourcesRaw, std::uint32_t flags)
Given a list of strings like "file.root:dir/obj", converts each string to a RootSource.
RootObjNode NodeFromKey(TKey &key)
RootSource GetMatchingPathsInFile(std::string_view fileName, std::string_view pattern, std::uint32_t flags)
Given a file and a "path pattern", returns a RootSource containing the tree of matched objects.
A representation of all objects involved in a rootls-style ROOT file listing.
std::unique_ptr< TFile > fFile
std::vector< NodeIdx_t > fDirList
std::vector< NodeIdx_t > fLeafList
std::vector< RootObjNode > fNodes
std::vector< std::string > fErrors