Method: String#modulize
- Defined in:
- lib/strokedb/core_ext/string.rb
#modulize ⇒ Object
28 29 30 31 |
# File 'lib/strokedb/core_ext/string.rb', line 28 def modulize return '' unless include?('::') && self[0,2] != '::' self.gsub(/^(.+)::(#{demodulize})$/,'\\1') end |