Class: IpynbDiff::Diff

Inherits:
SimpleDelegator
  • Object
show all
Defined in:
lib/diff.rb

Overview

The result of a diff object

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(from, to, diffy_opts) ⇒ Diff

Returns a new instance of Diff.



13
14
15
16
17
18
# File 'lib/diff.rb', line 13

def initialize(from, to, diffy_opts)
  super(Diffy::Diff.new(from.as_text, to.as_text, **diffy_opts))

  @from = from
  @to = to
end

Instance Attribute Details

#fromObject (readonly)

Returns the value of attribute from.



11
12
13
# File 'lib/diff.rb', line 11

def from
  @from
end

#toObject (readonly)

Returns the value of attribute to.



11
12
13
# File 'lib/diff.rb', line 11

def to
  @to
end