Class: BusinessFlow::DSL::ParameterObject

Inherits:
Object
  • Object
show all
Defined in:
lib/business_flow/dsl.rb

Overview

Manage logic around input parameters

Instance Method Summary collapse

Constructor Details

#initialize(parameters) ⇒ ParameterObject

Returns a new instance of ParameterObject.



385
386
387
# File 'lib/business_flow/dsl.rb', line 385

def initialize(parameters)
  @parameters = parameters
end

Instance Method Details

#fetch(key) ⇒ Object



389
390
391
392
393
# File 'lib/business_flow/dsl.rb', line 389

def fetch(key)
  value = inner_fetch(key)
  return yield if !value && block_given?
  value
end

#to_sObject



395
396
397
# File 'lib/business_flow/dsl.rb', line 395

def to_s
  @parameters.to_s
end