[project @ 2004-04-28 03:33:52 by unknown_lamer]
[clinton/bobotpp.git] / source / DCCConnection.H
index 31c9e15..8049f15 100644 (file)
@@ -1,6 +1,6 @@
 // DCCConnection.H  -*- C++ -*-
 // Copyright (c) 1998 Etienne BERNARD
-// Copyright (c) 2002 Clinton Ebadi
+// Copyright (c) 2002,2003 Clinton Ebadi
 
 // This program is free software; you can redistribute it and/or modify
 // it under the terms of the GNU General Public License as published by
@@ -29,24 +29,34 @@ class DCCPerson;
 class UserCommands;
 
 class DCCConnection : public Connection {
+protected:
   Bot *bot;
   String nuh;
   std::time_t lastSpoken;
   bool autoRemove;
+  DCCConnection (unsigned long, int);
 
 public:
   DCCConnection(Bot *, String, unsigned long, int);
 
-  bool connect();
-  bool handleInput();
+  virtual bool connect()=0;
+  virtual bool handleInput()=0;
 
-  void sendNotice(String);
+  virtual void sendNotice(String)=0;
 
-  friend class Bot;
-  friend class DCCPerson;
-  friend class DCCParser;
-  friend class UserCommands;
-  friend class DCCManager;
+  // Accessors
+  virtual Bot* get_bot () const { return bot; };
+  virtual std::time_t get_lastSpoken () const { return lastSpoken; };
+  virtual bool get_autoRemove () const { return autoRemove; };
+  virtual String get_nuh () const { return nuh;};
+  // Setters
+  virtual void set_autoRemove (bool new_ar) { autoRemove = new_ar;};
+
+  //  friend class Bot;
+  //  friend class DCCPerson;
+  //  friend class DCCParser;
+  //  friend class UserCommands;
+  //  friend class DCCManager;
 };
 
 #endif