LoadPlugin.h

Go to the documentation of this file.
00001 /***************************************************************************
00002  * File:        ./LoadPlugin.h
00003  * Author:      Ronni Grapenthin, NORVULK & HU-BERLIN
00004  * Created:     09.03.2007
00005  * Licence:     GPLv2
00006  *
00007  * #########################################################################
00008  *
00009  * CrusDe, simulation framework for crustal deformation studies
00010  * Copyright (C) 2007 Ronni Grapenthin
00011  *
00012  * This program is free software; you can redistribute it and/or
00013  * modify it under the terms of the GNU General Public License
00014  * as published by the Free Software Foundation; version 2
00015  * of the License.
00016  *
00017  * This program is distributed in the hope that it will be useful,
00018  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00019  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00020  * GNU General Public License for more details.
00021  *
00022  * You should have received a copy of the GNU General Public License
00023  * along with this program; if not, write to the Free Software
00024  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
00025  *
00026  ****************************************************************************/
00027 
00028 #ifndef _load_plugin_h
00029 #define _load_plugin_h
00030 
00031 #include "Plugin.h"
00032 #include "constants.h"
00033 #include "config.h"
00034 #include <iostream>
00035 #include <cassert>
00036 #include <dlfcn.h>
00037 
00038 using namespace std;
00039 
00040 //typedef void (*value_void_t)(loadhistory_exec_function);
00041 
00045 class LoadPlugin : public Plugin
00046 {
00047 
00048         private:
00049                 load_exec_function        func_value;                   /*  Pointer to loaded routine   */
00050 //              value_void_t   set_history_func_value;  /*  pointer to loaded set history function */
00052                 LoadPlugin(const LoadPlugin& x); 
00053 
00054         public:
00055                 LoadPlugin(const string=NULL);  /* Constructor */
00056                 virtual ~LoadPlugin();          /* Destructor */
00057                 
00058                 virtual void load(const string) throw (FileNotFound, LibHandleError);
00059 //              virtual void selftest();
00060 //              void    setHistoryFunction(loadhistory_exec_function history_func) throw (LibHandleError);
00061                 
00062                 /*plug - in interface*/
00063                 double  getValueAt(int, int);                   
00064                 
00065                 /*get pointers to exec functions*/
00066                 load_exec_function getValueFunction();
00067 };
00068 
00069 #endif // _load_plugin_h

Generated on Sun Aug 31 13:19:00 2008 for CrusDe by  doxygen 1.5.0