Class: Dtn::Streaming::Requests::Admin::SetClientStats

Inherits:
Dtn::Streaming::Request show all
Defined in:
lib/dtn/streaming/requests/admin/set_client_stats.rb

Overview

Request client statistics from IQFeed.

Call this is you want IQFeed to send you a message every second about the status of every connection. Lets you know things like number of subscriptions and if the connection is buffering.

Instance Method Summary collapse

Methods inherited from Dtn::Streaming::Request

#initialize

Constructor Details

This class inherits a constructor from Dtn::Streaming::Request

Instance Method Details

#call(turned_on: true) ⇒ Object



13
14
15
# File 'lib/dtn/streaming/requests/admin/set_client_stats.rb', line 13

def call(turned_on: true, **)
  socket.puts "S,CLIENTSTATS #{turned_on ? "ON" : "OFF"}\r\n"
end