34 [
'overwrite',
'overwriteSame',
'headers' ],
43 $status = StatusValue::newGood();
47 $maxFileSize = $this->backend->maxFileSizeInternal();
48 if ( $sourceSize > $maxFileSize ) {
49 $status->fatal(
'backend-fail-maxsize', $this->params[
'dst'], $maxFileSize );
59 if ( $status->isOK() ) {
60 $batchPredicates->
assumeFileExists( $this->params[
'dst'], $sourceSize, $sourceSha1 );
67 if ( $this->overwriteSameCase ) {
68 $status = StatusValue::newGood();
71 $status = $this->backend->createInternal( $this->
setFlags( $this->params ) );
78 return strlen( $this->params[
'content'] );
82 return \Wikimedia\base_convert( sha1( $this->params[
'content'] ), 16, 36, 31 );
86 return [ $this->params[
'dst'] ];
91class_alias( CreateFileOp::class,
'CreateFileOp' );
Generic operation result class Has warning/error list, boolean status and arbitrary value.