Class: ShutdownHook

Inherits:
Object show all
Defined in:
lib/shutdown_kill.rb

Instance Method Summary collapse

Constructor Details

#initialize(&block) ⇒ ShutdownHook

Returns a new instance of ShutdownHook.



4
5
6
7
# File 'lib/shutdown_kill.rb', line 4

def initialize( &block)
	super()
	@block=block
end

Instance Method Details

#runObject



8
9
10
# File 'lib/shutdown_kill.rb', line 8

def run
    @block[]
end