Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
Total | n/a |
0 / 0 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
1 | <?php |
2 | |
3 | namespace GrowthExperiments\NewcomerTasks; |
4 | |
5 | use MediaWiki\Linker\LinkTarget; |
6 | |
7 | /** |
8 | * Shared base interface for recommendations for structured tasks. |
9 | * @see https://www.mediawiki.org/wiki/Growth/Personalized_first_day/Structured_tasks |
10 | * @see RecommendationProvider |
11 | */ |
12 | interface Recommendation { |
13 | |
14 | /** |
15 | * Get the title of the page for which the recommendation was generated. |
16 | * @return LinkTarget |
17 | */ |
18 | public function getTitle(): LinkTarget; |
19 | |
20 | /** |
21 | * Serialize the object into an array representation that can be turned into JSON |
22 | * and passed to the frontend code. |
23 | * @return array |
24 | */ |
25 | public function toArray(): array; |
26 | |
27 | } |