virtual | ~TQPathManager() |
static TClass* | Class() |
bool | deleteLocalFile(TString filename) |
string | findConfigPath(TString filename, bool errorMessageIfNotFound = true, bool searchExecutionDir = true) |
static string | findFileFromEnvVar(const TString& filename, const string& envVar, bool printWarnings = true) |
static string | findFileFromEnvVarWithoutExecDir(const TString& filename, const string& envVar, bool printWarnings = true) |
static string | findFileFromList(TString filename, const string& searchPathList, bool printWarnings = true) |
static string | findFileFromListWithoutExecDir(TString filename, const string& searchPathList, bool printWarnings = true) |
vector<TString> | getAllTargetPaths() |
TString | getLocalDirectory() const |
string | getLocalPath(TString filename) |
static TQPathManager* | getPathManager() |
string | getTargetPath(TString filename, bool printWarnings = true) |
bool | getUseTemporaryStorage() const |
virtual TClass* | IsA() const |
TQPathManager& | operator=(const TQPathManager&) |
void | registerLocalPath(TString targetFile) |
bool | setLocalDirectory(TString localDirectory) |
void | setUseTemporaryStorage(bool useTemporaryStorage) |
void | setVerbose(bool verbose) |
void | setWorkingDirectory(TString dir) |
virtual void | ShowMembers(TMemberInspector& insp) const |
virtual void | Streamer(TBuffer&) |
void | StreamerNVirtual(TBuffer& ClassDef_StreamerNVirtual_b) |
TQPathManager(bool useTemporaryStorage = gUseTemporaryStorageDefault) | |
TQPathManager(const TQPathManager&) | |
TQPathManager(TString localDirectory, bool useTemporaryStorage = gUseTemporaryStorageDefault) | |
void | unregisterLocalPath(TString targetFile) |
virtual Bool_t | CheckTObjectHashConsistency() const |
void | deleteTargetPathEntry(const TString& filePath) |
TString | determineTargetDir() const |
static string | findFileFromEnvVar_internal(const TString& filename, const string& envVar, bool printWarnings, bool searchExecutionDir) |
static string | findFileFromList_internal(TString filename, const string& searchPathList, bool printWarnings, bool searchExecutionDir) |
TString | getTargetPathName(TString targetFile) const |
void | initialize(const TString& localDirectory, bool useTemporaryStorage) |
bool | isInLocalPaths_local(const TString& filePath) const |
bool | isInLocalPaths_target(TString filename) const |
bool | isInTargetPaths(const TString& filePath) const |
map<TString,bool> | alwaysReturnLocalPath | |
static int | filenameIndex | |
static TQPathManager | gPathManager | |
static bool | gPathManagerExists | |
static const bool | gUseTemporaryStorageDefault | |
TString | localDirectory | |
map<TString,TString> | localPaths | |
bool | pathsRequested | |
TString | pwd | |
vector<TString> | targetPaths | |
bool | useTemporaryStorage | |
bool | verbose |
Inheritance Chart: | |||||
|
Take value of envVar and use it to call findFileFromList
changes the working directory to the given path WARNING: this change affects the reading and writing location of files in many places, some of which the person calling this function (i.e., you) might not be aware of. Only call this function if you know *exactly* what you are doing and why!
Largely copied from Athena's more sophisticated PathResolver 1. if filename is given as absolute path, 1.1 if it exists, return absolute path 1.2 if it doesn't exist, return "" 2. if filename is local file and searchExecutionDir, return absolute path 3. if filename is in searchPathList, return absolute path 4. otherwise return ""
1. If temporary storage is disabled, return target path.
2. If target filename is on record, return corresponding local filename.
3. If target filename does not have a local equivalent, create the file
and return the its path.
Local files are saved in
"/tmp/<username>/<processNumber>_<filenameIndex>_<filename>".
Filenames with TQFolder syntax e.g. folder.root:objectinside>>::label are supported in these cases, only folder.root will be used for finding the config and the absolute path including :objectinside>>::label will be returned. You can ignore looking for configs in the execution directory with setting ignoreExecutionDirectory to true.
1. If temporary storage is disabled, 1.1 if target path is on record, delete it instead of local path and return true, 1.2 else return false 2. If file is not on record, return false. 3. Otherwise delete the file, erase the entry from localPaths and return true. Returns true if the file is on record (either in local or target location), otherwise returns false. This does not necessarily say that a file has been deleted. This method does not work properly if the variables useTemporaryStorage or localDirectory are changed after paths have been requested.
Construct local output directory.
1. Loop over all pairs of local and target files. Copy all local files to their target location.
Find out if filename is already in list of target files (i.e. if there is a local file associated with this target file).
Find out if filePath is already in list of local paths (i.e. if there is a target file associated with this local file).
@env:[CAFOUTPUTDIR] Directory which outputs produced by various CAF classes and tools should end up in
Constructor: Show a warning if environment variable CAFOUTPUTDIR cannot be read. gUseTemporaryStrageDefault is read from env vars "CAFUSETEMPDIR" or (at lower priority) "CAFUSELOCALSTORAGE" upon loading the library