| Conditions | 1 |
| Paths | 1 |
| Total Lines | 10 |
| Code Lines | 7 |
| Lines | 10 |
| Ratio | 100 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 59 | View Code Duplication | public function readpassword($prompt) |
|
| 60 | { |
||
| 61 | echo $prompt; |
||
| 62 | system('stty -echo'); |
||
| 63 | $password = rtrim(fgets(STDIN), PHP_EOL); |
||
| 64 | system('stty echo'); |
||
| 65 | echo "\n"; |
||
| 66 | |||
| 67 | return $password; |
||
| 68 | } |
||
| 69 | } |
||
| 70 |
If you implement
__calland you know which methods are available, you can improve IDE auto-completion and static analysis by adding a @method annotation to the class.This is often the case, when
__callis implemented by a parent class and only the child class knows which methods exist: