Logo ROOT  
Reference Guide
TSystemFile.h
Go to the documentation of this file.
1 // @(#)root/base:$Id$
2 // Author: Rene Brun 26/06/96
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 #ifndef ROOT_TSystemFile
13 #define ROOT_TSystemFile
14 
15 
16 //////////////////////////////////////////////////////////////////////////
17 // //
18 // TSystemFile //
19 // //
20 // Describes an Operating System file for the browser. //
21 // //
22 //////////////////////////////////////////////////////////////////////////
23 
24 
25 #include "TNamed.h"
26 
27 class TBrowser;
28 
29 class TSystemFile : public TNamed {
30 private:
31  TString fIconName; // icon name
32 
33 public:
34  TSystemFile();
35  TSystemFile(const char *filename, const char *dirname);
36  virtual ~TSystemFile();
37  virtual void Browse(TBrowser *b);
38  virtual void Rename(const char *name); // *MENU*
39  virtual void Delete(); // *MENU*
40  virtual void Copy(const char *to); // *MENU*
41  virtual void Move(const char *to); // *MENU*
42  virtual void Edit(); // *MENU*
43 
44  virtual Bool_t IsDirectory(const char *dir = 0) const;
45  virtual void SetIconName(const char *name) { fIconName = name; }
46  const char *GetIconName() const { return fIconName.Data(); }
47 
48  // dummy methods from TObject
49  virtual void Inspect() const;
50  virtual void Dump() const;
51 
52  void DrawClass() const { }
53  TObject *DrawClone(Option_t *) const { return 0; }
54  void SetDrawOption(Option_t *) { }
55  void SetName(const char *name) { TNamed::SetName(name); }
56  void SetTitle(const char *title) { TNamed::SetTitle(title); }
57  void Delete(Option_t *) { }
58  void Copy(TObject & ) const { }
59 
60  ClassDef(TSystemFile,0) //A system file
61 };
62 
63 #endif
64 
TBrowser
Definition: TBrowser.h:37
TSystemFile::Delete
void Delete(Option_t *)
Delete this object.
Definition: TSystemFile.h:57
TSystemFile::GetIconName
const char * GetIconName() const
Returns mime type name of object.
Definition: TSystemFile.h:46
TSystemFile::Dump
virtual void Dump() const
dump this file
Definition: TSystemFile.cxx:177
TNamed::SetName
virtual void SetName(const char *name)
Set the name of the TNamed.
Definition: TNamed.cxx:140
TSystemFile::SetIconName
virtual void SetIconName(const char *name)
Definition: TSystemFile.h:45
TSystemFile::Copy
void Copy(TObject &) const
Copy this to obj.
Definition: TSystemFile.h:58
TString::Data
const char * Data() const
Definition: TString.h:369
TSystemFile::~TSystemFile
virtual ~TSystemFile()
Delete TSystemFile object.
Definition: TSystemFile.cxx:46
TSystemFile::Move
virtual void Move(const char *to)
move this file
Definition: TSystemFile.cxx:125
TNamed.h
TSystemFile::DrawClone
TObject * DrawClone(Option_t *) const
Draw a clone of this object in the current selected pad for instance with: gROOT->SetSelectedPad(gPad...
Definition: TSystemFile.h:53
TSystemFile::Copy
virtual void Copy(const char *to)
copy this file
Definition: TSystemFile.cxx:102
TSystemFile::fIconName
TString fIconName
Definition: TSystemFile.h:31
TSystemFile::IsDirectory
virtual Bool_t IsDirectory(const char *dir=0) const
Check if object is a directory.
Definition: TSystemFile.cxx:53
TString
Definition: TString.h:136
b
#define b(i)
Definition: RSha256.hxx:118
bool
TSystemFile::Rename
virtual void Rename(const char *name)
rename this file
Definition: TSystemFile.cxx:162
TSystemFile::SetName
void SetName(const char *name)
Set the name of the TNamed.
Definition: TSystemFile.h:55
Option_t
const typedef char Option_t
Definition: RtypesCore.h:66
TSystemFile
Definition: TSystemFile.h:29
TNamed
Definition: TNamed.h:29
TSystemFile::Delete
virtual void Delete()
delete this file
Definition: TSystemFile.cxx:154
TNamed::SetTitle
virtual void SetTitle(const char *title="")
Set the title of the TNamed.
Definition: TNamed.cxx:164
TSystemFile::SetDrawOption
void SetDrawOption(Option_t *)
Set drawing option for object.
Definition: TSystemFile.h:54
TSystemFile::SetTitle
void SetTitle(const char *title)
Set the title of the TNamed.
Definition: TSystemFile.h:56
TSystemFile::Browse
virtual void Browse(TBrowser *b)
Execute default action for this system file (action is specified in the $HOME/.root....
Definition: TSystemFile.cxx:69
TObject
Definition: TObject.h:37
ClassDef
#define ClassDef(name, id)
Definition: Rtypes.h:325
name
char name[80]
Definition: TGX11.cxx:110
TSystemFile::DrawClass
void DrawClass() const
Draw class inheritance tree of the class to which this object belongs.
Definition: TSystemFile.h:52
TSystemFile::Edit
virtual void Edit()
Invoke text editor on this file.
Definition: TSystemFile.cxx:78
TSystemFile::TSystemFile
TSystemFile()
TSystemFile default constructor.
Definition: TSystemFile.cxx:30
TSystemFile::Inspect
virtual void Inspect() const
inspect this file
Definition: TSystemFile.cxx:170