33 #include "../translator/Translator.h" 39 #include <boost/format.hpp> 51 boost::format err_msg(
TE_TR(
"There is already a library registered with the name: %1%."));
65 {
return le.m_name == name; });
69 boost::format err_msg(
TE_TR(
"There is no library registered with the name: %1%."));
76 boost::format err_msg(
TE_TR(
"The library cannot be initialized in order to remove it."));
94 boost::format err_msg(
TE_TR(
"There is no library registered with the name: %1%."));
108 boost::format err_msg(
TE_TR(
"There is no library registered with the name: %1%."));
Base exception class for plugin module.
Specific exception types for Library Manager.
#define TE_TR(message)
It marks a string in order to get translated.
static LibraryManager & instance()
It returns a reference to the singleton instance.
boost::error_info< struct tag_error_description, std::string > ErrorDescription
The base type for error report messages.
A singleton that can be used to observe the available libraries in the system.
bool isInitialized(const std::string &name)
The current state of the LibraryEntry.
std::vector< te::core::LibraryEntry > library_entries
LibraryManager()
Singleton constructor must be private or protected.
A singleton that can be used to observe the available shared libraries in the system.
const LibraryEntry & get(const std::string &name)
Return a null pointer if a library doesnt't exist.
An exception indicating that a given item was not found in a collection (or range).
~LibraryManager()
Singleton destructor must be private or protected.
An exception indicating that a given argument is not valid, for instance if a given item already exis...
void insert(const LibraryEntry &entry)
It inserts a LibraryEntry to the manager.
bool exists(const std::string &name)
Checks if a LibraryEntry exists from a given name.
void remove(const std::string &name)
It removes a LibraryEntry from the manager.