MediaWiki
1.34.0
|
Implements uploading from previously stored file. More...
Public Member Functions | |
__construct ( $user=false, $stash=false, $repo=false) | |
getSourceType () | |
getTempFileSha1Base36 () | |
Get the base 36 SHA1 of the file. More... | |
initialize ( $key, $name='upload_file', $initTempFile=true) | |
initializeFromRequest (&$request) | |
postProcessUpload () | |
Remove the database record after a successful upload. More... | |
unsaveUploadedFile () | |
Remove a temporarily kept file stashed by saveTempUploadedFile(). More... | |
Static Public Member Functions | |
static | isValidKey ( $key) |
static | isValidRequest ( $request) |
Protected Attributes | |
$mFileKey | |
$mFileProps | |
$mSourceType | |
$mVirtualTempPath | |
Private Attributes | |
$repo | |
$stash | |
Implements uploading from previously stored file.
Definition at line 30 of file UploadFromStash.php.
UploadFromStash::__construct | ( | $user = false , |
|
$stash = false , |
|||
$repo = false |
|||
) |
User | bool | $user | Default: false Sometimes this won't exist, as when running from cron. |
UploadStash | bool | $stash | Default: false |
FileRepo | bool | $repo | Default: false |
Definition at line 47 of file UploadFromStash.php.
References $repo, $stash, RepoGroup\singleton(), and wfDebug().
UploadFromStash::getSourceType | ( | ) |
UploadFromStash::getTempFileSha1Base36 | ( | ) |
UploadFromStash::initialize | ( | $key, | |
$name = 'upload_file' , |
|||
$initTempFile = true |
|||
) |
string | $key | |
string | $name | |
bool | $initTempFile |
Definition at line 92 of file UploadFromStash.php.
Referenced by initializeFromRequest().
UploadFromStash::initializeFromRequest | ( | & | $request | ) |
WebRequest | &$request |
Definition at line 115 of file UploadFromStash.php.
References initialize().
|
static |
string | $key |
Definition at line 71 of file UploadFromStash.php.
References UploadStash\KEY_FORMAT_REGEX.
Referenced by isValidRequest(), and ApiUpload\selectUploadModule().
|
static |
WebRequest | $request |
Definition at line 80 of file UploadFromStash.php.
References isValidKey().
UploadFromStash::postProcessUpload | ( | ) |
Remove the database record after a successful upload.
Definition at line 154 of file UploadFromStash.php.
References unsaveUploadedFile().
UploadFromStash::unsaveUploadedFile | ( | ) |
Remove a temporarily kept file stashed by saveTempUploadedFile().
Definition at line 147 of file UploadFromStash.php.
Referenced by postProcessUpload().
|
protected |
Definition at line 31 of file UploadFromStash.php.
|
protected |
Definition at line 33 of file UploadFromStash.php.
|
protected |
Definition at line 34 of file UploadFromStash.php.
Referenced by getSourceType().
|
protected |
Definition at line 32 of file UploadFromStash.php.
|
private |
Definition at line 40 of file UploadFromStash.php.
Referenced by __construct().
|
private |
Definition at line 37 of file UploadFromStash.php.
Referenced by __construct().