Class: SellObject::FormatterProxy
- Inherits:
-
Object
- Object
- SellObject::FormatterProxy
- Defined in:
- lib/sell_object/formatter_proxy.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#target ⇒ Object
Returns the value of attribute target.
Instance Method Summary collapse
-
#initialize(target_object) ⇒ FormatterProxy
constructor
A new instance of FormatterProxy.
Constructor Details
#initialize(target_object) ⇒ FormatterProxy
Returns a new instance of FormatterProxy.
5 6 7 |
# File 'lib/sell_object/formatter_proxy.rb', line 5 def initialize(target_object) self.target = target_object end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args, &block) ⇒ Object (private)
11 12 13 |
# File 'lib/sell_object/formatter_proxy.rb', line 11 def method_missing(method, *args, &block) target.send(args.first).to_s end |
Instance Attribute Details
#target ⇒ Object
Returns the value of attribute target.
3 4 5 |
# File 'lib/sell_object/formatter_proxy.rb', line 3 def target @target end |