Class: Stomper::Sockets::TCP
- Inherits:
-
TCPSocket
- Object
- TCPSocket
- Stomper::Sockets::TCP
- Defined in:
- lib/stomper/sockets.rb
Overview
A wrapper for an TCP Socket that tidies up the specifics so our Connection library isn’t troubled by them.
Instance Method Summary collapse
-
#initialize(host, port) ⇒ TCP
constructor
Create a new TCP connection to
host
onport
.
Constructor Details
#initialize(host, port) ⇒ TCP
Create a new Stomper::Sockets::TCP connection to host
on port
.
70 71 72 73 |
# File 'lib/stomper/sockets.rb', line 70 def initialize(host, port) @socket = TCPSocket.new(host, port) super(@socket) end |