Class: Blufin::YmlError

Inherits:
Object
  • Object
show all
Defined in:
lib/core/error_handling/yml_error.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(type, file, section, field, message) ⇒ YmlError

Returns a new instance of YmlError.



7
8
9
10
11
12
13
14
15
16
17
# File 'lib/core/error_handling/yml_error.rb', line 7

def initialize(type, file, section, field, message)

    message = [message] if message.is_a?(String)

    @type    = type
    @file    = file
    @section = section
    @field   = field
    @message = message

end

Instance Attribute Details

#fieldObject

Returns the value of attribute field.



5
6
7
# File 'lib/core/error_handling/yml_error.rb', line 5

def field
  @field
end

#fileObject

Returns the value of attribute file.



5
6
7
# File 'lib/core/error_handling/yml_error.rb', line 5

def file
  @file
end

#messageObject

Returns the value of attribute message.



5
6
7
# File 'lib/core/error_handling/yml_error.rb', line 5

def message
  @message
end

#sectionObject

Returns the value of attribute section.



5
6
7
# File 'lib/core/error_handling/yml_error.rb', line 5

def section
  @section
end

#typeObject

Returns the value of attribute type.



5
6
7
# File 'lib/core/error_handling/yml_error.rb', line 5

def type
  @type
end