@@ -86,7 +86,7 @@ discard block |
||
| 86 | 86 | /** |
| 87 | 87 | * @param string $file |
| 88 | 88 | * @param int $compress |
| 89 | - * @param null $convert_file_to |
|
| 89 | + * @param string $convert_file_to |
|
| 90 | 90 | * @return bool |
| 91 | 91 | */ |
| 92 | 92 | public function send_image( |
@@ -181,7 +181,7 @@ discard block |
||
| 181 | 181 | |
| 182 | 182 | /** |
| 183 | 183 | * ImagickWrapper constructor. |
| 184 | - * @param $path |
|
| 184 | + * @param string $path |
|
| 185 | 185 | */ |
| 186 | 186 | public function __construct($path) |
| 187 | 187 | { |
@@ -232,6 +232,10 @@ discard block |
||
| 232 | 232 | } |
| 233 | 233 | |
| 234 | 234 | //@todo implement border logic case for Imagick |
| 235 | + |
|
| 236 | + /** |
|
| 237 | + * @param integer $border |
|
| 238 | + */ |
|
| 235 | 239 | public function resize($thumbw, $thumbh, $border, $specific_size = false) |
| 236 | 240 | { |
| 237 | 241 | if (!$this->image_validated) return false; |
@@ -329,7 +333,7 @@ discard block |
||
| 329 | 333 | |
| 330 | 334 | /** |
| 331 | 335 | * GDWrapper constructor. |
| 332 | - * @param $path |
|
| 336 | + * @param string $path |
|
| 333 | 337 | */ |
| 334 | 338 | public function __construct($path) |
| 335 | 339 | { |
@@ -392,6 +396,9 @@ discard block |
||
| 392 | 396 | } |
| 393 | 397 | } |
| 394 | 398 | |
| 399 | + /** |
|
| 400 | + * @param integer $border |
|
| 401 | + */ |
|
| 395 | 402 | public function resize($thumbw, $thumbh, $border, $specific_size = false) |
| 396 | 403 | { |
| 397 | 404 | if (!$this->image_validated) { |
@@ -66,6 +66,7 @@ discard block |
||
| 66 | 66 | * @param int user id |
| 67 | 67 | * @param int user friend id |
| 68 | 68 | * @param string |
| 69 | + * @param integer $user_friend |
|
| 69 | 70 | * @return int |
| 70 | 71 | * @author isaac flores paz |
| 71 | 72 | */ |
@@ -129,6 +130,8 @@ discard block |
||
| 129 | 130 | * @param int group id |
| 130 | 131 | * @param string name to search |
| 131 | 132 | * @param bool true will load firstname, lastname, and image name |
| 133 | + * @param integer $user_id |
|
| 134 | + * @param integer $id_group |
|
| 132 | 135 | * @return array |
| 133 | 136 | * @author Julio Montoya <[email protected]> Cleaning code, function renamed, $load_extra_info option added |
| 134 | 137 | * @author isaac flores paz |
@@ -210,6 +213,9 @@ discard block |
||
| 210 | 213 | * @param int user friend id |
| 211 | 214 | * @param string title of the message |
| 212 | 215 | * @param string content of the message |
| 216 | + * @param integer $user_id |
|
| 217 | + * @param string $message_title |
|
| 218 | + * @param string $message_content |
|
| 213 | 219 | * @return boolean |
| 214 | 220 | * @author isaac flores paz |
| 215 | 221 | * @author Julio Montoya <[email protected]> Cleaning code |
@@ -287,6 +293,7 @@ discard block |
||
| 287 | 293 | * Get number messages of the inbox |
| 288 | 294 | * @author isaac flores paz |
| 289 | 295 | * @param int user receiver id |
| 296 | + * @param integer $user_receiver_id |
|
| 290 | 297 | * @return int |
| 291 | 298 | */ |
| 292 | 299 | public static function get_message_number_invitation_by_user_id($user_receiver_id) |
@@ -477,6 +484,7 @@ discard block |
||
| 477 | 484 | * Denies invitation |
| 478 | 485 | * @param int user sender id |
| 479 | 486 | * @param int user receiver id |
| 487 | + * @param integer $user_receiver_id |
|
| 480 | 488 | * @return bool |
| 481 | 489 | * |
| 482 | 490 | * @author isaac flores paz |
@@ -579,7 +587,7 @@ discard block |
||
| 579 | 587 | * @param string $subject |
| 580 | 588 | * @param string $content |
| 581 | 589 | * |
| 582 | - * @return string message invitation |
|
| 590 | + * @return false|null message invitation |
|
| 583 | 591 | */ |
| 584 | 592 | public static function sendInvitationToUser($userId, $subject = '', $content = '') |
| 585 | 593 | { |
@@ -1379,7 +1387,7 @@ discard block |
||
| 1379 | 1387 | * @param string $messageContent of the message |
| 1380 | 1388 | * @param int $messageId id parent |
| 1381 | 1389 | * @param string $messageStatus status type of message |
| 1382 | - * @return boolean |
|
| 1390 | + * @return false|string |
|
| 1383 | 1391 | * @author Yannick Warnier |
| 1384 | 1392 | */ |
| 1385 | 1393 | public static function sendWallMessage( |
@@ -1480,7 +1488,7 @@ discard block |
||
| 1480 | 1488 | * Gets all messages from someone's wall (within specific limits) |
| 1481 | 1489 | * @param int $userId id of wall shown |
| 1482 | 1490 | * @param string $messageStatus status wall message |
| 1483 | - * @param int|string $parentId id message (Post main) |
|
| 1491 | + * @param integer|null $parentId id message (Post main) |
|
| 1484 | 1492 | * @param string $start Date from which we want to show the messages, in UTC time |
| 1485 | 1493 | * @param int $limit Limit for the number of parent messages we want to show |
| 1486 | 1494 | * @param int $offset Wall message query offset |
@@ -1796,7 +1804,7 @@ discard block |
||
| 1796 | 1804 | |
| 1797 | 1805 | /** |
| 1798 | 1806 | * verify if Url Exist - Using Curl |
| 1799 | - * @param $uri url |
|
| 1807 | + * @param string $uri url |
|
| 1800 | 1808 | * |
| 1801 | 1809 | * @return boolean |
| 1802 | 1810 | */ |
@@ -1822,7 +1830,7 @@ discard block |
||
| 1822 | 1830 | /** |
| 1823 | 1831 | * Delete messages delete logic |
| 1824 | 1832 | * @param int $id id message to delete. |
| 1825 | - * @return bool status query |
|
| 1833 | + * @return Statement status query |
|
| 1826 | 1834 | */ |
| 1827 | 1835 | public static function deleteMessage($id) |
| 1828 | 1836 | { |
@@ -224,7 +224,7 @@ discard block |
||
| 224 | 224 | /** |
| 225 | 225 | * Import the aicc object (as a result from the parse_config_files function) into the database structure |
| 226 | 226 | * @param string $course_code |
| 227 | - * @return bool Returns -1 on error |
|
| 227 | + * @return false|null Returns -1 on error |
|
| 228 | 228 | */ |
| 229 | 229 | public function import_aicc($course_code) |
| 230 | 230 | { |
@@ -641,7 +641,7 @@ discard block |
||
| 641 | 641 | /** |
| 642 | 642 | * Sets the Author LP in the database |
| 643 | 643 | * @param string $author |
| 644 | - * @return true |
|
| 644 | + * @return boolean |
|
| 645 | 645 | */ |
| 646 | 646 | public function set_author($author = '') |
| 647 | 647 | { |
@@ -811,7 +811,8 @@ discard block |
||
| 811 | 811 | * Static function to parse AICC ini files. |
| 812 | 812 | * Based on work by sinedeo at gmail dot com published on php.net (parse_ini_file()). |
| 813 | 813 | * @param string File path |
| 814 | - * @return array Structured array |
|
| 814 | + * @param string $f |
|
| 815 | + * @return string Structured array |
|
| 815 | 816 | */ |
| 816 | 817 | public function parse_ini_file_quotes_safe($f) |
| 817 | 818 | { |
@@ -864,7 +865,7 @@ discard block |
||
| 864 | 865 | * @param string INI File string |
| 865 | 866 | * @param array List of names of sections that should be considered |
| 866 | 867 | * as containing only hard string data (no variables), provided in lower case |
| 867 | - * @return array Structured array |
|
| 868 | + * @return string Structured array |
|
| 868 | 869 | */ |
| 869 | 870 | public function parse_ini_string_quotes_safe($s, $pure_strings = array()) |
| 870 | 871 | { |
@@ -928,6 +929,7 @@ discard block |
||
| 928 | 929 | * @param string CSV delimiter |
| 929 | 930 | * @param string CSV enclosure |
| 930 | 931 | * @param boolean Might one field name happen more than once on the same line? (then split by comma in the values) |
| 932 | + * @param string $f |
|
| 931 | 933 | * @return array Simple structured array |
| 932 | 934 | */ |
| 933 | 935 | public function parse_csv_file($f, $delim = ',', $enclosure = '"', $multiples = false) |
@@ -408,7 +408,7 @@ discard block |
||
| 408 | 408 | * Read and validate the quiz module XML |
| 409 | 409 | * |
| 410 | 410 | * @param resource $moduleXml XML file |
| 411 | - * @return mixed | array if is a valid xml file, false otherwise |
|
| 411 | + * @return string | array if is a valid xml file, false otherwise |
|
| 412 | 412 | */ |
| 413 | 413 | public function readQuizModule($moduleXml) |
| 414 | 414 | { |
@@ -626,7 +626,7 @@ discard block |
||
| 626 | 626 | * Fix moodle files that contains spaces |
| 627 | 627 | * @param array $importedFiles |
| 628 | 628 | * @param string $text |
| 629 | - * @return mixed |
|
| 629 | + * @return string |
|
| 630 | 630 | */ |
| 631 | 631 | public function fixPathInText($importedFiles, &$text) |
| 632 | 632 | { |
@@ -648,10 +648,10 @@ discard block |
||
| 648 | 648 | * |
| 649 | 649 | * @param array $questionList |
| 650 | 650 | * @param string $questionType |
| 651 | - * @param object $questionInstance Question/Answer instance |
|
| 651 | + * @param Question $questionInstance Question/Answer instance |
|
| 652 | 652 | * @param array $currentQuestion |
| 653 | 653 | * @param array $importedFiles |
| 654 | - * @return integer db response |
|
| 654 | + * @return boolean|null db response |
|
| 655 | 655 | */ |
| 656 | 656 | public function processAnswers( |
| 657 | 657 | $questionList, |
@@ -809,7 +809,7 @@ discard block |
||
| 809 | 809 | /** |
| 810 | 810 | * Process Chamilo Unique Answer |
| 811 | 811 | * |
| 812 | - * @param object $objAnswer |
|
| 812 | + * @param Answer $objAnswer |
|
| 813 | 813 | * @param array $answerValues |
| 814 | 814 | * @param integer $position |
| 815 | 815 | * @param integer $questionWeighting |
@@ -850,7 +850,7 @@ discard block |
||
| 850 | 850 | /** |
| 851 | 851 | * Process Chamilo True False |
| 852 | 852 | * |
| 853 | - * @param object $objAnswer |
|
| 853 | + * @param Answer $objAnswer |
|
| 854 | 854 | * @param array $answerValues |
| 855 | 855 | * @param integer $position |
| 856 | 856 | * @param integer $questionWeighting |
@@ -892,7 +892,7 @@ discard block |
||
| 892 | 892 | /** |
| 893 | 893 | * Process Chamilo FillBlanks |
| 894 | 894 | * |
| 895 | - * @param object $objAnswer |
|
| 895 | + * @param Answer $objAnswer |
|
| 896 | 896 | * @param array $questionType |
| 897 | 897 | * @param array $answerValues |
| 898 | 898 | * @param string $placeholder |
@@ -1051,7 +1051,7 @@ discard block |
||
| 1051 | 1051 | * Litle utility to delete the unuseful tags |
| 1052 | 1052 | * |
| 1053 | 1053 | * @param $array |
| 1054 | - * @param $keys |
|
| 1054 | + * @param string[] $keys |
|
| 1055 | 1055 | */ |
| 1056 | 1056 | public function traverseArray(&$array, $keys) |
| 1057 | 1057 | { |
@@ -18,7 +18,7 @@ discard block |
||
| 18 | 18 | * |
| 19 | 19 | * @param string Course id field name |
| 20 | 20 | * @param string Course id value |
| 21 | - * @return mixed True if the course was successfully deleted, WSError otherwise |
|
| 21 | + * @return WSError True if the course was successfully deleted, WSError otherwise |
|
| 22 | 22 | */ |
| 23 | 23 | protected function deleteCourseHelper( |
| 24 | 24 | $course_id_field_name, |
@@ -110,7 +110,7 @@ discard block |
||
| 110 | 110 | * @param string Course id field name |
| 111 | 111 | * @param string Course id value |
| 112 | 112 | * @param array Course extra fields |
| 113 | - * @return mixed Generated id if creation was successful, WSError otherwise |
|
| 113 | + * @return WSError Generated id if creation was successful, WSError otherwise |
|
| 114 | 114 | */ |
| 115 | 115 | protected function createCourseHelper( |
| 116 | 116 | $title, |
@@ -278,7 +278,7 @@ discard block |
||
| 278 | 278 | * @param int Unsubscribe (0 = denied, 1 = allowed) |
| 279 | 279 | * @param string Visual code |
| 280 | 280 | * @param array Course extra fields |
| 281 | - * @return mixed True in case of success, WSError otherwise |
|
| 281 | + * @return WSError True in case of success, WSError otherwise |
|
| 282 | 282 | */ |
| 283 | 283 | protected function editCourseHelper( |
| 284 | 284 | $course_id_field_name, |
@@ -456,7 +456,8 @@ discard block |
||
| 456 | 456 | * @param string User id value |
| 457 | 457 | * @param int Set to 1 to subscribe, 0 to unsubscribe |
| 458 | 458 | * @param int Status (STUDENT or TEACHER) Used for subscription only |
| 459 | - * @return mixed True if subscription or unsubscription was successful, false otherwise |
|
| 459 | + * @param integer $state |
|
| 460 | + * @return WSError True if subscription or unsubscription was successful, false otherwise |
|
| 460 | 461 | */ |
| 461 | 462 | protected function changeUserSubscription( |
| 462 | 463 | $course_id_field_name, |
@@ -205,6 +205,9 @@ |
||
| 205 | 205 | } |
| 206 | 206 | } |
| 207 | 207 | |
| 208 | + /** |
|
| 209 | + * @param integer $user_id |
|
| 210 | + */ |
|
| 208 | 211 | protected function set_message_as_read($user_id, $message_id) |
| 209 | 212 | { |
| 210 | 213 | $table_message = Database::get_main_table(TABLE_MESSAGE); |
@@ -20,7 +20,7 @@ discard block |
||
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | /** |
| 23 | - * @return array |
|
| 23 | + * @return string[] |
|
| 24 | 24 | */ |
| 25 | 25 | public static function getTags() |
| 26 | 26 | { |
@@ -266,7 +266,7 @@ discard block |
||
| 266 | 266 | * @param int $courseId |
| 267 | 267 | * @param int $userId |
| 268 | 268 | * |
| 269 | - * @return array |
|
| 269 | + * @return integer |
|
| 270 | 270 | */ |
| 271 | 271 | public static function getAnnouncementInfoById( |
| 272 | 272 | $announcementId, |
@@ -492,7 +492,7 @@ discard block |
||
| 492 | 492 | * @param bool $sendToUsersInSession |
| 493 | 493 | * @param int $authorId |
| 494 | 494 | * |
| 495 | - * @return int false on failure, ID of the announcement on success |
|
| 495 | + * @return false|string false on failure, ID of the announcement on success |
|
| 496 | 496 | */ |
| 497 | 497 | public static function add_announcement( |
| 498 | 498 | $courseInfo, |
@@ -628,7 +628,7 @@ discard block |
||
| 628 | 628 | * @param string $file_comment |
| 629 | 629 | * @param bool $sendToUsersInSession |
| 630 | 630 | * |
| 631 | - * @return bool|int |
|
| 631 | + * @return false|string |
|
| 632 | 632 | */ |
| 633 | 633 | public static function add_group_announcement( |
| 634 | 634 | $title, |
@@ -886,7 +886,7 @@ discard block |
||
| 886 | 886 | |
| 887 | 887 | /** |
| 888 | 888 | * @param int $insert_id |
| 889 | - * @return bool |
|
| 889 | + * @return false|null |
|
| 890 | 890 | */ |
| 891 | 891 | public static function update_mail_sent($insert_id) |
| 892 | 892 | { |
@@ -906,6 +906,7 @@ discard block |
||
| 906 | 906 | * Gets all announcements from a user by course |
| 907 | 907 | * @param string course db |
| 908 | 908 | * @param int user id |
| 909 | + * @param integer $user_id |
|
| 909 | 910 | * @return array html with the content and count of announcements or false otherwise |
| 910 | 911 | */ |
| 911 | 912 | public static function get_all_annoucement_by_user_course($course_code, $user_id) |
@@ -1135,6 +1136,7 @@ discard block |
||
| 1135 | 1136 | * has been sent to |
| 1136 | 1137 | * @param string The tool (announcement, agenda, ...) |
| 1137 | 1138 | * @param int ID of the element of the corresponding type |
| 1139 | + * @param string $tool |
|
| 1138 | 1140 | * @return array Array of users and groups to whom the element has been sent |
| 1139 | 1141 | */ |
| 1140 | 1142 | public static function sent_to($tool, $id) |
@@ -1206,6 +1208,7 @@ discard block |
||
| 1206 | 1208 | * @param int announcement id |
| 1207 | 1209 | * @param string file comment |
| 1208 | 1210 | * @param array uploaded file $_FILES |
| 1211 | + * @param string|null $file_comment |
|
| 1209 | 1212 | * @return int -1 if failed, 0 if unknown (should not happen), 1 if success |
| 1210 | 1213 | */ |
| 1211 | 1214 | public static function add_announcement_attachment_file( |
@@ -1268,6 +1271,8 @@ discard block |
||
| 1268 | 1271 | * @param int attach id |
| 1269 | 1272 | * @param array uploaded file $_FILES |
| 1270 | 1273 | * @param string file comment |
| 1274 | + * @param integer $id_attach |
|
| 1275 | + * @param string $file_comment |
|
| 1271 | 1276 | * @return int |
| 1272 | 1277 | */ |
| 1273 | 1278 | public static function edit_announcement_attachment_file( |
@@ -327,7 +327,7 @@ discard block |
||
| 327 | 327 | * @param string $full_text The full text of the new post |
| 328 | 328 | * @param string $file_comment The text of the comment (if any) |
| 329 | 329 | * @param int $blog_id The internal blog ID |
| 330 | - * @return void |
|
| 330 | + * @return string|null |
|
| 331 | 331 | */ |
| 332 | 332 | public static function createPost($title, $full_text, $file_comment, $blog_id) |
| 333 | 333 | { |
@@ -1156,7 +1156,7 @@ discard block |
||
| 1156 | 1156 | * @param int $blog_id |
| 1157 | 1157 | * @param int $post_id |
| 1158 | 1158 | * @param int $task_id |
| 1159 | - * @return array |
|
| 1159 | + * @return integer |
|
| 1160 | 1160 | */ |
| 1161 | 1161 | public static function getThreadedComments( |
| 1162 | 1162 | $current = 0, |
@@ -1277,7 +1277,7 @@ discard block |
||
| 1277 | 1277 | * @param int $blog_id |
| 1278 | 1278 | * @param int $post_id |
| 1279 | 1279 | * @param int $comment_id |
| 1280 | - * @return void |
|
| 1280 | + * @return string|null |
|
| 1281 | 1281 | */ |
| 1282 | 1282 | public static function displayRatingCreateForm($type, $blog_id, $post_id, $comment_id = null) |
| 1283 | 1283 | { |
@@ -1346,7 +1346,7 @@ discard block |
||
| 1346 | 1346 | * @param string $type |
| 1347 | 1347 | * @param integer $blog_id |
| 1348 | 1348 | * @param integer $item_id |
| 1349 | - * @return array |
|
| 1349 | + * @return double |
|
| 1350 | 1350 | */ |
| 1351 | 1351 | public static function displayRating($type, $blog_id, $item_id) |
| 1352 | 1352 | { |
@@ -2463,7 +2463,7 @@ discard block |
||
| 2463 | 2463 | * The listed users are users subcribed in the course. |
| 2464 | 2464 | * @author Toon Keppens |
| 2465 | 2465 | * @param int $blog_id |
| 2466 | - * @return false|null Form with sortable table with users to unsubcribe from a blog. |
|
| 2466 | + * @return false|string Form with sortable table with users to unsubcribe from a blog. |
|
| 2467 | 2467 | */ |
| 2468 | 2468 | public static function displayUserUnsubscriptionForm($blog_id) |
| 2469 | 2469 | { |
@@ -2924,7 +2924,7 @@ discard block |
||
| 2924 | 2924 | * @param int $blog_id the blog's id |
| 2925 | 2925 | * @param int $post_id the post's id |
| 2926 | 2926 | * @param int $comment_id the comment's id |
| 2927 | - * @return array with the post info according the parameters |
|
| 2927 | + * @return integer with the post info according the parameters |
|
| 2928 | 2928 | * @author Julio Montoya |
| 2929 | 2929 | * @version avril 2008, dokeos 1.8.5 |
| 2930 | 2930 | */ |
@@ -191,6 +191,7 @@ discard block |
||
| 191 | 191 | * Build the prefilter form. |
| 192 | 192 | * |
| 193 | 193 | * This type allow filter all other multiple select terms by one term in a dinamic way |
| 194 | + * @param string $prefilter_prefix |
|
| 194 | 195 | */ |
| 195 | 196 | function search_widget_prefilter_form( |
| 196 | 197 | $action, |
@@ -285,6 +286,8 @@ discard block |
||
| 285 | 286 | |
| 286 | 287 | /** |
| 287 | 288 | * Show search form |
| 289 | + * @param string $action |
|
| 290 | + * @param boolean $show_thesaurus |
|
| 288 | 291 | */ |
| 289 | 292 | function display_search_form($action, $show_thesaurus, $sf_terms, $op) |
| 290 | 293 | { |