@@ -31,7 +31,7 @@ |
||
31 | 31 | /** |
32 | 32 | * Wrap a stream from libsmbclient-php into a regular php stream |
33 | 33 | * |
34 | - * @param \Icewind\SMB\NativeState $state |
|
34 | + * @param NativeState $state |
|
35 | 35 | * @param resource $smbStream |
36 | 36 | * @param string $mode |
37 | 37 | * @param string $url |
@@ -31,7 +31,7 @@ |
||
31 | 31 | /** |
32 | 32 | * Wrap a stream from libsmbclient-php into a regular php stream |
33 | 33 | * |
34 | - * @param \Icewind\SMB\NativeState $state |
|
34 | + * @param NativeState $state |
|
35 | 35 | * @param resource $smbStream |
36 | 36 | * @param string $mode |
37 | 37 | * @param string $url |
@@ -20,7 +20,7 @@ |
||
20 | 20 | * Check if the smbclient php extension is available |
21 | 21 | * |
22 | 22 | * @param ISystem $system |
23 | - * @return bool |
|
23 | + * @return string|boolean |
|
24 | 24 | */ |
25 | 25 | public static function available(ISystem $system) { |
26 | 26 | return $system->getSmbclientPath(); |
@@ -121,6 +121,10 @@ discard block |
||
121 | 121 | return $this->name; |
122 | 122 | } |
123 | 123 | |
124 | + /** |
|
125 | + * @param string $command |
|
126 | + * @param string $path |
|
127 | + */ |
|
124 | 128 | protected function simpleCommand($command, $path) { |
125 | 129 | $escapedPath = $this->escapePath($path); |
126 | 130 | $cmd = $command . ' ' . $escapedPath; |
@@ -131,7 +135,7 @@ discard block |
||
131 | 135 | /** |
132 | 136 | * List the content of a remote folder |
133 | 137 | * |
134 | - * @param $path |
|
138 | + * @param string $path |
|
135 | 139 | * @return \Icewind\SMB\IFileInfo[] |
136 | 140 | * |
137 | 141 | * @throws \Icewind\SMB\Exception\NotFoundException |
@@ -344,7 +348,7 @@ discard block |
||
344 | 348 | /** |
345 | 349 | * @param string $path |
346 | 350 | * @param int $mode a combination of FileInfo::MODE_READONLY, FileInfo::MODE_ARCHIVE, FileInfo::MODE_SYSTEM and FileInfo::MODE_HIDDEN, FileInfo::NORMAL |
347 | - * @return mixed |
|
351 | + * @return boolean |
|
348 | 352 | */ |
349 | 353 | public function setMode($path, $mode) { |
350 | 354 | $modeString = ''; |
@@ -388,7 +392,7 @@ discard block |
||
388 | 392 | |
389 | 393 | /** |
390 | 394 | * @param string $command |
391 | - * @return array |
|
395 | + * @return string[] |
|
392 | 396 | */ |
393 | 397 | protected function execute($command) { |
394 | 398 | $this->connect(); |
@@ -20,6 +20,9 @@ discard block |
||
20 | 20 | /** @var Parser */ |
21 | 21 | private $parser; |
22 | 22 | |
23 | + /** |
|
24 | + * @param string $command |
|
25 | + */ |
|
23 | 26 | public function __construct($command, Parser $parser, $env = []) { |
24 | 27 | parent::__construct($command, $env); |
25 | 28 | $this->parser = $parser; |
@@ -88,7 +91,7 @@ discard block |
||
88 | 91 | /** |
89 | 92 | * Check |
90 | 93 | * |
91 | - * @param $line |
|
94 | + * @param string|false $line |
|
92 | 95 | * @return bool |
93 | 96 | */ |
94 | 97 | private function isPrompt($line) { |
@@ -112,6 +112,9 @@ discard block |
||
112 | 112 | return new NativeFileInfo($this, $path, basename($path), $this->getStat($path)); |
113 | 113 | } |
114 | 114 | |
115 | + /** |
|
116 | + * @param string $path |
|
117 | + */ |
|
115 | 118 | private function getStat($path) { |
116 | 119 | return $this->getState()->stat($this->buildUrl($path)); |
117 | 120 | } |
@@ -276,7 +279,7 @@ discard block |
||
276 | 279 | * |
277 | 280 | * @param string $path |
278 | 281 | * @param string $attribute attribute to get the info |
279 | - * @param mixed $value |
|
282 | + * @param integer $value |
|
280 | 283 | * @return string the attribute value |
281 | 284 | */ |
282 | 285 | public function setAttribute($path, $attribute, $value) { |
@@ -290,7 +293,7 @@ discard block |
||
290 | 293 | /** |
291 | 294 | * @param string $path |
292 | 295 | * @param int $mode a combination of FileInfo::MODE_READONLY, FileInfo::MODE_ARCHIVE, FileInfo::MODE_SYSTEM and FileInfo::MODE_HIDDEN, FileInfo::NORMAL |
293 | - * @return mixed |
|
296 | + * @return string |
|
294 | 297 | */ |
295 | 298 | public function setMode($path, $mode) { |
296 | 299 | return $this->setAttribute($path, 'system.dos_attr.mode', $mode); |