UploadedFileFactory
in package
implements
UploadedFileFactoryInterface
Interfaces, Classes, Traits and Enums
- UploadedFileFactoryInterface
Table of Contents
- createUploadedFile() : UploadedFileInterface
- Create a new uploaded file.
Methods
createUploadedFile()
Create a new uploaded file.
public
createUploadedFile(StreamInterface $stream[, int $size = null ][, int $error = UPLOAD_ERR_OK ][, string $clientFilename = null ][, string $clientMediaType = null ]) : UploadedFileInterface
If a size is not provided it will be determined by checking the size of the stream.
Parameters
- $stream : StreamInterface
-
The underlying stream representing the uploaded file content.
- $size : int = null
-
The size of the file in bytes.
- $error : int = UPLOAD_ERR_OK
-
The PHP file upload error.
- $clientFilename : string = null
-
The filename as provided by the client, if any.
- $clientMediaType : string = null
-
The media type as provided by the client, if any.