A Discrete-Event Network Simulator
API
LteSecondaryCellHandoverTestCase Class Reference

Test measurement-based handover to secondary cell. More...

+ Inheritance diagram for LteSecondaryCellHandoverTestCase:
+ Collaboration diagram for LteSecondaryCellHandoverTestCase:

Public Member Functions

 LteSecondaryCellHandoverTestCase (std::string name, bool useIdealRrc)
 Creates an instance of the measurement-based secondary cell handover test case. More...
 
void ShutdownCell (uint32_t cellId)
 Shutdown cellId by reducing its power to 1 dBm. More...
 
void UeHandoverStartCallback (uint64_t imsi, uint16_t sourceCellId, uint16_t rnti, uint16_t targetCellId)
 Callback method indicating start of UE handover. More...
 
- Public Member Functions inherited from ns3::TestCase
 TestCase (const TestCase &)=delete
 
virtual ~TestCase ()
 Destructor. More...
 
std::string GetName (void) const
 
TestCaseoperator= (const TestCase &)=delete
 

Private Member Functions

virtual void DoRun ()
 Run a simulation. More...
 
virtual void DoTeardown ()
 Verify that handover has occurred during the simulation. More...
 

Private Attributes

bool m_hasUeHandoverStarted
 true if UE started handover More...
 
uint8_t m_numberOfComponentCarriers
 Number of component carriers. More...
 
Ptr< LteEnbNetDevicem_sourceEnbDev
 Source eNB device. More...
 
bool m_useIdealRrc
 whether LTE is configured to use ideal RRC More...
 

Additional Inherited Members

- Public Types inherited from ns3::TestCase
enum  TestDuration { QUICK = 1 , EXTENSIVE = 2 , TAKES_FOREVER = 3 }
 How long the test takes to execute. More...
 
- Protected Member Functions inherited from ns3::TestCase
 TestCase (std::string name)
 Constructor. More...
 
void AddTestCase (TestCase *testCase, TestDuration duration=QUICK)
 Add an individual child TestCase to this test suite. More...
 
TestCaseGetParent () const
 Get the parent of this TestCsse. More...
 
bool IsStatusFailure (void) const
 Check if any tests failed. More...
 
bool IsStatusSuccess (void) const
 Check if all tests passed. More...
 
void SetDataDir (std::string directory)
 Set the data directory where reference trace files can be found. More...
 
void ReportTestFailure (std::string cond, std::string actual, std::string limit, std::string message, std::string file, int32_t line)
 Log the failure of this TestCase. More...
 
bool MustAssertOnFailure (void) const
 Check if this run should assert on failure. More...
 
bool MustContinueOnFailure (void) const
 Check if this run should continue on failure. More...
 
std::string CreateDataDirFilename (std::string filename)
 Construct the full path to a file in the data directory. More...
 
std::string CreateTempDirFilename (std::string filename)
 Construct the full path to a file in a temporary directory. More...
 

Detailed Description

Test measurement-based handover to secondary cell.

Definition at line 49 of file lte-test-secondary-cell-handover.cc.

Constructor & Destructor Documentation

◆ LteSecondaryCellHandoverTestCase()

LteSecondaryCellHandoverTestCase::LteSecondaryCellHandoverTestCase ( std::string  name,
bool  useIdealRrc 
)

Creates an instance of the measurement-based secondary cell handover test case.

Parameters
namename of the test case
useIdealRrcif true, simulation uses Ideal RRC protocol, otherwise simulation uses Real RRC protocol

Definition at line 98 of file lte-test-secondary-cell-handover.cc.

Member Function Documentation

◆ DoRun()

◆ DoTeardown()

void LteSecondaryCellHandoverTestCase::DoTeardown ( void  )
privatevirtual

Verify that handover has occurred during the simulation.

Reimplemented from ns3::TestCase.

Definition at line 184 of file lte-test-secondary-cell-handover.cc.

References m_hasUeHandoverStarted, NS_LOG_FUNCTION, and NS_TEST_ASSERT_MSG_EQ.

◆ ShutdownCell()

void LteSecondaryCellHandoverTestCase::ShutdownCell ( uint32_t  cellId)

Shutdown cellId by reducing its power to 1 dBm.

Parameters
cellIdID of the cell to shutdown

Definition at line 107 of file lte-test-secondary-cell-handover.cc.

References ns3::LteEnbNetDevice::GetPhy(), m_sourceEnbDev, and third::phy.

Referenced by DoRun().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ UeHandoverStartCallback()

void LteSecondaryCellHandoverTestCase::UeHandoverStartCallback ( uint64_t  imsi,
uint16_t  sourceCellId,
uint16_t  rnti,
uint16_t  targetCellId 
)

Callback method indicating start of UE handover.

Parameters
imsiThe IMSI
sourceCellIdThe source cell ID
rntiThe RNTI
targetCellIdThe target cell ID

Definition at line 114 of file lte-test-secondary-cell-handover.cc.

References m_hasUeHandoverStarted, and NS_LOG_FUNCTION.

Referenced by DoRun().

+ Here is the caller graph for this function:

Member Data Documentation

◆ m_hasUeHandoverStarted

bool LteSecondaryCellHandoverTestCase::m_hasUeHandoverStarted
private

true if UE started handover

Definition at line 95 of file lte-test-secondary-cell-handover.cc.

Referenced by DoTeardown(), and UeHandoverStartCallback().

◆ m_numberOfComponentCarriers

uint8_t LteSecondaryCellHandoverTestCase::m_numberOfComponentCarriers
private

Number of component carriers.

Definition at line 91 of file lte-test-secondary-cell-handover.cc.

Referenced by DoRun().

◆ m_sourceEnbDev

Ptr<LteEnbNetDevice> LteSecondaryCellHandoverTestCase::m_sourceEnbDev
private

Source eNB device.

Definition at line 93 of file lte-test-secondary-cell-handover.cc.

Referenced by DoRun(), and ShutdownCell().

◆ m_useIdealRrc

bool LteSecondaryCellHandoverTestCase::m_useIdealRrc
private

whether LTE is configured to use ideal RRC

Definition at line 90 of file lte-test-secondary-cell-handover.cc.

Referenced by DoRun().


The documentation for this class was generated from the following file: