Class: Contrast::Api::Communication::UnixSocket
- Includes:
- Socket
- Defined in:
- lib/contrast/api/communication/unix_socket.rb
Overview
Implements a UNIX domain socket to connect to the Contrast Service.
Constant Summary
Constants included from Socket
Instance Attribute Summary collapse
-
#path ⇒ Object
readonly
Returns the value of attribute path.
Instance Method Summary collapse
-
#initialize(path) ⇒ UnixSocket
constructor
Create the socket.
- #new_socket ⇒ Object
Methods included from Socket
Constructor Details
#initialize(path) ⇒ UnixSocket
Create the socket
17 18 19 |
# File 'lib/contrast/api/communication/unix_socket.rb', line 17 def initialize path @path = path end |
Instance Attribute Details
#path ⇒ Object (readonly)
Returns the value of attribute path.
13 14 15 |
# File 'lib/contrast/api/communication/unix_socket.rb', line 13 def path @path end |
Instance Method Details
#new_socket ⇒ Object
21 22 23 |
# File 'lib/contrast/api/communication/unix_socket.rb', line 21 def new_socket ::UNIXSocket.new(path) end |