The Gaudi Framework  master (37c0b60a)
cpluginsvc.Factory Class Reference
Inheritance diagram for cpluginsvc.Factory:
Collaboration diagram for cpluginsvc.Factory:

Public Member Functions

def name (self)
 
def library (self)
 
def type (self)
 
def classname (self)
 
def properties (self)
 
def load (self)
 
def __repr__ (self)
 

Static Private Attributes

 _fields_
 

Detailed Description

Factory holds informations about a component's factory:
- its name
- the library hosting that component
- the type of component (algorithm, service, tool, ...)
- the return type of this factory
- the C++ class name of that component
- the properties which may decorate that component.

Definition at line 100 of file cpluginsvc.py.

Member Function Documentation

◆ __repr__()

def cpluginsvc.Factory.__repr__ (   self)

Definition at line 145 of file cpluginsvc.py.

145  def __repr__(self):
146  return "<Factory id=%s library=%s type=%s class=%s props=%d>" % (
147  self.name,
148  self.library,
149  self.type,
150  self.classname,
151  len(self.properties),
152  )
153 

◆ classname()

def cpluginsvc.Factory.classname (   self)

Definition at line 129 of file cpluginsvc.py.

129  def classname(self):
130  return _lib.cgaudi_factory_get_classname(self).decode("ascii")
131 

◆ library()

def cpluginsvc.Factory.library (   self)

Definition at line 121 of file cpluginsvc.py.

121  def library(self):
122  return _lib.cgaudi_factory_get_library(self).decode("ascii")
123 

◆ load()

def cpluginsvc.Factory.load (   self)
load the C++ library hosting this factory

Definition at line 141 of file cpluginsvc.py.

141  def load(self):
142  """load the C++ library hosting this factory"""
143  return ctypes.CDLL(self.library, ctypes.RTLD_GLOBAL)
144 

◆ name()

def cpluginsvc.Factory.name (   self)

Definition at line 117 of file cpluginsvc.py.

117  def name(self):
118  return self._id.decode("ascii")
119 

◆ properties()

def cpluginsvc.Factory.properties (   self)

Definition at line 133 of file cpluginsvc.py.

133  def properties(self):
134  props = {}
135  nprops = _lib.cgaudi_factory_get_property_size(self)
136  for i in range(nprops):
137  prop = _lib.cgaudi_factory_get_property_at(self, i)
138  props[prop.key] = prop.value
139  return props
140 

◆ type()

def cpluginsvc.Factory.type (   self)

Definition at line 125 of file cpluginsvc.py.

125  def type(self):
126  return _lib.cgaudi_factory_get_type(self).decode("ascii")
127 

Member Data Documentation

◆ _fields_

cpluginsvc.Factory._fields_
staticprivate

Definition at line 111 of file cpluginsvc.py.


The documentation for this class was generated from the following file:
GaudiPartProp.decorators.__repr__
__repr__
decorate the vector of properties
Definition: decorators.py:173
gaudiComponentHelp.properties
properties
Definition: gaudiComponentHelp.py:68
gaudirun.type
type
Definition: gaudirun.py:160
ConditionsStallTest.name
name
Definition: ConditionsStallTest.py:77
Gaudi::Functional::details::zip::range
decltype(auto) range(Args &&... args)
Zips multiple containers together to form a single range.
Definition: details.h:97