/**
 * @file
 * $Id: pluginloader.h 2579 2005-10-04 16:15:50Z plasmahh $
 * $Revision: 2579 $
 * $Author: plasmahh $
 * $Date: 2005-10-04 18:15:50 +0200 (Di, 04 Okt 2005) $
 *
 * This file is part of The iWear Framework.
 *
 * The iWear Framework is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by the
 * Free Software Foundation as in version 2 of the License.

 * 
 * The iWear Framework is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
 * or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
 * more details.
 * 
 * You should have received a copy of the GNU General Public License along with
 * The iWear Framework; if not, write to the Free Software Foundation, Inc., 59
 * Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */

#ifndef __IWREMOTE_PLUGINLOADER_H
#define __IWREMOTE_PLUGINLOADER_H


#include <iwear/pluginhandle.h>

namespace iwear
{
    namespace net
    {

class CallProvider;
class CallManager;
class SearchProvider;

class PluginLoader: public PluginHandle
{
private:
protected:
    const char* (*pn)(void);
    const char* (*pv)(void);
    const char* (*pt)(void);

    uint32_t (*iv)(void);
public:
    PluginLoader( );
    virtual ~PluginLoader( );

    const char* get_plugin_name( void );

    const char* get_plugin_version( void );

    const char* get_plugin_type( void );
    
    uint32_t get_iwearrpc_version( void );
    
};

class CallProviderHandle: public PluginLoader
{
private:
protected:
    CallProvider* (*cp)(CallManager*);
    void (*dc)(CallProvider*);
public:

    CallProviderHandle( );
    virtual ~CallProviderHandle( );
    CallProvider* create_callprovider( CallManager* );
    void destroy_callprovider( CallProvider* );
};

class SearchProviderHandle: public PluginLoader
{
private:
protected:
    SearchProvider* (*cp)(CallManager*);
    void (*dc)(SearchProvider*);
public:

    SearchProviderHandle( );
    virtual ~SearchProviderHandle( );
    SearchProvider* create_searchprovider( CallManager* );
    void destroy_searchprovider( SearchProvider* );
};

}
}
#endif
