Class: Wamp::MessageHandler::Goodbye

Inherits:
Base
  • Object
show all
Defined in:
lib/wamp/message_handler/goodbye.rb

Overview

send unregister message

Instance Attribute Summary

Attributes inherited from Base

#connection, #message

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from Wamp::MessageHandler::Base

Instance Method Details

#handleObject



13
14
15
16
# File 'lib/wamp/message_handler/goodbye.rb', line 13

def handle
  goodbye = Wampproto::Message::Goodbye.new({}, "wamp.close.goodbye_and_out")
  send_serialized goodbye
end

#send_message(&callback) ⇒ Object



7
8
9
10
11
# File 'lib/wamp/message_handler/goodbye.rb', line 7

def send_message(&callback)
  store[store_key] = { callback: callback }

  send_serialized message
end