Class: CfFactory::CfCloudFormationCommands
- Inherits:
-
Object
- Object
- CfFactory::CfCloudFormationCommands
- Includes:
- CfInner
- Defined in:
- lib/cf_factory/cloudformation/cf_cloudformation_commands.rb
Instance Method Summary collapse
- #additional_indent ⇒ Object
- #get_cf_attributes ⇒ Object
-
#initialize(commands) ⇒ CfCloudFormationCommands
constructor
A new instance of CfCloudFormationCommands.
Methods included from CfInner
#generate, #generate_name, #hash_to_string, #set_quotes
Constructor Details
#initialize(commands) ⇒ CfCloudFormationCommands
Returns a new instance of CfCloudFormationCommands.
9 10 11 12 |
# File 'lib/cf_factory/cloudformation/cf_cloudformation_commands.rb', line 9 def initialize(commands) @commands = commands @additional_indent = 4 end |
Instance Method Details
#additional_indent ⇒ Object
14 15 16 |
# File 'lib/cf_factory/cloudformation/cf_cloudformation_commands.rb', line 14 def additional_indent @additional_indent += 2 end |
#get_cf_attributes ⇒ Object
18 19 20 21 22 23 24 |
# File 'lib/cf_factory/cloudformation/cf_cloudformation_commands.rb', line 18 def get_cf_attributes result = {} @commands.each() {|command| result[command.get_name] = command.generate } result end |