41 class DummyCongControl;
96 .AddConstructor<DummyCongControl> ()
97 .SetGroupName (
"Internet")
105 m_segmentsReceived (0)
121 m_congCtl = CreateObject<DummyCongControl> ();
123 s->SetCongestionControlAlgorithm (
m_congCtl);
147 "Not all acked segments have been passed to PktsAcked method");
void PktsAcked(Ptr< TcpSocketState > tcb, uint32_t segmentsAcked, const Time &rtt)
Timing information on received ACK.
Callback< void, uint32_t > m_test
Simulation virtual time values and global simulation resolution.
TcpPktsAckedOpenTest(const std::string &desc)
Smart pointer class similar to boost::intrusive_ptr.
uint32_t GetSegSize(SocketWho who)
Get the segment size of the node specified.
NUMERIC_TYPE GetValue() const
Extracts the numeric value of the sequence number.
uint32_t m_segmentsReceived
Contains the number of times PktsAcked is called.
virtual Ptr< TcpSocketMsgBase > CreateSenderSocket(Ptr< Node > node)
Create and install the socket to install on the sender.
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
The NewReno implementation.
This test suite implements a Unit Test.
void PktsAckedCalled(uint32_t segmentsAcked)
void FinalChecks()
Performs the (eventual) final checks through test asserts.
Ptr< DummyCongControl > m_congCtl
Contains the ack number received.
void AddTestCase(TestCase *testCase, enum TestDuration duration)
Add an individual child TestCase to this test suite.
void SetMTU(uint32_t mtu)
MTU of the bottleneck link.
#define NS_TEST_ASSERT_MSG_EQ(actual, limit, msg)
Test that an actual and expected (limit) value are equal and report and abort if not.
Callback< R > MakeCallback(R(T::*memPtr)(void), OBJ objPtr)
static TypeId GetTypeId(void)
Every class exported by the ns3 library is enclosed in the ns3 namespace.
void SetCallback(Callback< void, uint32_t > test)
void SetAppPktCount(uint32_t pktCount)
Set app packet count.
virtual Ptr< TcpSocketMsgBase > CreateSenderSocket(Ptr< Node > node)
Create and install the socket to install on the sender.
virtual void Rx(const Ptr< const Packet > p, const TcpHeader &h, SocketWho who)
Packet received from IP layer.
ns3::TcpPktsAckedTestSuite g_TcpPktsAckedTestSuite
SocketWho
Used as parameter of methods, specifies on what node the caller is interested (e.g.
virtual void ConfigureEnvironment()
Change the configuration of the evironment.
General infrastructure for TCP testing.
virtual void ConfigureEnvironment(void)
Change the configuration of the evironment.
Behaves as NewReno, except that each time PktsAcked is called, a notification is sent to TcpPktsAcked...
a unique identifier for an interface.
TypeId SetParent(TypeId tid)
Set the parent TypeId.
void test(void)
Example use of ns3::SystemThread.