cppexpose
1.0.0.b785e04f23b8
C++ library for type introspection, reflection, and scripting interface
Main Page
Namespaces
Classes
Files
File List
File Members
cppexpose
include
cppexpose
plugin
plugin_api.h
Go to the documentation of this file.
1
2
#pragma once
3
4
5
#include <vector>
6
7
#include <
cppexpose/plugin/ComponentManager.h
>
8
#include <
cppexpose/plugin/ComponentRegistry.h
>
9
#include <
cppexpose/plugin/Component.h
>
10
11
12
#ifdef _MSC_VER
13
# define CPPEXPOSE_PLUGIN_API __declspec(dllexport)
14
#elif __GNUC__
15
# define CPPEXPOSE_PLUGIN_API __attribute__ ((visibility ("default")))
16
#else
17
# define CPPEXPOSE_PLUGIN_API __attribute__ ((visibility ("default")))
18
#endif
19
20
21
#define CPPEXPOSE_DECLARE_COMPONENT(TYPE, BASETYPE, TAGS, ICON, ANNOTATIONS, DESCRIPTION, VENDOR, VERSION) \
22
class ComponentType : public cppexpose::Component<TYPE, BASETYPE> \
23
{ \
24
public: \
25
ComponentType() \
26
: cppexpose::Component<TYPE, BASETYPE>( \
27
#TYPE, \
28
DESCRIPTION, \
29
#BASETYPE, \
30
TAGS, \
31
ICON, \
32
ANNOTATIONS, \
33
VENDOR, \
34
VERSION) \
35
{ \
36
cppexpose::ComponentManager::registry().addComponent(this); \
37
} \
38
}; \
39
\
40
static ComponentType Component;
41
42
#define CPPEXPOSE_COMPONENT(TYPE, BASETYPE) \
43
TYPE::ComponentType TYPE::Component;
Component.h
ComponentRegistry.h
ComponentManager.h
Generated on Sat Oct 20 2018 00:21:36 for cppexpose by
1.8.11