Wikibase
MediaWiki Wikibase extension
Wikibase\Repo\Api\RemoveQualifiers Class Reference

API module for removing qualifiers from a statement. More...

+ Inheritance diagram for Wikibase\Repo\Api\RemoveQualifiers:
+ Collaboration diagram for Wikibase\Repo\Api\RemoveQualifiers:

Public Member Functions

 __construct (ApiMain $mainModule, string $moduleName, ApiErrorReporter $errorReporter, StatementChangeOpFactory $statementChangeOpFactory, StatementModificationHelper $modificationHelper, StatementGuidParser $guidParser, callable $resultBuilderInstantiator, callable $entitySavingHelperInstantiator, bool $federatedPropertiesEnabled)
 
 execute ()
 
 isWriteMode ()
 
 needsToken ()
 

Static Public Member Functions

static factory (ApiMain $mainModule, string $moduleName, EntityIdParser $entityIdParser, StatementGuidParser $statementGuidParser, StatementGuidValidator $statementGuidValidator)
 

Protected Member Functions

 getAllowedParams ()
 
 getExamplesMessages ()
 

Protected Attributes

 $errorReporter
 

Private Member Functions

 validateParameters (array $params)
 
 getChangeOps (string $statementGuid, array $qualifierHashes)
 
 getQualifierHashesFromParams (array $params, Statement $statement)
 

Private Attributes

 $statementChangeOpFactory
 
 $modificationHelper
 
 $guidParser
 
 $resultBuilder
 
 $entitySavingHelper
 

Detailed Description

API module for removing qualifiers from a statement.

Author
Jeroen De Dauw < jeroe.nosp@m.nded.nosp@m.auw@g.nosp@m.mail.nosp@m..com >
Tobias Gritschacher < tobia.nosp@m.s.gr.nosp@m.itsch.nosp@m.ache.nosp@m.r@wik.nosp@m.imed.nosp@m.ia.de >

Constructor & Destructor Documentation

◆ __construct()

Wikibase\Repo\Api\RemoveQualifiers::__construct ( ApiMain  $mainModule,
string  $moduleName,
ApiErrorReporter  $errorReporter,
StatementChangeOpFactory  $statementChangeOpFactory,
StatementModificationHelper  $modificationHelper,
StatementGuidParser  $guidParser,
callable  $resultBuilderInstantiator,
callable  $entitySavingHelperInstantiator,
bool  $federatedPropertiesEnabled 
)

Member Function Documentation

◆ execute()

Wikibase\Repo\Api\RemoveQualifiers::execute ( )

◆ factory()

static Wikibase\Repo\Api\RemoveQualifiers::factory ( ApiMain  $mainModule,
string  $moduleName,
EntityIdParser  $entityIdParser,
StatementGuidParser  $statementGuidParser,
StatementGuidValidator  $statementGuidValidator 
)
static

◆ getAllowedParams()

Wikibase\Repo\Api\RemoveQualifiers::getAllowedParams ( )
protected

◆ getChangeOps()

Wikibase\Repo\Api\RemoveQualifiers::getChangeOps ( string  $statementGuid,
array  $qualifierHashes 
)
private
Parameters
string$statementGuid
string[]$qualifierHashes
Returns
ChangeOp[]

◆ getExamplesMessages()

Wikibase\Repo\Api\RemoveQualifiers::getExamplesMessages ( )
protected

◆ getQualifierHashesFromParams()

Wikibase\Repo\Api\RemoveQualifiers::getQualifierHashesFromParams ( array  $params,
Statement  $statement 
)
private
Parameters
array$params
Statement$statement
Returns
string[]

◆ isWriteMode()

Wikibase\Repo\Api\RemoveQualifiers::isWriteMode ( )

◆ needsToken()

Wikibase\Repo\Api\RemoveQualifiers::needsToken ( )
See also
ApiBase::needsToken
Returns
string

◆ validateParameters()

Wikibase\Repo\Api\RemoveQualifiers::validateParameters ( array  $params)
private
Parameters
array$params
Exceptions
ApiUsageException

Member Data Documentation

◆ $entitySavingHelper

Wikibase\Repo\Api\RemoveQualifiers::$entitySavingHelper
private

◆ $errorReporter

Wikibase\Repo\Api\RemoveQualifiers::$errorReporter
protected

◆ $guidParser

Wikibase\Repo\Api\RemoveQualifiers::$guidParser
private

◆ $modificationHelper

Wikibase\Repo\Api\RemoveQualifiers::$modificationHelper
private

◆ $resultBuilder

Wikibase\Repo\Api\RemoveQualifiers::$resultBuilder
private

◆ $statementChangeOpFactory

Wikibase\Repo\Api\RemoveQualifiers::$statementChangeOpFactory
private

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