Wikibase
MediaWiki Wikibase extension
Loading...
Searching...
No Matches
Wikibase\Repo\FederatedProperties\SummaryParsingPrefetchHelper Class Reference

A helper class for parsing and prefetching properties from summaries for federated properties. More...

Public Member Functions

 __construct (PrefetchingTermLookup $prefetchingLookup)
 
 prefetchFederatedProperties ( $rows, array $languageCodes, array $termTypes)
 
 extractSummaryProperties ( $result)
 

Public Attributes

const PROPERTY_SUMMARY_REGEXP = '/\[\[(\S+)(P[1-9]\d*)\]\]/'
 Matching links to properties in in edit summaries, such as "[[Property:P123]]" or "[[wdbeta:Special:EntityPage/P123]]".
 

Private Member Functions

 getCommentText ( $revisionRow)
 

Private Attributes

 $prefetchingLookup
 

Detailed Description

A helper class for parsing and prefetching properties from summaries for federated properties.

Constructor & Destructor Documentation

◆ __construct()

Wikibase\Repo\FederatedProperties\SummaryParsingPrefetchHelper::__construct ( PrefetchingTermLookup $prefetchingLookup)

Member Function Documentation

◆ extractSummaryProperties()

Wikibase\Repo\FederatedProperties\SummaryParsingPrefetchHelper::extractSummaryProperties ( $result)
Parameters
IResultWrapper | \stdClass[] | RevisionRecord[]$result
Returns
PropertyId[]

◆ getCommentText()

Wikibase\Repo\FederatedProperties\SummaryParsingPrefetchHelper::getCommentText ( $revisionRow)
private
Parameters
\stdClass | RevisionRecord | null$revisionRow
Returns
string|null

◆ prefetchFederatedProperties()

Wikibase\Repo\FederatedProperties\SummaryParsingPrefetchHelper::prefetchFederatedProperties ( $rows,
array $languageCodes,
array $termTypes )
Parameters
IResultWrapper | \stdClass[] | RevisionRecord[]$rows
array$languageCodes
array$termTypes

Member Data Documentation

◆ $prefetchingLookup

Wikibase\Repo\FederatedProperties\SummaryParsingPrefetchHelper::$prefetchingLookup
private

◆ PROPERTY_SUMMARY_REGEXP

const Wikibase\Repo\FederatedProperties\SummaryParsingPrefetchHelper::PROPERTY_SUMMARY_REGEXP = '/\[\[(\S+)(P[1-9]\d*)\]\]/'

Matching links to properties in in edit summaries, such as "[[Property:P123]]" or "[[wdbeta:Special:EntityPage/P123]]".


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