diff options
author | Tom Gilbert <tom@linuxbrit.co.uk> | 2005-07-27 16:32:32 +0000 |
---|---|---|
committer | Tom Gilbert <tom@linuxbrit.co.uk> | 2005-07-27 16:32:32 +0000 |
commit | 2a96c9198c1f6e13407d0999083f6ce5e0bc06fa (patch) | |
tree | b3b9247d275d9b554665bc22884104d266d2e757 /rbot/channel.rb | |
parent | 21949774b91eaec6ecde4eaa8ad121e2c0a36b87 (diff) |
move rbot into lib - still rearranging for packaging/installation
Diffstat (limited to 'rbot/channel.rb')
-rw-r--r-- | rbot/channel.rb | 54 |
1 files changed, 0 insertions, 54 deletions
diff --git a/rbot/channel.rb b/rbot/channel.rb deleted file mode 100644 index edd206bf..00000000 --- a/rbot/channel.rb +++ /dev/null @@ -1,54 +0,0 @@ -module Irc - - # class to store IRC channel data (users, topic, per-channel configurations) - class IRCChannel - # name of channel - attr_reader :name - - # current channel topic - attr_reader :topic - - # hash containing users currently in the channel - attr_accessor :users - - # if true, bot won't talk in this channel - attr_accessor :quiet - - # name:: channel name - # create a new IRCChannel - def initialize(name) - @name = name - @users = Hash.new - @quiet = false - @topic = Topic.new - end - - # eg @bot.channels[chan].topic = topic - def topic=(name) - @topic.name = name - end - - # class to store IRC channel topic information - class Topic - # topic name - attr_accessor :name - - # timestamp - attr_accessor :timestamp - - # topic set by - attr_accessor :by - - def initialize - @name = "" - end - - # when called like "puts @bots.channels[chan].topic" - def to_s - @name - end - end - - end - -end |