Class: String
- Inherits:
-
Object
- Object
- String
- Defined in:
- lib/restfulx/configuration.rb
Instance Method Summary collapse
-
#dcfirst ⇒ Object
Down-case first character of a string leaving the rest of it intact.
-
#ucfirst ⇒ Object
Upper-case first character of a string leave the rest of the string intact.
Instance Method Details
#dcfirst ⇒ Object
Down-case first character of a string leaving the rest of it intact
20 21 22 |
# File 'lib/restfulx/configuration.rb', line 20 def dcfirst self[0,1].downcase + self[1..-1] end |
#ucfirst ⇒ Object
Upper-case first character of a string leave the rest of the string intact
15 16 17 |
# File 'lib/restfulx/configuration.rb', line 15 def ucfirst self[0,1].capitalize + self[1..-1] end |