MediaWiki REL1_39
FauxRequestUpload Class Reference

Object to fake the $_FILES array. More...

Inheritance diagram for FauxRequestUpload:
Collaboration diagram for FauxRequestUpload:

Public Member Functions

 __construct ( $data, $request, $key)
 Constructor.
 
- Public Member Functions inherited from WebRequestUpload
 __construct ( $request, $key)
 Constructor.
 
 exists ()
 Return whether a file with this name was uploaded.
 
 getError ()
 Return the upload error.
 
 getName ()
 Return the original filename of the uploaded file.
 
 getSize ()
 Return the file size of the uploaded file.
 
 getTempName ()
 Return the path to the temporary file.
 
 getType ()
 Return the client specified content type.
 
 isIniSizeOverflow ()
 Returns whether this upload failed because of overflow of a maximum set in php.ini.
 

Additional Inherited Members

- Public Attributes inherited from WebRequestUpload
const REQUIRED_FILEINFO_KEYS = [ 'name', 'size', 'tmp_name', 'type', 'error', ]
 All keys a fileinfo has to specific to work with this class.
 
- Protected Attributes inherited from WebRequestUpload
bool $doesExist
 
array null $fileInfo
 
WebRequest $request
 

Detailed Description

Object to fake the $_FILES array.

Since
1.37

Definition at line 29 of file FauxRequestUpload.php.

Constructor & Destructor Documentation

◆ __construct()

FauxRequestUpload::__construct ( $data,
$request,
$key )

Constructor.

Should only be called by FauxRequest

Parameters
array$dataArray of non-urlencoded key => value pairs, the fake (whole) FILES values
FauxRequest$requestThe associated faux request
string$keyname of upload param

Definition at line 39 of file FauxRequestUpload.php.

References WebRequestUpload\$request.


The documentation for this class was generated from the following file: