com :: Container :: Container :: Class Container
[hide private]
[frames] | no frames]

Class Container

       object --+        
                |        
Mediator.Mediator --+    
                    |    
  Component.Component --+
                        |
                       Container

Runtime container for running components. The Container loads and instantiates components.

Instance Methods [hide private]
 
__init__(self, *paths)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
 
__find_modules(self, path)
Returns a list of the modules of all components under the given path.
 
__load_module(self, path)
Loads and returns the module from the given path.
 
__register_messages(self, mod)
Registers the messages of the given module.
 
__load_components(self, mod)
Loads the components of the given module.
 
load_path(self, path)
Loads all components from the given path.
 
__repr__(self)
Returns a string representation of this component. (Inherited from com.Mediator.Mediator)
 
_attach_to_message_bus(self) (Inherited from com.Mediator.Mediator)
 
call_service(self, svc, *args)
Calls the given service and returns the return value of the service. (Inherited from com.Mediator.Mediator)
 
drop_event(self) (Inherited from com.Mediator.Mediator)
 
emit_event(self, event, *args)
Emits the given message. (Inherited from com.Mediator.Mediator)
 
emit_message(self, msg, *args)
Emits the given message. (Inherited from com.Mediator.Mediator)
 
get_pass_type(self) (Inherited from com.Mediator.Mediator)
 
handle_message(self, msg, *args)
Gets invoked when a message arrives on the message bus. (Inherited from com.Mediator.Mediator)
 
pass_on_event(self) (Inherited from com.Mediator.Mediator)
 
set_pass_type(self, ptype) (Inherited from com.Mediator.Mediator)

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __setattr__, __str__

Class Variables [hide private]
  PASS_TYPE_DROP = 1 (Inherited from com.Mediator.Mediator)
  PASS_TYPE_INVALID = 0 (Inherited from com.Mediator.Mediator)
  PASS_TYPE_PASS_ON = 2 (Inherited from com.Mediator.Mediator)
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, *paths)
(Constructor)

 

x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Parameters:
  • paths - paths where to look for components
Overrides: object.__init__

__load_module(self, path)

 

Loads and returns the module from the given path. Returns None if the module could not be loaded.

load_path(self, path)

 

Loads all components from the given path.

Parameters:
  • path - path of components directory