Sha256: c8f4e3954df86f3c364bf6ce4066ba094201343ba9190d7f1f084bec656534c1
Contents?: true
Size: 802 Bytes
Versions: 3
Compression:
Stored size: 802 Bytes
Contents
require 'chef_metal/action_handler' module ChefMetal class AddPrefixActionHandler extend Forwardable def initialize(action_handler, prefix) @action_handler = action_handler @prefix = prefix end attr_reader :action_handler attr_reader :prefix def_delegators :@action_handler, :should_perform_actions, :updated!, :debug_name, :open_stream # TODO remove this as soon as HUMANLY POSSIBLE (looking at you, chef-metal-fog) def_delegators :@action_handler, :new_resource def performed_action(description) action_handler.performed_action(Array(description).map { |d| "#{prefix}#{d}" }) end def perform_action(description, &block) action_handler.perform_action(Array(description).map { |d| "#{prefix}#{d}" }, &block) end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
chef-metal-0.10.2 | lib/chef_metal/add_prefix_action_handler.rb |
chef-metal-0.10.1 | lib/chef_metal/add_prefix_action_handler.rb |
chef-metal-0.10 | lib/chef_metal/add_prefix_action_handler.rb |