Merge "Minor getWithSetCallback() example formatting tweaks"
[lhc/web/wiklou.git] / includes / libs / objectcache / WANObjectCache.php
index 6c69b14..621ad42 100644 (file)
@@ -86,7 +86,7 @@ class WANObjectCache {
        /** Default time-since-expiry on a miss that makes a key "hot" */
        const LOCK_TSE = 1;
 
-       /** Idiom for set()/getWithSetCallback() TTL */
+       /** Idiom for set()/getWithSetCallback() TTL being "forever" */
        const TTL_NONE = 0;
        /** Idiom for getWithSetCallback() callbacks to avoid calling set() */
        const TTL_UNCACHEABLE = -1;
@@ -556,8 +556,8 @@ class WANObjectCache {
         *
         *             return CatConfig::newFromRow( $dbr->selectRow( ... ) );
         *         },
-        *         // Calling touchCheckKey() on this key invalidates the cache
         *         array(
+        *             // Calling touchCheckKey() on this key invalidates the cache
         *             'checkKeys' => array( wfMemcKey( 'site-cat-config' ) ),
         *             // Try to only let one datacenter thread manage cache updates at a time
         *             'lockTSE' => 30
@@ -581,9 +581,9 @@ class WANObjectCache {
         *
         *             return CatState::newFromResults( $dbr->select( ... ) );
         *         },
-        *         // The "check" keys that represent things the value depends on;
-        *         // Calling touchCheckKey() on any of them invalidates the cache
         *         array(
+        *              // The "check" keys that represent things the value depends on;
+        *              // Calling touchCheckKey() on any of them invalidates the cache
         *             'checkKeys' => array(
         *                 wfMemcKey( 'sustenance-bowls', $cat->getRoomId() ),
         *                 wfMemcKey( 'people-present', $cat->getHouseId() ),