Index: src/node/socket.cc |
=================================================================== |
--- a/src/node/socket.cc |
+++ b/src/node/socket.cc |
@@ -173,6 +173,12 @@ |
return p->GetSize (); |
} |
+void |
+Socket::SetIfIndex(uint32_t ifIndex) |
+{ |
+ NS_ASSERT(0); |
+} |
+ |
void |
Socket::NotifyConnectionSucceeded (void) |
@@ -415,4 +421,58 @@ |
os << (m_dontFragment?"true":"false"); |
} |
+ |
+SocketRecvIfTag::SocketRecvIfTag () |
+{ |
+} |
+ |
+void |
+SocketRecvIfTag::SetRecvIf (uint32_t ifindex) |
+{ |
+ m_ifindex = ifindex; |
+} |
+ |
+uint32_t |
+SocketRecvIfTag::GetRecvIf (void) const |
+{ |
+ return m_ifindex; |
+} |
+ |
+ |
+TypeId |
+SocketRecvIfTag::GetTypeId (void) |
+{ |
+ static TypeId tid = TypeId ("ns3::SocketRecvIfTag") |
+ .SetParent<Tag> () |
+ .AddConstructor<SocketRecvIfTag> () |
+ ; |
+ return tid; |
+} |
+TypeId |
+SocketRecvIfTag::GetInstanceTypeId (void) const |
+{ |
+ return GetTypeId (); |
+} |
+ |
+uint32_t |
+SocketRecvIfTag::GetSerializedSize (void) const |
+{ |
+ return sizeof(uint32_t); |
+} |
+void |
+SocketRecvIfTag::Serialize (TagBuffer i) const |
+{ |
+ i.WriteU32 (m_ifindex); |
+} |
+void |
+SocketRecvIfTag::Deserialize (TagBuffer i) |
+{ |
+ m_ifindex = i.ReadU32 (); |
+} |
+void |
+SocketRecvIfTag::Print (std::ostream &os) const |
+{ |
+ os << "RecvIf=" << (uint32_t) m_ifindex; |
+} |
+ |
}//namespace ns3 |