@@ -95,7 +95,7 @@ |
||
95 | 95 | * @param string $key |
96 | 96 | * @param mixed $value |
97 | 97 | * @param int $ttl |
98 | - * @return bool|mixed |
|
98 | + * @return boolean |
|
99 | 99 | * @throws \OC\ForbiddenException |
100 | 100 | */ |
101 | 101 | public function set($key, $value, $ttl = 0) { |
@@ -132,7 +132,7 @@ |
||
132 | 132 | } |
133 | 133 | |
134 | 134 | /** |
135 | - * @param $message |
|
135 | + * @param string $message |
|
136 | 136 | * @param array $additional |
137 | 137 | * @return array |
138 | 138 | */ |
@@ -361,7 +361,7 @@ discard block |
||
361 | 361 | |
362 | 362 | /** |
363 | 363 | * returns the internal ownCloud name for the given LDAP DN of the user, false on DN outside of search DN or failure |
364 | - * @param string $dn the dn of the user object |
|
364 | + * @param string $fdn the dn of the user object |
|
365 | 365 | * @param string $ldapName optional, the display name of the object |
366 | 366 | * @return string|false with with the name to use in ownCloud |
367 | 367 | */ |
@@ -378,7 +378,7 @@ discard block |
||
378 | 378 | |
379 | 379 | /** |
380 | 380 | * returns an internal ownCloud name for the given LDAP DN, false on DN outside of search DN |
381 | - * @param string $dn the dn of the user object |
|
381 | + * @param string $fdn the dn of the user object |
|
382 | 382 | * @param string $ldapName optional, the display name of the object |
383 | 383 | * @param bool $isUser optional, whether it is a user object (otherwise group assumed) |
384 | 384 | * @return string|false with with the name to use in ownCloud |
@@ -638,7 +638,7 @@ discard block |
||
638 | 638 | * the login filter. |
639 | 639 | * |
640 | 640 | * @param string $loginName |
641 | - * @param array $attributes optional, list of attributes to read |
|
641 | + * @param string[] $attributes optional, list of attributes to read |
|
642 | 642 | * @return array |
643 | 643 | */ |
644 | 644 | public function fetchUsersByLoginName($loginName, $attributes = array('dn')) { |
@@ -711,7 +711,7 @@ discard block |
||
711 | 711 | |
712 | 712 | /** |
713 | 713 | * @param string $filter |
714 | - * @param string|string[] $attr |
|
714 | + * @param string[] $attr |
|
715 | 715 | * @param int $limit |
716 | 716 | * @param int $offset |
717 | 717 | * @return array |
@@ -759,7 +759,7 @@ discard block |
||
759 | 759 | |
760 | 760 | /** |
761 | 761 | * @param string $filter |
762 | - * @param string|string[] $attr |
|
762 | + * @param string[] $attr |
|
763 | 763 | * @param int $limit |
764 | 764 | * @param int $offset |
765 | 765 | * @return false|int |
@@ -809,6 +809,7 @@ discard block |
||
809 | 809 | * retrieved. Results will according to the order in the array. |
810 | 810 | * @param int $limit optional, maximum results to be counted |
811 | 811 | * @param int $offset optional, a starting point |
812 | + * @param string $filter |
|
812 | 813 | * @return array|false array with the search result as first value and pagedSearchOK as |
813 | 814 | * second | false if not successful |
814 | 815 | */ |
@@ -1063,7 +1064,7 @@ discard block |
||
1063 | 1064 | |
1064 | 1065 | /** |
1065 | 1066 | * @param string $name |
1066 | - * @return bool|mixed|string |
|
1067 | + * @return string |
|
1067 | 1068 | */ |
1068 | 1069 | public function sanitizeUsername($name) { |
1069 | 1070 | if($this->connection->ldapIgnoreNamingRules) { |
@@ -1087,6 +1088,7 @@ discard block |
||
1087 | 1088 | * escapes (user provided) parts for LDAP filter |
1088 | 1089 | * @param string $input, the provided value |
1089 | 1090 | * @param bool $allowAsterisk whether in * at the beginning should be preserved |
1091 | + * @param string $input |
|
1090 | 1092 | * @return string the escaped string |
1091 | 1093 | */ |
1092 | 1094 | public function escapeFilterPart($input, $allowAsterisk = false) { |
@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | /** |
53 | 53 | * get color for on-page elements: |
54 | 54 | * theme color by default, grey if theme color is to bright |
55 | - * @param $color |
|
55 | + * @param string $color |
|
56 | 56 | * @return string |
57 | 57 | */ |
58 | 58 | public function elementColor($color) { |
@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | } |
84 | 84 | |
85 | 85 | /** |
86 | - * @param $color |
|
86 | + * @param string $color |
|
87 | 87 | * @return string base64 encoded radio button svg |
88 | 88 | */ |
89 | 89 | public function generateRadioButton($color) { |
@@ -152,8 +152,8 @@ discard block |
||
152 | 152 | /** |
153 | 153 | * replace default color with a custom one |
154 | 154 | * |
155 | - * @param $svg string content of a svg file |
|
156 | - * @param $color string color to match |
|
155 | + * @param string $svg string content of a svg file |
|
156 | + * @param string $color string color to match |
|
157 | 157 | * @return string |
158 | 158 | */ |
159 | 159 | public function colorizeSvg($svg, $color) { |
@@ -101,7 +101,7 @@ discard block |
||
101 | 101 | /** |
102 | 102 | * Return the number of address books for a principal |
103 | 103 | * |
104 | - * @param $principalUri |
|
104 | + * @param string $principalUri |
|
105 | 105 | * @return int |
106 | 106 | */ |
107 | 107 | public function getAddressBooksForUserCount($principalUri) { |
@@ -234,7 +234,8 @@ discard block |
||
234 | 234 | } |
235 | 235 | |
236 | 236 | /** |
237 | - * @param $addressBookUri |
|
237 | + * @param string $addressBookUri |
|
238 | + * @param string $principal |
|
238 | 239 | * @return array|null |
239 | 240 | */ |
240 | 241 | public function getAddressBooksByUri($principal, $addressBookUri) { |
@@ -916,6 +917,7 @@ discard block |
||
916 | 917 | * * readOnly - boolean |
917 | 918 | * * summary - Optional, a description for the share |
918 | 919 | * |
920 | + * @param integer $addressBookId |
|
919 | 921 | * @return array |
920 | 922 | */ |
921 | 923 | public function getShares($addressBookId) { |
@@ -1015,7 +1017,7 @@ discard block |
||
1015 | 1017 | |
1016 | 1018 | /** |
1017 | 1019 | * For shared address books the sharee is set in the ACL of the address book |
1018 | - * @param $addressBookId |
|
1020 | + * @param integer $addressBookId |
|
1019 | 1021 | * @param $acl |
1020 | 1022 | * @return array |
1021 | 1023 | */ |
@@ -1023,6 +1025,9 @@ discard block |
||
1023 | 1025 | return $this->sharingBackend->applyShareAcl($addressBookId, $acl); |
1024 | 1026 | } |
1025 | 1027 | |
1028 | + /** |
|
1029 | + * @param boolean $toV2 |
|
1030 | + */ |
|
1026 | 1031 | private function convertPrincipal($principalUri, $toV2) { |
1027 | 1032 | if ($this->principalBackend->getPrincipalPrefix() === 'principals') { |
1028 | 1033 | list(, $name) = URLUtil::splitPath($principalUri); |
@@ -34,7 +34,7 @@ |
||
34 | 34 | private $webRoot; |
35 | 35 | |
36 | 36 | /** |
37 | - * @param $webRoot |
|
37 | + * @param string $webRoot |
|
38 | 38 | */ |
39 | 39 | public function __construct($webRoot) { |
40 | 40 | $this->webRoot = $webRoot; |
@@ -89,6 +89,9 @@ discard block |
||
89 | 89 | return $this->getMountsFromQuery($query); |
90 | 90 | } |
91 | 91 | |
92 | + /** |
|
93 | + * @param string $userId |
|
94 | + */ |
|
92 | 95 | public function getMountsForUser($userId, $groupIds) { |
93 | 96 | $builder = $this->connection->getQueryBuilder(); |
94 | 97 | $query = $builder->select(['m.mount_id', 'mount_point', 'storage_backend', 'auth_backend', 'priority', 'm.type']) |
@@ -125,6 +128,10 @@ discard block |
||
125 | 128 | return $this->getMountsFromQuery($query); |
126 | 129 | } |
127 | 130 | |
131 | + /** |
|
132 | + * @param integer $type |
|
133 | + * @param string|null $value |
|
134 | + */ |
|
128 | 135 | protected function getForQuery(IQueryBuilder $builder, $type, $value) { |
129 | 136 | $query = $builder->select(['m.mount_id', 'mount_point', 'storage_backend', 'auth_backend', 'priority', 'm.type']) |
130 | 137 | ->from('external_mounts', 'm') |
@@ -332,6 +339,9 @@ discard block |
||
332 | 339 | } |
333 | 340 | } |
334 | 341 | |
342 | + /** |
|
343 | + * @param integer $mountId |
|
344 | + */ |
|
335 | 345 | public function addApplicable($mountId, $type, $value) { |
336 | 346 | $this->connection->insertIfNotExist('*PREFIX*external_applicable', [ |
337 | 347 | 'mount_id' => $mountId, |
@@ -340,6 +350,9 @@ discard block |
||
340 | 350 | ], ['mount_id', 'type', 'value']); |
341 | 351 | } |
342 | 352 | |
353 | + /** |
|
354 | + * @param integer $mountId |
|
355 | + */ |
|
343 | 356 | public function removeApplicable($mountId, $type, $value) { |
344 | 357 | $builder = $this->connection->getQueryBuilder(); |
345 | 358 | $query = $builder->delete('external_applicable') |
@@ -473,6 +486,9 @@ discard block |
||
473 | 486 | return array_combine($keys, $values); |
474 | 487 | } |
475 | 488 | |
489 | + /** |
|
490 | + * @param string $value |
|
491 | + */ |
|
476 | 492 | private function encryptValue($value) { |
477 | 493 | return $this->crypto->encrypt($value); |
478 | 494 | } |
@@ -24,7 +24,7 @@ |
||
24 | 24 | /** |
25 | 25 | * BaseResponse constructor. |
26 | 26 | * |
27 | - * @param DataResponse|null $dataResponse |
|
27 | + * @param DataResponse $dataResponse |
|
28 | 28 | * @param string $format |
29 | 29 | * @param string|null $statusMessage |
30 | 30 | * @param int|null $itemsCount |
@@ -129,7 +129,7 @@ discard block |
||
129 | 129 | /** |
130 | 130 | * returns the registerd classes in the given table |
131 | 131 | * |
132 | - * @param $table |
|
132 | + * @param string $table |
|
133 | 133 | * @return string[] |
134 | 134 | */ |
135 | 135 | private function getClasses($table) { |
@@ -225,6 +225,11 @@ discard block |
||
225 | 225 | ); |
226 | 226 | } |
227 | 227 | |
228 | + /** |
|
229 | + * @param string $table |
|
230 | + * @param string $idCol |
|
231 | + * @param string $id |
|
232 | + */ |
|
228 | 233 | private function update($table, $idCol, $id, $values) { |
229 | 234 | $query = $this->dbc->getQueryBuilder(); |
230 | 235 | $query->update($table); |
@@ -275,8 +280,8 @@ discard block |
||
275 | 280 | /** |
276 | 281 | * deletes an settings or admin entry from the given table |
277 | 282 | * |
278 | - * @param $table |
|
279 | - * @param $className |
|
283 | + * @param string $table |
|
284 | + * @param string $className |
|
280 | 285 | */ |
281 | 286 | private function remove($table, $className) { |
282 | 287 | $query = $this->dbc->getQueryBuilder(); |
@@ -362,6 +367,9 @@ discard block |
||
362 | 367 | return $sections; |
363 | 368 | } |
364 | 369 | |
370 | + /** |
|
371 | + * @param string $section |
|
372 | + */ |
|
365 | 373 | private function getBuiltInAdminSettings($section) { |
366 | 374 | $forms = []; |
367 | 375 | try { |
@@ -401,6 +409,9 @@ discard block |
||
401 | 409 | return $forms; |
402 | 410 | } |
403 | 411 | |
412 | + /** |
|
413 | + * @param string $section |
|
414 | + */ |
|
404 | 415 | private function getAdminSettingsFromDB($section, &$settings) { |
405 | 416 | $query = $this->dbc->getQueryBuilder(); |
406 | 417 | $query->select(['class', 'priority']) |