MediaWiki
REL1_20
|
Helper class for file undeletion. More...
Public Member Functions | |
__construct (File $file, $unsuppress=false) | |
addAll () | |
Add all revisions of the file. | |
addId ($fa_id) | |
Add a file by ID. | |
addIds ($ids) | |
Add a whole lot of files by ID. | |
cleanup () | |
Delete unused files in the deleted zone. | |
cleanupFailedBatch ($storeStatus, $storeBatch) | |
Cleanup a failed batch. | |
execute () | |
Run the transaction, except the cleanup batch. | |
removeNonexistentFiles ($triplets) | |
Removes non-existent files from a store batch. | |
removeNonexistentFromCleanup ($batch) | |
Removes non-existent files from a cleanup batch. | |
Public Attributes | |
$all | |
$cleanupBatch | |
LocalFile | $file |
$ids | |
$unsuppress = false |
Helper class for file undeletion.
Definition at line 1953 of file LocalFile.php.
LocalFileRestoreBatch::__construct | ( | File $ | file, |
$ | unsuppress = false |
||
) |
$file | File |
$unsuppress | bool |
Definition at line 1964 of file LocalFile.php.
Add all revisions of the file.
Definition at line 1988 of file LocalFile.php.
LocalFileRestoreBatch::addId | ( | $ | fa_id | ) |
Add a file by ID.
Definition at line 1974 of file LocalFile.php.
LocalFileRestoreBatch::addIds | ( | $ | ids | ) |
Add a whole lot of files by ID.
Definition at line 1981 of file LocalFile.php.
Delete unused files in the deleted zone.
This should be called from outside the transaction in which execute() was called.
Definition at line 2269 of file LocalFile.php.
LocalFileRestoreBatch::cleanupFailedBatch | ( | $ | storeStatus, |
$ | storeBatch | ||
) |
Cleanup a failed batch.
The batch was only partially successful, so rollback by removing all items that were succesfully copied.
Status | $storeStatus | |
array | $storeBatch |
Definition at line 2288 of file LocalFile.php.
Run the transaction, except the cleanup batch.
The cleanup batch should be run in a separate transaction, because it locks different rows and there's no need to keep the image row locked while it's acquiring those locks The caller may have its own transaction open. So we save the batch and let the caller call cleanup()
Definition at line 2000 of file LocalFile.php.
LocalFileRestoreBatch::removeNonexistentFiles | ( | $ | triplets | ) |
Removes non-existent files from a store batch.
$triplets | array |
Definition at line 2222 of file LocalFile.php.
Removes non-existent files from a cleanup batch.
$batch | array |
Definition at line 2244 of file LocalFile.php.
LocalFileRestoreBatch::$all |
Definition at line 1958 of file LocalFile.php.
LocalFileRestoreBatch::$cleanupBatch |
Definition at line 1958 of file LocalFile.php.
LocalFile LocalFileRestoreBatch::$file |
Definition at line 1956 of file LocalFile.php.
LocalFileRestoreBatch::$ids |
Definition at line 1958 of file LocalFile.php.
LocalFileRestoreBatch::$unsuppress = false |
Definition at line 1958 of file LocalFile.php.