22 #ifndef __KPIM_SHARED_PLUGINLOADER_H__
23 #define __KPIM_SHARED_PLUGINLOADER_H__
25 #include <pluginloaderbase.h>
78 template< typename T, typename T_config >
102 doScan( T_config::path );
109 void * main_func = mainFunc( type, T_config::mainfunc );
110 if ( !main_func ) return 0;
114 return ((T* (*)())( main_func ))();
118 template< typename T, typename T_config >
119 PluginLoader<T,T_config> * PluginLoader<T,T_config>::mSelf = 0;
123 #define KPIM_DEFINE_PLUGIN_LOADER( pl, t, mf, p ) \
125 struct KDE_EXPORT pl##Config { \
126 static const char * const mainfunc; \
127 static const char * const path; \
129 const char * const pl##Config::mainfunc = mf; \
130 const char * const pl##Config::path = p; \
132 typedef KPIM::PluginLoader< t, pl##Config > pl; \
135 #endif // __KPIM_SHARED_PLUGINLOADER_H__
|