CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
TStorageFactorySystem Class Reference

#include <TStorageFactorySystem.h>

Inheritance diagram for TStorageFactorySystem:

Public Member Functions

Bool_t AccessPathName (const char *path, EAccessMode mode) override
 
 ClassDefOverride (TStorageFactorySystem, 0)
 
void FreeDirectory (void *dirp) override
 
const char * GetDirEntry (void *dirp) override
 
Int_t GetPathInfo (const char *path, FileStat_t &info) override
 
Int_t MakeDirectory (const char *name) override
 
void * OpenDirectory (const char *name) override
 
 TStorageFactorySystem (const char *, Bool_t)
 
 TStorageFactorySystem (void)
 
int Unlink (const char *name) override
 
 ~TStorageFactorySystem (void) override
 

Private Member Functions

void * GetDirPt (void) const
 

Private Attributes

void * fDirp
 

Detailed Description

TSystem wrapper around StorageFactory and CMS Storage. This class is a blatant copy of TDCacheSystem.

Definition at line 10 of file TStorageFactorySystem.h.

Constructor & Destructor Documentation

TStorageFactorySystem::TStorageFactorySystem ( const char *  ,
Bool_t   
)

Definition at line 6 of file TStorageFactorySystem.cc.

7  : TSystem("-StorageFactory", "Storage Factory System"), fDirp(nullptr) {
8  SetName("StorageFactory");
9 }
TStorageFactorySystem::TStorageFactorySystem ( void  )

Definition at line 11 of file TStorageFactorySystem.cc.

Referenced by GetDirPt().

12  : TSystem("-StorageFactory", "Storage Factory System"), fDirp(nullptr) {
13  SetName("StorageFactory");
14 }
TStorageFactorySystem::~TStorageFactorySystem ( void  )
override

Definition at line 16 of file TStorageFactorySystem.cc.

Referenced by GetDirPt().

16 {}

Member Function Documentation

Bool_t TStorageFactorySystem::AccessPathName ( const char *  path,
EAccessMode  mode 
)
override

Definition at line 38 of file TStorageFactorySystem.cc.

References StorageFactory::check(), and StorageFactory::get().

Referenced by GetDirPt().

38  {
39  // NB: This return reverse of check(): kTRUE if access *fails*
40  return name ? !StorageFactory::get()->check(name) : kTRUE;
41 }
bool check(const std::string &url, IOOffset *size=0) const
static const StorageFactory * get(void)
TStorageFactorySystem::ClassDefOverride ( TStorageFactorySystem  ,
 
)

Referenced by GetDirPt().

void TStorageFactorySystem::FreeDirectory ( void *  dirp)
override

Definition at line 31 of file TStorageFactorySystem.cc.

Referenced by GetDirPt().

31 { Error("FreeDirectory", "Unsupported"); }
edm::ErrorSummaryEntry Error
const char * TStorageFactorySystem::GetDirEntry ( void *  dirp)
override

Definition at line 33 of file TStorageFactorySystem.cc.

Referenced by GetDirPt().

33  {
34  Error("GetDirEntry", "Unsupported");
35  return nullptr;
36 }
edm::ErrorSummaryEntry Error
void* TStorageFactorySystem::GetDirPt ( void  ) const
inlineprivate
Int_t TStorageFactorySystem::GetPathInfo ( const char *  path,
FileStat_t &  info 
)
override

Definition at line 48 of file TStorageFactorySystem.cc.

References trackerTree::check(), and StorageFactory::get().

Referenced by GetDirPt().

48  {
49  info.fDev = 0;
50  info.fIno = 0;
51  info.fMode = 0644;
52  info.fUid = 0;
53  info.fGid = 0;
54  info.fSize = 0;
55  info.fMtime = 0;
56 
57  IOOffset storageSize;
58  if (StorageFactory::get()->check(name, &storageSize)) {
59  info.fSize = storageSize;
60  return 0;
61  }
62 
63  return -1;
64 }
static const TGPicture * info(bool iBackgroundIsBlack)
static const StorageFactory * get(void)
int64_t IOOffset
Definition: IOTypes.h:19
def check(config)
Definition: trackerTree.py:14
Int_t TStorageFactorySystem::MakeDirectory ( const char *  name)
override

Definition at line 21 of file TStorageFactorySystem.cc.

Referenced by GetDirPt().

21  {
22  Error("MakeDirectory", "Unsupported");
23  return -1;
24 }
edm::ErrorSummaryEntry Error
void * TStorageFactorySystem::OpenDirectory ( const char *  name)
override

Definition at line 26 of file TStorageFactorySystem.cc.

Referenced by GetDirPt().

26  {
27  Error("OpenDirectory", "Unsupported");
28  return nullptr;
29 }
edm::ErrorSummaryEntry Error
Int_t TStorageFactorySystem::Unlink ( const char *  name)
override

Definition at line 43 of file TStorageFactorySystem.cc.

Referenced by GetDirPt().

43  {
44  Error("Unlink", "Unsupported");
45  return 1;
46 }
edm::ErrorSummaryEntry Error

Member Data Documentation

void* TStorageFactorySystem::fDirp
private

Definition at line 12 of file TStorageFactorySystem.h.

Referenced by GetDirPt().