Class: Jets::Cfn::Resource::Nested::Base
- Defined in:
- lib/jets/cfn/resource/nested/base.rb
Direct Known Subclasses
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Base
constructor
A new instance of Base.
- #outputs ⇒ Object
-
#template_filename ⇒ Object
Examples: api-gateway.yml api-resources-1.yml api-methods-1.yml app-posts_controller.yml shared-custom.yml.
- #template_url ⇒ Object
Methods inherited from Base
#attributes, #logical_id, #parameters, #permission, #properties, #replacements, #replacer, #standarize, #template, truncate_id, #type
Methods included from Util::Camelize
Constructor Details
#initialize(options = {}) ⇒ Base
Returns a new instance of Base.
8 9 10 |
# File 'lib/jets/cfn/resource/nested/base.rb', line 8 def initialize(={}) @options = # not used yet end |
Instance Method Details
#outputs ⇒ Object
12 13 14 15 16 |
# File 'lib/jets/cfn/resource/nested/base.rb', line 12 def outputs { logical_id => "!Ref #{logical_id}", } end |
#template_filename ⇒ Object
Examples:
api-gateway.yml
api-resources-1.yml
api-methods-1.yml
app-posts_controller.yml
shared-custom.yml
29 30 31 32 33 34 35 36 |
# File 'lib/jets/cfn/resource/nested/base.rb', line 29 def template_filename filename = if @path # AppClass, Authorizer, Shared @path.sub("#{Jets::Names.templates_folder}/", '').gsub('/','-').sub('.yml', '') else self.class.name.to_s.sub(/.*Nested::/,'').underscore.gsub('/','-').dasherize end [filename, @page_number].compact.join('-') + '.yml' end |