diff --git a/src/internet/model/tcp-socket-state.cc b/src/internet/model/tcp-socket-state.cc index de47c3e95..9179d97d9 100644 --- a/src/internet/model/tcp-socket-state.cc +++ b/src/internet/model/tcp-socket-state.cc @@ -39,39 +39,39 @@ TcpSocketState::GetTypeId (void) .AddTraceSource ("CongestionWindow", "The TCP connection's congestion window", MakeTraceSourceAccessor (&TcpSocketState::m_cWnd), - "ns3::TracedValue::Uint32Callback") + "ns3::TracedValueCallback::Uint32") .AddTraceSource ("CongestionWindowInflated", "The TCP connection's inflated congestion window", MakeTraceSourceAccessor (&TcpSocketState::m_cWndInfl), - "ns3::TracedValue::Uint32Callback") + "ns3::TracedValueCallback::Uint32") .AddTraceSource ("SlowStartThreshold", "TCP slow start threshold (bytes)", MakeTraceSourceAccessor (&TcpSocketState::m_ssThresh), - "ns3::TracedValue::Uint32Callback") + "ns3::TracedValueCallback::Uint32") .AddTraceSource ("CongState", "TCP Congestion machine state", MakeTraceSourceAccessor (&TcpSocketState::m_congState), - "ns3::TracedValue::TcpCongStatesTracedValueCallback") + "ns3::TracedValueCallback::TcpCongState") .AddTraceSource ("EcnState", "Trace ECN state change of socket", MakeTraceSourceAccessor (&TcpSocketState::m_ecnState), - "ns3::TracedValue::EcnStatesTracedValueCallback") + "ns3::TracedValueCallback::EcnState") .AddTraceSource ("HighestSequence", "Highest sequence number received from peer", MakeTraceSourceAccessor (&TcpSocketState::m_highTxMark), - "ns3::SequenceNumber32TracedValueCallback") + "ns3::TracedValueCallback::SequenceNumber32") .AddTraceSource ("NextTxSequence", "Next sequence number to send (SND.NXT)", MakeTraceSourceAccessor (&TcpSocketState::m_nextTxSequence), - "ns3::SequenceNumber32TracedValueCallback") + "ns3::TracedValueCallback::SequenceNumber32") .AddTraceSource ("BytesInFlight", "The TCP connection's congestion window", MakeTraceSourceAccessor (&TcpSocketState::m_bytesInFlight), - "ns3::TracedValue::Uint32Callback") + "ns3::TracedValueCallback::Uint32") .AddTraceSource ("RTT", "Last RTT sample", MakeTraceSourceAccessor (&TcpSocketState::m_lastRtt), - "ns3::TracedValue::TimeCallback") + "ns3::TracedValueCallback::Time") ; return tid; } diff --git a/src/internet/model/tcp-socket-state.h b/src/internet/model/tcp-socket-state.h index 12381df77..a41958820 100644 --- a/src/internet/model/tcp-socket-state.h +++ b/src/internet/model/tcp-socket-state.h @@ -113,26 +113,6 @@ public: * This state is used for tracing. */ } EcnState_t; - /** - * \ingroup tcp - * TracedValue Callback signature for TcpCongState_t - * - * \param [in] oldValue original value of the traced variable - * \param [in] newValue new value of the traced variable - */ - typedef void (* TcpCongStatesTracedValueCallback)(const TcpCongState_t oldValue, - const TcpCongState_t newValue); - - /** - * \ingroup tcp - * TracedValue Callback signature for EcnState_t - * - * \param [in] oldValue original value of the traced variable - * \param [in] newValue new value of the traced variable - */ - typedef void (* EcnStatesTracedValueCallback)(const EcnState_t oldValue, - const EcnState_t newValue); - /** * \brief Literal names of TCP states for use in log messages */ @@ -195,4 +175,28 @@ public: } }; +namespace TracedValueCallback { + + /** + * \ingroup tcp + * TracedValue Callback signature for TcpCongState_t + * + * \param [in] oldValue original value of the traced variable + * \param [in] newValue new value of the traced variable + */ + typedef void (* TcpCongState)(const TcpSocketState::TcpCongState_t oldValue, + const TcpSocketState::TcpCongState_t newValue); + + /** + * \ingroup tcp + * TracedValue Callback signature for EcnState_t + * + * \param [in] oldValue original value of the traced variable + * \param [in] newValue new value of the traced variable + */ + typedef void (* EcnState)(const TcpSocketState::EcnState_t oldValue, + const TcpSocketState::EcnState_t newValue); + +} // namespace TracedValueCallback + } //namespace ns3