Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

SrvTransMgr.h

Go to the documentation of this file.
00001 /*
00002  * Dibbler - a portable DHCPv6
00003  *
00004  * authors: Tomasz Mrugalski <thomson@klub.com.pl>
00005  *          Marek Senderski <msend@o2.pl>
00006  *
00007  * released under GNU GPL v2 or later licence
00008  *
00009  * $Id: SrvTransMgr.h,v 1.8 2005/02/01 00:57:36 thomson Exp $
00010  *
00011  * $Log: SrvTransMgr.h,v $
00012  * Revision 1.8  2005/02/01 00:57:36  thomson
00013  * no message
00014  *
00015  * Revision 1.7  2005/01/12 00:10:05  thomson
00016  * Compilation fixes.
00017  *
00018  * Revision 1.6  2005/01/08 16:52:04  thomson
00019  * Relay support implemented.
00020  *
00021  * Revision 1.5  2004/12/07 00:45:10  thomson
00022  * Manager creation unified and cleaned up.
00023  *
00024  * Revision 1.4  2004/09/05 15:27:49  thomson
00025  * Data receive switched from recvfrom to recvmsg, unicast partially supported.
00026  *
00027  * Revision 1.3  2004/09/03 20:58:36  thomson
00028  * *** empty log message ***
00029  *
00030  *
00031  */
00032 
00033 class TSrvTransMgr;
00034 #ifndef SRVTRANSMGR_H
00035 #define SRVTRANSMGR_H
00036 
00037 #include <string>
00038 #include "SmartPtr.h"
00039 #include "Container.h"
00040 #include "Opt.h"
00041 #include "SrvMsg.h"
00042 #include "SrvIfaceMgr.h"
00043 #include "SrvCfgMgr.h"
00044 #include "SrvAddrMgr.h"
00045 
00046 class TSrvTransMgr
00047 {
00048     friend ostream & operator<<(ostream &strum, TSrvTransMgr &x);
00049   public:
00050     TSrvTransMgr(SmartPtr<TSrvIfaceMgr> ifaceMgr,
00051                  SmartPtr<TSrvAddrMgr> addrMgr,
00052                  SmartPtr<TSrvCfgMgr> cfgMgr,
00053                  string xmlFile);
00054     ~TSrvTransMgr();
00055 
00056     bool openSocket(SmartPtr<TSrvCfgIface> confIface);
00057 
00058     long getTimeout();
00059     void relayMsg(SmartPtr<TSrvMsg> msg);
00060     void doDuties();
00061     void dump();
00062 
00063     bool isDone();
00064     void shutdown();
00065     
00066     char * getCtrlAddr();
00067     int    getCtrlIface();
00068     
00069     void setThat(SmartPtr<TSrvTransMgr> that);
00070   private:
00071     string XmlFile;
00072     TContainer< SmartPtr<TSrvMsg> > MsgLst;
00073     bool IsDone;
00074 
00075     SmartPtr<TSrvIfaceMgr> IfaceMgr;
00076     SmartPtr<TSrvTransMgr> That;
00077     SmartPtr<TSrvCfgMgr>  CfgMgr;
00078     SmartPtr<TSrvAddrMgr>  AddrMgr;
00079 
00080     int ctrlIface;
00081     char ctrlAddr[48];
00082 };
00083 
00084 
00085 
00086 #endif
00087 
00088 
00089 

Generated on Wed Mar 16 00:10:29 2005 for Dibbler - a portable DHCPv6 by  doxygen 1.3.9.1