| # Gaudi Framework, version v25r0 |

Home |  | Generated: Mon Feb 17 2014

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Namespace List
- Namespace Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Classes | Functions | Variables
GaudiPluginService.cpluginsvc Namespace Reference

## Classes
class | Registry
class | Factory
class | Property

## Functions
def | _get_filename
def | registry
def | factories

## Variables
string | __doc__
| cpluginsvc is a ctypes-based wrapper for the C-exposed API of GaudiPluginService
tuple | __all__
| _libname None
tuple | _lib ctypes.cdll.LoadLibrary(_libname)
| _instance None
list | _functions_list
list | n f[0]
tuple | func getattr(_lib, n)

## Function Documentation

def GaudiPluginService.cpluginsvc._get_filename | ( |  | ) |
| private

Definition at line 31 of file cpluginsvc.py.

31
32 def _get_filename():
33 if _libname:
34 return _libname
35 import platform
36 name = platform.system()
37
38 fname = {
39 'Darwin': "libGaudiPluginService.so", # or .dylib ? FIXME
40 'Windows': "libGaudiPluginService.dll",
41 'Linux': "libGaudiPluginService.so",
42 }[name]
43 return fname

def GaudiPluginService.cpluginsvc.factories | ( |  | ) |

    factories returns the list of components factory informations known to the plugin service

Definition at line 72 of file cpluginsvc.py.

72
73 def factories():
74 '''
75 factories returns the list of components factory informations known to the plugin service
76 '''
77 return registry().factories

def GaudiPluginService.cpluginsvc.registry | ( |  | ) |

    registry returns the singleton-like instance of the plugin service.

Definition at line 63 of file cpluginsvc.py.

63
64 def registry():
65 '''registry returns the singleton-like instance of the plugin service.'''
66
67 global _instance
68 if _instance:
69 return _instance
70 _instance = _lib.cgaudi_pluginsvc_instance()
71 return _instance

## Variable Documentation

tuple GaudiPluginService.cpluginsvc.__all__

Initial value:
1 (
2 "Registry",
3 "registry",
4 "factories",
5 "Factory",
6 "Property",
7 )

Definition at line 22 of file cpluginsvc.py.

string GaudiPluginService.cpluginsvc.__doc__

Initial value:
1 '''
2 cpluginsvc is a ctypes-based wrapper for the C-API of the GaudiPluginService.
3
4 e.g.:
5
6 >>> from GaudiPluginService import cpluginsvc
7 >>> for _,f in cpluginsvc.factories().items():
8 ... try:
9 ... f.load()
10 ... except Exception:
11 ... print ("** could not load [%s] for factory [%s]" % (f.library, f.name))
12 ... continue
13 ... print f
14 ... for k,v in f.properties.iteritems():
15 ... print ("\t%s: %s" % (k,v))
16 '''

cpluginsvc is a ctypes-based wrapper for the C-exposed API of GaudiPluginService

Definition at line 2 of file cpluginsvc.py.

list GaudiPluginService.cpluginsvc._functions_list

Definition at line 159 of file cpluginsvc.py.

GaudiPluginService.cpluginsvc._instance None

Definition at line 62 of file cpluginsvc.py.

tuple GaudiPluginService.cpluginsvc._lib ctypes.cdll.LoadLibrary(_libname)

Definition at line 45 of file cpluginsvc.py.

tuple GaudiPluginService.cpluginsvc._libname None

Definition at line 30 of file cpluginsvc.py.

tuple GaudiPluginService.cpluginsvc.func getattr(_lib, n)

Definition at line 218 of file cpluginsvc.py.

list GaudiPluginService.cpluginsvc.n f[0]

Definition at line 217 of file cpluginsvc.py.