instance method
demodulize
Ruby on Rails 3.2.22.5
Since v3.0.20Signature
demodulize()
Removes the module part from the constant expression in the string.
"ActiveRecord::CoreExtensions::String::Inflections".demodulize # => "Inflections" "Inflections".demodulize # => "Inflections"
See also deconstantize.
Source
# File activesupport/lib/active_support/core_ext/string/inflections.rb, line 122
def demodulize
ActiveSupport::Inflector.demodulize(self)
end
Defined in activesupport/lib/active_support/core_ext/string/inflections.rb line 122
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in String