Class: Simmer::Specification::Act::Params

Inherits:
Object
  • Object
show all
Defined in:
lib/simmer/specification/act/params.rb

Overview

Understands how to compile a list of files and key value pairs for Pdi::Spoon consumption.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(files: {}, keys: {}) ⇒ Params

Returns a new instance of Params.



20
21
22
23
24
25
26
# File 'lib/simmer/specification/act/params.rb', line 20

def initialize(files: {}, keys: {})
  @files     = files || {}
  @keys      = keys || {}
  @evaluator = Util::Evaluator.new

  freeze
end

Instance Attribute Details

#filesObject (readonly)

Returns the value of attribute files.



18
19
20
# File 'lib/simmer/specification/act/params.rb', line 18

def files
  @files
end

#keysObject (readonly)

Returns the value of attribute keys.



18
19
20
# File 'lib/simmer/specification/act/params.rb', line 18

def keys
  @keys
end

Instance Method Details

#compile(files_path, config = {}) ⇒ Object



28
29
30
# File 'lib/simmer/specification/act/params.rb', line 28

def compile(files_path, config = {})
  compiled_file_params(files_path, config).merge(compiled_key_params(config))
end