original_string: public function reschedule(Job $job, \DateTime $date, $priority = PheanstalkInterface::DEFAULT_PRIORITY)
      {
          if ($date < new \DateTime()) {
              throw new \InvalidArgumentException(
                  sprintf('You cannot reschedule a job in the past (got %s, and the current date is %s)', $date->format(DATE_ISO8601), date(DATE_ISO8601))
              );
          }
  
          $this->pheanstalk->release($job, $priority, $date->getTimestamp() - time());
  
          $this->logJob($job->getId(), sprintf('Rescheduled job for %s', $date->format('Y-m-d H:i:s')));
      }
code: public function reschedule(Job $job, \DateTime $date, $priority = PheanstalkInterface::DEFAULT_PRIORITY)
      {
          if ($date < new \DateTime()) {
              throw new \InvalidArgumentException(
                  sprintf('You cannot reschedule a job in the past (got %s, and the current date is %s)', $date->format(DATE_ISO8601), date(DATE_ISO8601))
              );
          }
  
          $this->pheanstalk->release($job, $priority, $date->getTimestamp() - time());
  
          $this->logJob($job->getId(), sprintf('Rescheduled job for %s', $date->format('Y-m-d H:i:s')));
      }
code_tokens: public function reschedule ( Job $ job , \ DateTime $ date , $ priority = PheanstalkInterface :: DEFAULT_PRIORITY ) { if ( $ date < new \ DateTime ( ) ) { throw new \ InvalidArgumentException ( sprintf ( 'You cannot reschedule a job in the past (got %s, and the current date is %s)' , $ date -> format ( DATE_ISO8601 ) , date ( DATE_ISO8601 ) ) ) ; } $ this -> pheanstalk -> release ( $ job , $ priority , $ date -> getTimestamp ( ) - time ( ) ) ; $ this -> logJob ( $ job -> getId ( ) , sprintf ( 'Rescheduled job for %s' , $ date -> format ( 'Y-m-d H:i:s' ) ) ) ; }
docstring: Reschedules a job.
  
  @param Job       $job
  @param \DateTime $date
  @param integer   $priority
  
  @throws \InvalidArgumentException When `$date` is in the past
docstring_tokens: Reschedules a job .