|
MediaWiki master
|
Inherits MediaWiki\EditPage\IEditObject.

Public Member Functions | |
| __construct (private readonly PageEditInputs $inputs, private readonly ServiceOptions $options, private readonly IContentHandlerFactory $contentHandlerFactory, private readonly EditConstraintFactory $constraintFactory, private readonly IConnectionProvider $connectionProvider, private readonly Language $contentLanguage, private readonly ContentTransformer $contentTransformer, private readonly LoggerInterface $editConflictLogger, private readonly PageEditingHelper $pageEditingHelper, private readonly RateLimiter $rateLimiter, private readonly RevisionStore $revisionStore, private readonly ShadowPageLoader $shadowPageLoader, private readonly TitleFormatter $titleFormatter, private readonly UserOptionsLookup $userOptionsLookup, private readonly WatchlistManager $watchlistManager, private readonly WatchedItemStoreInterface $watchedItemStore, private readonly WikiPageFactory $wikiPageFactory,) | |
| edit () | |
| Perform checks, perform the edit if they pass, and wrap the resulting data in a PageEditResult object. | |
Public Attributes | |
| const | CONSTRUCTOR_OPTIONS |
Public Attributes inherited from MediaWiki\EditPage\IEditObject | |
| const | AS_ARTICLE_WAS_DELETED = 222 |
| Status: article was deleted while editing and wpRecreate == false or form was not posted. | |
| const | AS_BLANK_ARTICLE = 224 |
| Status: user tried to create a blank page and wpIgnoreBlankArticle == false. | |
| const | AS_BLOCKED_PAGE_FOR_USER = 215 |
| Status: User is blocked from editing this page. | |
| const | AS_BROKEN_REDIRECT = 244 |
| Status: user tried to create a redirect to a nonexistent page. | |
| const | AS_CHANGE_TAG_ERROR = 237 |
| Status: an error relating to change tagging. | |
| const | AS_CONFLICT_DETECTED = 225 |
| Status: (non-resolvable) edit conflict. | |
| const | AS_CONTENT_TOO_BIG = 216 |
| Status: Content too big (> $wgMaxArticleSize) | |
| const | AS_DOUBLE_REDIRECT = 245 |
| Status: user tried to create a redirect to another redirect. | |
| const | AS_DOUBLE_REDIRECT_LOOP = 246 |
| Status: user tried to create a redirect to another redirect that is pointing to the current page. | |
| const | AS_END = 231 |
| Status: WikiPage::doEdit() was unsuccessful. | |
| const | AS_HOOK_ERROR = 210 |
| Status: Article update aborted by a hook function. | |
| const | AS_HOOK_ERROR_EXPECTED = 212 |
| Status: A hook function returned an error. | |
| const | AS_IMAGE_REDIRECT_ANON = 233 |
| Status: anonymous user is not allowed to upload (User::isAllowed('upload') == false) | |
| const | AS_IMAGE_REDIRECT_LOGGED = 234 |
| Status: logged in user is not allowed to upload (User::isAllowed('upload') == false) | |
| const | AS_INVALID_REDIRECT_TARGET = 247 |
| Status: user tried to create a redirect to an invalid redirect target. | |
| const | AS_MAX_ARTICLE_SIZE_EXCEEDED = 229 |
| Status: article is too big (> $wgMaxArticleSize), after merging in the new section. | |
| const | AS_NO_CHANGE_CONTENT_MODEL = 235 |
| Status: user tried to modify the content model, but is not allowed to do that ( User::isAllowed('editcontentmodel') == false ) | |
| const | AS_NO_CREATE_PERMISSION = 223 |
| Status: user tried to create this page, but is not allowed to do that. | |
| const | AS_PARSE_ERROR = 240 |
| Status: can't parse content. | |
| const | AS_RATE_LIMITED = 221 |
| Status: rate limiter for action 'edit' was tripped. | |
| const | AS_READ_ONLY_PAGE = 220 |
| Status: wiki is in readonly mode (ReadOnlyMode::isReadOnly() == true) | |
| const | AS_READ_ONLY_PAGE_ANON = 218 |
| Status: this anonymous user is not allowed to edit this page. | |
| const | AS_READ_ONLY_PAGE_LOGGED = 219 |
| Status: this logged in user is not allowed to edit this page. | |
| const | AS_REVISION_MISSING = 248 |
| Status: user tried to edit a revision that went missing. | |
| const | AS_REVISION_WAS_DELETED = 217 |
| Status: revision x was deleted while editing (?action=edit&oldid=x) | |
| const | AS_SELF_REDIRECT = 236 |
| Status: user tried to create self-redirect and wpIgnoreSelfRedirect is false. | |
| const | AS_SPAM_ERROR = 232 |
| Status: summary contained spam according to one of the regexes in $wgSummarySpamRegex. | |
| const | AS_SUCCESS_NEW_ARTICLE = 201 |
| Status: Article successfully created. | |
| const | AS_SUCCESS_UPDATE = 200 |
| Status: Article successfully updated. | |
| const | AS_SUMMARY_NEEDED = 226 |
| Status: no edit summary given and the user has forceeditsummary set and the user is not editing in their own userspace or talkspace and wpIgnoreBlankSummary == false. | |
| const | AS_TEXTBOX_EMPTY = 228 |
| Status: user tried to create a new section without content. | |
| const | AS_UNABLE_TO_ACQUIRE_TEMP_ACCOUNT = 243 |
| Status: edit rejected because server was unable to acquire a temporary account name for this user. | |
| const | AS_UNICODE_NOT_SUPPORTED = 242 |
| Status: edit rejected because browser doesn't support Unicode. | |
| MediaWiki\PageEdit\PageEdit::__construct | ( | private readonly PageEditInputs | $inputs, |
| private readonly ServiceOptions | $options, | ||
| private readonly IContentHandlerFactory | $contentHandlerFactory, | ||
| private readonly EditConstraintFactory | $constraintFactory, | ||
| private readonly IConnectionProvider | $connectionProvider, | ||
| private readonly Language | $contentLanguage, | ||
| private readonly ContentTransformer | $contentTransformer, | ||
| private readonly LoggerInterface | $editConflictLogger, | ||
| private readonly PageEditingHelper | $pageEditingHelper, | ||
| private readonly RateLimiter | $rateLimiter, | ||
| private readonly RevisionStore | $revisionStore, | ||
| private readonly ShadowPageLoader | $shadowPageLoader, | ||
| private readonly TitleFormatter | $titleFormatter, | ||
| private readonly UserOptionsLookup | $userOptionsLookup, | ||
| private readonly WatchlistManager | $watchlistManager, | ||
| private readonly WatchedItemStoreInterface | $watchedItemStore, | ||
| private readonly WikiPageFactory | $wikiPageFactory ) |
Definition at line 75 of file PageEdit.php.
| MediaWiki\PageEdit\PageEdit::edit | ( | ) |
Perform checks, perform the edit if they pass, and wrap the resulting data in a PageEditResult object.
Definition at line 103 of file PageEdit.php.
| const MediaWiki\PageEdit\PageEdit::CONSTRUCTOR_OPTIONS |
Definition at line 60 of file PageEdit.php.