# includes/diff
'DiffEngine' => 'includes/diff/DairikiDiff.php',
'DiffOp' => 'includes/diff/DairikiDiff.php',
- 'DiffOp_Add' => 'includes/diff/DairikiDiff.php',
- 'DiffOp_Change' => 'includes/diff/DairikiDiff.php',
- 'DiffOp_Copy' => 'includes/diff/DairikiDiff.php',
- 'DiffOp_Delete' => 'includes/diff/DairikiDiff.php',
+ 'DiffOpAdd' => 'includes/diff/DairikiDiff.php',
+ 'DiffOpChange' => 'includes/diff/DairikiDiff.php',
+ 'DiffOpCopy' => 'includes/diff/DairikiDiff.php',
+ 'DiffOpDelete' => 'includes/diff/DairikiDiff.php',
'HWLDFWordAccumulator' => 'includes/diff/DairikiDiff.php',
'ArrayDiffFormatter' => 'includes/diff/ArrayDiffFormatter.php',
'Diff' => 'includes/diff/DairikiDiff.php',
* @private
* @ingroup DifferenceEngine
*/
-class DiffOp_Copy extends DiffOp {
+class DiffOpCopy extends DiffOp {
public $type = 'copy';
function __construct( $orig, $closing = false ) {
}
/**
- * @return DiffOp_Copy
+ * @return DiffOpCopy
*/
function reverse() {
- return new DiffOp_Copy( $this->closing, $this->orig );
+ return new DiffOpCopy( $this->closing, $this->orig );
}
}
* @private
* @ingroup DifferenceEngine
*/
-class DiffOp_Delete extends DiffOp {
+class DiffOpDelete extends DiffOp {
public $type = 'delete';
function __construct( $lines ) {
}
/**
- * @return DiffOp_Add
+ * @return DiffOpAdd
*/
function reverse() {
- return new DiffOp_Add( $this->orig );
+ return new DiffOpAdd( $this->orig );
}
}
* @private
* @ingroup DifferenceEngine
*/
-class DiffOp_Add extends DiffOp {
+class DiffOpAdd extends DiffOp {
public $type = 'add';
function __construct( $lines ) {
}
/**
- * @return DiffOp_Delete
+ * @return DiffOpDelete
*/
function reverse() {
- return new DiffOp_Delete( $this->closing );
+ return new DiffOpDelete( $this->closing );
}
}
* @private
* @ingroup DifferenceEngine
*/
-class DiffOp_Change extends DiffOp {
+class DiffOpChange extends DiffOp {
public $type = 'change';
function __construct( $orig, $closing ) {
}
/**
- * @return DiffOp_Change
+ * @return DiffOpChange
*/
function reverse() {
- return new DiffOp_Change( $this->closing, $this->orig );
+ return new DiffOpChange( $this->closing, $this->orig );
}
}
++$yi;
}
if ( $copy ) {
- $edits[] = new DiffOp_Copy( $copy );
+ $edits[] = new DiffOpCopy( $copy );
}
// Find deletes & adds.
}
if ( $delete && $add ) {
- $edits[] = new DiffOp_Change( $delete, $add );
+ $edits[] = new DiffOpChange( $delete, $add );
} elseif ( $delete ) {
- $edits[] = new DiffOp_Delete( $delete );
+ $edits[] = new DiffOpDelete( $delete );
} elseif ( $add ) {
- $edits[] = new DiffOp_Add( $add );
+ $edits[] = new DiffOpAdd( $add );
}
}
wfProfileOut( __METHOD__ );
} else {
if ( $ntrail ) {
$context = array_slice( $edit->orig, 0, $ntrail );
- $block[] = new DiffOp_Copy( $context );
+ $block[] = new DiffOpCopy( $context );
}
$this->block( $x0, $ntrail + $xi - $x0,
$y0, $ntrail + $yi - $y0,
$y0 = $yi - count( $context );
$block = array();
if ( $context ) {
- $block[] = new DiffOp_Copy( $context );
+ $block[] = new DiffOpCopy( $context );
}
}
$block[] = $edit;