@@ -25,6 +25,7 @@ |
||
25 | 25 | |
26 | 26 | /** |
27 | 27 | * Useful finder - experimental akelos like only use in notification.lib.php send function |
28 | + * @param string $type |
|
28 | 29 | */ |
29 | 30 | public function find($type, $options = null) |
30 | 31 | { |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | |
37 | 37 | /** |
38 | 38 | * |
39 | - * @return StaticPlugin |
|
39 | + * @return BuyCoursesPlugin |
|
40 | 40 | */ |
41 | 41 | static function create() |
42 | 42 | { |
@@ -252,7 +252,7 @@ discard block |
||
252 | 252 | /** |
253 | 253 | * Save a transfer account information |
254 | 254 | * @param array $params The transfer account |
255 | - * @return int Rows affected. Otherwise return false |
|
255 | + * @return false|string Rows affected. Otherwise return false |
|
256 | 256 | */ |
257 | 257 | public function saveTransferAccount($params) |
258 | 258 | { |
@@ -664,7 +664,7 @@ discard block |
||
664 | 664 | /** |
665 | 665 | * Get session info |
666 | 666 | * @param array $sessionId The session ID |
667 | - * @return array |
|
667 | + * @return Session |
|
668 | 668 | */ |
669 | 669 | public function getSessionInfo($sessionId) |
670 | 670 | { |
@@ -757,7 +757,7 @@ discard block |
||
757 | 757 | * Register a sale |
758 | 758 | * @param int $itemId The product ID |
759 | 759 | * @param int $paymentType The payment type |
760 | - * @return boolean |
|
760 | + * @return false|string |
|
761 | 761 | */ |
762 | 762 | public function registerSale($itemId, $paymentType) |
763 | 763 | { |
@@ -939,7 +939,7 @@ discard block |
||
939 | 939 | |
940 | 940 | /** |
941 | 941 | * Get payment types |
942 | - * @return array |
|
942 | + * @return string[] |
|
943 | 943 | */ |
944 | 944 | public function getPaymentTypes() |
945 | 945 | { |
@@ -977,7 +977,7 @@ discard block |
||
977 | 977 | |
978 | 978 | /** |
979 | 979 | * Get the statuses for sales |
980 | - * @return array |
|
980 | + * @return string[] |
|
981 | 981 | */ |
982 | 982 | public function getSaleStatuses() |
983 | 983 | { |
@@ -990,7 +990,7 @@ discard block |
||
990 | 990 | |
991 | 991 | /** |
992 | 992 | * Get the statuses for Payouts |
993 | - * @return array |
|
993 | + * @return string[] |
|
994 | 994 | */ |
995 | 995 | public function getPayoutStatuses() |
996 | 996 | { |
@@ -1003,7 +1003,7 @@ discard block |
||
1003 | 1003 | |
1004 | 1004 | /** |
1005 | 1005 | * Get the list of product types |
1006 | - * @return array |
|
1006 | + * @return string[] |
|
1007 | 1007 | */ |
1008 | 1008 | public function getProductTypes() |
1009 | 1009 | { |
@@ -1384,7 +1384,7 @@ discard block |
||
1384 | 1384 | /** |
1385 | 1385 | * Register a item |
1386 | 1386 | * @param array $itemData The item data |
1387 | - * @return int The item ID. Otherwise return false |
|
1387 | + * @return false|string The item ID. Otherwise return false |
|
1388 | 1388 | */ |
1389 | 1389 | public function registerItem(array $itemData) |
1390 | 1390 | { |
@@ -1542,7 +1542,7 @@ discard block |
||
1542 | 1542 | /** |
1543 | 1543 | * Verify if the beneficiary have a paypal account |
1544 | 1544 | * @param int $userId |
1545 | - * @return true if the user have a paypal account, false if not |
|
1545 | + * @return boolean if the user have a paypal account, false if not |
|
1546 | 1546 | */ |
1547 | 1547 | public function verifyPaypalAccountByBeneficiary($userId) |
1548 | 1548 | { |
@@ -242,6 +242,9 @@ discard block |
||
242 | 242 | return $hmac; |
243 | 243 | } |
244 | 244 | |
245 | +/** |
|
246 | + * @param string|false $text |
|
247 | + */ |
|
245 | 248 | function _openid_sha1($text) { |
246 | 249 | $hex = sha1($text); |
247 | 250 | $raw = ''; |
@@ -404,6 +407,10 @@ discard block |
||
404 | 407 | */ |
405 | 408 | if (!function_exists('bcpowmod')) { |
406 | 409 | |
410 | + /** |
|
411 | + * @param string $exp |
|
412 | + * @param string $mod |
|
413 | + */ |
|
407 | 414 | function bcpowmod($base, $exp, $mod) { |
408 | 415 | $square = bcmod($base, $mod); |
409 | 416 | $result = 1; |
@@ -230,7 +230,7 @@ |
||
230 | 230 | /** |
231 | 231 | * Get id |
232 | 232 | * |
233 | - * @return boolean |
|
233 | + * @return integer |
|
234 | 234 | */ |
235 | 235 | public function getId() |
236 | 236 | { |
@@ -91,7 +91,7 @@ |
||
91 | 91 | } |
92 | 92 | |
93 | 93 | /** |
94 | - * @param array $array |
|
94 | + * @param string[] $array |
|
95 | 95 | */ |
96 | 96 | public function set_tools_to_build($array) |
97 | 97 | { |
@@ -3054,7 +3054,7 @@ |
||
3054 | 3054 | * @param integer $thread_qualify |
3055 | 3055 | * @param integer $qualify_time |
3056 | 3056 | * @param integer $session_id |
3057 | - * @return array optional |
|
3057 | + * @return string|null optional |
|
3058 | 3058 | * @author Isaac Flores <[email protected]>, U.N.A.S University |
3059 | 3059 | * @version October 2008, dokeos 1.8.6 |
3060 | 3060 | */ |
@@ -1244,6 +1244,7 @@ discard block |
||
1244 | 1244 | * Gets the list of courses a specific user is subscribed to |
1245 | 1245 | * @param int User ID |
1246 | 1246 | * @param boolean $fetch_session Whether to get session courses or not - NOT YET IMPLEMENTED |
1247 | + * @param integer $userid |
|
1247 | 1248 | * @return array Array of courses in the form [0]=>('code'=>xxx,'db'=>xxx,'dir'=>xxx,'status'=>d) |
1248 | 1249 | */ |
1249 | 1250 | function api_get_user_courses($userid, $fetch_session = true) |
@@ -3036,7 +3037,7 @@ discard block |
||
3036 | 3037 | * on the session visibility |
3037 | 3038 | * @param bool $tutor Whether to check if the user has the tutor role |
3038 | 3039 | * @param bool $coach Whether to check if the user has the coach role |
3039 | -* @return boolean true: the user has the rights to edit, false: he does not |
|
3040 | +* @return boolean|null true: the user has the rights to edit, false: he does not |
|
3040 | 3041 | */ |
3041 | 3042 | function api_is_allowed_to_session_edit($tutor = false, $coach = false) |
3042 | 3043 | { |
@@ -6656,7 +6657,7 @@ discard block |
||
6656 | 6657 | /** |
6657 | 6658 | * Returns an array of global configuration settings which should be ignored |
6658 | 6659 | * when printing the configuration settings screens |
6659 | - * @return array Array of strings, each identifying one of the excluded settings |
|
6660 | + * @return string[] Array of strings, each identifying one of the excluded settings |
|
6660 | 6661 | */ |
6661 | 6662 | function api_get_locked_settings() { |
6662 | 6663 | return array( |
@@ -6699,6 +6700,7 @@ discard block |
||
6699 | 6700 | * false if he isn't. If the user ID is given and is an integer, then the same |
6700 | 6701 | * ID is simply returned |
6701 | 6702 | * @param integer User ID |
6703 | + * @param integer $user_id |
|
6702 | 6704 | * @return boolean Integer User ID is logged in, or false otherwise |
6703 | 6705 | */ |
6704 | 6706 | function api_user_is_login($user_id = null) { |
@@ -7143,6 +7145,7 @@ discard block |
||
7143 | 7145 | /** |
7144 | 7146 | * Gets memory limit in bytes |
7145 | 7147 | * @param string The memory size (128M, 1G, 1000K, etc) |
7148 | + * @param string $mem |
|
7146 | 7149 | * @return int |
7147 | 7150 | * @assert (null) === false |
7148 | 7151 | * @assert ('1t') === 1099511627776 |
@@ -51,7 +51,7 @@ |
||
51 | 51 | * @param string $objetives |
52 | 52 | * @param string $target_audience |
53 | 53 | * @param int $user_id |
54 | - * @return mixed The database id of the newly created course request or FALSE on failure. |
|
54 | + * @return false|string The database id of the newly created course request or FALSE on failure. |
|
55 | 55 | */ |
56 | 56 | public static function create_course_request( |
57 | 57 | $wanted_code, |
@@ -1333,6 +1333,8 @@ discard block |
||
1333 | 1333 | * @param string type of time filter: 'last_week' or 'custom' |
1334 | 1334 | * @param string start date date('Y-m-d H:i:s') |
1335 | 1335 | * @param string end date date('Y-m-d H:i:s') |
1336 | + * @param string $start_date |
|
1337 | + * @param string $end_date |
|
1336 | 1338 | * @return timestamp $nb_seconds |
1337 | 1339 | */ |
1338 | 1340 | public static function get_time_spent_on_the_platform( |
@@ -1435,7 +1437,7 @@ discard block |
||
1435 | 1437 | * Get first connection date for a student |
1436 | 1438 | * @param int $student_id |
1437 | 1439 | * |
1438 | - * @return string|bool Date format long without day or false if there are no connections |
|
1440 | + * @return string|false Date format long without day or false if there are no connections |
|
1439 | 1441 | */ |
1440 | 1442 | public static function get_first_connection_date($student_id) |
1441 | 1443 | { |
@@ -1465,7 +1467,7 @@ discard block |
||
1465 | 1467 | * @param int $student_id |
1466 | 1468 | * @param bool $warning_message Show a warning message (optional) |
1467 | 1469 | * @param bool $return_timestamp True for returning results in timestamp (optional) |
1468 | - * @return string|int|bool Date format long without day, false if there are no connections or |
|
1470 | + * @return string Date format long without day, false if there are no connections or |
|
1469 | 1471 | * timestamp if parameter $return_timestamp is true |
1470 | 1472 | */ |
1471 | 1473 | public static function get_last_connection_date($student_id, $warning_message = false, $return_timestamp = false) |
@@ -2762,6 +2764,9 @@ discard block |
||
2762 | 2764 | * @param array Limit average to listed lp ids |
2763 | 2765 | * @param int Session id (optional), if param $session_id is |
2764 | 2766 | * null(default) it'll return results including sessions, 0 = session is not filtered |
2767 | + * @param integer $student_id |
|
2768 | + * @param string $course_code |
|
2769 | + * @param integer $session_id |
|
2765 | 2770 | * @return int Total time |
2766 | 2771 | */ |
2767 | 2772 | public static function get_time_spent_in_lp($student_id, $course_code, $lp_ids = array(), $session_id = null) |
@@ -2831,6 +2836,8 @@ discard block |
||
2831 | 2836 | * @param int|array Student id(s) |
2832 | 2837 | * @param string Course code |
2833 | 2838 | * @param int Learning path id |
2839 | + * @param integer $student_id |
|
2840 | + * @param string $course_code |
|
2834 | 2841 | * @return int Total time |
2835 | 2842 | */ |
2836 | 2843 | public static function get_last_connection_time_in_lp($student_id, $course_code, $lp_id, $session_id = 0) |
@@ -5504,7 +5511,7 @@ discard block |
||
5504 | 5511 | |
5505 | 5512 | /** |
5506 | 5513 | * @param FormValidator $form |
5507 | - * @return mixed |
|
5514 | + * @return FormValidator |
|
5508 | 5515 | */ |
5509 | 5516 | public static function setUserSearchForm($form) |
5510 | 5517 | { |
@@ -6985,7 +6992,7 @@ discard block |
||
6985 | 6992 | * @param int $user_id |
6986 | 6993 | * @param int $course_id |
6987 | 6994 | * @param int $session_id |
6988 | - * @return array |
|
6995 | + * @return string[] |
|
6989 | 6996 | */ |
6990 | 6997 | public function display_login_tracking_info($view, $user_id, $course_id, $session_id = 0) |
6991 | 6998 | { |
@@ -7031,9 +7038,9 @@ discard block |
||
7031 | 7038 | /** |
7032 | 7039 | * Displays the exercise results for a specific user in a specific course. |
7033 | 7040 | * @param string $view |
7034 | - * @param int $user_id User ID |
|
7041 | + * @param int $userId User ID |
|
7035 | 7042 | * @param string $courseCode Course code |
7036 | - * @return array |
|
7043 | + * @return string[] |
|
7037 | 7044 | * @todo remove globals |
7038 | 7045 | */ |
7039 | 7046 | public function display_exercise_tracking_info($view, $userId, $courseCode) |