Rosetta  2020.37
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
utility::Inline_File_Provider Class Reference

#include <inline_file_provider.hh>

Inheritance diagram for utility::Inline_File_Provider:
Inheritance graph
[legend]

Public Member Functions

void init_static_inputs ()
 
void show_contents ()
 
void add_input_file (const std::string &filename, const std::string &contents)
 
void add_black_listed_file (const std::string &filename)
 
void clear_input_files ()
 
void remove_input_file (const std::string &filename)
 
bool file_exists (const std::string &filename)
 
bool get_ostream (const std::string &filename, std::ostream **the_stream)
 
bool get_istream (const std::string &filename, std::istream **the_stream)
 
bool get_sstream (const std::string &filename, std::stringstream **the_stream)
 
void add_file_provider_hook (const Inline_File_Provider_HookOP &new_hook)
 
- Public Member Functions inherited from utility::SingletonBase< Inline_File_Provider >
 SingletonBase ()
 public constructor (the derived class must have a private constructor, of course). More...
 

Private Member Functions

bool is_black_listed_file (const std::string &filename)
 
bool find_sstream (std::vector< std::pair< std::string, std::stringstream * > > &file_catalog, const std::string &filename, std::stringstream **the_stream)
 
std::string standardise_filename (std::string filename)
 

Private Attributes

std::vector< std::pair
< std::string,
std::stringstream * > > 
input_files
 
std::vector< std::pair
< std::string,
std::stringstream * > > 
output_files
 
std::vector
< Inline_File_Provider_HookOP
file_provider_hooks_
 
std::vector< std::string > black_listed_files_
 

Friends

class utility::SingletonBase< Inline_File_Provider >
 

Additional Inherited Members

- Static Public Member Functions inherited from utility::SingletonBase< Inline_File_Provider >
static Inline_File_Providerget_instance ()
 Safely instantiate a singleton class in a (possibly) multithreaded context. More...
 

Member Function Documentation

void utility::Inline_File_Provider::add_black_listed_file ( const std::string &  filename)

References black_listed_files_.

void utility::Inline_File_Provider::add_file_provider_hook ( const Inline_File_Provider_HookOP new_hook)

References file_provider_hooks_.

void utility::Inline_File_Provider::add_input_file ( const std::string &  filename,
const std::string &  contents 
)
void utility::Inline_File_Provider::clear_input_files ( )

References input_files.

bool utility::Inline_File_Provider::file_exists ( const std::string &  filename)
bool utility::Inline_File_Provider::find_sstream ( std::vector< std::pair< std::string, std::stringstream * > > &  file_catalog,
const std::string &  filename,
std::stringstream **  the_stream 
)
private

Referenced by get_sstream().

bool utility::Inline_File_Provider::get_istream ( const std::string &  filename,
std::istream **  the_stream 
)
bool utility::Inline_File_Provider::get_ostream ( const std::string &  filename,
std::ostream **  the_stream 
)
bool utility::Inline_File_Provider::get_sstream ( const std::string &  filename,
std::stringstream **  the_stream 
)
void utility::Inline_File_Provider::init_static_inputs ( )
bool utility::Inline_File_Provider::is_black_listed_file ( const std::string &  filename)
private

References black_listed_files_, and utility::filename().

Referenced by get_istream().

void utility::Inline_File_Provider::remove_input_file ( const std::string &  filename)

References input_files.

void utility::Inline_File_Provider::show_contents ( )
std::string utility::Inline_File_Provider::standardise_filename ( std::string  filename)
private

Friends And Related Function Documentation

Member Data Documentation

std::vector< std::string > utility::Inline_File_Provider::black_listed_files_
private
std::vector<Inline_File_Provider_HookOP> utility::Inline_File_Provider::file_provider_hooks_
private
std::vector< std::pair < std::string, std::stringstream* > > utility::Inline_File_Provider::input_files
private
std::vector< std::pair < std::string, std::stringstream* > > utility::Inline_File_Provider::output_files
private

Referenced by get_ostream(), and get_sstream().


The documentation for this class was generated from the following files: