Class: ConfigTemplates::Collections::Templates
- Inherits:
-
Object
- Object
- ConfigTemplates::Collections::Templates
- Defined in:
- lib/config_templates/collections/templates.rb
Instance Method Summary collapse
- #find_all ⇒ Object
-
#initialize(config, locator) ⇒ Templates
constructor
A new instance of Templates.
Constructor Details
#initialize(config, locator) ⇒ Templates
Returns a new instance of Templates.
5 6 7 8 |
# File 'lib/config_templates/collections/templates.rb', line 5 def initialize(config, locator) @config = config @locator = locator end |
Instance Method Details
#find_all ⇒ Object
10 11 12 13 14 |
# File 'lib/config_templates/collections/templates.rb', line 10 def find_all @locator.templates.map do |path| ::ConfigTemplates::Models::Template.new path, @config end end |