Class: Kanji::Generators::Type
- Inherits:
-
AbstractGenerator
- Object
- AbstractGenerator
- Kanji::Generators::Type
- Defined in:
- lib/kanji/generators/type.rb
Instance Method Summary collapse
-
#initialize(name, attributes) ⇒ Type
constructor
A new instance of Type.
- #populate_templates ⇒ Object
Methods inherited from AbstractGenerator
Constructor Details
#initialize(name, attributes) ⇒ Type
Returns a new instance of Type.
8 9 10 11 12 |
# File 'lib/kanji/generators/type.rb', line 8 def initialize(name, attributes) @name = name @attributes = attributes.map { |attr| attr.split(":") } super(destination) end |
Instance Method Details
#populate_templates ⇒ Object
14 15 16 17 18 19 |
# File 'lib/kanji/generators/type.rb', line 14 def populate_templates add_type add_repository add_mutations add_migration end |