MediaWiki REL1_40
|
Builder class for the EditResult object. More...
Public Member Functions | |
__construct (RevisionStore $revisionStore, array $softwareTags, ServiceOptions $options) | |
buildEditResult () | |
markAsRevert (int $revertMethod, int $newestRevertedRevId, int $revertAfterRevId=null) | |
Marks this edit as a revert and applies relevant information. | |
setIsNew (bool $isNew) | |
Set whether the edit created a new page. | |
setOriginalRevision ( $originalRevision) | |
setRevisionRecord (RevisionRecord $revisionRecord) | |
Set the revision associated with this edit. | |
Public Attributes | |
const | CONSTRUCTOR_OPTIONS |
Builder class for the EditResult object.
Definition at line 36 of file EditResultBuilder.php.
MediaWiki\Storage\EditResultBuilder::__construct | ( | RevisionStore | $revisionStore, |
array | $softwareTags, | ||
ServiceOptions | $options ) |
RevisionStore | $revisionStore | |
string[] | $softwareTags | Array of currently enabled software change tags. Can be obtained from ChangeTags::getSoftwareTags() |
ServiceOptions | $options | Options for this instance. |
Definition at line 91 of file EditResultBuilder.php.
References MediaWiki\Config\ServiceOptions\assertRequiredOptions().
MediaWiki\Storage\EditResultBuilder::buildEditResult | ( | ) |
Definition at line 106 of file EditResultBuilder.php.
MediaWiki\Storage\EditResultBuilder::markAsRevert | ( | int | $revertMethod, |
int | $newestRevertedRevId, | ||
int | $revertAfterRevId = null ) |
Marks this edit as a revert and applies relevant information.
int | $revertMethod | The method used to make the revert: REVERT_UNDO, REVERT_ROLLBACK or REVERT_MANUAL |
int | $newestRevertedRevId | the revision ID of the latest reverted revision. |
int | null | $revertAfterRevId | the revision ID after which revisions are being reverted. Defaults to the revision before the $newestRevertedRevId. |
Definition at line 160 of file EditResultBuilder.php.
References MediaWiki\Storage\EditResult\REVERT_MANUAL, MediaWiki\Storage\EditResult\REVERT_ROLLBACK, and MediaWiki\Storage\EditResult\REVERT_UNDO.
MediaWiki\Storage\EditResultBuilder::setIsNew | ( | bool | $isNew | ) |
Set whether the edit created a new page.
Should only be called by PageUpdater when saving an edit.
bool | $isNew |
Definition at line 147 of file EditResultBuilder.php.
MediaWiki\Storage\EditResultBuilder::setOriginalRevision | ( | $originalRevision | ) |
RevisionRecord | int | false | null | $originalRevision | RevisionRecord or revision ID for the original revision. False or null to unset. |
Definition at line 198 of file EditResultBuilder.php.
MediaWiki\Storage\EditResultBuilder::setRevisionRecord | ( | RevisionRecord | $revisionRecord | ) |
Set the revision associated with this edit.
Should only be called by PageUpdater when saving an edit.
RevisionRecord | $revisionRecord |
Definition at line 137 of file EditResultBuilder.php.
const MediaWiki\Storage\EditResultBuilder::CONSTRUCTOR_OPTIONS |
Definition at line 38 of file EditResultBuilder.php.
Referenced by MediaWiki\Storage\PageUpdater\__construct().