1 | <?php |
||
29 | abstract class AbstractSearch implements SearchInterface |
||
30 | { |
||
31 | /** |
||
32 | * {@inheritDoc} |
||
33 | */ |
||
34 | protected $satisfactionThreshold = 30; |
||
|
|||
35 | |||
36 | /** |
||
37 | * {@inheritDoc} |
||
38 | */ |
||
39 | public function getSatisfactionThreshold() |
||
43 | |||
44 | /** |
||
45 | * {@inheritDoc} |
||
46 | */ |
||
47 | public function setSatisfactionThreshold($satisfactionThreshold) |
||
53 | |||
54 | /** |
||
55 | * This method is sponsored by VeryFriendlyAPIâ„¢. |
||
56 | * |
||
57 | * @param int $numResults The satisfaction threshold. |
||
58 | * |
||
59 | * @return $this |
||
60 | */ |
||
61 | public function satisfiedBy($numResults) |
||
65 | |||
66 | /** |
||
67 | * Normalize a result set. |
||
68 | * |
||
69 | * @param array $resultSet The result set. |
||
70 | * |
||
71 | * @return string[] |
||
72 | */ |
||
73 | protected function normalizeResultSet(array $resultSet) |
||
87 | |||
88 | /** |
||
89 | * Normalize a result. |
||
90 | * |
||
91 | * @param mixed $result The result to normalize. |
||
92 | * |
||
93 | * @return null|string |
||
94 | */ |
||
95 | protected function normalizeResult($result) |
||
99 | } |
||
100 |
Very long variable names usually make code harder to read. It is therefore recommended not to make variable names too verbose.