Class: Declarative::Option
- Inherits:
-
Object
- Object
- Declarative::Option
- Defined in:
- lib/declarative/option.rb,
lib/declarative/option/version.rb
Constant Summary collapse
- VERSION =
"0.1.0"
Instance Method Summary collapse
Instance Method Details
#call(value, options = {}) ⇒ Object
9 10 11 12 13 14 |
# File 'lib/declarative/option.rb', line 9 def call(value, ={}) return lambda_for_proc(value, ) if value.is_a?(Proc) return lambda_for_symbol(value, ) if value.is_a?(Symbol) return lambda_for_callable(value, ) if callable?(value, ) lambda_for_static(value, ) end |