1 | <?php |
||
26 | class HomePathDeterminator |
||
27 | { |
||
28 | /** |
||
29 | * The cached value. |
||
30 | * |
||
31 | * @var string |
||
32 | */ |
||
33 | private $home; |
||
34 | |||
35 | /** |
||
36 | * Create a new instance. |
||
37 | * |
||
38 | * @param string $home The home dir if desired to override (null to autodetect). |
||
|
|||
39 | */ |
||
40 | public function __construct($home = null) |
||
44 | |||
45 | /** |
||
46 | * Retrieve the home directory. |
||
47 | * |
||
48 | * @return string |
||
49 | */ |
||
50 | public function homeDir() |
||
58 | |||
59 | /** |
||
60 | * Retrieve the directory to store tenside related data. |
||
61 | * |
||
62 | * @return string |
||
63 | */ |
||
64 | public function tensideDataDir() |
||
68 | |||
69 | /** |
||
70 | * Determine the correct working directory. |
||
71 | * |
||
72 | * @return string |
||
73 | * |
||
74 | * @throws \RuntimeException When the home directory is not /web. |
||
75 | */ |
||
76 | private function detectHomeDirectory() |
||
99 | } |
||
100 |
This check looks for
@param
annotations where the type inferred by our type inference engine differs from the declared type.It makes a suggestion as to what type it considers more descriptive.
Most often this is a case of a parameter that can be null in addition to its declared types.