Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

PluginMgr.h

Go to the documentation of this file.
00001 /***************************************************************************
00002  *cr
00003  *cr            (C) Copyright 1995-2019 The Board of Trustees of the
00004  *cr                        University of Illinois
00005  *cr                         All Rights Reserved
00006  *cr
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  * RCS INFORMATION:
00011  *
00012  *      $RCSfile: PluginMgr.h,v $
00013  *      $Author: johns $        $Locker:  $             $State: Exp $
00014  *      $Revision: 1.17 $       $Date: 2019/01/17 21:21:01 $
00015  *
00016  ***************************************************************************
00017  * DESCRIPTION:
00018  *   Plugin Manager: Scans a specified set of directories looking for shared
00019  *   libraries that implement the vmdplugin interface.  Stores a copy of 
00020  *   the plugins it finds so that they can be passed off to other routines that
00021  *   know the specific interface for the plugin.
00022  * 
00023  * LICENSE:
00024  *   UIUC Open Source License
00025  *   http://www.ks.uiuc.edu/Research/vmd/plugins/pluginlicense.html
00026  *
00027  ***************************************************************************/
00028 #ifndef PLUGIN_MGR_H__
00029 #define PLUGIN_MGR_H__
00030 
00031 #include "ResizeArray.h"
00032 #include "vmdplugin.h"
00033 
00034 typedef ResizeArray<vmdplugin_t *> PluginList;
00035 
00040 class PluginMgr {
00041 public:
00042   PluginMgr();
00043   virtual ~PluginMgr();
00044 
00047   int load_static_plugins();
00048 
00052   int load_sharedlibrary_plugins(const char *path);
00053   
00057   int plugins(PluginList &, const char * = 0, const char * = 0);
00058   
00059 protected:
00060   int add_plugin(const char *path, const char *file);
00061   PluginList pluginlist;
00062   ResizeArray<void *>handlelist;
00063 
00064   static int register_cb(void *, vmdplugin_t *);
00065   int num_in_library;
00066   const char *curpath;  
00067 };    
00068 
00069 #endif

Generated on Wed Oct 9 02:43:22 2024 for VMD (current) by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002