Class: EasyCommand::Failure
Instance Method Summary
collapse
Methods inherited from Result
#initialize, #on_failure, #on_success, #result
#[]
Methods included from Chainable
included, #then
Instance Method Details
#errors ⇒ Object
46
47
48
49
50
51
|
# File 'lib/easy_command/result.rb', line 46
def errors
@_errors ||=
EasyCommand::Errors.new.tap do |errors|
errors.add(:result, :failure)
end
end
|
#failure? ⇒ Boolean
39
|
# File 'lib/easy_command/result.rb', line 39
def failure?; true; end
|
#success? ⇒ Boolean
38
|
# File 'lib/easy_command/result.rb', line 38
def success?; false; end
|
#with_errors(errors) ⇒ Object
41
42
43
44
|
# File 'lib/easy_command/result.rb', line 41
def with_errors(errors)
@_errors = errors
self
end
|