Ejemplo n.º 1
0
 def __init__(self):
     cmd.Cmd.__init__(self)
     LunchServerController.__init__(self)
     
     self.logger = newLogger("cli")
     self.prompt = "> "
     self.commands = set(["exit"])
     self.addModule(CLIMessageHandling())  
     self.addModule(CLIOptionHandling())
     self.addModule(CLIPluginHandling(self))
     self.addModule(CLIPrivacyHandling())
     self.addModule(CLILoggingHandling())
     
     get_server().initialize(self)
     
     if get_settings().get_plugins_enabled():
         for pluginInfo in get_plugin_manager().getAllPlugins():
             if pluginInfo.plugin_object.is_activated:
                 self.addModule(pluginInfo.plugin_object)
             
     get_notification_center().connectApplicationUpdate(self.notifyUpdates)
             
     self.exitCode = 0
     # if serverStopped is called, we can determine if it was a regular exit.
     self.cleanExit = False
     self.initialized = False
Ejemplo n.º 2
0
 def __init__(self):
     super(SignalTest, self).__init__()
     self.logger = newLogger("test")