VTK
vtkDynamicLoader.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkDynamicLoader.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
24 #ifndef vtkDynamicLoader_h
25 #define vtkDynamicLoader_h
26 
27 #include "vtkCommonCoreModule.h" // For export macro
28 #include "vtkObject.h"
29 #include <vtksys/DynamicLoader.hxx>
30 
31 //BTX
32 typedef vtksys::DynamicLoader::LibraryHandle vtkLibHandle;
33 // Cannot use this as this is a void (*)() but VTK old API used to be void*
34 typedef vtksys::DynamicLoader::SymbolPointer vtkSymbolPointer;
35 //ETX
36 
38 {
39 public:
40  static vtkDynamicLoader* New();
41  vtkTypeMacro(vtkDynamicLoader,vtkObject);
42 
43  //BTX
46  static vtkLibHandle OpenLibrary(const char*);
47 
50  static int CloseLibrary(vtkLibHandle);
51 
53 
55  static void* GetSymbolAddress(vtkLibHandle, const char*);
56  //ETX
58 
60  static const char* LibPrefix();
61 
63  static const char* LibExtension();
64 
66  static const char* LastError();
67 
68 protected:
71 
72 private:
73  vtkDynamicLoader(const vtkDynamicLoader&); // Not implemented.
74  void operator=(const vtkDynamicLoader&); // Not implemented.
75 };
76 
77 #endif
78 // VTK-HeaderTest-Exclude: vtkDynamicLoader.h
abstract base class for most VTK objects
Definition: vtkObject.h:61
#define VTKCOMMONCORE_EXPORT
vtksys::DynamicLoader::SymbolPointer vtkSymbolPointer
vtksys::DynamicLoader::LibraryHandle vtkLibHandle
class interface to system dynamic libraries
static vtkObject * New()