Class: XDry::MethodPatcher
- Inherits:
-
ItemPatcher
- Object
- ItemPatcher
- XDry::MethodPatcher
- Defined in:
- lib/xdry/patching/item_patchers.rb
Instance Attribute Summary collapse
-
#insertion_point ⇒ Object
readonly
Returns the value of attribute insertion_point.
-
#new_code ⇒ Object
readonly
Returns the value of attribute new_code.
-
#oclass ⇒ Object
readonly
Returns the value of attribute oclass.
Attributes inherited from ItemPatcher
Instance Method Summary collapse
-
#initialize(patcher, oclass, selector, insertion_point, new_code) ⇒ MethodPatcher
constructor
A new instance of MethodPatcher.
Methods inherited from ItemPatcher
Constructor Details
#initialize(patcher, oclass, selector, insertion_point, new_code) ⇒ MethodPatcher
Returns a new instance of MethodPatcher.
53 54 55 56 57 58 59 |
# File 'lib/xdry/patching/item_patchers.rb', line 53 def initialize patcher, oclass, selector, insertion_point, new_code @oclass = oclass @selector = selector @insertion_point = insertion_point @new_code = new_code super(patcher) end |
Instance Attribute Details
#insertion_point ⇒ Object (readonly)
Returns the value of attribute insertion_point.
50 51 52 |
# File 'lib/xdry/patching/item_patchers.rb', line 50 def insertion_point @insertion_point end |
#new_code ⇒ Object (readonly)
Returns the value of attribute new_code.
51 52 53 |
# File 'lib/xdry/patching/item_patchers.rb', line 51 def new_code @new_code end |
#oclass ⇒ Object (readonly)
Returns the value of attribute oclass.
49 50 51 |
# File 'lib/xdry/patching/item_patchers.rb', line 49 def oclass @oclass end |