1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
|
<?php
use MediaWiki\Content\Content;
class CustomDifferenceEngine extends DifferenceEngine {
public function __construct() {
parent::__construct();
}
public function generateContentDiffBody( Content $old, Content $new ) {
return $old->getText() . '|' . $new->getText();
}
public function showDiffStyle() {
$this->getOutput()->addModules( 'foo' );
}
public function getDiffBodyCacheKeyParams() {
$params = parent::getDiffBodyCacheKeyParams();
$params[] = 'foo';
return $params;
}
}
|