Package elisa :: Package plugins :: Package poblesec :: Package base :: Module hierarchy :: Class HierarchyController

Class HierarchyController

source code


Generic base controller that provides some asynchronous loading facilities.

Every deferred call done in the context of this controller should be registered in the internal dictionary of deferreds so as to keep track of them and allow their cancellation if needed (e.g. when cleaning the controller). Each value of this internal dictionary is a list, meaning that several deferred calls can be associated to one key.

>>> self.register_deferred(key, deferred)

To cancel all the deferred calls associated to a given key, do:

>>> self.cancel_deferreds(key)
Instance Methods
 
__init__(self)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
register_deferred(self, key, deferred)
Register a deferred call to be associated to a given key.
source code
 
cancel_deferreds(self, key)
Cancel all the currently pending deferred calls associated to one given key in the internal dictionary.
source code
 
cancel_all_deferreds(self)
Cancel all the currently pending deferred calls.
source code
twisted.internet.defer.Deferred
clean(self)
Clean the component.
source code

Inherited from extern.log.log.Loggable: debug, doLog, error, info, log, logFunction, logObjectName, warning, warningFailure

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

    Inherited from pigment.pigment_controller.PigmentController
bool
handle_input(self, manager, event)
Handle an Elisa input event.
source code
 
has_focus(self) source code
 
prepare(self)
Called after widget is added to the canvas.
source code
 
ready(self)
Called after frontend finished creation of the controller and all decorators are loaded.
source code
 
removed(self)
Called after widget is removed from the canvas.
source code
None or elisa.core.utils.defer.Deferred
set_frontend(self, frontend)
Set the frontend for the controller.
source code
 
set_path(self, path)
Set the path for the controller.
source code
    Inherited from core.component.Component
twisted.internet.defer.Deferred
initialize(self, **kwargs)
Initialize the component.
source code
 
name__get(self) source code
 
name__set(self, value) source code
Class Methods
    Inherited from core.component.Component
elisa.core.component.Component or a subclass
create(cls, config_section=None, **kwargs)
Create and initialize the component.
source code
Class Variables

Inherited from extern.log.log.Loggable: logCategory

    Inherited from pigment.pigment_controller.PigmentController
  __gsignals__ = {'clean':(gobject.SIGNAL_RUN_LAST, gobject.TYPE...
    Inherited from core.component.Component
  config_doc = {}
  default_config = {}
  name = property(fget= name__get, fset= name__set)
Instance Variables
dict of any immutable type -> list of {elisa.core.utils.defer.Deferred} deferreds
currently pending deferred calls
    Inherited from pigment.pigment_controller.PigmentController
elisa.core.components.frontend.Frontend frontend
frontend that created the controller
str path
path for which that controller was selected
bool sensitive
whether this controller should react on click events
elisa.plugins.pigment.widgets.widget.Widget widget
Pigment widget containing the UI of the controller
Properties

Inherited from object: __class__

Method Details

__init__(self)
(Constructor)

source code 

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

Overrides: object.__init__
(inherited documentation)

cancel_deferreds(self, key)

source code 

Cancel all the currently pending deferred calls associated to one given key in the internal dictionary.

Parameters:
  • key (any immutable type) - the key in the internal deferreds dictionary

clean(self)

source code 

Clean the component.

This method is called when a component is not needed anymore to clean its state.

Returns: twisted.internet.defer.Deferred
a deferred called when the component has finished cleaning its state
Overrides: core.component.Component.clean
(inherited documentation)