Dibbler - a portable DHCPv6  1.0.2RC1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
ClntOptTA.h
Go to the documentation of this file.
1 /*
2  * Dibbler - a portable DHCPv6
3  *
4  * authors: Tomasz Mrugalski <thomson@klub.com.pl>
5  * Marek Senderski <msend@o2.pl>
6  *
7  * released under GNU GPL v2 only licence
8  *
9  */
10 
11 class TOptTA;
12 class TMsg;
13 
14 #ifndef CLNTIA_TA_H
15 #define CLNTIA_TA_H
16 
17 #include "OptTA.h"
18 #include "OptIAAddress.h"
19 #include "IPv6Addr.h"
20 #include "Msg.h"
21 
22 class TClntOptTA : public TOptTA
23 {
24  public:
25  TClntOptTA(unsigned int iaid, TMsg* parent);
26  TClntOptTA(char * buf, int bufsize, TMsg* parent);
27  TClntOptTA(SPtr<TAddrIA> ta, TMsg* parent);
28  ~TClntOptTA();
29 
30  bool doDuties();
31  int getStatusCode();
32 
35  void firstAddr();
36  int countAddr();
37  bool isValid() const;
38  void setIface(int iface); // used to override interface (e.g. when msg is received via loopback)
39 
40  void setContext(int iface, SPtr<TIPv6Addr> clntAddr);
41 
42  private:
43  void releaseAddr(long IAID, SPtr<TIPv6Addr> addr );
44 
46  int Iface;
47 };
48 
49 
50 #endif /* CLNTIA_TA_H */
51