function Diff::orig in Diff 6
Same name and namespace in other branches
- 5.2 DiffEngine.php \Diff::orig()
- 5 DiffEngine.php \Diff::orig()
- 6.2 DiffEngine.php \Diff::orig()
- 7.3 DiffEngine.php \Diff::orig()
- 7.2 DiffEngine.php \Diff::orig()
* Get the original set of lines. * * This reconstructs the $from_lines parameter passed to the * constructor. * *
Return value
array The original sequence of strings.
1 call to Diff::orig()
- Diff::_check in ./DiffEngine.php 
- * Check a Diff for validity. * * This is here only for debugging purposes.
1 method overrides Diff::orig()
- WordLevelDiff::orig in ./DiffEngine.php 
- * Get the original set of lines. * * This reconstructs the $from_lines parameter passed to the * constructor. * *
File
- ./DiffEngine.php, line 613 
Class
- Diff
- Class representing a 'diff' between two sequences of strings. @todo document @private @subpackage DifferenceEngine
Code
function orig() {
  $lines = array();
  foreach ($this->edits as $edit) {
    if ($edit->orig) {
      array_splice($lines, sizeof($lines), 0, $edit->orig);
    }
  }
  return $lines;
}