def set_run_completed(self, boolean, start_datetime, end_datetime):
        """Set the value of _run_completed."""
        self._run_completed = boolean

        if (start_datetime, end_datetime) != (None, None):
            # start_datetime: Sat Feb 28 23:54:27 2015
            # end_datetime: Sat Feb 28 23:54:30 2015
            try:
                fmt = "%a %b %d %H:%M:%S %Y"
                self.start_datetime = datetime.datetime.strptime(start_datetime, fmt)
                self.end_datetime = datetime.datetime.strptime(end_datetime, fmt)
            except Exception as exc:
                # Maybe LOCALE != en_US
                logger.warning(str(exc))
def set_run_completed ( self , boolean , start_datetime , end_datetime ) : self . _run_completed = boolean if ( start_datetime , end_datetime ) != ( None , None ) : try : fmt = "%a %b %d %H:%M:%S %Y" self . start_datetime = datetime . datetime . strptime ( start_datetime , fmt ) self . end_datetime = datetime . datetime . strptime ( end_datetime , fmt ) except Exception as exc : logger . warning ( str ( exc ) )
Set the value of _run_completed.