‪TYPO3CMS  ‪main
TYPO3\CMS\Core\Http\UploadedFileFactory Class Reference
Inheritance diagram for TYPO3\CMS\Core\Http\UploadedFileFactory:

Public Member Functions

 createUploadedFile (StreamInterface $stream, int $size=null, int $error=\UPLOAD_ERR_OK, string $clientFilename=null, string $clientMediaType=null)
 

Detailed Description

Note that this is not public API, use PSR-17 interfaces instead.

Definition at line 27 of file UploadedFileFactory.php.

Member Function Documentation

◆ createUploadedFile()

TYPO3\CMS\Core\Http\UploadedFileFactory::createUploadedFile ( StreamInterface  $stream,
int  $size = null,
int  $error = \UPLOAD_ERR_OK,
string  $clientFilename = null,
string  $clientMediaType = null 
)

Create a new uploaded file.

If a size is not provided it will be determined by checking the size of the file.

See also
https://php.net/manual/features.file-upload.post-method.php
https://php.net/manual/features.file-upload.errors.php
Parameters
StreamInterface$stream‪Underlying stream representing the uploaded file content.
int$size‪in bytes
int$error‪PHP file upload error
string$clientFilename‪Filename as provided by the client, if any.
string$clientMediaType‪Media type as provided by the client, if any.
Exceptions

Definition at line 45 of file UploadedFileFactory.php.