Module: LIT::Utils Private
- Defined in:
- lib/lit/utils.rb
Overview
This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.
Defined Under Namespace
Classes: MapHash
Class Method Summary collapse
Class Method Details
.camelize(string) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
7 8 9 |
# File 'lib/lit/utils.rb', line 7 def self.camelize(string) string.to_s.split("_").collect(&:capitalize).join end |
.const_reset(mod, const_name, const_value) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
36 37 38 39 40 41 42 |
# File 'lib/lit/utils.rb', line 36 def self.const_reset(mod, const_name, const_value) if mod.const_defined?(const_name, false) mod.send(:remove_const, const_name) end mod.const_set(const_name, const_value) end |