Class: Async::Signals::Controller::Registration

Inherits:
Object
  • Object
show all
Defined in:
lib/async/signals/controller.rb

Overview

Represents an installed set of signal handlers.

Instance Method Summary collapse

Constructor Details

#initialize(controller, handlers) ⇒ Registration

Initialize the registration.



88
89
90
91
# File 'lib/async/signals/controller.rb', line 88

def initialize(controller, handlers)
	@controller = controller
	@handlers = handlers
end

Instance Method Details

#closeObject

Remove this registration from the controller.



94
95
96
97
98
99
# File 'lib/async/signals/controller.rb', line 94

def close
	if handlers = @handlers
		@handlers = nil
		@controller.remove(self, handlers)
	end
end