Index: trunk/phase3/languages/LanguageConverter.php |
— | — | @@ -766,6 +766,8 @@ |
767 | 767 | |
768 | 768 | /** |
769 | 769 | * Returns language specific hash options. |
| 770 | + * |
| 771 | + * @return string |
770 | 772 | */ |
771 | 773 | public function getExtraHashOptions() { |
772 | 774 | $variant = $this->getPreferredVariant(); |
— | — | @@ -870,6 +872,8 @@ |
871 | 873 | * @param $code String: language code |
872 | 874 | * @param $subpage String: subpage name |
873 | 875 | * @param $recursive Boolean: parse subpages recursively? Defaults to true. |
| 876 | + * |
| 877 | + * @return array |
874 | 878 | */ |
875 | 879 | function parseCachedTable( $code, $subpage = '', $recursive = true ) { |
876 | 880 | static $parsed = array(); |
— | — | @@ -1233,6 +1237,8 @@ |
1234 | 1238 | |
1235 | 1239 | /** |
1236 | 1240 | * @private |
| 1241 | + * |
| 1242 | + * @return string |
1237 | 1243 | */ |
1238 | 1244 | function getRulesDesc() { |
1239 | 1245 | $codesep = $this->mConverter->mDescCodeSep; |
— | — | @@ -1253,6 +1259,8 @@ |
1254 | 1260 | /** |
1255 | 1261 | * Parse rules conversion. |
1256 | 1262 | * @private |
| 1263 | + * |
| 1264 | + * @return string |
1257 | 1265 | */ |
1258 | 1266 | function getRuleConvertedStr( $variant ) { |
1259 | 1267 | $bidtable = $this->mBidtable; |
— | — | @@ -1462,6 +1470,7 @@ |
1463 | 1471 | |
1464 | 1472 | /** |
1465 | 1473 | * Get display text on markup -{...}- |
| 1474 | + * @return string |
1466 | 1475 | */ |
1467 | 1476 | public function getDisplay() { |
1468 | 1477 | return $this->mRuleDisplay; |
— | — | @@ -1469,6 +1478,7 @@ |
1470 | 1479 | |
1471 | 1480 | /** |
1472 | 1481 | * Get converted title. |
| 1482 | + * @return string |
1473 | 1483 | */ |
1474 | 1484 | public function getTitle() { |
1475 | 1485 | return $this->mRuleTitle; |
Index: trunk/phase3/languages/classes/LanguageTi.php |
— | — | @@ -7,6 +7,11 @@ |
8 | 8 | class LanguageTi extends Language { |
9 | 9 | /** |
10 | 10 | * Use singular form for zero |
| 11 | + * |
| 12 | + * @param $count int |
| 13 | + * @param $forms array |
| 14 | + * |
| 15 | + * @return string |
11 | 16 | */ |
12 | 17 | function convertPlural( $count, $forms ) { |
13 | 18 | if ( !count( $forms ) ) { return ''; } |
Index: trunk/phase3/languages/classes/LanguageTl.php |
— | — | @@ -7,6 +7,11 @@ |
8 | 8 | class LanguageTl extends Language { |
9 | 9 | /** |
10 | 10 | * Use singular form for zero |
| 11 | + * |
| 12 | + * @param $count int |
| 13 | + * @param $forms array |
| 14 | + * |
| 15 | + * @return string |
11 | 16 | */ |
12 | 17 | function convertPlural( $count, $forms ) { |
13 | 18 | if ( !count( $forms ) ) { return ''; } |
Index: trunk/phase3/languages/classes/LanguageTr.php |
— | — | @@ -12,6 +12,10 @@ |
13 | 13 | */ |
14 | 14 | class LanguageTr extends Language { |
15 | 15 | |
| 16 | + /** |
| 17 | + * @param $string string |
| 18 | + * @return string |
| 19 | + */ |
16 | 20 | function ucfirst ( $string ) { |
17 | 21 | if ( !empty( $string ) && $string[0] == 'i' ) { |
18 | 22 | return 'İ' . substr( $string, 1 ); |
— | — | @@ -20,6 +24,10 @@ |
21 | 25 | } |
22 | 26 | } |
23 | 27 | |
| 28 | + /** |
| 29 | + * @param $string string |
| 30 | + * @return mixed|string |
| 31 | + */ |
24 | 32 | function lcfirst ( $string ) { |
25 | 33 | if ( !empty( $string ) && $string[0] == 'I' ) { |
26 | 34 | return 'ı' . substr( $string, 1 ); |
— | — | @@ -28,13 +36,27 @@ |
29 | 37 | } |
30 | 38 | } |
31 | 39 | |
32 | | - /** @see bug 28040 */ |
| 40 | + /** |
| 41 | + * @see bug 28040 |
| 42 | + * |
| 43 | + * @param $string string |
| 44 | + * @param $first string |
| 45 | + * |
| 46 | + * @return string |
| 47 | + */ |
33 | 48 | function uc( $string, $first = false ) { |
34 | 49 | $string = preg_replace( '/i/', 'İ', $string ); |
35 | 50 | return parent::uc( $string, $first ); |
36 | 51 | } |
37 | 52 | |
38 | | - /** @see bug 28040 */ |
| 53 | + /** |
| 54 | + * @see bug 28040 |
| 55 | + * |
| 56 | + * @param $string string |
| 57 | + * @param $first string |
| 58 | + * |
| 59 | + * @return string |
| 60 | + */ |
39 | 61 | function lc( $string, $first = false ) { |
40 | 62 | $string = preg_replace( '/I/', 'ı', $string ); |
41 | 63 | return parent::lc( $string, $first ); |
Index: trunk/phase3/languages/classes/LanguageMl.php |
— | — | @@ -15,6 +15,10 @@ |
16 | 16 | * |
17 | 17 | * @todo FIXME: This is language-specific for now only to avoid the negative |
18 | 18 | * performance impact of enabling it for all languages. |
| 19 | + * |
| 20 | + * @param $s string |
| 21 | + * |
| 22 | + * @return string |
19 | 23 | */ |
20 | 24 | function normalize( $s ) { |
21 | 25 | global $wgFixMalayalamUnicode; |
Index: trunk/phase3/languages/classes/LanguageIu.php |
— | — | @@ -128,6 +128,8 @@ |
129 | 129 | /** |
130 | 130 | * We want our external link captions to be converted in variants, |
131 | 131 | * so we return the original text instead -{$text}-, except for URLs |
| 132 | + * |
| 133 | + * @return string |
132 | 134 | */ |
133 | 135 | function markNoConversion( $text, $noParse = false ) { |
134 | 136 | if ( $noParse || preg_match( "/^https?:\/\/|ftp:\/\/|irc:\/\//", $text ) ) |
— | — | @@ -138,6 +140,8 @@ |
139 | 141 | /** |
140 | 142 | * An ugly function wrapper for parsing Image titles |
141 | 143 | * (to prevent image name conversion) |
| 144 | + * |
| 145 | + * @return string |
142 | 146 | */ |
143 | 147 | function autoConvert( $text, $toVariant = false ) { |
144 | 148 | global $wgTitle; |
— | — | @@ -149,7 +153,9 @@ |
150 | 154 | } |
151 | 155 | |
152 | 156 | /** |
153 | | - * It translates text into variant |
| 157 | + * It translates text into variant |
| 158 | + * |
| 159 | + * @return string |
154 | 160 | */ |
155 | 161 | function translate( $text, $toVariant ) { |
156 | 162 | // If $text is empty or only includes spaces, do nothing |
Index: trunk/phase3/languages/classes/LanguageUk.php |
— | — | @@ -86,6 +86,10 @@ |
87 | 87 | |
88 | 88 | /** |
89 | 89 | * Ukrainian numeric format is "12 345,67" but "1234,56" |
| 90 | + * |
| 91 | + * @param $_ string |
| 92 | + * |
| 93 | + * @return string |
90 | 94 | */ |
91 | 95 | function commafy( $_ ) { |
92 | 96 | if ( !preg_match( '/^\-?\d{1,4}(\.\d+)?$/', $_ ) ) { |
Index: trunk/phase3/languages/classes/LanguageKaa.php |
— | — | @@ -10,6 +10,8 @@ |
11 | 11 | # Invoked with {{GRAMMAR:case|word}} |
12 | 12 | /** |
13 | 13 | * Cases: genitive, dative, accusative, locative, ablative, comitative + possessive forms |
| 14 | + * |
| 15 | + * @return string |
14 | 16 | */ |
15 | 17 | function convertGrammar( $word, $case ) { |
16 | 18 | global $wgGrammarForms; |
Index: trunk/phase3/languages/classes/LanguageRu.php |
— | — | @@ -99,6 +99,10 @@ |
100 | 100 | * Four-digit number should be without group commas (spaces) |
101 | 101 | * See manual of style at http://ru.wikipedia.org/wiki/Википедия:Оформление_статей |
102 | 102 | * So "1 234 567", "12 345" but "1234" |
| 103 | + * |
| 104 | + * @param $_ string |
| 105 | + * |
| 106 | + * @return string |
103 | 107 | */ |
104 | 108 | function commafy( $_ ) { |
105 | 109 | if ( preg_match( '/^-?\d{1,4}(\.\d*)?$/', $_ ) ) { |
Index: trunk/phase3/languages/classes/LanguageKk.php |
— | — | @@ -234,6 +234,8 @@ |
235 | 235 | /** |
236 | 236 | * An ugly function wrapper for parsing Image titles |
237 | 237 | * (to prevent image name conversion) |
| 238 | + * |
| 239 | + * @return string |
238 | 240 | */ |
239 | 241 | function autoConvert( $text, $toVariant = false ) { |
240 | 242 | global $wgTitle; |
— | — | @@ -246,6 +248,8 @@ |
247 | 249 | |
248 | 250 | /** |
249 | 251 | * It translates text into variant |
| 252 | + * |
| 253 | + * @return string |
250 | 254 | */ |
251 | 255 | function translate( $text, $toVariant ) { |
252 | 256 | global $wgLanguageCode; |
— | — | @@ -340,6 +344,8 @@ |
341 | 345 | /** |
342 | 346 | * We want our external link captions to be converted in variants, |
343 | 347 | * so we return the original text instead -{$text}-, except for URLs |
| 348 | + * |
| 349 | + * @return string |
344 | 350 | */ |
345 | 351 | function markNoConversion( $text, $noParse = false ) { |
346 | 352 | if ( $noParse || preg_match( "/^https?:\/\/|ftp:\/\/|irc:\/\//", $text ) ) |
Index: trunk/phase3/languages/classes/LanguageSl.php |
— | — | @@ -9,6 +9,11 @@ |
10 | 10 | # Invoked with {{GRAMMAR:case|word}} |
11 | 11 | /** |
12 | 12 | * Cases: rodilnik, dajalnik, tožilnik, mestnik, orodnik |
| 13 | + * |
| 14 | + * @param $word string |
| 15 | + * @param $case string |
| 16 | + * |
| 17 | + * @return string |
13 | 18 | */ |
14 | 19 | function convertGrammar( $word, $case ) { |
15 | 20 | global $wgGrammarForms; |
Index: trunk/phase3/languages/classes/LanguageKu.php |
— | — | @@ -155,6 +155,8 @@ |
156 | 156 | /** |
157 | 157 | * We want our external link captions to be converted in variants, |
158 | 158 | * so we return the original text instead -{$text}-, except for URLs |
| 159 | + * |
| 160 | + * @return string |
159 | 161 | */ |
160 | 162 | function markNoConversion( $text, $noParse = false ) { |
161 | 163 | if ( $noParse || preg_match( "/^https?:\/\/|ftp:\/\/|irc:\/\//", $text ) ) |
— | — | @@ -165,6 +167,8 @@ |
166 | 168 | /** |
167 | 169 | * An ugly function wrapper for parsing Image titles |
168 | 170 | * (to prevent image name conversion) |
| 171 | + * |
| 172 | + * @return string |
169 | 173 | */ |
170 | 174 | function autoConvert( $text, $toVariant = false ) { |
171 | 175 | global $wgTitle; |
— | — | @@ -178,6 +182,8 @@ |
179 | 183 | /** |
180 | 184 | * It translates text into variant, specials: |
181 | 185 | * - ommiting roman numbers |
| 186 | + * |
| 187 | + * @return string |
182 | 188 | */ |
183 | 189 | function translate( $text, $toVariant ) { |
184 | 190 | /* From Kazakh interface, maybe we need it later |
Index: trunk/phase3/languages/classes/LanguageSr.php |
— | — | @@ -100,6 +100,8 @@ |
101 | 101 | /** |
102 | 102 | * We want our external link captions to be converted in variants, |
103 | 103 | * so we return the original text instead -{$text}-, except for URLs |
| 104 | + * |
| 105 | + * @return string |
104 | 106 | */ |
105 | 107 | function markNoConversion( $text, $noParse = false ) { |
106 | 108 | if ( $noParse || preg_match( "/^https?:\/\/|ftp:\/\/|irc:\/\//", $text ) ) |
— | — | @@ -110,6 +112,8 @@ |
111 | 113 | /** |
112 | 114 | * An ugly function wrapper for parsing Image titles |
113 | 115 | * (to prevent image name conversion) |
| 116 | + * |
| 117 | + * @return string |
114 | 118 | */ |
115 | 119 | function autoConvert( $text, $toVariant = false ) { |
116 | 120 | global $wgTitle; |
— | — | @@ -123,6 +127,8 @@ |
124 | 128 | /** |
125 | 129 | * It translates text into variant, specials: |
126 | 130 | * - ommiting roman numbers |
| 131 | + * |
| 132 | + * @return string |
127 | 133 | */ |
128 | 134 | function translate( $text, $toVariant ) { |
129 | 135 | $breaks = '[^\w\x80-\xff]'; |
— | — | @@ -154,6 +160,8 @@ |
155 | 161 | * |
156 | 162 | * @author Nikola Smolenski <smolensk@eunet.rs> |
157 | 163 | * @since 1.18 |
| 164 | + * |
| 165 | + * @return bool |
158 | 166 | */ |
159 | 167 | public function guessVariant( $text, $variant ) { |
160 | 168 | $numCyrillic = preg_match_all("/[шђчћжШЂЧЋЖ]/u", $text, $dummy); |
— | — | @@ -166,9 +174,7 @@ |
167 | 175 | } else { |
168 | 176 | return false; |
169 | 177 | } |
170 | | - |
171 | 178 | } |
172 | | - |
173 | 179 | } |
174 | 180 | |
175 | 181 | /** |