class UploadedFile in Zircon Profile 8
Same name in this branch
- 8 vendor/zendframework/zend-diactoros/src/UploadedFile.php \Zend\Diactoros\UploadedFile
- 8 vendor/symfony/http-foundation/File/UploadedFile.php \Symfony\Component\HttpFoundation\File\UploadedFile
- 8 vendor/symfony/psr-http-message-bridge/Tests/Fixtures/UploadedFile.php \Symfony\Bridge\PsrHttpMessage\Tests\Fixtures\UploadedFile
Same name and namespace in other branches
- 8.0 vendor/symfony/psr-http-message-bridge/Tests/Fixtures/UploadedFile.php \Symfony\Bridge\PsrHttpMessage\Tests\Fixtures\UploadedFile
@author Kévin Dunglas <dunglas@gmail.com>
Hierarchy
- class \Symfony\Bridge\PsrHttpMessage\Tests\Fixtures\UploadedFile implements UploadedFileInterface
Expanded class hierarchy of UploadedFile
1 file declares its use of UploadedFile
- HttpFoundationFactoryTest.php in vendor/
symfony/ psr-http-message-bridge/ Tests/ Factory/ HttpFoundationFactoryTest.php
File
- vendor/
symfony/ psr-http-message-bridge/ Tests/ Fixtures/ UploadedFile.php, line 19
Namespace
Symfony\Bridge\PsrHttpMessage\Tests\FixturesView source
class UploadedFile implements UploadedFileInterface {
private $filePath;
private $size;
private $error;
private $clientFileName;
private $clientMediaType;
public function __construct($filePath, $size = null, $error = UPLOAD_ERR_OK, $clientFileName = null, $clientMediaType = null) {
$this->filePath = $filePath;
$this->size = $size;
$this->error = $error;
$this->clientFileName = $clientFileName;
$this->clientMediaType = $clientMediaType;
}
public function getStream() {
throw new \RuntimeException('No stream is available.');
}
public function moveTo($targetPath) {
rename($this->filePath, $targetPath);
}
public function getSize() {
return $this->size;
}
public function getError() {
return $this->error;
}
public function getClientFilename() {
return $this->clientFileName;
}
public function getClientMediaType() {
return $this->clientMediaType;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
UploadedFile:: |
private | property | ||
UploadedFile:: |
private | property | ||
UploadedFile:: |
private | property | ||
UploadedFile:: |
private | property | ||
UploadedFile:: |
private | property | ||
UploadedFile:: |
public | function |
Retrieve the filename sent by the client. Overrides UploadedFileInterface:: |
|
UploadedFile:: |
public | function |
Retrieve the media type sent by the client. Overrides UploadedFileInterface:: |
|
UploadedFile:: |
public | function |
Retrieve the error associated with the uploaded file. Overrides UploadedFileInterface:: |
|
UploadedFile:: |
public | function |
Retrieve the file size. Overrides UploadedFileInterface:: |
|
UploadedFile:: |
public | function |
Retrieve a stream representing the uploaded file. Overrides UploadedFileInterface:: |
|
UploadedFile:: |
public | function |
Move the uploaded file to a new location. Overrides UploadedFileInterface:: |
|
UploadedFile:: |
public | function |