public function getHunkStartLines($hunks)
public function getHunkStartLines($hunks)
Get a map of lines on which hunks start, other than line 1. This datastructure is used to determine when to render "Context not available." in diffs with multiple hunks.
Parameters
array | $hunks |
Return
dict<int, bool> | Map of lines where hunks start, other than line 1. |
private function setVisibleLinesMask($mask)
private function setVisibleLinesMask($mask)
Parameters
$mask |
Return
wild |
public function getVisibleLinesMask()
public function getVisibleLinesMask()
Return
wild |
private function setIntraLineDiffs($intra_line_diffs)
private function setIntraLineDiffs($intra_line_diffs)
Parameters
$intra_line_diffs |
Return
wild |
public function getIntraLineDiffs()
public function getIntraLineDiffs()
Return
wild |
private function setNewLines($new_lines)
private function setNewLines($new_lines)
Parameters
$new_lines |
Return
wild |
public function getNewLines()
public function getNewLines()
Return
wild |
private function setOldLines($old_lines)
private function setOldLines($old_lines)
Parameters
$old_lines |
Return
wild |
public function getOldLines()
public function getOldLines()
Return
wild |
public function getOldLineTypeMap()
public function getOldLineTypeMap()
Return
wild |
public function setOldLineTypeMap($map)
public function setOldLineTypeMap($map)
Parameters
array | $map |
Return
wild |
public function getNewLineTypeMap()
public function getNewLineTypeMap()
Return
wild |
public function setNewLineTypeMap($map)
public function setNewLineTypeMap($map)
Parameters
array | $map |
Return
wild |
public function setDepthOnlyLines($map)
public function setDepthOnlyLines($map)
Parameters
array | $map |
Return
wild |
public function getDepthOnlyLines()
public function getDepthOnlyLines()
Return
wild |
public function setNormalized($normalized)
public function setNormalized($normalized)
Parameters
$normalized |
Return
wild |
public function getNormalized()
public function getNormalized()
Return
wild |
public function getIsDeleted()
public function getIsDeleted()
Return
wild |
public function getHasAnyChanges()
public function getHasAnyChanges()
Returns true if the hunks change anything, including whitespace.
Return
wild |
private function getHasChanges($filter)
private function getHasChanges($filter)
Parameters
$filter |
Return
wild |
public function reparseHunksForSpecialAttributes()
public function reparseHunksForSpecialAttributes()
This function takes advantage of the parsing work done in parseHunksForLineData() and continues the struggle to hammer this data into something we can display to a user.
In particular, this function re-parses the hunks to make them equivalent in length for easy rendering, adding null as necessary to pad the length.
Anyhoo, this function is not particularly well-named but I try.
NOTE: this function must be called after
parseHunksForLineData().
Return
wild |
public function generateIntraLineDiffs()
public function generateIntraLineDiffs()
Return
wild |
public function generateVisibleBlocksMask($lines_context)
public function generateVisibleBlocksMask($lines_context)
Parameters
$lines_context |
Return
wild |
public function generateVisibleLinesMask($lines_context)
public function generateVisibleLinesMask($lines_context)
Parameters
$lines_context |
Return
wild |
public function getOldCorpus()
public function getOldCorpus()
Return
wild |
public function getNewCorpus()
public function getNewCorpus()
Return
wild |
private function getCorpus($lines)
private function getCorpus($lines)
Parameters
array | $lines |
Return
wild |
public function parseHunksForLineData($hunks)
public function parseHunksForLineData($hunks)
Parameters
array | $hunks |
Return
wild |
public function parseHunksForHighlightMasks($changeset_hunks, $old_hunks, $new_hunks)
public function parseHunksForHighlightMasks($changeset_hunks, $old_hunks, $new_hunks)
Parameters
array | $changeset_hunks | |
array | $old_hunks | |
array | $new_hunks |
Return
wild |
public function makeContextDiff($hunks, $is_new, $line_number, $line_length, $add_context)
public function makeContextDiff($hunks, $is_new, $line_number, $line_length, $add_context)
Parameters
array | $hunks | |
$is_new | ||
$line_number | ||
$line_length | ||
$add_context |
Return
wild |
private function computeOffsets($hunks)
private function computeOffsets($hunks)
Parameters
array | $hunks |
Return
wild |
private function getIndentDepth($text, $tab_width)
private function getIndentDepth($text, $tab_width)
Parameters
$text | ||
$tab_width |
Return
wild |
private function getCharacterCountForVisualWhitespace($text, $depth, $tab_width)
private function getCharacterCountForVisualWhitespace($text, $depth, $tab_width)
Parameters
$text | ||
$depth | ||
$tab_width |
Return
wild |
private function updateChangeTypesForNormalization()
private function updateChangeTypesForNormalization()
Return
wild |