Parent

Included Modules

Class Index [+]

Quicksearch

MessagePack::RPC::UDPTransport::BasicSocket

Constants

HAVE_DNRL

Attributes

io[R]

Public Class Methods

new(io) click to toggle source
    # File lib/msgpack/rpc/transport/udp.rb, line 34
34:                 def initialize(io)
35:                         io.do_not_reverse_lookup = true if HAVE_DNRL
36:                         super(io)
37:                         @io = io
38:                 end

Public Instance Methods

on_readable() click to toggle source
    # File lib/msgpack/rpc/transport/udp.rb, line 42
42:                 def on_readable
43:                         begin
44:                                 data, addr = @io.recvfrom(64*1024) # FIXME buffer size
45:                         rescue Errno::EAGAIN
46:                                 return
47:                         end
48: 
49:                         # FIXME multiple objects in one message
50:                         obj = MessagePack.unpack(data)
51:                         on_message(obj, addr)
52:                 rescue
53:                         # FIXME log
54:                         return
55:                 end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.