Class: DevSystem::SimpleGenerator::UnitHelper
- Inherits:
-
Object
- Object
- DevSystem::SimpleGenerator::UnitHelper
- Defined in:
- lib/dev_system/sub/generator/generators/simple_generator.rb
Overview
helper classes
Instance Method Summary collapse
- #section(name, section = {}) ⇒ Object
- #sections ⇒ Object
- #view(name, view = {}) ⇒ Object
- #views ⇒ Object
Instance Method Details
#section(name, section = {}) ⇒ Object
121 122 123 124 |
# File 'lib/dev_system/sub/generator/generators/simple_generator.rb', line 121 def section name, section = {} sections << section section[:name] = name end |
#sections ⇒ Object
133 134 135 |
# File 'lib/dev_system/sub/generator/generators/simple_generator.rb', line 133 def sections @sections ||= [] end |
#view(name, view = {}) ⇒ Object
126 127 128 129 130 131 |
# File 'lib/dev_system/sub/generator/generators/simple_generator.rb', line 126 def view name, view = {} views << view view[:name] = name view[:key] ||= name view[:format] ||= :rb end |
#views ⇒ Object
137 138 139 |
# File 'lib/dev_system/sub/generator/generators/simple_generator.rb', line 137 def views @views ||= [] end |