MyGUI
3.4.0
MyGUIEngine
include
MyGUI_DynLib.h
Go to the documentation of this file.
1
/*
2
* This source file is part of MyGUI. For the latest info, see http://mygui.info/
3
* Distributed under the MIT License
4
* (See accompanying file COPYING.MIT or copy at http://opensource.org/licenses/MIT)
5
*/
6
7
#ifndef MYGUI_DYNLIB_H_
8
#define MYGUI_DYNLIB_H_
9
10
#include "
MyGUI_Prerequest.h
"
11
#include <string>
12
13
14
#if MYGUI_PLATFORM == MYGUI_PLATFORM_WIN32
15
# define MYGUI_DYNLIB_HANDLE hInstance
16
struct
HINSTANCE__;
17
typedef
struct
HINSTANCE__* hInstance;
18
#elif MYGUI_PLATFORM == MYGUI_PLATFORM_LINUX
19
# define MYGUI_DYNLIB_HANDLE void*
20
#elif MYGUI_PLATFORM == MYGUI_PLATFORM_APPLE
21
# include <CoreFoundation/CFBundle.h>
22
# define MYGUI_DYNLIB_HANDLE CFBundleRef
23
#endif
24
25
namespace
MyGUI
26
{
27
34
class
MYGUI_EXPORT
DynLib
35
{
36
friend
class
DynLibManager
;
37
38
protected
:
39
DynLib
(
const
std::string& name);
40
41
public
:
42
45
bool
load();
46
49
void
unload();
50
52
std::string getName(
void
)
const
;
53
62
void
* getSymbol(
const
std::string& strName )
const
noexcept;
63
64
protected
:
66
std::string dynlibError()
const
;
67
68
protected
:
70
std::string
mName
;
71
73
MYGUI_DYNLIB_HANDLE
mInstance
;
74
};
75
76
}
// namespace MyGUI
77
78
#endif // MYGUI_DYNLIB_H_
MyGUI::DynLib::mName
std::string mName
Name of library.
Definition:
MyGUI_DynLib.h:70
MYGUI_DYNLIB_HANDLE
#define MYGUI_DYNLIB_HANDLE
Definition:
MyGUI_DynLib.h:19
MyGUI::DynLib
Resource holding data about a dynamic library.
Definition:
MyGUI_DynLib.h:35
MyGUI_Prerequest.h
MYGUI_EXPORT
#define MYGUI_EXPORT
Definition:
MyGUI_Platform.h:89
MyGUI::DynLib::mInstance
void * mInstance
Handle to the loaded library.
Definition:
MyGUI_DynLib.h:73
MyGUI
Definition:
MyGUI_ActionController.h:15
MyGUI::DynLibManager
Manager of dynamic libraries.
Definition:
MyGUI_DynLibManager.h:22
Generated by
1.8.20