- wfProfileOut( $fname );
- }
-
- function getGoodAdditions()
- {
- return array_diff( $this->mGoodLinks, $this->mOldGoodLinks );
- }
-
- function getBadAdditions()
- {
- #wfDebug( "mOldBadLinks: " . implode( ', ', array_keys( $this->mOldBadLinks ) ) . "\n" );
- #wfDebug( "mBadLinks: " . implode( ', ', array_keys( $this->mBadLinks ) ) . "\n" );
- return array_values( array_diff( array_keys( $this->mBadLinks ), array_keys( $this->mOldBadLinks ) ) );
- }
-
- function getImageAdditions()
- {
- return array_diff_assoc( $this->mImageLinks, $this->mOldImageLinks );
- }
-
- function getGoodDeletions()
- {
- return array_diff( $this->mOldGoodLinks, $this->mGoodLinks );
- }
-
- function getBadDeletions()
- {
- return array_values( array_diff( array_keys( $this->mOldBadLinks ), array_keys( $this->mBadLinks ) ));
- }
-
- function getImageDeletions()
- {
- return array_diff_assoc( $this->mOldImageLinks, $this->mImageLinks );
- }
-
- # Parameters: $which is one of the LINKCACHE_xxx constants, $del and $add are
- # the incremental update arrays which will be filled. Returns whether or not it's
- # worth doing the incremental version. For example, if [[List of mathematical topics]]
- # was blanked, it would take a long, long time to do incrementally.
- function incrementalSetup( $which, &$del, &$add )
- {
- if ( ! $this->mPreFilled ) {
- return false;
+ $s = $db->selectRow( 'page',
+ array( 'page_id', 'page_len', 'page_is_redirect' ),
+ array( 'page_namespace' => $nt->getNamespace(), 'page_title' => $nt->getDBkey() ),
+ __METHOD__, $options );
+ # Set fields...
+ if ( $s !== false ) {
+ $id = $s->page_id;
+ $len = $s->page_len;
+ $redirect = $s->page_is_redirect;
+ } else {
+ $len = -1;
+ $redirect = 0;