Class: Cmdlet::Case::Title
- Inherits:
-
BaseCmdlet
- Object
- BaseCmdlet
- Cmdlet::Case::Title
- Defined in:
- lib/cmdlet/case/title.rb
Overview
Title: Title case the characters in the given 'string'
Instance Method Summary collapse
-
#call(value) ⇒ String
Value converted to title case.
Methods inherited from BaseCmdlet
Instance Method Details
#call(value) ⇒ String
Returns value converted to title case.
11 12 13 14 15 16 17 18 |
# File 'lib/cmdlet/case/title.rb', line 11 def call(value) tokenizer.parse(value, separator: ' ', preserve_case: true, compress_prefix_numerals: false, compress_suffix_numerals: false) .titleize end |