MediaWiki  REL1_19
CreateFileOp Class Reference

Create a file in the backend with the given content. More...

Inheritance diagram for CreateFileOp:
Collaboration diagram for CreateFileOp:

List of all members.

Public Member Functions

 storagePathsChanged ()
 Get a list of storage paths written to for this operation.

Protected Member Functions

 allowedParams ()
 Get the file operation parameters.
 doAttempt ()
 doPrecheck (array &$predicates)
 getSourceSha1Base36 ()
 precheckDestExistence() helper function to get the source file SHA-1.

Detailed Description

Create a file in the backend with the given content.

Parameters similar to FileBackendStore::createInternal(), which include: content : the raw file contents dst : destination storage path overwrite : do nothing and pass if an identical file exists at destination overwriteSame : override any existing file at destination

Definition at line 491 of file FileOp.php.


Member Function Documentation

CreateFileOp::allowedParams ( ) [protected]

Get the file operation parameters.

Returns:
Array (required params list, optional params list)

Reimplemented from FileOp.

Definition at line 492 of file FileOp.php.

CreateFileOp::doAttempt ( ) [protected]
Returns:
Status

Reimplemented from FileOp.

Definition at line 517 of file FileOp.php.

References Status\newGood().

Here is the call graph for this function:

CreateFileOp::doPrecheck ( array &$  predicates) [protected]
Returns:
Status

Reimplemented from FileOp.

Definition at line 496 of file FileOp.php.

References FileOp\getParam(), Status\newGood(), and FileOp\precheckDestExistence().

Here is the call graph for this function:

precheckDestExistence() helper function to get the source file SHA-1.

Subclasses should overwride this iff the source is not in storage.

Returns:
string|false Returns false on failure

Reimplemented from FileOp.

Definition at line 526 of file FileOp.php.

References wfBaseConvert().

Here is the call graph for this function:

Get a list of storage paths written to for this operation.

Returns:
Array

Reimplemented from FileOp.

Definition at line 530 of file FileOp.php.


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