library: libGFAL #include "TGFALFile.h" |
TGFALSystem
class description - source file - inheritance tree (.pdf)
private:
virtual void* GetDirPtr() const
public:
TGFALSystem()
TGFALSystem(const TGFALSystem&)
virtual ~TGFALSystem()
virtual Bool_t AccessPathName(const char* path, EAccessMode mode)
static TClass* Class()
virtual void FreeDirectory(void* dirp)
virtual const char* GetDirEntry(void* dirp) const
virtual Int_t GetPathInfo(const char* path, FileStat_t& buf)
virtual TClass* IsA() const
virtual Int_t MakeDirectory(const char* name)
virtual void* OpenDirectory(const char* name)
TGFALSystem& operator=(const TGFALSystem&)
virtual void ShowMembers(TMemberInspector& insp, char* parent)
virtual void Streamer(TBuffer& b)
void StreamerNVirtual(TBuffer& b)
private:
void* fDirp directory handler
TGFALFile
A TGFALFile is like a normal TFile except that it reads and writes
its data via the underlaying Grid access mechanism.
TGFALFile file names are either a logical file name, a guid, an
SURL or a TURL, like:
gfal:/lfn/user/r/rdm/galice.root
Grid storage interactions today require using several existing
software components:
- The replica catalog services to locate valid replicas of
files.
- The SRM software to ensure:
- files exist on disk (they are recalled from mass
storage if necessary) or
- space is allocated on disk for new files (they are possibly
migrated to mass storage later)
- A file access mechanism to access files from the storage
system on the worker node.
The GFAL library hides these interactions and presents a Posix
interface for the I/O operations. The currently supported protocols
are: file for local access, dcap, gsidcap and kdcap (dCache access
protocol) and rfio (CASTOR access protocol).
File naming convention:
A file name can be a Logical File Name (LFN), a Grid Unique
IDentifier (GUID), a file replica (SURL) or a Transport file
name (TURL):
an LFN starts with lfn:
for example lfn:baud/testgfal15
a GUID starts with guid:
for example guid:2cd59291-7ae7-4778-af6d-b1f423719441
an SURL starts with srm://
for example srm://wacdr002d.cern.ch:8443/castor/
cern.ch/user/b/baud/testgfal15
a TURL starts with a protocol name:
for example rfio:////castor/cern.ch/user/b/baud/testgfal15
Note that for the TGFALFile plugin to work, all these pathnames
should be prepended by gfal:.
TGFALSystem() : TSystem("-gfal", "GFAL Helper System")
Create helper class that allows directory access via GFAL.
Int_t MakeDirectory(const char *dir)
Make a directory via GFAL.
void* OpenDirectory(const char *dir)
Open a directory via GFAL. Returns an opaque pointer to a dir
structure. Returns 0 in case of error.
void FreeDirectory(void *dirp)
Free directory via GFAL.
const char* GetDirEntry(void *dirp)
Get directory entry via GFAL. Returns 0 in case no more entries.
Int_t GetPathInfo(const char *path, FileStat_t &buf)
Get info about a file. Info is returned in the form of a FileStat_t
structure (see TSystem.h).
The function returns 0 in case of success and 1 if the file could
not be stat'ed.
Bool_t AccessPathName(const char *path, EAccessMode mode)
Returns FALSE if one can access a file using the specified access mode.
Mode is the same as for the Unix access(2) function.
Attention, bizarre convention of return value!!
Inline Functions
void ~TGFALSystem()
void* GetDirPtr() const
TClass* Class()
TClass* IsA() const
void ShowMembers(TMemberInspector& insp, char* parent)
void Streamer(TBuffer& b)
void StreamerNVirtual(TBuffer& b)
TGFALSystem TGFALSystem(const TGFALSystem&)
TGFALSystem& operator=(const TGFALSystem&)
Author: Fons Rademakers 8/12/2005
Last update: root/gfal:$Name: $:$Id: TGFALFile.cxx,v 1.3 2006/02/24 08:55:26 brun Exp $
Copyright (C) 1995-2005, Rene Brun and Fons Rademakers. *
ROOT page - Class index - Class Hierarchy - Top of the page
This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.