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
27class TBrowser;
28
29class TSystemFile : public TNamed {
30private:
31 TString fIconName; // icon name
32
33public:
35 TSystemFile(const char *filename, const char *dirname);
36 virtual ~TSystemFile();
37 virtual void Rename(const char *name); // *MENU*
38 virtual void Delete(); // *MENU*
39 virtual void Copy(const char *to); // *MENU*
40 virtual void Move(const char *to); // *MENU*
41 virtual void Edit(); // *MENU*
42
43 virtual Bool_t IsDirectory(const char *dir = 0) const;
44 virtual void SetIconName(const char *name) { fIconName = name; }
45 const char *GetIconName() const override { return fIconName.Data(); }
46
47 void Browse(TBrowser *b) override;
48
49 // dummy methods from TObject
50 void Inspect() const override;
51 void Dump() const override;
52
53 void DrawClass() const override { }
54 TObject *DrawClone(Option_t *) const override { return nullptr; }
55 void SetDrawOption(Option_t *) override { }
56 void SetName(const char *name) override { TNamed::SetName(name); }
57 void SetTitle(const char *title) override { TNamed::SetTitle(title); }
58 void Delete(Option_t *) override { }
59 void Copy(TObject &) const override { }
60
61 ClassDefOverride(TSystemFile,0) //A system file
62};
63
64#endif
65
const char Option_t
Definition: RtypesCore.h:66
#define ClassDefOverride(name, id)
Definition: Rtypes.h:339
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char filename
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t b
char name[80]
Definition: TGX11.cxx:110
Using a TBrowser one can browse all ROOT objects.
Definition: TBrowser.h:37
The TNamed class is the base class for all named ROOT classes.
Definition: TNamed.h:29
virtual void SetTitle(const char *title="")
Set the title of the TNamed.
Definition: TNamed.cxx:164
virtual void SetName(const char *name)
Set the name of the TNamed.
Definition: TNamed.cxx:140
Mother of all ROOT objects.
Definition: TObject.h:37
Basic string class.
Definition: TString.h:136
const char * Data() const
Definition: TString.h:369
A TSystemFile describes an operating system file.
Definition: TSystemFile.h:29
TSystemFile()
TSystemFile default constructor.
Definition: TSystemFile.cxx:30
void Dump() const override
dump this file
virtual void Move(const char *to)
move this file
void Copy(TObject &) const override
Copy this to obj.
Definition: TSystemFile.h:59
TString fIconName
Definition: TSystemFile.h:31
const char * GetIconName() const override
Returns mime type name of object.
Definition: TSystemFile.h:45
virtual void Delete()
delete this file
virtual void Rename(const char *name)
rename this file
virtual void Edit()
Invoke text editor on this file.
Definition: TSystemFile.cxx:78
void SetTitle(const char *title) override
Set the title of the TNamed.
Definition: TSystemFile.h:57
void Browse(TBrowser *b) override
Execute default action for this system file (action is specified in the $HOME/.root....
Definition: TSystemFile.cxx:69
TObject * DrawClone(Option_t *) const override
Draw a clone of this object in the current selected pad for instance with: gROOT->SetSelectedPad(gPad...
Definition: TSystemFile.h:54
void Inspect() const override
inspect this file
virtual void SetIconName(const char *name)
Definition: TSystemFile.h:44
virtual void Copy(const char *to)
copy this file
void SetName(const char *name) override
Set the name of the TNamed.
Definition: TSystemFile.h:56
void SetDrawOption(Option_t *) override
Set drawing option for object.
Definition: TSystemFile.h:55
void DrawClass() const override
Draw class inheritance tree of the class to which this object belongs.
Definition: TSystemFile.h:53
void Delete(Option_t *) override
Delete this object.
Definition: TSystemFile.h:58
virtual Bool_t IsDirectory(const char *dir=0) const
Check if object is a directory.
Definition: TSystemFile.cxx:53
virtual ~TSystemFile()
Delete TSystemFile object.
Definition: TSystemFile.cxx:46