Class: Yobi::DiffStatistics

Inherits:
FancyHash show all
Defined in:
lib/yobi/repository/diff.rb,
sig/yobi.rbs

Overview

The "statistics" message from a diff run, the final result once the command finishes. Dispatched to Yobi::DiffOutcome#statistics.

Instance Method Summary collapse

Methods inherited from FancyHash

#initialize, #inspect, #pretty_print

Constructor Details

This class inherits a constructor from Yobi::FancyHash

Instance Method Details

#addedYobi::DiffStat

Returns:



135
136
137
# File 'lib/yobi/repository/diff.rb', line 135

def added
  @added ||= DiffStat.new(self["added"] || {})
end

#changed_filesInteger

Returns:

  • (Integer)


130
131
132
# File 'lib/yobi/repository/diff.rb', line 130

def changed_files
  self["changed_files"] || 0
end

#removedYobi::DiffStat

Returns:



140
141
142
# File 'lib/yobi/repository/diff.rb', line 140

def removed
  @removed ||= DiffStat.new(self["removed"] || {})
end

#source_snapshotString?

Returns:

  • (String, nil)


120
121
122
# File 'lib/yobi/repository/diff.rb', line 120

def source_snapshot
  self["source_snapshot"]
end

#target_snapshotString?

Returns:

  • (String, nil)


125
126
127
# File 'lib/yobi/repository/diff.rb', line 125

def target_snapshot
  self["target_snapshot"]
end