LEFT | RIGHT |
1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ | 1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ |
2 /* | 2 /* |
3 * Copyright (c) 2007 INRIA | 3 * Copyright (c) 2007 INRIA |
4 * | 4 * |
5 * This program is free software; you can redistribute it and/or modify | 5 * This program is free software; you can redistribute it and/or modify |
6 * it under the terms of the GNU General Public License version 2 as | 6 * it under the terms of the GNU General Public License version 2 as |
7 * published by the Free Software Foundation; | 7 * published by the Free Software Foundation; |
8 * | 8 * |
9 * This program is distributed in the hope that it will be useful, | 9 * This program is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 10 matching lines...) Expand all Loading... |
21 #define UDP_SOCKET_IMPL_H | 21 #define UDP_SOCKET_IMPL_H |
22 | 22 |
23 #include <stdint.h> | 23 #include <stdint.h> |
24 #include <queue> | 24 #include <queue> |
25 #include "ns3/callback.h" | 25 #include "ns3/callback.h" |
26 #include "ns3/traced-callback.h" | 26 #include "ns3/traced-callback.h" |
27 #include "ns3/socket.h" | 27 #include "ns3/socket.h" |
28 #include "ns3/ptr.h" | 28 #include "ns3/ptr.h" |
29 #include "ns3/ipv4-address.h" | 29 #include "ns3/ipv4-address.h" |
30 #include "ns3/udp-socket.h" | 30 #include "ns3/udp-socket.h" |
| 31 #include "ns3/ipv4-interface.h" |
31 #include "icmpv4.h" | 32 #include "icmpv4.h" |
32 | 33 |
33 namespace ns3 { | 34 namespace ns3 { |
34 | 35 |
35 class Ipv4EndPoint; | 36 class Ipv4EndPoint; |
36 class Node; | 37 class Node; |
37 class Packet; | 38 class Packet; |
38 class UdpL4Protocol; | 39 class UdpL4Protocol; |
39 | 40 |
40 /** | 41 /** |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
91 virtual int32_t GetIpMulticastIf (void) const; | 92 virtual int32_t GetIpMulticastIf (void) const; |
92 virtual void SetIpMulticastLoop (bool loop); | 93 virtual void SetIpMulticastLoop (bool loop); |
93 virtual bool GetIpMulticastLoop (void) const; | 94 virtual bool GetIpMulticastLoop (void) const; |
94 virtual void SetMtuDiscover (bool discover); | 95 virtual void SetMtuDiscover (bool discover); |
95 virtual bool GetMtuDiscover (void) const; | 96 virtual bool GetMtuDiscover (void) const; |
96 | 97 |
97 | 98 |
98 friend class UdpSocketFactory; | 99 friend class UdpSocketFactory; |
99 // invoked by Udp class | 100 // invoked by Udp class |
100 int FinishBind (void); | 101 int FinishBind (void); |
101 void ForwardUp (Ptr<Packet> p, Ipv4Address saddr, Ipv4Address daddr, uint16_t
port,· | 102 void ForwardUp (Ptr<Packet> p, Ipv4Header header, uint16_t port,· |
102 Ptr<NetDevice> device); | 103 Ptr<Ipv4Interface> incomingInterface); |
103 void Destroy (void); | 104 void Destroy (void); |
104 int DoSend (Ptr<Packet> p); | 105 int DoSend (Ptr<Packet> p); |
105 int DoSendTo (Ptr<Packet> p, const Address &daddr); | 106 int DoSendTo (Ptr<Packet> p, const Address &daddr); |
106 int DoSendTo (Ptr<Packet> p, Ipv4Address daddr, uint16_t dport); | 107 int DoSendTo (Ptr<Packet> p, Ipv4Address daddr, uint16_t dport); |
107 void ForwardIcmp (Ipv4Address icmpSource, uint8_t icmpTtl,· | 108 void ForwardIcmp (Ipv4Address icmpSource, uint8_t icmpTtl,· |
108 uint8_t icmpType, uint8_t icmpCode, | 109 uint8_t icmpType, uint8_t icmpCode, |
109 uint32_t icmpInfo); | 110 uint32_t icmpInfo); |
110 | 111 |
111 Ipv4EndPoint *m_endPoint; | 112 Ipv4EndPoint *m_endPoint; |
112 Ptr<Node> m_node; | 113 Ptr<Node> m_node; |
(...skipping 16 matching lines...) Expand all Loading... |
129 uint8_t m_ipMulticastTtl; | 130 uint8_t m_ipMulticastTtl; |
130 int32_t m_ipMulticastIf; | 131 int32_t m_ipMulticastIf; |
131 bool m_ipMulticastLoop; | 132 bool m_ipMulticastLoop; |
132 bool m_mtuDiscover; | 133 bool m_mtuDiscover; |
133 Callback<void, Ipv4Address,uint8_t,uint8_t,uint8_t,uint32_t> m_icmpCallback; | 134 Callback<void, Ipv4Address,uint8_t,uint8_t,uint8_t,uint32_t> m_icmpCallback; |
134 }; | 135 }; |
135 | 136 |
136 }//namespace ns3 | 137 }//namespace ns3 |
137 | 138 |
138 #endif /* UDP_SOCKET_IMPL_H */ | 139 #endif /* UDP_SOCKET_IMPL_H */ |
LEFT | RIGHT |