Module: Sequel::Plugins::SingularTableNames::ClassMethods
- Defined in:
- lib/sequel/plugins/singular_table_names.rb
Instance Method Summary collapse
-
#implicit_table_name ⇒ Object
Returns the implicit table name for the model class, which is the demodulized, underscored, name of the class.
Instance Method Details
#implicit_table_name ⇒ Object
Returns the implicit table name for the model class, which is the demodulized, underscored, name of the class.
Artist.implicit_table_name # => :artist
Foo::ArtistAlias.implicit_table_name # => :artist_alias
25 26 27 |
# File 'lib/sequel/plugins/singular_table_names.rb', line 25 def implicit_table_name underscore(demodulize(name)).to_sym end |