Package zeroinstall :: Package injector :: Module background :: Class BackgroundHandler
[frames] | no frames]

Class BackgroundHandler

source code

     object --+    
              |    
handler.Handler --+
                  |
                 BackgroundHandler

A Handler for non-interactive background updates. Runs the GUI if interaction is required.

Instance Methods
 
__init__(self, title)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
get_network_state(self) source code
tasks.Blocker
confirm_trust_keys(self, interface, sigs, iface_xml)
Run the GUI if we need to confirm any keys.
source code
 
report_error(self, exception, tb=None)
Report an exception to the user.
source code
 
notify(self, title, message, timeout=0, actions=[])
Send a D-BUS notification message if possible.
source code

Inherited from handler.Handler: downloads_changed, get_download, impl_added_to_store, monitor_download, wait_for_blocker

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

Instance Variables

Inherited from handler.Handler: monitored_downloads, n_completed_downloads, total_bytes_downloaded

Properties

Inherited from object: __class__

Method Details

__init__(self, title)
(Constructor)

source code 

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

Overrides: object.__init__
(inherited documentation)

confirm_trust_keys(self, interface, sigs, iface_xml)

source code 

Run the GUI if we need to confirm any keys.

Parameters:
  • interface - the interface being updated
  • sigs - a list of signatures (from gpg.check_stream)
  • iface_xml - the downloaded data (not yet trusted)
Returns: tasks.Blocker
a blocker, if confirmation will happen asynchronously, or None
Overrides: handler.Handler.confirm_trust_keys

report_error(self, exception, tb=None)

source code 

Report an exception to the user.

Parameters:
  • exception - the exception to report
  • tb - optional traceback
Overrides: handler.Handler.report_error
(inherited documentation)

notify(self, title, message, timeout=0, actions=[])

source code 

Send a D-BUS notification message if possible. If there is no notification service available, log the message instead.