Class: CodeGenerator
- Includes:
- InstanceHelpers
- Defined in:
- lib/code_generator/code_generator.rb
Constant Summary collapse
- TAB =
" "
Instance Attribute Summary collapse
-
#root_dir ⇒ Object
Returns the value of attribute root_dir.
-
#types ⇒ Object
Returns the value of attribute types.
Instance Method Summary collapse
- #generate_self_code ⇒ Object
-
#initialize(types, root_dir) ⇒ CodeGenerator
constructor
A new instance of CodeGenerator.
Methods included from InstanceHelpers
#lib_enum_postfix, #lib_prefix
Constructor Details
#initialize(types, root_dir) ⇒ CodeGenerator
Returns a new instance of CodeGenerator.
13 14 15 16 |
# File 'lib/code_generator/code_generator.rb', line 13 def initialize(types, root_dir) @types = types @root_dir = root_dir end |
Instance Attribute Details
#root_dir ⇒ Object
Returns the value of attribute root_dir.
9 10 11 |
# File 'lib/code_generator/code_generator.rb', line 9 def root_dir @root_dir end |
#types ⇒ Object
Returns the value of attribute types.
8 9 10 |
# File 'lib/code_generator/code_generator.rb', line 8 def types @types end |
Instance Method Details
#generate_self_code ⇒ Object
18 19 20 21 |
# File 'lib/code_generator/code_generator.rb', line 18 def generate_self_code generateModules(types) generateReadme(types) end |