Class: Symbol
- Inherits:
-
Object
- Object
- Symbol
- Defined in:
- lib/helpers/symbol.rb
Overview
:nodoc:
Instance Method Summary collapse
-
#to_underscore_sym ⇒ Object
From Carl Youngblood’s excellent SBN gem: sbn.rubyforge.org/.
Instance Method Details
#to_underscore_sym ⇒ Object
From Carl Youngblood’s excellent SBN gem: sbn.rubyforge.org/
3 4 5 |
# File 'lib/helpers/symbol.rb', line 3 def to_underscore_sym self.to_s.titleize.gsub(/\s+/, '').underscore.to_sym end |