Class: Rails::Generators::GeneratedAttribute

Inherits:
Object
  • Object
show all
Defined in:
lib/generators/toystore.rb

Instance Method Summary collapse

Instance Method Details

#type_classObject

Override type_class to return correct for uuid and automatically camel case all other types.



54
55
56
57
# File 'lib/generators/toystore.rb', line 54

def type_class
  return 'SimpleUUID::UUID' if type.to_s == 'uuid'
  return type.to_s.camelcase
end