Class: BindingDumper::CoreExt::LocalBindingPatchBuilder
- Inherits:
-
Object
- Object
- BindingDumper::CoreExt::LocalBindingPatchBuilder
- Defined in:
- lib/binding_dumper/core_ext/local_binding_patch_builder.rb
Overview
Class responsible for building patch for local binding
Instance Attribute Summary collapse
-
#undumped ⇒ Object
readonly
Returns the value of attribute undumped.
Instance Method Summary collapse
-
#initialize(undumped) ⇒ LocalBindingPatchBuilder
constructor
A new instance of LocalBindingPatchBuilder.
-
#patch ⇒ Module
Returns module that is ready for patching existing binding.
Constructor Details
#initialize(undumped) ⇒ LocalBindingPatchBuilder
24 25 26 |
# File 'lib/binding_dumper/core_ext/local_binding_patch_builder.rb', line 24 def initialize(undumped) @undumped = undumped end |
Instance Attribute Details
#undumped ⇒ Object (readonly)
Returns the value of attribute undumped.
20 21 22 |
# File 'lib/binding_dumper/core_ext/local_binding_patch_builder.rb', line 20 def undumped @undumped end |
Instance Method Details
#patch ⇒ Module
Returns module that is ready for patching existing binding
32 33 34 35 36 37 38 39 40 41 42 |
# File 'lib/binding_dumper/core_ext/local_binding_patch_builder.rb', line 32 def patch deps = [ file_method_patch, line_method_patch, method_method_patch, eval_method_patch ] Module.new do include *deps end end |