Lines Matching +full:edit -(+path:inc +path:lang) -(+path:lib +path:plugins +path:lang) -(+path:lib +path:tpl +path:dokuwiki +path:lang)
177 // Compute the edit operations.
551 foreach ($this->edits as $edit) {
552 $rev->edits[] = $edit->reverse();
563 foreach ($this->edits as $edit) {
564 if ($edit->type != 'copy')
579 foreach ($this->edits as $edit) {
580 if ($edit->type == 'copy')
581 $lcs += count($edit->orig);
597 foreach ($this->edits as $edit) {
598 if ($edit->orig)
599 array_splice($lines, count($lines), 0, $edit->orig);
615 foreach ($this->edits as $edit) {
616 if ($edit->closing)
617 array_splice($lines, count($lines), 0, $edit->closing);
643 foreach ($this->edits as $edit) {
644 if ($prevtype == $edit->type)
645 throw new \RuntimeException("Edit sequence is non-optimal");
646 $prevtype = $edit->type;
748 foreach ($diff->edits as $edit) {
749 if ($edit->type == 'copy') {
751 if (count($edit->orig) <= $nlead + $ntrail) {
752 $block[] = $edit;
756 $context = array_slice($edit->orig, 0, $ntrail);
763 $context = $edit->orig;
774 $block[] = $edit;
777 if ($edit->orig)
778 $xi += count($edit->orig);
779 if ($edit->closing)
780 $yi += count($edit->closing);
798 foreach ($edits as $edit) {
799 if ($edit->type == 'copy')
800 $this->_context($edit->orig);
801 elseif ($edit->type == 'add')
802 $this->_added($edit->closing);
803 elseif ($edit->type == 'delete')
804 $this->_deleted($edit->orig);
805 elseif ($edit->type == 'change')
806 $this->_changed($edit->orig, $edit->closing);
808 throw new \RuntimeException("Unknown edit type");
1024 foreach ($this->edits as $edit) {
1025 if ($edit->type == 'copy')
1026 $orig->addWords($edit->orig);
1027 elseif ($edit->orig)
1028 $orig->addWords($edit->orig, 'mark');
1036 foreach ($this->edits as $edit) {
1037 if ($edit->type == 'copy')
1038 $closing->addWords($edit->closing);
1039 elseif ($edit->closing)
1040 $closing->addWords($edit->closing, 'mark');
1065 foreach ($this->edits as $edit) {
1066 if ($edit->type == 'copy')
1067 $orig->addWords($edit->closing);
1068 elseif ($edit->type == 'change'){
1069 $orig->addWords($edit->orig, 'del');
1070 $orig->addWords($edit->closing, 'add');
1071 } elseif ($edit->type == 'delete')
1072 $orig->addWords($edit->orig, 'del');
1073 elseif ($edit->type == 'add')
1074 $orig->addWords($edit->closing, 'add');
1075 elseif ($edit->orig)
1076 $orig->addWords($edit->orig, 'del');
1352 foreach ($this->_edits as $edit) {
1353 if ($edit->isConflict()) {
1357 $edit->final1,
1359 $edit->final2,
1363 $lines = array_merge($lines, $edit->merged());
1389 if ($edit = $bb->finish()) {
1390 $edits[] = $edit;
1439 if ($edit = $bb->finish()) {
1440 $edits[] = $edit;
1553 $edit = new _Diff3_Op($this->orig, $this->final1, $this->final2);
1555 return $edit;