Class: RemoteExec::Base
- Inherits:
-
Object
- Object
- RemoteExec::Base
- Extended by:
- RubyHooks::InstanceHooks
- Defined in:
- lib/remote-exec/base.rb
Overview
Define minimal interface for execution handlers
Instance Method Summary collapse
-
#initialize ⇒ Base
constructor
standard in place handler that ensures shutdown is called.
-
#shutdown ⇒ Object
minimal handler for shutdown.
Constructor Details
#initialize ⇒ Base
standard in place handler that ensures shutdown is called
55 56 57 58 59 60 61 62 63 |
# File 'lib/remote-exec/base.rb', line 55 def initialize if block_given? begin yield self ensure shutdown end end end |
Instance Method Details
#shutdown ⇒ Object
minimal handler for shutdown
66 67 68 |
# File 'lib/remote-exec/base.rb', line 66 def shutdown before_shutdown.changed_and_notify(self) end |