Sha256: 73e17ca407a2e71a0541ac482f4e82c1b9c9cc925d6f1ee2620a1ae9d21f73f2
Contents?: true
Size: 576 Bytes
Versions: 28
Compression:
Stored size: 576 Bytes
Contents
# frozen_string_literal: true module AnyCable module BroadcastAdapters class Base def raw_broadcast(_data) raise NotImplementedError end def broadcast(stream, payload) raw_broadcast({stream: stream, data: payload}.to_json) end def broadcast_command(command, **payload) raw_broadcast({command: command, payload: payload}.to_json) end def announce! logger.info "Broadcasting via #{self.class.name}" end private def logger AnyCable.logger end end end end
Version data entries
28 entries across 28 versions & 2 rubygems