@@ -228,8 +228,8 @@ discard block |
||
228 | 228 | * Fetches a route and maps a resource list of models under provided key |
229 | 229 | * |
230 | 230 | * @param Route|string $route |
231 | - * @param $resourceKey |
|
232 | - * @param $resourceClass |
|
231 | + * @param string $resourceKey |
|
232 | + * @param string $resourceClass |
|
233 | 233 | * @return ArrayCollection |
234 | 234 | */ |
235 | 235 | protected function getResourceCollection($route, $resourceKey, $resourceClass) |
@@ -246,7 +246,7 @@ discard block |
||
246 | 246 | /** |
247 | 247 | * Returns users list |
248 | 248 | * |
249 | - * @return Collection|User[] |
|
249 | + * @return ArrayCollection |
|
250 | 250 | */ |
251 | 251 | public function getUsers() |
252 | 252 | { |
@@ -315,8 +315,8 @@ discard block |
||
315 | 315 | /** |
316 | 316 | * |
317 | 317 | * |
318 | - * @param User|string $user A User model or userId |
|
319 | - * @return Collection|Notification[] |
|
318 | + * @param string $user A User model or userId |
|
319 | + * @return ArrayCollection |
|
320 | 320 | */ |
321 | 321 | public function getUserNotifications($user) |
322 | 322 | { |
@@ -329,8 +329,8 @@ discard block |
||
329 | 329 | /** |
330 | 330 | * Returns the list of badges that certain user has won |
331 | 331 | * |
332 | - * @param User|string $user A User model or userId |
|
333 | - * @return Collection|Badge[] |
|
332 | + * @param string $user A User model or userId |
|
333 | + * @return ArrayCollection |
|
334 | 334 | */ |
335 | 335 | public function getUserBadges($user) |
336 | 336 | { |
@@ -343,10 +343,10 @@ discard block |
||
343 | 343 | /** |
344 | 344 | * Returns the number of achievements of each type for certain user |
345 | 345 | * |
346 | - * @param User|string $user A User model or userId |
|
346 | + * @param string $user A User model or userId |
|
347 | 347 | * @param array|string $types List of types in a comma-separated string or array. |
348 | 348 | * All the types will be returned by default |
349 | - * @return Collection|Achievement[] |
|
349 | + * @return ArrayCollection |
|
350 | 350 | */ |
351 | 351 | public function getUserAchievements($user, $types = []) |
352 | 352 | { |
@@ -364,9 +364,9 @@ discard block |
||
364 | 364 | /** |
365 | 365 | * Returns the list of steps in a quest telling if certain user has already completed them |
366 | 366 | * |
367 | - * @param User|string $user A User model or userId |
|
367 | + * @param string $user A User model or userId |
|
368 | 368 | * @param string $questCode |
369 | - * @return Collection|QuestStep[] |
|
369 | + * @return ArrayCollection |
|
370 | 370 | */ |
371 | 371 | public function getUserProgressInQuest($user, $questCode) |
372 | 372 | { |
@@ -380,7 +380,7 @@ discard block |
||
380 | 380 | /** |
381 | 381 | * Returns the list of created quests |
382 | 382 | * |
383 | - * @return Collection|Quest[] |
|
383 | + * @return ArrayCollection |
|
384 | 384 | */ |
385 | 385 | public function getQuests() |
386 | 386 | { |
@@ -390,8 +390,8 @@ discard block |
||
390 | 390 | /** |
391 | 391 | * Returns all the quests with which a user is involved with, including the list of their steps |
392 | 392 | * |
393 | - * @param User|string $user A User model or userId |
|
394 | - * @return Collection|Quest[] |
|
393 | + * @param string $user A User model or userId |
|
394 | + * @return ArrayCollection |
|
395 | 395 | */ |
396 | 396 | public function getUserStatusInQuests($user) |
397 | 397 | { |
@@ -402,7 +402,7 @@ discard block |
||
402 | 402 | } |
403 | 403 | |
404 | 404 | /** |
405 | - * @return Collection|Level[] |
|
405 | + * @return ArrayCollection |
|
406 | 406 | */ |
407 | 407 | public function getLevels() |
408 | 408 | { |
@@ -412,7 +412,7 @@ discard block |
||
412 | 412 | /** |
413 | 413 | * Returns the level of a user in certain scenario |
414 | 414 | * |
415 | - * @param User|string $user A User model or userId |
|
415 | + * @param string $user A User model or userId |
|
416 | 416 | * @param string|null $scenarioCode |
417 | 417 | * @return Level |
418 | 418 | */ |
@@ -441,8 +441,8 @@ discard block |
||
441 | 441 | * If a user is provided, the list will include the team of that user, even if it is not in the top list |
442 | 442 | * |
443 | 443 | * @param int|null $maxCount Maximum number of results |
444 | - * @param User|string|null $user A User model or userId |
|
445 | - * @return Collection|Team[] |
|
444 | + * @param string $user A User model or userId |
|
445 | + * @return ArrayCollection |
|
446 | 446 | */ |
447 | 447 | public function getTeamsLeaderboard($maxCount = null, $user = null) |
448 | 448 | { |
@@ -468,7 +468,7 @@ discard block |
||
468 | 468 | * Returns the top rated items |
469 | 469 | * |
470 | 470 | * @param int $maxCount |
471 | - * @return Collection|Item[] |
|
471 | + * @return ArrayCollection |
|
472 | 472 | */ |
473 | 473 | public function getItemsLeaderboard($maxCount = 6) |
474 | 474 | { |
@@ -480,8 +480,8 @@ discard block |
||
480 | 480 | /** |
481 | 481 | * Rates an item increasing its score and setting the rate from certain user. |
482 | 482 | * |
483 | - * @param User|string $user a User model or userId |
|
484 | - * @param Item|string $item an Item model or itemId |
|
483 | + * @param string $user a User model or userId |
|
484 | + * @param string $item an Item model or itemId |
|
485 | 485 | * @param int $score |
486 | 486 | * @return Item |
487 | 487 | */ |
@@ -513,8 +513,8 @@ discard block |
||
513 | 513 | /** |
514 | 514 | * Rates an item increasing its score and setting the rate from certain user. |
515 | 515 | * |
516 | - * @param User|string $user a User model or userId |
|
517 | - * @param array $items an array of Item models |
|
516 | + * @param string $user a User model or userId |
|
517 | + * @param Item[] $items an array of Item models |
|
518 | 518 | * @return ArrayCollection |
519 | 519 | */ |
520 | 520 | public function rateSeveralItems($user, array $items) |
@@ -545,7 +545,7 @@ discard block |
||
545 | 545 | /** |
546 | 546 | * Deletes certain item |
547 | 547 | * |
548 | - * @param Item|string $item an Item model or itemId |
|
548 | + * @param string $item an Item model or itemId |
|
549 | 549 | * @return void |
550 | 550 | */ |
551 | 551 | public function deleteItem($item) |
@@ -559,7 +559,7 @@ discard block |
||
559 | 559 | /** |
560 | 560 | * Resets an item's score to zero |
561 | 561 | * |
562 | - * @param Item|string $item an Item model or itemId |
|
562 | + * @param string $item an Item model or itemId |
|
563 | 563 | * @return void |
564 | 564 | */ |
565 | 565 | public function resetItemScore($item) |
@@ -575,7 +575,7 @@ discard block |
||
575 | 575 | * By calling this method, only the properties username, fullName, avatar and score of the User will be popullated, |
576 | 576 | * as well as the provided userId |
577 | 577 | * |
578 | - * @param $userId |
|
578 | + * @param string $userId |
|
579 | 579 | * @return User |
580 | 580 | */ |
581 | 581 | public function getUserData($userId) |
@@ -596,10 +596,10 @@ discard block |
||
596 | 596 | /** |
597 | 597 | * Performs an action notification from certain user |
598 | 598 | * |
599 | - * @param User|string $user A User model or userId |
|
599 | + * @param string $user A User model or userId |
|
600 | 600 | * @param string $actionCode |
601 | 601 | * @param Item|string $item An Item model or itemId |
602 | - * @param array $categories |
|
602 | + * @param string[] $categories |
|
603 | 603 | * @return void |
604 | 604 | */ |
605 | 605 | public function notifyAction($user, $actionCode, $item = null, array $categories = []) |
@@ -627,7 +627,7 @@ discard block |
||
627 | 627 | /** |
628 | 628 | * Performs an action notification from certain user |
629 | 629 | * |
630 | - * @param User|string $user A User model or userId |
|
630 | + * @param string $user A User model or userId |
|
631 | 631 | * @param array $actions array of Action objects or strings |
632 | 632 | * @return void |
633 | 633 | */ |
@@ -661,11 +661,11 @@ discard block |
||
661 | 661 | /** |
662 | 662 | * Performs an interaction notification between two users |
663 | 663 | * |
664 | - * @param User|string $user A User model or userId |
|
665 | - * @param User|string $targetUser A User model or userId |
|
664 | + * @param string $user A User model or userId |
|
665 | + * @param string $targetUser A User model or userId |
|
666 | 666 | * @param string $interactionCode |
667 | 667 | * @param Item|null $item An Item model or itemId |
668 | - * @param array $categories |
|
668 | + * @param string[] $categories |
|
669 | 669 | * @return void |
670 | 670 | */ |
671 | 671 | public function notifyInteraction($user, $targetUser, $interactionCode, $item = null, array $categories = []) |
@@ -694,7 +694,7 @@ discard block |
||
694 | 694 | /** |
695 | 695 | * Returns the number of times a user has performed certain action |
696 | 696 | * |
697 | - * @param User|string $user A User model or userId |
|
697 | + * @param string $user A User model or userId |
|
698 | 698 | * @param string $actionCode |
699 | 699 | * @return int |
700 | 700 | */ |
@@ -711,10 +711,10 @@ discard block |
||
711 | 711 | /** |
712 | 712 | * Returns information about the status of an interactionaccording to its limits |
713 | 713 | * |
714 | - * @param User|string $user A User model or userId |
|
715 | - * @param User|string $targetUser A User model or userId |
|
714 | + * @param string $user A User model or userId |
|
715 | + * @param string $targetUser A User model or userId |
|
716 | 716 | * @param string $interactionCode |
717 | - * @param Item|string $item An Item model or itemId |
|
717 | + * @param string $item An Item model or itemId |
|
718 | 718 | * @return array |
719 | 719 | */ |
720 | 720 | public function getInteractionStatus($user, $targetUser, $interactionCode, $item) |
@@ -749,9 +749,9 @@ discard block |
||
749 | 749 | /** |
750 | 750 | * Returns the list of most recent updates for certain user |
751 | 751 | * |
752 | - * @param User|string $user A User model or userId |
|
752 | + * @param string $user A User model or userId |
|
753 | 753 | * @param int $maxCount |
754 | - * @return Collection|Update[] |
|
754 | + * @return ArrayCollection |
|
755 | 755 | */ |
756 | 756 | public function getUserLastUpdates($user, $maxCount = null) |
757 | 757 | { |
@@ -89,7 +89,7 @@ discard block |
||
89 | 89 | } |
90 | 90 | |
91 | 91 | /** |
92 | - * @return mixed |
|
92 | + * @return boolean |
|
93 | 93 | */ |
94 | 94 | public function getGeneratesNotification() |
95 | 95 | { |
@@ -97,7 +97,7 @@ discard block |
||
97 | 97 | } |
98 | 98 | |
99 | 99 | /** |
100 | - * @param mixed $generatesNotification |
|
100 | + * @param boolean $generatesNotification |
|
101 | 101 | * @return $this |
102 | 102 | */ |
103 | 103 | public function setGeneratesNotification($generatesNotification) |