Class: Net::IRC::AsyncSession
- Inherits:
-
Server::Session
- Object
- Server::Session
- Net::IRC::AsyncSession
- Defined in:
- lib/net/irc/mala.rb
Instance Method Summary collapse
-
#initialize(*args) ⇒ AsyncSession
constructor
A new instance of AsyncSession.
- #on_disconnected ⇒ Object
- #on_new_thread ⇒ Object
- #on_user(m) ⇒ Object
Constructor Details
#initialize(*args) ⇒ AsyncSession
Returns a new instance of AsyncSession.
9 10 11 |
# File 'lib/net/irc/mala.rb', line 9 def initialize(*args) super end |
Instance Method Details
#on_disconnected ⇒ Object
26 27 28 |
# File 'lib/net/irc/mala.rb', line 26 def on_disconnected @streaming_thread.kill rescue nil end |
#on_new_thread ⇒ Object
30 31 32 |
# File 'lib/net/irc/mala.rb', line 30 def on_new_thread raise "not implemented error" end |
#on_user(m) ⇒ Object
13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/net/irc/mala.rb', line 13 def on_user(m) super post server_name, MODE, @nick, "+o" post @prefix, JOIN, main_channel post server_name, MODE, main_channel, "+mto", @nick post server_name, MODE, main_channel, "+q", @nick @streaming_thread = Thread.start do on_new_thread end end |