FormUploadedFile.php in Drupal 10
File
core/modules/file/src/Upload/FormUploadedFile.php
View source
<?php
namespace Drupal\file\Upload;
use Symfony\Component\HttpFoundation\File\UploadedFile;
class FormUploadedFile implements UploadedFileInterface {
protected $uploadedFile;
public function __construct(UploadedFile $uploadedFile) {
$this->uploadedFile = $uploadedFile;
}
public function getClientOriginalName() : string {
return $this->uploadedFile
->getClientOriginalName();
}
public function isValid() : bool {
return $this->uploadedFile
->isValid();
}
public function getErrorMessage() : string {
return $this->uploadedFile
->getErrorMessage();
}
public function getError() : int {
return $this->uploadedFile
->getError();
}
public function getSize() : int {
return $this->uploadedFile
->getSize();
}
public function getRealPath() {
return $this->uploadedFile
->getRealPath();
}
public function getPathname() : string {
return $this->uploadedFile
->getPathname();
}
public function getFilename() : string {
return $this->uploadedFile
->getFilename();
}
}