00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034 #ifndef _PDYNALINK
00035 #define _PDYNALINK
00036
00037 #if !defined(P_RTEMS)
00038
00039 #ifdef P_USE_PRAGMA
00040 #pragma interface
00041 #endif
00042
00051 class PDynaLink : public PObject
00052 {
00053 PCLASSINFO(PDynaLink, PObject);
00054
00055 public:
00061 PDynaLink();
00065 PDynaLink(
00066 const PString & name
00067 );
00068
00071 ~PDynaLink();
00073
00076
00077
00078
00079
00080
00081 virtual PBoolean Open(
00082 const PString & name
00083 );
00084
00087 virtual void Close();
00088
00091 virtual PBoolean IsLoaded() const;
00092
00102 virtual PString GetName(
00103 PBoolean full = PFalse
00104 ) const;
00105
00111 static PString GetExtension();
00113
00116
00117 typedef void (*Function)();
00118
00119
00125 PBoolean GetFunction(
00126 PINDEX index,
00127 Function & func
00128 );
00129
00135 PBoolean GetFunction(
00136 const PString & name,
00137 Function & func
00138 );
00140
00141
00142
00143 #ifdef _WIN32
00144 #include "msos/ptlib/dynalink.h"
00145 #else
00146 #include "unix/ptlib/dynalink.h"
00147 #endif
00148 };
00149
00150 #endif // !defined(P_RTEMS)
00151
00152 #endif
00153
00154