original_string: private function determineDriver($file)
      {
          $exception = new InvalidArgumentException(
              "Cannot initialize the configuration driver. I could not determine ".
              "the correct driver class."
          );
  
          if (is_null($file) || !is_string($file)) {
              throw $exception;
          }
  
          $nameDivision = explode('.', $file);
          $extension = strtolower(end($nameDivision));
  
          if (!array_key_exists($extension, $this->extensionToDriver)) {
              throw $exception;
          }
  
          return $this->extensionToDriver[$extension];
      }
code: private function determineDriver($file)
      {
          $exception = new InvalidArgumentException(
              "Cannot initialize the configuration driver. I could not determine ".
              "the correct driver class."
          );
  
          if (is_null($file) || !is_string($file)) {
              throw $exception;
          }
  
          $nameDivision = explode('.', $file);
          $extension = strtolower(end($nameDivision));
  
          if (!array_key_exists($extension, $this->extensionToDriver)) {
              throw $exception;
          }
  
          return $this->extensionToDriver[$extension];
      }
code_tokens: private function determineDriver ( $ file ) { $ exception = new InvalidArgumentException ( "Cannot initialize the configuration driver. I could not determine " . "the correct driver class." ) ; if ( is_null ( $ file ) || ! is_string ( $ file ) ) { throw $ exception ; } $ nameDivision = explode ( '.' , $ file ) ; $ extension = strtolower ( end ( $ nameDivision ) ) ; if ( ! array_key_exists ( $ extension , $ this -> extensionToDriver ) ) { throw $ exception ; } return $ this -> extensionToDriver [ $ extension ] ; }
docstring: Tries to determine the driver class based on given file
  
  @param string $file
  @return mixed
docstring_tokens: Tries to determine the driver class based on given file