|  | 
| def | __init__ (self, cpp_type) | 
|  | 
| def | store (self, value) | 
|  | 
| def | default (self, value) | 
|  | 
| def | name (self) | 
|  | 
| def | name (self, value) | 
|  | 
| def | cpp_type (self) | 
|  | 
| def | cpp_type (self, value) | 
|  | 
| def | load (self, value) | 
|  | 
| def | is_set (self, value) | 
|  | 
| def | opt_value (self, value) | 
|  | 
| def | merge (self, a, b) | 
|  | 
Definition at line 202 of file semantics.py.
 
◆ __init__()
      
        
          | def GaudiConfig2.semantics.ComponentSemantics.__init__ | ( |  | self, | 
        
          |  |  |  | cpp_type | 
        
          |  | ) |  |  | 
      
 
Reimplemented from GaudiConfig2.semantics.PropertySemantics.
Definition at line 214 of file semantics.py.
  214     def __init__(self, cpp_type):
 
  215         super(ComponentSemantics, self).__init__(cpp_type)
 
  217             self.cpp_type, self.interfaces = cpp_type.split(
":", 1)
 
  218             self.interfaces = set(self.interfaces.split(
","))
 
  220             self.cpp_type = cpp_type
 
  221             self.interfaces = set()
 
 
 
◆ default()
      
        
          | def GaudiConfig2.semantics.ComponentSemantics.default | ( |  | self, | 
        
          |  |  |  | value | 
        
          |  | ) |  |  | 
      
 
 
◆ store()
      
        
          | def GaudiConfig2.semantics.ComponentSemantics.store | ( |  | self, | 
        
          |  |  |  | value | 
        
          |  | ) |  |  | 
      
 
Validation/transformation of the data to be stored.
 
Reimplemented from GaudiConfig2.semantics.PropertySemantics.
Definition at line 223 of file semantics.py.
  223     def store(self, value):
 
  224         from . 
import Configurable, Configurables
 
  226         if isinstance(value, Configurable):
 
  228         elif isinstance(value, str):
 
  230             if value 
in Configurable.instances:
 
  231                 value = Configurable.instances[value]
 
  235                     t, n = value.split(
"/")
 
  238                 value = Configurables.getByType(t).getInstance(n)
 
  241                 "cannot assign {!r} to {!r}, requested string or {!r}".
format(
 
  242                     value, self.name, self.cpp_type
 
  245         if value.__component_type__ != self.cpp_type:
 
  247                 "wrong type for {!r}: expected {!r}, got {!r}".
format(
 
  248                     self.name, self.cpp_type, value.__component_type__
 
  253             if value.__interfaces__:
 
  254                 if not self.interfaces.issubset(value.__interfaces__):
 
  256                         "wrong interfaces for {!r}: required {}".
format(
 
  257                             self.name, list(self.interfaces)
 
  260         except AttributeError:
 
 
 
◆ __handled_types__
  
  | 
        
          | GaudiConfig2.semantics.ComponentSemantics.__handled_types__ |  | staticprivate | 
 
 
◆ cpp_type
      
        
          | GaudiConfig2.semantics.ComponentSemantics.cpp_type | 
      
 
 
◆ interfaces
      
        
          | GaudiConfig2.semantics.ComponentSemantics.interfaces | 
      
 
 
The documentation for this class was generated from the following file: