Class: String
Instance Method Summary collapse
-
#classify ⇒ Object
.….….….….….….….….….….….….….….….….….….….….….….….….…..
-
#humanize ⇒ Object
.….….….….….….….….….….….….….….….….….….….….….….….….…..
Instance Method Details
#classify ⇒ Object
.….….….….….….….….….….….….….….….….….….….….….….….….…..
5 6 7 |
# File 'lib/agent_xmpp/patches/string.rb', line 5 def classify split('_').collect{|s| s.capitalize}.join end |
#humanize ⇒ Object
.….….….….….….….….….….….….….….….….….….….….….….….….…..
10 11 12 |
# File 'lib/agent_xmpp/patches/string.rb', line 10 def humanize gsub(/_/, ' ') end |