Class: Calyx::Modifier
- Inherits:
-
Object
- Object
- Calyx::Modifier
- Defined in:
- lib/calyx/modifier.rb
Instance Method Summary collapse
Instance Method Details
#extend_with(name) ⇒ Object
3 4 5 |
# File 'lib/calyx/modifier.rb', line 3 def extend_with(name) extend name end |
#transform(name, value) ⇒ Object
7 8 9 10 11 12 13 14 15 |
# File 'lib/calyx/modifier.rb', line 7 def transform(name, value) if respond_to?(name) send(name, value) elsif value.respond_to?(name) value.send(name) else value end end |