Index: trunk/phase3/includes/LinksUpdate.php |
— | — | @@ -328,7 +328,7 @@ |
329 | 329 | * @param $insertions |
330 | 330 | * @param $fromField |
331 | 331 | */ |
332 | | - function dumbTableUpdate( $table, $insertions, $fromField ) { |
| 332 | + private function dumbTableUpdate( $table, $insertions, $fromField ) { |
333 | 333 | $this->mDb->delete( $table, array( $fromField => $this->mId ), __METHOD__ ); |
334 | 334 | if ( count( $insertions ) ) { |
335 | 335 | # The link array was constructed without FOR UPDATE, so there may |
— | — | @@ -392,7 +392,7 @@ |
393 | 393 | * @param $existing array |
394 | 394 | * @return array |
395 | 395 | */ |
396 | | - function getLinkInsertions( $existing = array() ) { |
| 396 | + private function getLinkInsertions( $existing = array() ) { |
397 | 397 | $arr = array(); |
398 | 398 | foreach( $this->mLinks as $ns => $dbkeys ) { |
399 | 399 | $diffs = isset( $existing[$ns] ) |
— | — | @@ -414,7 +414,7 @@ |
415 | 415 | * @param $existing array |
416 | 416 | * @return array |
417 | 417 | */ |
418 | | - function getTemplateInsertions( $existing = array() ) { |
| 418 | + private function getTemplateInsertions( $existing = array() ) { |
419 | 419 | $arr = array(); |
420 | 420 | foreach( $this->mTemplates as $ns => $dbkeys ) { |
421 | 421 | $diffs = isset( $existing[$ns] ) ? array_diff_key( $dbkeys, $existing[$ns] ) : $dbkeys; |
— | — | @@ -435,7 +435,7 @@ |
436 | 436 | * @param $existing array |
437 | 437 | * @return array |
438 | 438 | */ |
439 | | - function getImageInsertions( $existing = array() ) { |
| 439 | + private function getImageInsertions( $existing = array() ) { |
440 | 440 | $arr = array(); |
441 | 441 | $diffs = array_diff_key( $this->mImages, $existing ); |
442 | 442 | foreach( $diffs as $iname => $dummy ) { |
— | — | @@ -452,7 +452,7 @@ |
453 | 453 | * @param $existing array |
454 | 454 | * @return array |
455 | 455 | */ |
456 | | - function getExternalInsertions( $existing = array() ) { |
| 456 | + private function getExternalInsertions( $existing = array() ) { |
457 | 457 | $arr = array(); |
458 | 458 | $diffs = array_diff_key( $this->mExternals, $existing ); |
459 | 459 | foreach( $diffs as $url => $dummy ) { |
— | — | @@ -473,7 +473,7 @@ |
474 | 474 | * |
475 | 475 | * @return array |
476 | 476 | */ |
477 | | - function getCategoryInsertions( $existing = array() ) { |
| 477 | + private function getCategoryInsertions( $existing = array() ) { |
478 | 478 | global $wgContLang, $wgCategoryCollation; |
479 | 479 | $diffs = array_diff_assoc( $this->mCategories, $existing ); |
480 | 480 | $arr = array(); |
— | — | @@ -516,7 +516,7 @@ |
517 | 517 | * |
518 | 518 | * @return array |
519 | 519 | */ |
520 | | - function getInterlangInsertions( $existing = array() ) { |
| 520 | + private function getInterlangInsertions( $existing = array() ) { |
521 | 521 | $diffs = array_diff_assoc( $this->mInterlangs, $existing ); |
522 | 522 | $arr = array(); |
523 | 523 | foreach( $diffs as $lang => $title ) { |
— | — | @@ -553,7 +553,7 @@ |
554 | 554 | * @param $existing array |
555 | 555 | * @return array |
556 | 556 | */ |
557 | | - function getInterwikiInsertions( $existing = array() ) { |
| 557 | + private function getInterwikiInsertions( $existing = array() ) { |
558 | 558 | $arr = array(); |
559 | 559 | foreach( $this->mInterwikis as $prefix => $dbkeys ) { |
560 | 560 | $diffs = isset( $existing[$prefix] ) ? array_diff_key( $dbkeys, $existing[$prefix] ) : $dbkeys; |
— | — | @@ -574,7 +574,7 @@ |
575 | 575 | * @param $existing array |
576 | 576 | * @return array |
577 | 577 | */ |
578 | | - function getLinkDeletions( $existing ) { |
| 578 | + private function getLinkDeletions( $existing ) { |
579 | 579 | $del = array(); |
580 | 580 | foreach ( $existing as $ns => $dbkeys ) { |
581 | 581 | if ( isset( $this->mLinks[$ns] ) ) { |
— | — | @@ -592,7 +592,7 @@ |
593 | 593 | * @param $existing array |
594 | 594 | * @return array |
595 | 595 | */ |
596 | | - function getTemplateDeletions( $existing ) { |
| 596 | + private function getTemplateDeletions( $existing ) { |
597 | 597 | $del = array(); |
598 | 598 | foreach ( $existing as $ns => $dbkeys ) { |
599 | 599 | if ( isset( $this->mTemplates[$ns] ) ) { |
— | — | @@ -610,7 +610,7 @@ |
611 | 611 | * @param $existing array |
612 | 612 | * @return array |
613 | 613 | */ |
614 | | - function getImageDeletions( $existing ) { |
| 614 | + private function getImageDeletions( $existing ) { |
615 | 615 | return array_diff_key( $existing, $this->mImages ); |
616 | 616 | } |
617 | 617 | |
— | — | @@ -620,7 +620,7 @@ |
621 | 621 | * @param $existing array |
622 | 622 | * @return array |
623 | 623 | */ |
624 | | - function getExternalDeletions( $existing ) { |
| 624 | + private function getExternalDeletions( $existing ) { |
625 | 625 | return array_diff_key( $existing, $this->mExternals ); |
626 | 626 | } |
627 | 627 | |
— | — | @@ -630,7 +630,7 @@ |
631 | 631 | * @param $existing array |
632 | 632 | * @return array |
633 | 633 | */ |
634 | | - function getCategoryDeletions( $existing ) { |
| 634 | + private function getCategoryDeletions( $existing ) { |
635 | 635 | return array_diff_assoc( $existing, $this->mCategories ); |
636 | 636 | } |
637 | 637 | |
— | — | @@ -640,7 +640,7 @@ |
641 | 641 | * @param $existing array |
642 | 642 | * @return array |
643 | 643 | */ |
644 | | - function getInterlangDeletions( $existing ) { |
| 644 | + private function getInterlangDeletions( $existing ) { |
645 | 645 | return array_diff_assoc( $existing, $this->mInterlangs ); |
646 | 646 | } |
647 | 647 | |
— | — | @@ -659,7 +659,7 @@ |
660 | 660 | * @param $existing array |
661 | 661 | * @return array |
662 | 662 | */ |
663 | | - function getInterwikiDeletions( $existing ) { |
| 663 | + private function getInterwikiDeletions( $existing ) { |
664 | 664 | $del = array(); |
665 | 665 | foreach ( $existing as $prefix => $dbkeys ) { |
666 | 666 | if ( isset( $this->mInterwikis[$prefix] ) ) { |
— | — | @@ -676,7 +676,7 @@ |
677 | 677 | * |
678 | 678 | * @return array |
679 | 679 | */ |
680 | | - function getExistingLinks() { |
| 680 | + private function getExistingLinks() { |
681 | 681 | $res = $this->mDb->select( 'pagelinks', array( 'pl_namespace', 'pl_title' ), |
682 | 682 | array( 'pl_from' => $this->mId ), __METHOD__, $this->mOptions ); |
683 | 683 | $arr = array(); |
— | — | @@ -694,7 +694,7 @@ |
695 | 695 | * |
696 | 696 | * @return array |
697 | 697 | */ |
698 | | - function getExistingTemplates() { |
| 698 | + private function getExistingTemplates() { |
699 | 699 | $res = $this->mDb->select( 'templatelinks', array( 'tl_namespace', 'tl_title' ), |
700 | 700 | array( 'tl_from' => $this->mId ), __METHOD__, $this->mOptions ); |
701 | 701 | $arr = array(); |
— | — | @@ -712,7 +712,7 @@ |
713 | 713 | * |
714 | 714 | * @return array |
715 | 715 | */ |
716 | | - function getExistingImages() { |
| 716 | + private function getExistingImages() { |
717 | 717 | $res = $this->mDb->select( 'imagelinks', array( 'il_to' ), |
718 | 718 | array( 'il_from' => $this->mId ), __METHOD__, $this->mOptions ); |
719 | 719 | $arr = array(); |
— | — | @@ -727,7 +727,7 @@ |
728 | 728 | * |
729 | 729 | * @return array |
730 | 730 | */ |
731 | | - function getExistingExternals() { |
| 731 | + private function getExistingExternals() { |
732 | 732 | $res = $this->mDb->select( 'externallinks', array( 'el_to' ), |
733 | 733 | array( 'el_from' => $this->mId ), __METHOD__, $this->mOptions ); |
734 | 734 | $arr = array(); |
— | — | @@ -742,7 +742,7 @@ |
743 | 743 | * |
744 | 744 | * @return array |
745 | 745 | */ |
746 | | - function getExistingCategories() { |
| 746 | + private function getExistingCategories() { |
747 | 747 | $res = $this->mDb->select( 'categorylinks', array( 'cl_to', 'cl_sortkey_prefix' ), |
748 | 748 | array( 'cl_from' => $this->mId ), __METHOD__, $this->mOptions ); |
749 | 749 | $arr = array(); |
— | — | @@ -758,7 +758,7 @@ |
759 | 759 | * |
760 | 760 | * @return array |
761 | 761 | */ |
762 | | - function getExistingInterlangs() { |
| 762 | + private function getExistingInterlangs() { |
763 | 763 | $res = $this->mDb->select( 'langlinks', array( 'll_lang', 'll_title' ), |
764 | 764 | array( 'll_from' => $this->mId ), __METHOD__, $this->mOptions ); |
765 | 765 | $arr = array(); |
— | — | @@ -790,7 +790,7 @@ |
791 | 791 | * |
792 | 792 | * @return array |
793 | 793 | */ |
794 | | - function getExistingProperties() { |
| 794 | + private function getExistingProperties() { |
795 | 795 | $res = $this->mDb->select( 'page_props', array( 'pp_propname', 'pp_value' ), |
796 | 796 | array( 'pp_page' => $this->mId ), __METHOD__, $this->mOptions ); |
797 | 797 | $arr = array(); |
— | — | @@ -804,7 +804,7 @@ |
805 | 805 | * Return the title object of the page being updated |
806 | 806 | * @return Title |
807 | 807 | */ |
808 | | - function getTitle() { |
| 808 | + public function getTitle() { |
809 | 809 | return $this->mTitle; |
810 | 810 | } |
811 | 811 | |
— | — | @@ -820,7 +820,7 @@ |
821 | 821 | * Invalidate any necessary link lists related to page property changes |
822 | 822 | * @param $changed |
823 | 823 | */ |
824 | | - function invalidateProperties( $changed ) { |
| 824 | + private function invalidateProperties( $changed ) { |
825 | 825 | global $wgPagePropLinkInvalidations; |
826 | 826 | |
827 | 827 | foreach ( $changed as $name => $value ) { |