Index: trunk/phase3/includes/parser/ParserCache.php |
— | — | @@ -31,7 +31,7 @@ |
32 | 32 | * |
33 | 33 | * @param $memCached Object |
34 | 34 | */ |
35 | | - function __construct( $memCached ) { |
| 35 | + protected function __construct( $memCached ) { |
36 | 36 | if ( !$memCached ) { |
37 | 37 | throw new MWException( "Tried to create a ParserCache with an invalid memcached" ); |
38 | 38 | } |
— | — | @@ -40,7 +40,7 @@ |
41 | 41 | |
42 | 42 | /** |
43 | 43 | * @param $article Article |
44 | | - * @param $hash |
| 44 | + * @param $hash string |
45 | 45 | * @return mixed|string |
46 | 46 | */ |
47 | 47 | protected function getParserOutputKey( $article, $hash ) { |
— | — | @@ -84,6 +84,9 @@ |
85 | 85 | |
86 | 86 | /** |
87 | 87 | * Retrieve the ParserOutput from ParserCache, even if it's outdated. |
| 88 | + * @param $article Article |
| 89 | + * @param $popts ParserOptions |
| 90 | + * @return ParserOutput|false |
88 | 91 | */ |
89 | 92 | public function getDirty( $article, $popts ) { |
90 | 93 | $value = $this->get( $article, $popts, true ); |
— | — | @@ -131,6 +134,7 @@ |
132 | 135 | /** |
133 | 136 | * Retrieve the ParserOutput from ParserCache. |
134 | 137 | * false if not found or outdated. |
| 138 | + * @return ParserOutput|false |
135 | 139 | */ |
136 | 140 | public function get( $article, $popts, $useOutdated = false ) { |
137 | 141 | global $wgCacheEpoch; |
— | — | @@ -203,7 +207,8 @@ |
204 | 208 | |
205 | 209 | $optionsKey->setContainsOldMagic( $parserOutput->containsOldMagic() ); |
206 | 210 | |
207 | | - $parserOutputKey = $this->getParserOutputKey( $article, $popts->optionsHash( $optionsKey->mUsedOptions ) ); |
| 211 | + $parserOutputKey = $this->getParserOutputKey( $article, |
| 212 | + $popts->optionsHash( $optionsKey->mUsedOptions ) ); |
208 | 213 | |
209 | 214 | // Save the timestamp so that we don't have to load the revision row on view |
210 | 215 | $parserOutput->mTimestamp = $article->getTimestamp(); |