original_string: public function save(File $file, $preparedPath)
      {
          if (false === ($i = array_search($preparedPath, $this->preparedPaths))) {
              throw new \RuntimeException("{$preparedPath} is not prepared by the filemanager");
          }
          unset($this->preparedPaths[$i]);
          $existed = $this->fs->exists($preparedPath);
          @$this->fs->remove($preparedPath);
  
          try {
              $this->dispatchEvent($existed ? ResourceEvent::REPLACED : ResourceEvent::CREATED, $preparedPath);
              $file->move(dirname($preparedPath), basename($preparedPath));
          } catch (FileException $fileException) {
              throw new FileException(
                  $fileException->getMessage() . "\n(hint: check the 'upload_max_filesize' in php.ini)",
                  0,
                  $fileException
              );
          }
      }
code: public function save(File $file, $preparedPath)
      {
          if (false === ($i = array_search($preparedPath, $this->preparedPaths))) {
              throw new \RuntimeException("{$preparedPath} is not prepared by the filemanager");
          }
          unset($this->preparedPaths[$i]);
          $existed = $this->fs->exists($preparedPath);
          @$this->fs->remove($preparedPath);
  
          try {
              $this->dispatchEvent($existed ? ResourceEvent::REPLACED : ResourceEvent::CREATED, $preparedPath);
              $file->move(dirname($preparedPath), basename($preparedPath));
          } catch (FileException $fileException) {
              throw new FileException(
                  $fileException->getMessage() . "\n(hint: check the 'upload_max_filesize' in php.ini)",
                  0,
                  $fileException
              );
          }
      }
code_tokens: public function save ( File $ file , $ preparedPath ) { if ( false === ( $ i = array_search ( $ preparedPath , $ this -> preparedPaths ) ) ) { throw new \ RuntimeException ( "{$preparedPath} is not prepared by the filemanager" ) ; } unset ( $ this -> preparedPaths [ $ i ] ) ; $ existed = $ this -> fs -> exists ( $ preparedPath ) ; @ $ this -> fs -> remove ( $ preparedPath ) ; try { $ this -> dispatchEvent ( $ existed ? ResourceEvent :: REPLACED : ResourceEvent :: CREATED , $ preparedPath ) ; $ file -> move ( dirname ( $ preparedPath ) , basename ( $ preparedPath ) ) ; } catch ( FileException $ fileException ) { throw new FileException ( $ fileException -> getMessage ( ) . "\n(hint: check the 'upload_max_filesize' in php.ini)" , 0 , $ fileException ) ; } }
docstring: Save a file to a previously prepared path.
  
  @param \Symfony\Component\HttpFoundation\File\File $file
  @param string $preparedPath
  @return void
  
  @throws \RuntimeException
docstring_tokens: Save a file to a previously prepared path .