36 while ((key = (
TKey*)nextkey())) {
67void CopyFile(
const char *fname) {
71 if (!
f ||
f->IsZombie()) {
72 printf(
"Cannot copy file: %s\n",fname);
83 if(
gSystem->AccessPathName(
"tot100.root")) {
84 gSystem->CopyFile(
"hsimple.root",
"tot100.root");
85 gSystem->CopyFile(
"hsimple.root",
"hs1.root");
86 gSystem->CopyFile(
"hsimple.root",
"hs2.root");
90 CopyFile(
"tot100.root");
91 CopyFile(
"hsimple.root");
const Bool_t kIterBackward
TClass instances represent classes, structs and namespaces in the ROOT type system.
Bool_t InheritsFrom(const char *cl) const override
Return kTRUE if this class inherits from a class with name "classname".
Describe directory structure in memory.
virtual TObject * Get(const char *namecycle)
Return pointer to object identified by namecycle.
void ls(Option_t *option="") const override
List Directory contents.
TObject * FindObject(const char *name) const override
Find object by name in the list of memory objects.
virtual Bool_t cd()
Change current directory to "this" directory.
virtual void SaveSelf(Bool_t=kFALSE)
virtual TDirectory * mkdir(const char *name, const char *title="", Bool_t returnExistingDirectory=kFALSE)
Create a sub-directory "a" or a hierarchy of sub-directories "a/b/c/...".
virtual TList * GetListOfKeys() const
A file, usually with extension .root, that stores data and code in the form of serialized objects in ...
static TFile * Open(const char *name, Option_t *option="", const char *ftitle="", Int_t compress=ROOT::RCompressionSetting::EDefaults::kUseCompiledDefault, Int_t netopt=0)
Create / open a file.
Book space in a file, create I/O buffers, to fill them, (un)compress them.
virtual const char * GetClassName() const
virtual TObject * ReadObj()
To read a TObject* from the file.
const char * GetName() const override
Returns name of object.
Mother of all ROOT objects.
virtual Int_t Write(const char *name=nullptr, Int_t option=0, Int_t bufsize=0)
Write this object to the current directory.
A TTree represents a columnar dataset.
virtual TTree * CloneTree(Long64_t nentries=-1, Option_t *option="")
Create a clone of this tree and copy nentries.
Int_t Write(const char *name=nullptr, Int_t option=0, Int_t bufsize=0) override
Write this object to the current directory.