Sha256: 6ca23cd2ce01b5474c6e53cf52f3429f9c7f4f07c725e26cf5d4ec8004ec2c86
Contents?: true
Size: 990 Bytes
Versions: 6
Compression:
Stored size: 990 Bytes
Contents
# frozen_string_literal: true module Sc2 class Connection # Callbacks should be included on your listening class # noinspection RubyUnusedLocalVariable module ConnectionListener # Called when connection established to application # @param connection [Sc2::Connection] # noinspection def on_connected(connection) Sc2.logger.debug { "#{self.class}.#{__method__} #{connection}" } end # Called while waiting on connection to application # @param connection [Sc2::Connection] # noinspection Lint/UnusedMethodArgument def on_connection_waiting(connection) Sc2.logger.debug { "#{self.class}.#{__method__} #{connection}" } end # Called when disconnected from application # @param connection [Sc2::Connection] # noinspection Lint/UnusedMethodArgument def on_disconnect(connection) Sc2.logger.debug { "#{self.class}.#{__method__} #{connection}" } end end end end
Version data entries
6 entries across 6 versions & 1 rubygems