Determine the directory location to use based on search prefixes.
More...
#include <SearchPath.hpp>
|
|
| SearchPath () |
| | Default constructor; initialize the parser to NULL.
|
|
| ~SearchPath () |
| | Destructor.
|
|
const std::string & | path () |
| | Get the resolved path.
|
| void | set_deserializer (std::unique_ptr< IValueDeserializer > fp) |
| | Set a custom parser.
|
| bool | load_file (const std::string &filename, const std::string &node="resources") |
| | Parse a file into memory.
|
|
| std::unique_ptr< IValueDeserializer > | fp_ |
| | Parser object to use.
|
| std::vector< std::string > | search_prefix_ |
| | List of path prefixes to scan through with the given path.
|
| std::string | path_ |
| | The resolved path.
|
Determine the directory location to use based on search prefixes.
- Todo
- Add an interface for using this class without a file.
Definition at line 46 of file SearchPath.hpp.
◆ raw_ptr
| typedef self_type* nom::SearchPath::raw_ptr |
◆ self_type
◆ shared_ptr
| typedef std::shared_ptr<self_type> nom::SearchPath::shared_ptr |
◆ unique_ptr
| typedef std::unique_ptr<self_type> nom::SearchPath::unique_ptr |
◆ load_file()
| bool nom::SearchPath::load_file |
( |
const std::string & | filename, |
|
|
const std::string & | node = "resources" ) |
Parse a file into memory.
- Parameters
-
| filename | The absolute file path. |
| node | The top-level object to use in formation of the path; defaults to an object member by name of "resources". |
◆ set_deserializer()
◆ fp_
◆ path_
| std::string nom::SearchPath::path_ |
|
private |
◆ search_prefix_
| std::vector<std::string> nom::SearchPath::search_prefix_ |
|
private |
List of path prefixes to scan through with the given path.
Definition at line 86 of file SearchPath.hpp.
The documentation for this class was generated from the following file:
- /home/jeff/Projects/nomlib.git/include/nomlib/serializers/SearchPath.hpp