Represents a single remote connection found via ActionCable.server.remote_connections.where(*)
. Exists solely for the purpose of calling disconnect
on that connection.
Namespace
Class
Methods
Attributes
[R] | server |
Class Public methods
new(server, ids)
📝 Source code
# File actioncable/lib/action_cable/remote_connections.rb, line 41
def initialize(server, ids)
@server = server
set_identifier_instance_vars(ids)
end
🔎 See on GitHub
Instance Public methods
disconnect()
Uses the internal channel to disconnect the connection.
📝 Source code
# File actioncable/lib/action_cable/remote_connections.rb, line 47
def disconnect
server.broadcast internal_channel, { type: "disconnect" }
end
🔎 See on GitHub