original_string: public function formatTime($dateTimeValue)
      {
          if ($dateTimeValue instanceof \Zend_Date) {
              $dateTimeValue = $dateTimeValue->getTimestamp();
          }
          $seconds = str_pad($dateTimeValue % 60, 2, '0', STR_PAD_LEFT);
          $rest    = intval($dateTimeValue / 60);
          $minutes = str_pad($rest % 60, 2, '0', STR_PAD_LEFT);
          $hours   = intval($rest / 60);
          $days    = intval($hours / 24);
  
          if ($hours > 48) {
              $hours = $hours % 24;
  
              return sprintf($this->_('%d days %d:%s:%s'), $days, $hours, $minutes, $seconds);
          } elseif ($hours) {
              return sprintf($this->_('%d:%s:%s'), $hours, $minutes, $seconds);
          } else {
              return sprintf($this->_('%d:%s'), $minutes, $seconds);
          }
      }
code: public function formatTime($dateTimeValue)
      {
          if ($dateTimeValue instanceof \Zend_Date) {
              $dateTimeValue = $dateTimeValue->getTimestamp();
          }
          $seconds = str_pad($dateTimeValue % 60, 2, '0', STR_PAD_LEFT);
          $rest    = intval($dateTimeValue / 60);
          $minutes = str_pad($rest % 60, 2, '0', STR_PAD_LEFT);
          $hours   = intval($rest / 60);
          $days    = intval($hours / 24);
  
          if ($hours > 48) {
              $hours = $hours % 24;
  
              return sprintf($this->_('%d days %d:%s:%s'), $days, $hours, $minutes, $seconds);
          } elseif ($hours) {
              return sprintf($this->_('%d:%s:%s'), $hours, $minutes, $seconds);
          } else {
              return sprintf($this->_('%d:%s'), $minutes, $seconds);
          }
      }
code_tokens: public function formatTime ( $ dateTimeValue ) { if ( $ dateTimeValue instanceof \ Zend_Date ) { $ dateTimeValue = $ dateTimeValue -> getTimestamp ( ) ; } $ seconds = str_pad ( $ dateTimeValue % 60 , 2 , '0' , STR_PAD_LEFT ) ; $ rest = intval ( $ dateTimeValue / 60 ) ; $ minutes = str_pad ( $ rest % 60 , 2 , '0' , STR_PAD_LEFT ) ; $ hours = intval ( $ rest / 60 ) ; $ days = intval ( $ hours / 24 ) ; if ( $ hours > 48 ) { $ hours = $ hours % 24 ; return sprintf ( $ this -> _ ( '%d days %d:%s:%s' ) , $ days , $ hours , $ minutes , $ seconds ) ; } elseif ( $ hours ) { return sprintf ( $ this -> _ ( '%d:%s:%s' ) , $ hours , $ minutes , $ seconds ) ; } else { return sprintf ( $ this -> _ ( '%d:%s' ) , $ minutes , $ seconds ) ; } }
docstring: Returns the time in seconds as a display string
  
  @param int $dateTimeValue
  @return string
docstring_tokens: Returns the time in seconds as a display string