Class: Neo4j::Generators::ModelGenerator

Inherits:
Rails::Generators::NamedBase
  • Object
show all
Includes:
MigrationHelper, SourcePathHelper
Defined in:
lib/rails/generators/neo4j/model/model_generator.rb

Overview

:nodoc:

Instance Method Summary collapse

Methods included from MigrationHelper

#base_migration_file_name, #existing_migration, #migration_file_name, #migration_lookup_at, #migration_template

Instance Method Details

#create_model_fileObject



17
18
19
20
# File 'lib/rails/generators/neo4j/model/model_generator.rb', line 17

def create_model_file
  template 'model.erb', File.join('app/models', class_path, "#{singular_name}.rb")
  migration_template 'migration.erb', 'create_'
end