Class: Blackhole::HoleConnection

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#holeObject

Returns the value of attribute hole.



8
9
10
# File 'lib/hole.rb', line 8

def hole
  @hole
end

Instance Method Details

#receive_data(data) ⇒ Object



10
11
12
13
14
# File 'lib/hole.rb', line 10

def receive_data(data)
  Blackhole.logger.debug "UDP packet: '#{data}'"
  # store to memory
  hole.store!(data)
end