1 #ifndef __CPPLUGINS__INTERFACE__INTERFACE__H__
2 #define __CPPLUGINS__INTERFACE__INTERFACE__H__
7 #include <Pluma/Pluma.hpp>
9 #include <cpPlugins/Interface/cpPlugins_Interface_Export.h>
10 #include <cpPlugins/Interface/Object.h>
11 #include <cpPlugins/Interface/ProcessObject.h>
19 class cpPlugins_Interface_EXPORT Interface
22 typedef Interface Self;
23 typedef std::vector< ProcessObjectProvider* > TProviders;
24 typedef std::map< std::string, unsigned int > TClass;
25 typedef std::map< std::string, TClass > TClasses;
27 std::map< std::string, std::vector< std::string > >
30 typedef TProviders::const_iterator TProvidersIterator;
31 typedef TClasses::const_iterator TClassesIterator;
35 virtual ~Interface( );
37 bool LoadDefaultConfiguration( const std::string& path );
38 bool SaveDefaultConfiguration( const std::string& path );
41 TClasses& GetClasses( );
42 const TClasses& GetClasses( ) const;
43 TLoadedPlugins& GetLoadedPlugins( );
44 const TLoadedPlugins& GetLoadedPlugins( ) const;
45 ProcessObject::Pointer CreateObject( const std::string& name ) const;
48 bool Load( const std::string& path );
49 bool Load( const std::string& folder, const std::string& name );
50 bool LoadFromFolder( const std::string& folder, bool r = false );
51 bool Unload( const std::string& name );
53 bool IsLoaded( const std::string& name ) const;
58 static void _SepFName(
59 const std::string& path,
66 TProviders m_Providers;
68 TLoadedPlugins m_LoadedPlugins;
75 #endif // __CPPLUGINS__INTERFACE__INTERFACE__H__