Class: Gitlab::Diff::SuggestionDiff

Inherits:
Object
  • Object
show all
Includes:
Utils::StrongMemoize
Defined in:
lib/gitlab/diff/suggestion_diff.rb

Instance Method Summary collapse

Methods included from Utils::StrongMemoize

#clear_memoization, #strong_memoize, #strong_memoized?

Constructor Details

#initialize(suggestible) ⇒ SuggestionDiff

Returns a new instance of SuggestionDiff.


10
11
12
# File 'lib/gitlab/diff/suggestion_diff.rb', line 10

def initialize(suggestible)
  @suggestible = suggestible
end

Instance Method Details

#diff_linesObject


14
15
16
# File 'lib/gitlab/diff/suggestion_diff.rb', line 14

def diff_lines
  Gitlab::Diff::Parser.new.parse(raw_diff.each_line).to_a
end