|
Rosetta
|
#include <GeneralFileManager.hh>

Public Member Functions | |
| std::string const & | get_file_contents (std::string const &filename) const |
| Get a weights file. Load it from disk if it has not already been loaded. More... | |
Public Member Functions inherited from utility::SingletonBase< GeneralFileManager > | |
| SingletonBase () | |
| public constructor (the derived class must have a private constructor, of course). More... | |
Private Member Functions | |
| GeneralFileManager () | |
| Empty constructor. More... | |
| GeneralFileManager (GeneralFileManager const &)=delete | |
| Explicitly deleted copy constructor. More... | |
| GeneralFileManager | operator= (GeneralFileManager const &)=delete |
| Explicitly deleted assignment operator. More... | |
Static Private Member Functions | |
| static GeneralFileContentsOP | create_instance (std::string const &script_file) |
| Create an instance of a GeneralFileContents object, by owning pointer. More... | |
Private Attributes | |
| std::map< std::string, GeneralFileContentsOP > | filename_to_filecontents_map_ |
| A map of filename to file contents. More... | |
Friends | |
| class | utility::SingletonBase< GeneralFileManager > |
Additional Inherited Members | |
Static Public Member Functions inherited from utility::SingletonBase< GeneralFileManager > | |
| static GeneralFileManager * | get_instance () |
| Safely instantiate a singleton class in a (possibly) multithreaded context. More... | |
|
private |
Empty constructor.
|
privatedelete |
Explicitly deleted copy constructor.
|
staticprivate |
Create an instance of a GeneralFileContents object, by owning pointer.
Needed for threadsafe creation. Loads data from disk. NOT for repeated calls!
References utility::filename().
Referenced by get_file_contents().
| std::string const & utility::io::GeneralFileManager::get_file_contents | ( | std::string const & | filename | ) | const |
Get a weights file. Load it from disk if it has not already been loaded.
Threadsafe and lazily loaded.
References create_instance(), utility::filename(), filename_to_filecontents_map_, plot::function, ptr(), utility::thread::safely_check_map_for_key_and_insert_if_absent(), and SAFELY_PASS_MUTEX.
|
privatedelete |
Explicitly deleted assignment operator.
|
friend |
|
mutableprivate |
A map of filename to file contents.
Referenced by get_file_contents().