00001 // this is for emacs file handling -*- mode: c++; indent-tabs-mode: nil -*- 00002 //---------------------------------------------------------------------- 00010 //---------------------------------------------------------------------- 00011 #include "icl_core_plugin/PluginManagerBase.h" 00012 00013 namespace icl_core { 00014 namespace plugin { 00015 00016 PluginManagerBase::PluginManagerBase(std::string plugin_dir) 00017 { 00018 addPluginPath(plugin_dir); 00019 } 00020 00021 StringList PluginManagerBase::pluginPaths() 00022 { 00023 return m_plugin_paths; 00024 } 00025 00026 void PluginManagerBase::addPluginPath(const std::string &path) 00027 { 00028 if (path != "") 00029 { 00030 m_plugin_paths.push_back(path); 00031 } 00032 else 00033 { 00034 LOGGING_TRACE(Plugin, "Cannot use an empty plugin path" << icl_core::logging::endl); 00035 } 00036 } 00037 00038 StringList PluginManagerBase::errorMessages() 00039 { 00040 return m_error_messages; 00041 } 00042 00044 #ifdef _IC_BUILDER_DEPRECATED_STYLE_ 00045 00049 StringList PluginManagerBase::PluginPaths() 00050 { 00051 return pluginPaths(); 00052 } 00053 00057 void PluginManagerBase::AddPluginPath(const std::string &path) 00058 { 00059 addPluginPath(path); 00060 } 00061 00067 StringList PluginManagerBase::ErrorMessages() 00068 { 00069 return errorMessages(); 00070 } 00071 00072 #endif 00073 00074 00075 void PluginManagerBase::clearErrorMessages() 00076 { 00077 m_error_messages.clear(); 00078 } 00079 00080 void PluginManagerBase::addErrorMessage(const std::string &message) 00081 { 00082 m_error_messages.push_back(message); 00083 } 00084 00086 #ifdef _IC_BUILDER_DEPRECATED_STYLE_ 00087 00088 void PluginManagerBase::ClearErrorMessages() 00089 { 00090 clearErrorMessages(); 00091 } 00092 00093 void PluginManagerBase::AddErrorMessage(const std::string &message) 00094 { 00095 addErrorMessage(message); 00096 } 00097 00098 #endif 00099 00100 00101 } 00102 }