r75293 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r75292‎ | r75293 | r75294 >
Date:21:01, 23 October 2010
Author:ialex
Status:ok
Tags:
Comment:
Fixed some doxygen warnings and consistency in documentation
Modified paths:
  • /trunk/phase3/includes/MessageBlobStore.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/MessageBlobStore.php
@@ -29,8 +29,11 @@
3030 * consistuent messages or the resource itself is changed.
3131 */
3232 class MessageBlobStore {
 33+
3334 /**
3435 * Get the message blobs for a set of modules
 36+ *
 37+ * @param $resourceLoader ResourceLoader object
3538 * @param $modules array Array of module objects keyed by module name
3639 * @param $lang string Language code
3740 * @return array An array mapping module names to message blobs
@@ -61,8 +64,10 @@
6265 * Generate and insert a new message blob. If the blob was already
6366 * present, it is not regenerated; instead, the preexisting blob
6467 * is fetched and returned.
65 - * @param $module string Module name
66 - * @param $lang string Language code
 68+ *
 69+ * @param $name String: module name
 70+ * @param $module ResourceLoaderModule object
 71+ * @param $lang String: language code
6772 * @return mixed Message blob or false if the module has no messages
6873 */
6974 public static function insertMessageBlob( $name, ResourceLoaderModule $module, $lang ) {
@@ -113,9 +118,11 @@
114119
115120 /**
116121 * Update all message blobs for a given module.
117 - * @param $module string Module name
118 - * @param $lang string Language code (optional)
119 - * @return mixed If $lang is set, the new message blob for that language is
 122+ *
 123+ * @param $name String: module name
 124+ * @param $module ResourceLoaderModule object
 125+ * @param $lang String: language code (optional)
 126+ * @return Mixed: if $lang is set, the new message blob for that language is
120127 * returned if present. Otherwise, null is returned.
121128 */
122129 public static function updateModule( $name, ResourceLoaderModule $module, $lang = null ) {
@@ -190,7 +197,8 @@
191198
192199 /**
193200 * Update a single message in all message blobs it occurs in.
194 - * @param $key string Message key
 201+ *
 202+ * @param $key String: message key
195203 */
196204 public static function updateMessage( $key ) {
197205 $dbw = wfGetDB( DB_MASTER );
@@ -241,9 +249,10 @@
242250
243251 /**
244252 * Create an update queue for updateMessage()
245 - * @param $key string Message key
246 - * @param $prevUpdates array Updates queue to refresh or null to build a fresh update queue
247 - * @return array Updates queue
 253+ *
 254+ * @param $key String: message key
 255+ * @param $prevUpdates Array: updates queue to refresh or null to build a fresh update queue
 256+ * @return Array: updates queue
248257 */
249258 private static function getUpdatesForMessage( $key, $prevUpdates = null ) {
250259 $dbw = wfGetDB( DB_MASTER );
@@ -291,9 +300,10 @@
292301
293302 /**
294303 * Reencode a message blob with the updated value for a message
295 - * @param $blob string Message blob (JSON object)
296 - * @param $key string Message key
297 - * @param $lang string Language code
 304+ *
 305+ * @param $blob String: message blob (JSON object)
 306+ * @param $key String: message key
 307+ * @param $lang String: language code
298308 * @return Message blob with $key replaced with its new value
299309 */
300310 private static function reencodeBlob( $blob, $key, $lang ) {
@@ -306,8 +316,10 @@
307317 /**
308318 * Get the message blobs for a set of modules from the database.
309319 * Modules whose blobs are not in the database are silently dropped.
310 - * @param $modules array Array of module names
311 - * @param $lang string Language code
 320+ *
 321+ * @param $resourceLoader ResourceLoader object
 322+ * @param $modules Array of module names
 323+ * @param $lang String: language code
312324 * @return array Array mapping module names to blobs
313325 */
314326 private static function getFromDB( ResourceLoader $resourceLoader, $modules, $lang ) {
@@ -341,9 +353,10 @@
342354
343355 /**
344356 * Generate the message blob for a given module in a given language.
345 - * @param $module string Module name
346 - * @param $lang string Language code
347 - * @return string JSON object
 357+ *
 358+ * @param $module ResourceLoaderModule object
 359+ * @param $lang String: language code
 360+ * @return String: JSON object
348361 */
349362 private static function generateMessageBlob( ResourceLoaderModule $module, $lang ) {
350363 $messages = array();

Status & tagging log