lib/rupnp/event.rb in rupnp-0.2.1 vs lib/rupnp/event.rb in rupnp-0.2.2

- old
+ new

@@ -7,12 +7,16 @@ # Get service ID # @return [Integer] attr_reader :sid + # @param [String] event_suburl Event subscription URL + # @param [String] callback_url Callback URL to receive events # @param [#to_i] sid # @param [Integer] timeout for event (in seconds) - def initialize(sid, timeout) + def initialize(event_suburl, callback_url, sid, timeout) + super() + @event_suburl = event_suburl @sid, @timeout = sid, timeout @timeout_timer = EM.add_timer(@timeout) { self << :timeout } end