Class: ESM::Websocket::Connection::Overseer
- Inherits:
-
Object
- Object
- ESM::Websocket::Connection::Overseer
- Defined in:
- lib/esm/websocket/connection/overseer.rb
Instance Method Summary collapse
- #add_to_lobby(connection) ⇒ Object
-
#initialize ⇒ Overseer
constructor
A new instance of Overseer.
Constructor Details
#initialize ⇒ Overseer
Returns a new instance of Overseer.
7 8 9 10 11 12 |
# File 'lib/esm/websocket/connection/overseer.rb', line 7 def initialize @queue = [] @mutex = Mutex.new oversee! end |
Instance Method Details
#add_to_lobby(connection) ⇒ Object
14 15 16 |
# File 'lib/esm/websocket/connection/overseer.rb', line 14 def add_to_lobby(connection) @queue << connection end |