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.



105
106
107
# File 'lib/exceptions.rb', line 105

def initialize(errors)
  @errors = errors
end

Instance Attribute Details

#errorsObject (readonly)

Returns the value of attribute errors.



102
103
104
# File 'lib/exceptions.rb', line 102

def errors
  @errors
end

#headerObject

Returns the value of attribute header.



103
104
105
# File 'lib/exceptions.rb', line 103

def header
  @header
end

Instance Method Details

#to_sObject



109
110
111
112
113
114
115
116
117
# File 'lib/exceptions.rb', line 109

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