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 | declare( strict_types = 1 ); |
3 | |
4 | namespace MediaWiki\Extension\Translate\TtmServer; |
5 | |
6 | /** |
7 | * Interface for TtmServer that can act as backend for translation search. |
8 | * @ingroup TTMServer |
9 | */ |
10 | interface SearchableTtmServer { |
11 | /** |
12 | * Performs a search in the translation database. |
13 | * |
14 | * @param string $queryString String to search for. |
15 | * @param array $opts Query options like language. |
16 | * @param array $highlight Tags for highlighting. |
17 | * @return mixed Result set |
18 | */ |
19 | public function search( string $queryString, array $opts, array $highlight ); |
20 | |
21 | /** |
22 | * @param mixed $resultset |
23 | * @return array[] |
24 | */ |
25 | public function getFacets( $resultset ): array; |
26 | |
27 | /** @param mixed $resultset */ |
28 | public function getTotalHits( $resultset ): int; |
29 | |
30 | /** |
31 | * @param mixed $resultset |
32 | * @return array[] |
33 | */ |
34 | public function getDocuments( $resultset ): array; |
35 | } |