class Cfer::Core::Stack

Public Instance Methods

output(name, value, options = {}) click to toggle source
# File lib/stax/cfer.rb, line 26
def output(name, value, options = {})
  opt = options.each_with_object({}) { |(k,v),h| h[k.to_s.capitalize] = v } # capitalize all keys
  export = opt.has_key?('Export') ? {'Name' => opt['Export']} : nil
  self[:Outputs][name] = opt.merge('Value' => value, 'Export' => export).compact
end