Class: Nayati::WorkflowResults::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/nayati/workflow_results/base.rb

Instance Method Summary collapse

Constructor Details

#initializeBase

Returns a new instance of Base.



4
5
6
7
# File 'lib/nayati/workflow_results/base.rb', line 4

def initialize
  @errors = {base: []}.with_indifferent_access
  @data = {}.with_indifferent_access
end

Instance Method Details

#add_base_error(error_message) ⇒ Object



13
14
15
# File 'lib/nayati/workflow_results/base.rb', line 13

def add_base_error(error_message)
  @errors[:base] << error_message
end

#success?Boolean

Returns:

  • (Boolean)


9
10
11
# File 'lib/nayati/workflow_results/base.rb', line 9

def success?
  !@errors.any?
end