Class: EventMachine::DnsCache::Socket

Inherits:
EM::Connection
  • Object
show all
Defined in:
lib/em/dns_cache.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#unbind_signallerObject

Returns the value of attribute unbind_signaller.



329
330
331
# File 'lib/em/dns_cache.rb', line 329

def unbind_signaller
  @unbind_signaller
end

Instance Method Details

#receive_data(dg) ⇒ Object



331
332
333
334
335
336
337
338
# File 'lib/em/dns_cache.rb', line 331

def receive_data dg
  m = nil
  begin
    m = Resolv::DNS::Message.decode dg
  rescue
  end
  Request.post(m) if m
end

#unbindObject



340
341
342
# File 'lib/em/dns_cache.rb', line 340

def unbind
  @unbind_signaller.call if @unbind_signaller
end