Exception: Machinery::Errors::SystemDescriptionValidationFailed

Inherits:
SystemDescriptionError show all
Defined in:
lib/exceptions.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(errors) ⇒ SystemDescriptionValidationFailed

Returns a new instance of SystemDescriptionValidationFailed.



87
88
89
# File 'lib/exceptions.rb', line 87

def initialize(errors)
  @errors = errors
end

Instance Attribute Details

#errorsObject (readonly)

Returns the value of attribute errors.



84
85
86
# File 'lib/exceptions.rb', line 84

def errors
  @errors
end

#headerObject

Returns the value of attribute header.



85
86
87
# File 'lib/exceptions.rb', line 85

def header
  @header
end

Instance Method Details

#to_sObject



91
92
93
94
95
96
97
98
99
# File 'lib/exceptions.rb', line 91

def to_s
  message = ""
  if @header
    message += header + "\n\n"
  end
  message += @errors.join("\n")
  message += "\n"
  message
end