parameters: (self, option=None)
return_statement: return pid
docstring: to call to start the component
              @return : None if ko
                        the pid if ok
docstring_summary: to call to start the component
docstring_tokens: to call to start the component
function: def start(self, option=None):
          """ to call to start the component
              @return : None if ko
                        the pid if ok
          """
          ### Check if the component is not already launched
          # notice that this test is not really needed as the plugin also test this in startup...
          # but the plugin does it before the MQ is initiated, so the error message won't go overt the MQ.
          # By doing it now, the error will go to the UI through the 'error' MQ messages (sended by self.log.error)
          res, pid_list = is_already_launched(self.log, self.type, self.name)
          if res:
              return 0
  
          ### Start the component
          self.log.info(u"Request to start core component : {0}".format(self.name))
          pid = self.exec_component("domogik.bin", option=option)
          self.set_pid(pid)
          if pid != 0:
              # Notice : we whould not need to do this as this information should be provided by the MQ plugin.status.
              # But as the IOLoop is not started when core components are launched with -r, -d or -x options, we don't
              # have the plugin.status message.
              self.set_status(STATUS_STOPPED)
  
          # no need to add a step to check if the component is started as the status is given to the user directly by the pub/sub 'plugin.status'
  
          return pid
function_tokens: def start ( self , option = None ) : ### Check if the component is not already launched # notice that this test is not really needed as the plugin also test this in startup... # but the plugin does it before the MQ is initiated, so the error message won't go overt the MQ. # By doing it now, the error will go to the UI through the 'error' MQ messages (sended by self.log.error) res , pid_list = is_already_launched ( self . log , self . type , self . name ) if res : return 0 ### Start the component self . log . info ( u"Request to start core component : {0}" . format ( self . name ) ) pid = self . exec_component ( "domogik.bin" , option = option ) self . set_pid ( pid ) if pid != 0 : # Notice : we whould not need to do this as this information should be provided by the MQ plugin.status. # But as the IOLoop is not started when core components are launched with -r, -d or -x options, we don't # have the plugin.status message. self . set_status ( STATUS_STOPPED ) # no need to add a step to check if the component is started as the status is given to the user directly by the pub/sub 'plugin.status' return pid