|
DUNE-DAQ
DUNE Trigger and Data Acquisition software
|
Path list handling mechanism. More...
#include <Path.hpp>
Public Member Functions | |
| Path () | |
| Path (const Path &other) | |
| Path (const std::string &path_list) | |
| contructor with a string | |
| operator std::string () const | |
| void | add (const OksSystem::File &dir) |
| add a directory to the path | |
| OksSystem::File | which (const std::string &name) const |
| resolve a name in the path | |
| void | write_to (std::ostream &stream) const |
| displays the path in a stream | |
| std::string | to_string () const |
| converts path into a string | |
Static Public Attributes | |
| static const char | PATH_SEPARATOR = ':' |
| char used as separator in strings (semi-colon) | |
Protected Member Functions | |
| void | parse_path_list (const std::string &path_list) |
| parse string containing path | |
Protected Attributes | |
| File::file_list_t | m_directories |
| list of directories | |
Path list handling mechanism.
This class represents an ordered set of directories. The main goal of this class is to proved tools to find a file in this set.
| OksSystem::Path::Path | ( | const Path & | other | ) |
Copy constructor
| other | the original object |
Definition at line 26 of file Path.cpp.
| OksSystem::Path::Path | ( | const std::string & | path_list | ) |
contructor with a string
Constructor
| path_list | string containing the list of directories |
Definition at line 34 of file Path.cpp.
| void OksSystem::Path::add | ( | const OksSystem::File & | dir | ) |
add a directory to the path
Add a directory to the path
| dir | the file to add |
| OksSystem::Path::operator std::string | ( | ) | const |
Definition at line 38 of file Path.cpp.
|
protected |
parse string containing path
Parses a string containing the path separated by semi-colons.
| path_list | the path |
Definition at line 57 of file Path.cpp.
| std::string OksSystem::Path::to_string | ( | ) | const |
converts path into a string
Prints the path into a string
Definition at line 99 of file Path.cpp.
| OksSystem::File OksSystem::Path::which | ( | const std::string & | name | ) | const |
resolve a name in the path
Finds the first occurence of a named file in the path.
| name | the name of the file to search for |
| EntityNotFoundIssue | if no matching file is found |
Definition at line 111 of file Path.cpp.
| void OksSystem::Path::write_to | ( | std::ostream & | stream | ) | const |
displays the path in a stream
Prints the path into a stream
| stream | destination stream |
Definition at line 82 of file Path.cpp.
|
protected |
|
static |