Class: Klomp::Frames::Unsubscribe

Inherits:
Frame
  • Object
show all
Defined in:
lib/klomp/frames.rb

Instance Method Summary collapse

Methods inherited from Frame

#[], #[]=, #body, #body=, #dump_headers, #headers, #name, #new_headers, #stringify_headers, #to_s

Constructor Details

#initialize(queue, hdrs = {}) ⇒ Unsubscribe

Returns a new instance of Unsubscribe.



114
115
116
117
# File 'lib/klomp/frames.rb', line 114

def initialize(queue, hdrs = {})
  headers['id'] = queue
  headers.update(stringify_headers(hdrs).reject { |k,v| %w(id).include? k })
end