Class: Cmdlet::Case::Snake
- Inherits:
-
BaseCmdlet
- Object
- BaseCmdlet
- Cmdlet::Case::Snake
- Defined in:
- lib/cmdlet/case/snake.rb
Overview
Snake: Snake case the characters in the given 'string'
Instance Method Summary collapse
-
#call(value) ⇒ String
Value converted to snake case.
Methods inherited from BaseCmdlet
Instance Method Details
#call(value) ⇒ String
Returns value converted to snake case.
11 12 13 |
# File 'lib/cmdlet/case/snake.rb', line 11 def call(value) tokenizer.parse(value, separator: '_', forced_separator: true) end |