Class: OnesnooperServer::Datagram

Inherits:
Object
  • Object
show all
Defined in:
lib/onesnooper_server/datagram.rb

Overview

Base class for all datagram processing classes. Defines required stub methods. No functionality is implemented here.

Instance Method Summary collapse

Constructor Details

#initialize(params = {}) ⇒ Datagram

Initializes class instances.


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

def initialize(params = {})
  @params = params
end

Instance Method Details

#run(deferred_callback) ⇒ Object

Runs datagram processing for the chosen datagram type.


15
16
17
# File 'lib/onesnooper_server/datagram.rb', line 15

def run(deferred_callback)
  fail "This method needs to be implemented in subclasses"
end