Sha256: 91102a588725dc6447ecbad419fca9c31849ab8353fd19ad060747cd59a77671

Contents?: true

Size: 219 Bytes

Versions: 13

Compression:

Stored size: 219 Bytes

Contents

class String
  def lower_camelcase
    str = dup
    str.gsub!(/\/(.?)/) { "::#{$1.upcase}" }
    str.gsub!(/(?:_+|-+)([a-z]|[0-9])/) { $1.upcase }
    str.gsub!(/(\A|\s)([A-Z])/) { $1 + $2.downcase }
    str
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
netsuite-0.8.11 lib/netsuite/core_ext/string/lower_camelcase.rb
netsuite-0.8.10 lib/netsuite/core_ext/string/lower_camelcase.rb
netsuite-0.8.9 lib/netsuite/core_ext/string/lower_camelcase.rb
netsuite-0.8.8 lib/netsuite/core_ext/string/lower_camelcase.rb
netsuite-0.8.7 lib/netsuite/core_ext/string/lower_camelcase.rb
netsuite-0.8.6 lib/netsuite/core_ext/string/lower_camelcase.rb
netsuite-0.8.5 lib/netsuite/core_ext/string/lower_camelcase.rb
netsuite-0.8.4 lib/netsuite/core_ext/string/lower_camelcase.rb
netsuite-0.8.3 lib/netsuite/core_ext/string/lower_camelcase.rb
netsuite-0.8.2 lib/netsuite/core_ext/string/lower_camelcase.rb
netsuite-0.8.1 lib/netsuite/core_ext/string/lower_camelcase.rb
netsuite-0.8.0 lib/netsuite/core_ext/string/lower_camelcase.rb
netsuite-0.7.9 lib/netsuite/core_ext/string/lower_camelcase.rb