LArFileHelper.h
Go to the documentation of this file.
1 /**
2  * @file larpandoracontent/LArHelpers/LArFileHelper.h
3  *
4  * @brief Header file for the file helper class
5  *
6  * $Log: $
7  */
8 #ifndef LAR_FILE_HELPER_H
9 #define LAR_FILE_HELPER_H 1
10 
11 #include <string>
12 
13 namespace lar_content
14 {
15 
16 /**
17  * @brief LArFileHelper class
18  */
20 {
21 public:
22  /**
23  * @brief Find the fully-qualified file name by searching through a list of delimiter-separated paths in a named environment
24  * variable. The fully-qualified file name will be provided for the first instance of the file name encountered.
25  *
26  * @param unqualifiedFileName the unqualified file name
27  * @param environmentVariable the name of the environment variable specifying a list of delimiter-separated paths
28  * @param delimiter the specified delimiter
29  *
30  * @return the fully-qualified name if found, else a StatusCode exception will be raised
31  */
32  static std::string FindFileInPath(const std::string &unqualifiedFileName, const std::string &environmentVariable, const std::string &delimiter = ":");
33 };
34 
35 } // namespace lar_content
36 
37 #endif // #ifndef LAR_FILE_HELPER_H
std::string string
Definition: nybbler.cc:12
static std::string FindFileInPath(const std::string &unqualifiedFileName, const std::string &environmentVariable, const std::string &delimiter=":")
Find the fully-qualified file name by searching through a list of delimiter-separated paths in a name...
LArFileHelper class.
Definition: LArFileHelper.h:19