Class: Wamp::MessageHandler::Invocation
- Inherits:
-
Base
- Object
- Base
- Wamp::MessageHandler::Invocation
show all
- Defined in:
- lib/wamp/message_handler/invocation.rb
Overview
Instance Attribute Summary
Attributes inherited from Base
#connection, #message
Instance Method Summary
collapse
Methods inherited from Base
#initialize, #send_message
Instance Method Details
#alt_store_key ⇒ Object
14
15
16
|
# File 'lib/wamp/message_handler/invocation.rb', line 14
def alt_store_key
"registration_#{message.registration_id}"
end
|
#handle ⇒ Object
7
8
9
10
11
12
|
# File 'lib/wamp/message_handler/invocation.rb', line 7
def handle
connection.session.receive_message(message)
data = store.fetch(alt_store_key)
send_yield_message data.fetch(:handler)
end
|
#invocation_response ⇒ Object
18
19
20
21
22
23
|
# File 'lib/wamp/message_handler/invocation.rb', line 18
def invocation_response
Type::Invocation.new(args: message.args, kwargs: message.kwargs, details: message.details).tap do |invocation|
invocation.connection = connection
invocation.request_id = message.request_id
end
end
|