Method: ActionCable::Connection::ClientSocket#transmit

Defined in:
actioncable/lib/action_cable/connection/client_socket.rb

#transmit(message) ⇒ Object



82
83
84
85
86
87
88
89
90
# File 'actioncable/lib/action_cable/connection/client_socket.rb', line 82

def transmit(message)
  return false if @ready_state > OPEN
  case message
  when Numeric then @driver.text(message.to_s)
  when String  then @driver.text(message)
  when Array   then @driver.binary(message)
  else false
  end
end