Wikibase
MediaWiki Wikibase extension
|
Helper class for modifying an entities statements. More...
Public Member Functions | |
__construct (SnakFactory $snakFactory, EntityIdParser $entityIdParser, StatementGuidValidator $guidValidator, ApiErrorReporter $errorReporter) | |
validateStatementGuid ( $guid) | |
getStatementFromEntity ( $guid, EntityDocument $entity) | |
getSnakInstance (array $params, PropertyId $propertyId) | |
createSummary (array $params, ApiBase $module) | |
Creates a new Summary instance suitable for representing the action performed by this module. More... | |
applyChangeOp (ChangeOp $changeOp, EntityDocument $entity, Summary $summary=null) | |
Applies the given ChangeOp to the given Entity. More... | |
Private Attributes | |
$snakFactory | |
$entityIdParser | |
$guidValidator | |
$errorReporter | |
Helper class for modifying an entities statements.
Wikibase\Repo\Api\StatementModificationHelper::__construct | ( | SnakFactory | $snakFactory, |
EntityIdParser | $entityIdParser, | ||
StatementGuidValidator | $guidValidator, | ||
ApiErrorReporter | $errorReporter | ||
) |
Wikibase\Repo\Api\StatementModificationHelper::createSummary | ( | array | $params, |
ApiBase | $module | ||
) |
Creates a new Summary instance suitable for representing the action performed by this module.
array | $params | |
ApiBase | $module |
Wikibase\Repo\Api\StatementModificationHelper::getSnakInstance | ( | array | $params, |
PropertyId | $propertyId | ||
) |
string[] | $params | Array with a 'snaktype' and an optional 'value' element. |
PropertyId | $propertyId |
ApiUsageException | |
LogicException |
Wikibase\Repo\Api\StatementModificationHelper::getStatementFromEntity | ( | $guid, | |
EntityDocument | $entity | ||
) |
string | $guid | |
EntityDocument | $entity |
ApiUsageException |
Wikibase\Repo\Api\StatementModificationHelper::validateStatementGuid | ( | $guid | ) |
string | $guid |
|
private |
|
private |
|
private |
|
private |