Class: Git::DirstatEntry

Inherits:
Data
  • Object
show all
Defined in:
lib/git/dirstat_info.rb

Overview

Immutable value object representing a single directory's contribution to a diff

Examples:

info = Git::DirstatEntry.new(directory: 'lib/commands/', percentage: 45.2)
info.directory   #=> "lib/commands/"
info.percentage  #=> 45.2

Instance Attribute Summary collapse

Instance Attribute Details

#directoryObject (readonly)

Returns the value of attribute directory

Returns:

  • (Object)

    the current value of directory



19
# File 'lib/git/dirstat_info.rb', line 19

DirstatEntry = Data.define(:directory, :percentage)

#percentageObject (readonly)

Returns the value of attribute percentage

Returns:

  • (Object)

    the current value of percentage



19
# File 'lib/git/dirstat_info.rb', line 19

DirstatEntry = Data.define(:directory, :percentage)