00001 // this is for emacs file handling -*- mode: c++; indent-tabs-mode: nil -*- 00002 00003 // -- BEGIN LICENSE BLOCK ---------------------------------------------- 00004 // This file is part of FZIs ic_workspace. 00005 // 00006 // This program is free software licensed under the LGPL 00007 // (GNU LESSER GENERAL PUBLIC LICENSE Version 3). 00008 // You can find a copy of this license in LICENSE folder in the top 00009 // directory of the source code. 00010 // 00011 // © Copyright 2016 FZI Forschungszentrum Informatik, Karlsruhe, Germany 00012 // 00013 // -- END LICENSE BLOCK ------------------------------------------------ 00014 00015 //---------------------------------------------------------------------- 00027 //---------------------------------------------------------------------- 00028 #ifndef ICL_CORE_PLUGIN_PLUGIN_MANAGER_BASE_H_INCLUDED 00029 #define ICL_CORE_PLUGIN_PLUGIN_MANAGER_BASE_H_INCLUDED 00030 00031 #include "icl_core_plugin/ImportExport.h" 00032 #include "icl_core_plugin/Logging.h" 00033 00034 #include <string> 00035 #include <list> 00036 00037 namespace icl_core { 00038 namespace plugin { 00039 00040 typedef std::list<std::string> StringList; 00041 00042 class ICL_CORE_PLUGIN_IMPORT_EXPORT PluginManagerBase 00043 { 00044 public: 00048 explicit PluginManagerBase(std::string plugin_dir = ""); 00049 00052 StringList pluginPaths(); 00053 00058 void addPluginPath(const std::string &path); 00059 00064 StringList errorMessages(); 00065 00067 #ifdef _IC_BUILDER_DEPRECATED_STYLE_ 00068 00072 ICL_CORE_VC_DEPRECATE_STYLE StringList PluginPaths() ICL_CORE_GCC_DEPRECATE_STYLE; 00073 00077 ICL_CORE_VC_DEPRECATE_STYLE void AddPluginPath(const std::string &path) 00078 ICL_CORE_GCC_DEPRECATE_STYLE; 00079 00085 ICL_CORE_VC_DEPRECATE_STYLE StringList ErrorMessages() ICL_CORE_GCC_DEPRECATE_STYLE; 00086 00087 #endif 00088 00089 00090 protected: 00091 void clearErrorMessages(); 00092 00093 void addErrorMessage(const std::string &message); 00094 00096 #ifdef _IC_BUILDER_DEPRECATED_STYLE_ 00097 00098 ICL_CORE_VC_DEPRECATE_STYLE void ClearErrorMessages() ICL_CORE_GCC_DEPRECATE_STYLE; 00099 00100 ICL_CORE_VC_DEPRECATE_STYLE void AddErrorMessage(const std::string &message) 00101 ICL_CORE_GCC_DEPRECATE_STYLE; 00102 00103 #endif 00104 00105 00106 StringList m_error_messages; 00107 00108 private: 00109 StringList m_plugin_paths; 00110 }; 00111 00112 } 00113 } 00114 00115 #endif