1 | <?php |
||
13 | class Git extends Command |
||
14 | { |
||
15 | |||
16 | /** @var string */ |
||
17 | private $gitExecutable = 'git'; |
||
18 | |||
19 | private $command; |
||
20 | |||
21 | private $workingDirectory; |
||
22 | |||
23 | /** |
||
24 | * Redirect stderr to stdout? - for testing purposes only |
||
25 | * Git writes his progressive output do stderr (even if everything ok) - at least when clonning |
||
26 | * @var bool |
||
27 | */ |
||
28 | private $redirectStderrToStdout = FALSE; |
||
29 | |||
30 | |||
31 | /** |
||
32 | * Returns path to git executable |
||
33 | * @return string |
||
34 | */ |
||
35 | 1 | public function getGitExecutable() |
|
39 | |||
40 | |||
41 | /** |
||
42 | * Sets path to git executable |
||
43 | * @param string $gitExecutable |
||
44 | */ |
||
45 | 2 | public function setGitExecutable($gitExecutable) |
|
52 | |||
53 | |||
54 | /** |
||
55 | * @return string |
||
56 | */ |
||
57 | 1 | public function getWorkingDirectory() |
|
61 | |||
62 | |||
63 | /** |
||
64 | * Sets path to working directory |
||
65 | * @param string $workingTree |
||
|
|||
66 | */ |
||
67 | 2 | public function setWorkingDirectory($workingDirectory) |
|
71 | |||
72 | |||
73 | /** |
||
74 | * @return boolean |
||
75 | */ |
||
76 | 1 | public function isRedirectStderrToStdout() |
|
80 | |||
81 | |||
82 | /** |
||
83 | * @param boolean $redirectStderrToStdout |
||
84 | */ |
||
85 | 2 | public function setRedirectStderrToStdout($redirectStderrToStdout) |
|
89 | |||
90 | |||
91 | /** |
||
92 | * Return setted git command |
||
93 | * @return mixed |
||
94 | */ |
||
95 | 1 | public function getCommand() |
|
99 | |||
100 | |||
101 | /** |
||
102 | * Sets git command (to be executed later) |
||
103 | * @param mixed $command |
||
104 | */ |
||
105 | 3 | public function setCommand($command) |
|
109 | |||
110 | |||
111 | /** |
||
112 | * Sets git command for cloning repository (to be executed later) |
||
113 | */ |
||
114 | 1 | public function cloneRepo($url, $branch = NULL, $dir = NULL) |
|
122 | |||
123 | |||
124 | /** |
||
125 | * @return ExecResult |
||
126 | */ |
||
127 | 2 | public function execute() |
|
140 | |||
141 | |||
142 | 2 | private function exec($command) |
|
148 | |||
149 | } |
This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.
Consider the following example. The parameter
$italy
is not defined by the methodfinale(...)
.The most likely cause is that the parameter was removed, but the annotation was not.