@@ -48,7 +48,6 @@ |
||
48 | 48 | * |
49 | 49 | * @since 1.9 |
50 | 50 | * |
51 | - * @param array $params |
|
52 | 51 | * |
53 | 52 | * @return string|null |
54 | 53 | */ |
@@ -50,6 +50,9 @@ discard block |
||
50 | 50 | $this->addTypeFromImportVocabulary( $property, current( $dataItems ) ); |
51 | 51 | } |
52 | 52 | |
53 | + /** |
|
54 | + * @param DIProperty $property |
|
55 | + */ |
|
53 | 56 | private function addTypeFromImportVocabulary( $property, $dataItem ) { |
54 | 57 | |
55 | 58 | $importValue = DataValueFactory::getInstance()->newDataValueByItem( |
@@ -79,6 +82,9 @@ discard block |
||
79 | 82 | $this->replaceAnyTypeByImportType( $property, $dataValue ); |
80 | 83 | } |
81 | 84 | |
85 | + /** |
|
86 | + * @param \SMWDataValue $dataValue |
|
87 | + */ |
|
82 | 88 | private function replaceAnyTypeByImportType( DIProperty $property, $dataValue ) { |
83 | 89 | |
84 | 90 | foreach ( $this->getSemanticData()->getPropertyValues( $property ) as $dataItem ) { |
@@ -45,7 +45,7 @@ |
||
45 | 45 | /** |
46 | 46 | * @since 2.2 |
47 | 47 | * |
48 | - * @return array |
|
48 | + * @return string[] |
|
49 | 49 | */ |
50 | 50 | public function getKownPredefinedPropertyLabels() { |
51 | 51 | return $this->languageDependentPropertyLabels; |
@@ -185,6 +185,7 @@ discard block |
||
185 | 185 | * |
186 | 186 | * The return value is the expected combined description. The object $currentDescription will |
187 | 187 | * also be changed (if it was non-NULL). |
188 | + * @param integer $compoundType |
|
188 | 189 | */ |
189 | 190 | private function newCompoundDescription( Description $currentDescription = null, Description $newDescription = null, $compoundType = SMW_CONJUNCTION_QUERY ) { |
190 | 191 | |
@@ -220,6 +221,10 @@ discard block |
||
220 | 221 | } |
221 | 222 | } |
222 | 223 | |
224 | + /** |
|
225 | + * @param Description $currentDescription |
|
226 | + * @param Description $newDescription |
|
227 | + */ |
|
223 | 228 | private function newCompoundDescriptionFor( $compoundType, $currentDescription, $newDescription ) { |
224 | 229 | |
225 | 230 | if ( ( ( $compoundType & SMW_CONJUNCTION_QUERY ) != 0 && ( $currentDescription instanceof Conjunction ) ) || |
@@ -104,7 +104,7 @@ discard block |
||
104 | 104 | * |
105 | 105 | * @param string $queryString |
106 | 106 | * |
107 | - * @return Query |
|
107 | + * @return \SMWQuery |
|
108 | 108 | */ |
109 | 109 | public function create( $queryString ) { |
110 | 110 | |
@@ -243,10 +243,18 @@ discard block |
||
243 | 243 | return $orders; |
244 | 244 | } |
245 | 245 | |
246 | + /** |
|
247 | + * @param string $sort |
|
248 | + * |
|
249 | + * @return string |
|
250 | + */ |
|
246 | 251 | private function getNormalizedSortLabel( $sort ) { |
247 | 252 | return Localizer::getInstance()->getNamespaceTextById( NS_CATEGORY ) == mb_convert_case( $sort, MB_CASE_TITLE ) ? '_INST' : $sort; |
248 | 253 | } |
249 | 254 | |
255 | + /** |
|
256 | + * @param string $key |
|
257 | + */ |
|
250 | 258 | private function getConfiguration( $key, $default ) { |
251 | 259 | return isset( $this->configuration[$key] ) ? $this->configuration[$key] : $default; |
252 | 260 | } |
@@ -211,7 +211,6 @@ discard block |
||
211 | 211 | /** |
212 | 212 | * @since 2.5 |
213 | 213 | * |
214 | - * @param QueryEngine $queryEngine |
|
215 | 214 | */ |
216 | 215 | public function disableCache() { |
217 | 216 | $this->enabledCache = false; |
@@ -283,7 +282,6 @@ discard block |
||
283 | 282 | /** |
284 | 283 | * @since 2.5 |
285 | 284 | * |
286 | - * @param DIWikiPage|array $list |
|
287 | 285 | * @param string $context |
288 | 286 | */ |
289 | 287 | public function resetCacheBy( $item, $context = '' ) { |
@@ -315,6 +313,11 @@ discard block |
||
315 | 313 | return $this->enabledCache && $this->blobStore->canUse() && ( $query->getContextPage() !== null || ( $query->getContextPage() === null && $this->nonEmbeddedCacheLifetime > 0 ) ); |
316 | 314 | } |
317 | 315 | |
316 | + /** |
|
317 | + * @param string $queryId |
|
318 | + * @param Query $query |
|
319 | + * @param \Onoi\BlobStore\Container $container |
|
320 | + */ |
|
318 | 321 | private function newQueryResultFromCache( $queryId, $query, $container ) { |
319 | 322 | |
320 | 323 | $results = array(); |
@@ -379,6 +382,12 @@ discard block |
||
379 | 382 | return $queryResult; |
380 | 383 | } |
381 | 384 | |
385 | + /** |
|
386 | + * @param QueryResult $queryResult |
|
387 | + * @param string $queryId |
|
388 | + * @param \Onoi\BlobStore\Container $container |
|
389 | + * @param Query $query |
|
390 | + */ |
|
382 | 391 | private function addQueryResultToCache( $queryResult, $queryId, $container, $query ) { |
383 | 392 | |
384 | 393 | $this->bufferedStatsdCollector->incr( 'misses' ); |
@@ -465,6 +474,9 @@ discard block |
||
465 | 474 | return md5( $subject . self::VERSION . $this->hashModifier ); |
466 | 475 | } |
467 | 476 | |
477 | + /** |
|
478 | + * @param string $message |
|
479 | + */ |
|
468 | 480 | private function log( $message, $context = array() ) { |
469 | 481 | |
470 | 482 | if ( $this->logger === null ) { |
@@ -474,6 +486,9 @@ discard block |
||
474 | 486 | $this->logger->info( $message, $context ); |
475 | 487 | } |
476 | 488 | |
489 | + /** |
|
490 | + * @param Query $query |
|
491 | + */ |
|
477 | 492 | private function getNoCacheId( $query ) { |
478 | 493 | |
479 | 494 | $id = 'noCache.misc'; |
@@ -493,6 +508,9 @@ discard block |
||
493 | 508 | return $id; |
494 | 509 | } |
495 | 510 | |
511 | + /** |
|
512 | + * @param string $date |
|
513 | + */ |
|
496 | 514 | private function initStats( $date ) { |
497 | 515 | |
498 | 516 | $this->bufferedStatsdCollector->shouldRecord( $this->isEnabled() ); |
@@ -448,7 +448,6 @@ discard block |
||
448 | 448 | * Extend the given SPARQL condition by a suitable order by variable, |
449 | 449 | * possibly adding conditions if required for the type of data. |
450 | 450 | * |
451 | - * @param Condition $sparqlCondition condition to modify |
|
452 | 451 | * @param string $mainVariable the variable that represents the value to be ordered |
453 | 452 | * @param integer $diType DataItem type id |
454 | 453 | */ |
@@ -493,6 +492,9 @@ discard block |
||
493 | 492 | } |
494 | 493 | } |
495 | 494 | |
495 | + /** |
|
496 | + * @param string $propertyKey |
|
497 | + */ |
|
496 | 498 | private function addOrderForUnknownPropertyKey( Condition &$condition, $propertyKey, $order ) { |
497 | 499 | |
498 | 500 | if ( $propertyKey === '' || $propertyKey === '#' ) { // order by result page sortkey |
@@ -223,6 +223,9 @@ |
||
223 | 223 | return QueryDebugOutputFormatter::getStringFrom( 'SPARQLStore', $entries, $query ); |
224 | 224 | } |
225 | 225 | |
226 | + /** |
|
227 | + * @param Condition $condition |
|
228 | + */ |
|
226 | 229 | private function isSingletonConditionWithElementMatch( $condition ) { |
227 | 230 | return $condition instanceof SingletonCondition && $condition->matchElement instanceof Element; |
228 | 231 | } |
@@ -100,7 +100,7 @@ discard block |
||
100 | 100 | /** |
101 | 101 | * @since 2.3 |
102 | 102 | * |
103 | - * @param array|false $namespaces |
|
103 | + * @param boolean $namespaces |
|
104 | 104 | */ |
105 | 105 | public function setRestrictionToNamespaces( $namespaces ) { |
106 | 106 | $this->namespaces = $namespaces; |
@@ -369,6 +369,9 @@ discard block |
||
369 | 369 | } |
370 | 370 | } |
371 | 371 | |
372 | + /** |
|
373 | + * @param boolean $emptyRange |
|
374 | + */ |
|
372 | 375 | private function findNextIdPosition( &$id, $emptyRange ) { |
373 | 376 | |
374 | 377 | $nextPosition = $id + $this->iterationLimit; |