Class: Pikuri::Finalizers::Closer
- Inherits:
-
Struct
- Object
- Struct
- Pikuri::Finalizers::Closer
- Defined in:
- lib/pikuri/finalizers.rb
Overview
Adapts a teardown block to the #close protocol, so a block and a
closeable share one registry.
Instance Attribute Summary collapse
-
#block ⇒ Object
Returns the value of attribute block.
Instance Method Summary collapse
Instance Attribute Details
#block ⇒ Object
Returns the value of attribute block
42 43 44 |
# File 'lib/pikuri/finalizers.rb', line 42 def block @block end |
Instance Method Details
#close ⇒ void
This method returns an undefined value.
44 45 46 |
# File 'lib/pikuri/finalizers.rb', line 44 def close block.call end |