Classes | Public Member Functions | Static Public Member Functions | Static Public Attributes | Private Member Functions | Private Attributes | List of all members
art::InputFileCatalog Class Reference

#include "/cvmfs/nova.opensciencegrid.org/externals/art/v2_13_00/source/art/Framework/IO/Catalog/InputFileCatalog.h"

Inheritance diagram for art::InputFileCatalog:
art::FileCatalog

Classes

struct  Config
 

Public Member Functions

 InputFileCatalog (fhicl::TableFragment< Config > const &config)
 
virtual ~InputFileCatalog ()=default
 
std::vector< FileCatalogItem > const & fileCatalogItems () const
 
FileCatalogItem const & currentFile () const
 
size_t currentIndex () const
 
bool getNextFile (int attempts=5)
 
bool hasNextFile (int attempts=5)
 
void rewind ()
 
void rewindTo (size_t index)
 
bool isSearchable ()
 
bool empty () const
 
void finish ()
 
std::vector< std::string > const & fileSources () const
 
void commitCatalog ()
 
std::stringurl ()
 
std::string const & url () const
 
void setActive ()
 
bool active () const
 

Static Public Member Functions

static bool isPhysical (std::string const &name)
 

Static Public Attributes

static constexpr size_t indexEnd {std::numeric_limits<size_t>::max()}
 

Private Member Functions

bool retrieveNextFile (FileCatalogItem &item, int attempts, bool transferOnly=false)
 
FileCatalogStatus retrieveNextFileFromCacheOrService (FileCatalogItem &item)
 
FileCatalogStatus transferNextFile (FileCatalogItem &item)
 

Private Attributes

std::vector< std::stringfileSources_
 
std::vector< FileCatalogItemfileCatalogItems_ {{}}
 
FileCatalogItem nextItem_ {}
 
size_t fileIdx_ {indexEnd}
 
size_t maxIdx_ {}
 
bool searchable_ {false}
 
bool nextFileProbed_ {false}
 
bool hasNextFile_ {false}
 
ServiceHandle< CatalogInterfaceci_
 
ServiceHandle< FileTransferft_
 

Detailed Description

Definition at line 33 of file InputFileCatalog.h.

Constructor & Destructor Documentation

art::InputFileCatalog::InputFileCatalog ( fhicl::TableFragment< Config > const &  config)
explicit
virtual art::InputFileCatalog::~InputFileCatalog ( )
virtualdefault

Member Function Documentation

bool art::FileCatalog::active ( ) const
inlineinherited

Definition at line 113 of file FileCatalog.h.

114  {
115  return active_;
116  }
void art::FileCatalog::commitCatalog ( )
inlineinherited

Definition at line 90 of file FileCatalog.h.

91  {}
FileCatalogItem const& art::InputFileCatalog::currentFile ( ) const
size_t art::InputFileCatalog::currentIndex ( ) const
bool art::InputFileCatalog::empty ( ) const
inline

Definition at line 58 of file InputFileCatalog.h.

59  {
60  return fileCatalogItems_.empty();
61  }
std::vector< FileCatalogItem > fileCatalogItems_
std::vector<FileCatalogItem> const& art::InputFileCatalog::fileCatalogItems ( ) const
inline

Definition at line 42 of file InputFileCatalog.h.

References samweb_client.projects::getNextFile(), and allTimeWatchdog::index.

43  {
44  return fileCatalogItems_;
45  }
std::vector< FileCatalogItem > fileCatalogItems_
std::vector<std::string> const& art::InputFileCatalog::fileSources ( ) const
inline

Definition at line 64 of file InputFileCatalog.h.

65  {
66  return fileSources_;
67  }
std::vector< std::string > fileSources_
void art::InputFileCatalog::finish ( )
bool art::InputFileCatalog::getNextFile ( int  attempts = 5)
bool art::InputFileCatalog::hasNextFile ( int  attempts = 5)
static bool art::FileCatalog::isPhysical ( std::string const &  name)
inlinestaticinherited

Definition at line 93 of file FileCatalog.h.

References string.

94  {
95  return (name.empty() || name.find(':') != std::string::npos);
96  }
const XML_Char * name
Definition: expat.h:151
bool art::InputFileCatalog::isSearchable ( )
inline

Definition at line 53 of file InputFileCatalog.h.

54  {
55  return searchable_;
56  }
bool art::InputFileCatalog::retrieveNextFile ( FileCatalogItem item,
int  attempts,
bool  transferOnly = false 
)
private
FileCatalogStatus art::InputFileCatalog::retrieveNextFileFromCacheOrService ( FileCatalogItem item)
private
void art::InputFileCatalog::rewind ( )
void art::InputFileCatalog::rewindTo ( size_t  index)
void art::FileCatalog::setActive ( )
inlineinherited

Definition at line 108 of file FileCatalog.h.

109  {
110  active_ = true;
111  }
FileCatalogStatus art::InputFileCatalog::transferNextFile ( FileCatalogItem item)
private
std::string& art::FileCatalog::url ( )
inlineinherited

Definition at line 98 of file FileCatalog.h.

References string.

99  {
100  return url_;
101  }
std::string url_
Definition: FileCatalog.h:119
std::string const& art::FileCatalog::url ( ) const
inlineinherited

Definition at line 103 of file FileCatalog.h.

104  {
105  return url_;
106  }
std::string url_
Definition: FileCatalog.h:119

Member Data Documentation

ServiceHandle<CatalogInterface> art::InputFileCatalog::ci_
private

Definition at line 87 of file InputFileCatalog.h.

std::vector<FileCatalogItem> art::InputFileCatalog::fileCatalogItems_ {{}}
private

Definition at line 79 of file InputFileCatalog.h.

size_t art::InputFileCatalog::fileIdx_ {indexEnd}
private

Definition at line 81 of file InputFileCatalog.h.

std::vector<std::string> art::InputFileCatalog::fileSources_
private

Definition at line 78 of file InputFileCatalog.h.

ServiceHandle<FileTransfer> art::InputFileCatalog::ft_
private

Definition at line 88 of file InputFileCatalog.h.

bool art::InputFileCatalog::hasNextFile_ {false}
private

Definition at line 85 of file InputFileCatalog.h.

constexpr size_t art::InputFileCatalog::indexEnd {std::numeric_limits<size_t>::max()}
static

Definition at line 69 of file InputFileCatalog.h.

size_t art::InputFileCatalog::maxIdx_ {}
private

Definition at line 82 of file InputFileCatalog.h.

bool art::InputFileCatalog::nextFileProbed_ {false}
private

Definition at line 84 of file InputFileCatalog.h.

FileCatalogItem art::InputFileCatalog::nextItem_ {}
private

Definition at line 80 of file InputFileCatalog.h.

bool art::InputFileCatalog::searchable_ {false}
private

Definition at line 83 of file InputFileCatalog.h.


The documentation for this class was generated from the following file: