| The Gaudi Framework v32r1 (f65d50dc)

capi_pluginservice.h
Go to the documentation of this file.
1 #ifndef _GAUDI_C_PLUGIN_SERVICE_H_
2 #define _GAUDI_C_PLUGIN_SERVICE_H_ 1
3 /*****************************************************************************\
4 * (c) Copyright 2013 CERN *
5 * *
6 * This software is distributed under the terms of the GNU General Public *
7 * Licence version 3 (GPL Version 3), copied verbatim in the file "LICENCE". *
8 * *
9 * In applying this licence, CERN does not waive the privileges and immunities *
10 * granted to it by virtue of its status as an Intergovernmental Organization *
11 * or submit itself to any jurisdiction. *
12 \*****************************************************************************/
13
14 /* @author Sebastien Binet <binet@cern.ch> */
15
16 #include <stdint.h>
17
18 #ifdef __cplusplus
19 extern "C" {
20 #endif
21
22 #if __GNUC__ >= 4
23 # define CGAUDI_HASCLASSVISIBILITY
24 #endif
25
26 #if defined( CGAUDI_HASCLASSVISIBILITY )
27 # define CGAUDI_IMPORT __attribute__( ( visibility( "default" ) ) )
28 # define CGAUDI_EXPORT __attribute__( ( visibility( "default" ) ) )
29 # define CGAUDI_LOCAL __attribute__( ( visibility( "hidden" ) ) )
30 #else
31 # define CGAUDI_IMPORT
32 # define CGAUDI_EXPORT
33 # define CGAUDI_LOCAL
34 #endif
35
36 #define CGAUDI_API CGAUDI_EXPORT
37
38 typedef struct {
39 void* registry;
40 } cgaudi_pluginsvc_t;
41
42 typedef struct {
43 cgaudi_pluginsvc_t registry;
44 const char* id;
45 } cgaudi_factory_t;
46
47 typedef struct {
48 cgaudi_pluginsvc_t registry;
49 const char* id;
50 const char* key;
51 } cgaudi_property_t;
52
53 CGAUDI_API
54 cgaudi_pluginsvc_t cgaudi_pluginsvc_instance( void );
55
56 CGAUDI_API
57 int cgaudi_pluginsvc_get_factory_size( cgaudi_pluginsvc_t self );
58
59 CGAUDI_API
60 cgaudi_factory_t cgaudi_pluginsvc_get_factory_at( cgaudi_pluginsvc_t self, int n );
61
62 CGAUDI_API
63 const char* cgaudi_factory_get_library( cgaudi_factory_t self );
64
65 CGAUDI_API
66 const char* cgaudi_factory_get_type( cgaudi_factory_t self );
67
68 CGAUDI_API
69 const char* cgaudi_factory_get_classname( cgaudi_factory_t self );
70
71 CGAUDI_API
72 int cgaudi_factory_get_property_size( cgaudi_factory_t self );
73
74 CGAUDI_API
75 cgaudi_property_t cgaudi_factory_get_property_at( cgaudi_factory_t self, int n );
76
77 CGAUDI_API
78 const char* cgaudi_property_get_key( cgaudi_property_t self );
79
80 CGAUDI_API
81 const char* cgaudi_property_get_value( cgaudi_property_t self );
82
83 #ifdef __cplusplus
84 } /* extern "C" */
85 #endif
86
87 #endif /* !_GAUDI_C_PLUGIN_SERVICE_H_ */
cgaudi_factory_t::registry
cgaudi_pluginsvc_t registry
Definition: capi_pluginservice.h:43
cgaudi_property_get_key
CGAUDI_API const char * cgaudi_property_get_key(cgaudi_property_t self)
Definition: capi_pluginservice.cpp:63
cgaudi_pluginsvc_t
Definition: capi_pluginservice.h:38
cgaudi_factory_get_property_size
CGAUDI_API int cgaudi_factory_get_property_size(cgaudi_factory_t self)
Definition: capi_pluginservice.cpp:49
cgaudi_property_t::id
const char * id
Definition: capi_pluginservice.h:49
cgaudi_factory_get_classname
CGAUDI_API const char * cgaudi_factory_get_classname(cgaudi_factory_t self)
Definition: capi_pluginservice.cpp:42
CGAUDI_API
#define CGAUDI_API
Definition: capi_pluginservice.h:36
cgaudi_pluginsvc_get_factory_at
CGAUDI_API cgaudi_factory_t cgaudi_pluginsvc_get_factory_at(cgaudi_pluginsvc_t self, int n)
Definition: capi_pluginservice.cpp:23
GaudiPluginService.cpluginsvc.n
n
Definition: cpluginsvc.py:210
cgaudi_pluginsvc_t::registry
void * registry
Definition: capi_pluginservice.h:39
cgaudi_factory_t
Definition: capi_pluginservice.h:42
cgaudi_property_t::registry
cgaudi_pluginsvc_t registry
Definition: capi_pluginservice.h:48
cgaudi_pluginsvc_instance
CGAUDI_API cgaudi_pluginsvc_t cgaudi_pluginsvc_instance(void)
Definition: capi_pluginservice.cpp:13
cgaudi_property_t
Definition: capi_pluginservice.h:47
cgaudi_factory_get_property_at
CGAUDI_API cgaudi_property_t cgaudi_factory_get_property_at(cgaudi_factory_t self, int n)
Definition: capi_pluginservice.cpp:55
cgaudi_property_t::key
const char * key
Definition: capi_pluginservice.h:50
cgaudi_factory_t::id
const char * id
Definition: capi_pluginservice.h:44
cgaudi_pluginsvc_get_factory_size
CGAUDI_API int cgaudi_pluginsvc_get_factory_size(cgaudi_pluginsvc_t self)
Definition: capi_pluginservice.cpp:18
cgaudi_factory_get_type
CGAUDI_API const char * cgaudi_factory_get_type(cgaudi_factory_t self)
Definition: capi_pluginservice.cpp:35
cgaudi_factory_get_library
CGAUDI_API const char * cgaudi_factory_get_library(cgaudi_factory_t self)
Definition: capi_pluginservice.cpp:30
cgaudi_property_get_value
CGAUDI_API const char * cgaudi_property_get_value(cgaudi_property_t self)
Definition: capi_pluginservice.cpp:65