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 CirrusSearch\BuildDocument\Completion; |
4 | |
5 | /** |
6 | * Extra builder for the completion suggester index. |
7 | * Useful to add extra suggestions that are not part of the default strategy. |
8 | */ |
9 | interface ExtraSuggestionsBuilder { |
10 | /** |
11 | * Builds extra suggestions. |
12 | * This method can be called twice per cirrus document. |
13 | * - first time with title suggestions |
14 | * - second time with redirect suggestions |
15 | * |
16 | * @param mixed[] $inputDoc |
17 | * @param string $suggestType (title or redirect) |
18 | * @param int $score |
19 | * @param \Elastica\Document $suggestDoc suggestion type (title or redirect) |
20 | * @param int $targetNamespace |
21 | */ |
22 | public function build( array $inputDoc, $suggestType, $score, \Elastica\Document $suggestDoc, $targetNamespace ); |
23 | |
24 | /** |
25 | * The fields needed by this extra builder. |
26 | * @return string[] the list of fields |
27 | */ |
28 | public function getRequiredFields(); |
29 | } |