Class: Domain::BadFile

Inherits:
Object
  • Object
show all
Defined in:
lib/plugins/pre_commit/domain/bad_file.rb

Overview

Represents a file with style errors.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, errors) ⇒ BadFile

Instanciate a default bad file.

Parameters:

  • The (String)

    File name

  • The (Array)

    errors



15
16
17
18
# File 'lib/plugins/pre_commit/domain/bad_file.rb', line 15

def initialize(name, errors)
  @name = name
  @errors = errors
end

Instance Attribute Details

#errorsObject (readonly)

Returns the value of attribute errors.



8
9
10
# File 'lib/plugins/pre_commit/domain/bad_file.rb', line 8

def errors
  @errors
end

#nameObject (readonly)

Returns the value of attribute name.



8
9
10
# File 'lib/plugins/pre_commit/domain/bad_file.rb', line 8

def name
  @name
end