Module: Constant::Define
- Defined in:
- lib/constant/define.rb
Class Method Summary collapse
Class Method Details
.call(constant_name, destination_constant, constant_value = nil) ⇒ Object
3 4 5 6 7 |
# File 'lib/constant/define.rb', line 3 def self.call(constant_name, destination_constant, constant_value=nil) constant_value = ::Module.new if constant_value.nil? destination_constant.const_set(constant_name, constant_value) constant_value end |