A simplified version of LteHelper, that is used for creation and configuration of LTE entities for testing purposes when just a limited LteHelper functionality is wanted. More...
#include "lte-simple-helper.h"
Public Member Functions | |
LteSimpleHelper () | |
~LteSimpleHelper () override | |
void | DoDispose () override |
Destructor implementation. | |
void | EnableDlPdcpTraces () |
Enable trace sinks for DL PDCP layer. | |
void | EnableDlRlcTraces () |
Enable trace sinks for DL RLC layer. | |
void | EnableLogComponents () |
Enables logging for all components of the LENA architecture. | |
void | EnablePdcpTraces () |
Enable trace sinks for PDCP layer. | |
void | EnableRlcTraces () |
Enable trace sinks for RLC layer. | |
void | EnableTraces () |
Enables trace sinks for MAC, RLC and PDCP. | |
void | EnableUlPdcpTraces () |
Enable trace sinks for UL PDCP layer. | |
void | EnableUlRlcTraces () |
Enable trace sinks for UL RLC layer. | |
NetDeviceContainer | InstallEnbDevice (NodeContainer c) |
create a set of eNB devices | |
NetDeviceContainer | InstallUeDevice (NodeContainer c) |
create a set of UE devices | |
Public Member Functions inherited from ns3::Object | |
Object () | |
Constructor. | |
~Object () override | |
Destructor. | |
void | AggregateObject (Ptr< Object > other) |
Aggregate two Objects together. | |
void | Dispose () |
Dispose of this Object. | |
AggregateIterator | GetAggregateIterator () const |
Get an iterator to the Objects aggregated to this one. | |
TypeId | GetInstanceTypeId () const override |
Get the most derived TypeId for this Object. | |
template<typename T > | |
Ptr< T > | GetObject () const |
Get a pointer to the requested aggregated Object. | |
template<> | |
Ptr< Object > | GetObject () const |
Specialization of () for objects of type ns3::Object. | |
template<typename T > | |
Ptr< T > | GetObject (TypeId tid) const |
Get a pointer to the requested aggregated Object by TypeId. | |
template<> | |
Ptr< Object > | GetObject (TypeId tid) const |
Specialization of (TypeId tid) for objects of type ns3::Object. | |
void | Initialize () |
Invoke DoInitialize on all Objects aggregated to this one. | |
bool | IsInitialized () const |
Check if the object has been initialized. | |
void | UnidirectionalAggregateObject (Ptr< Object > other) |
Aggregate an Object to another Object. | |
Public Member Functions inherited from ns3::SimpleRefCount< Object, ObjectBase, ObjectDeleter > | |
SimpleRefCount () | |
Default constructor. | |
SimpleRefCount (const SimpleRefCount &o) | |
Copy constructor. | |
uint32_t | GetReferenceCount () const |
Get the reference count of the object. | |
SimpleRefCount & | operator= (const SimpleRefCount &o) |
Assignment operator. | |
void | Ref () const |
Increment the reference count. | |
void | Unref () const |
Decrement the reference count. | |
Public Member Functions inherited from ns3::ObjectBase | |
virtual | ~ObjectBase () |
Virtual destructor. | |
void | GetAttribute (std::string name, AttributeValue &value, bool permissive=false) const |
Get the value of an attribute, raising fatal errors if unsuccessful. | |
bool | GetAttributeFailSafe (std::string name, AttributeValue &value) const |
Get the value of an attribute without raising errors. | |
void | SetAttribute (std::string name, const AttributeValue &value) |
Set a single attribute, raising fatal errors if unsuccessful. | |
bool | SetAttributeFailSafe (std::string name, const AttributeValue &value) |
Set a single attribute without raising errors. | |
bool | TraceConnect (std::string name, std::string context, const CallbackBase &cb) |
Connect a TraceSource to a Callback with a context. | |
bool | TraceConnectWithoutContext (std::string name, const CallbackBase &cb) |
Connect a TraceSource to a Callback without a context. | |
bool | TraceDisconnect (std::string name, std::string context, const CallbackBase &cb) |
Disconnect from a TraceSource a Callback previously connected with a context. | |
bool | TraceDisconnectWithoutContext (std::string name, const CallbackBase &cb) |
Disconnect from a TraceSource a Callback previously connected without a context. | |
Static Public Member Functions | |
static TypeId | GetTypeId () |
Get the type ID. | |
Static Public Member Functions inherited from ns3::Object | |
static TypeId | GetTypeId () |
Register this type. | |
Static Public Member Functions inherited from ns3::ObjectBase | |
static TypeId | GetTypeId () |
Get the type ID. | |
Public Attributes | |
Ptr< LteTestMac > | m_enbMac |
ENB MAC. | |
Ptr< LteTestRrc > | m_enbRrc |
ENB RRC. | |
Ptr< LteTestMac > | m_ueMac |
UE MAC. | |
Ptr< LteTestRrc > | m_ueRrc |
UE RRC. | |
Protected Member Functions | |
void | DoInitialize () override |
Initialize() implementation. | |
Protected Member Functions inherited from ns3::Object | |
Object (const Object &o) | |
Copy an Object. | |
virtual void | NotifyNewAggregate () |
Notify all Objects aggregated to this one of a new Object being aggregated. | |
Protected Member Functions inherited from ns3::ObjectBase | |
void | ConstructSelf (const AttributeConstructionList &attributes) |
Complete construction of ObjectBase; invoked by derived classes. | |
virtual void | NotifyConstructionCompleted () |
Notifier called once the ObjectBase is fully constructed. | |
Private Types | |
enum | LteRlcEntityType_t { RLC_UM = 1 , RLC_AM = 2 } |
LteRlcEntityType_t enumeration. More... | |
Private Member Functions | |
Ptr< NetDevice > | InstallSingleEnbDevice (Ptr< Node > n) |
Install single ENB device. | |
Ptr< NetDevice > | InstallSingleUeDevice (Ptr< Node > n) |
Install single UE device. | |
Private Attributes | |
ObjectFactory | m_enbDeviceFactory |
ENB device factory. | |
Ptr< LtePdcp > | m_enbPdcp |
ENB PDCP. | |
Ptr< LteRlc > | m_enbRlc |
ENB RLC. | |
enum ns3::LteSimpleHelper::LteRlcEntityType_t | m_lteRlcEntityType |
RLC entity type. | |
Ptr< SimpleChannel > | m_phyChannel |
the physical channel | |
ObjectFactory | m_ueDeviceFactory |
UE device factory. | |
Ptr< LtePdcp > | m_uePdcp |
UE PDCP. | |
Ptr< LteRlc > | m_ueRlc |
UE RLC. | |
Additional Inherited Members | |
Related Symbols inherited from ns3::ObjectBase | |
static TypeId | GetObjectIid () |
Ensure the TypeId for ObjectBase gets fully configured to anchor the inheritance tree properly. | |
A simplified version of LteHelper, that is used for creation and configuration of LTE entities for testing purposes when just a limited LteHelper functionality is wanted.
Definition at line 36 of file lte-simple-helper.h.
|
private |
LteRlcEntityType_t enumeration.
Enumerator | |
---|---|
RLC_UM | |
RLC_AM |
Definition at line 148 of file lte-simple-helper.h.
ns3::LteSimpleHelper::LteSimpleHelper | ( | ) |
Definition at line 28 of file lte-simple-helper.cc.
References ns3::LteSimpleNetDevice::GetTypeId(), m_enbDeviceFactory, m_ueDeviceFactory, NS_LOG_FUNCTION, and ns3::ObjectFactory::SetTypeId().
|
override |
Definition at line 45 of file lte-simple-helper.cc.
References NS_LOG_FUNCTION.
|
overridevirtual |
Destructor implementation.
This method is called by Dispose() or by the Object's destructor, whichever comes first.
Subclasses are expected to implement their real destruction code in an overridden version of this method and chain up to their parent's implementation once they are done. i.e, for simplicity, the destructor of every subclass should be empty and its content should be moved to the associated DoDispose() method.
It is safe to call GetObject() from within this method.
Reimplemented from ns3::Object.
Definition at line 66 of file lte-simple-helper.cc.
References ns3::Object::DoDispose(), m_enbMac, m_phyChannel, m_ueMac, and NS_LOG_FUNCTION.
|
overrideprotectedvirtual |
Initialize() implementation.
This method is called only once by Initialize(). If the user calls Initialize() multiple times, DoInitialize() is called only the first time.
Subclasses are expected to override this method and chain up to their parent's implementation once they are done. It is safe to call GetObject() and AggregateObject() from within this method.
Reimplemented from ns3::Object.
Definition at line 36 of file lte-simple-helper.cc.
References ns3::CreateObject(), ns3::Object::DoInitialize(), m_phyChannel, and NS_LOG_FUNCTION.
void ns3::LteSimpleHelper::EnableDlPdcpTraces | ( | ) |
Enable trace sinks for DL PDCP layer.
Definition at line 354 of file lte-simple-helper.cc.
References NS_LOG_FUNCTION_NOARGS.
Referenced by EnablePdcpTraces().
void ns3::LteSimpleHelper::EnableDlRlcTraces | ( | ) |
Enable trace sinks for DL RLC layer.
Definition at line 279 of file lte-simple-helper.cc.
References NS_LOG_FUNCTION_NOARGS.
Referenced by EnableRlcTraces().
void ns3::LteSimpleHelper::EnableLogComponents | ( | ) |
Enables logging for all components of the LENA architecture.
Definition at line 201 of file lte-simple-helper.cc.
References ns3::LOG_LEVEL_ALL, ns3::LOG_PREFIX_FUNC, ns3::LOG_PREFIX_NODE, ns3::LOG_PREFIX_TIME, and ns3::LogComponentEnable().
void ns3::LteSimpleHelper::EnablePdcpTraces | ( | ) |
Enable trace sinks for PDCP layer.
Definition at line 347 of file lte-simple-helper.cc.
References EnableDlPdcpTraces(), and EnableUlPdcpTraces().
Referenced by EnableTraces().
void ns3::LteSimpleHelper::EnableRlcTraces | ( | ) |
Enable trace sinks for RLC layer.
Definition at line 226 of file lte-simple-helper.cc.
References EnableDlRlcTraces(), and EnableUlRlcTraces().
Referenced by EnableTraces().
void ns3::LteSimpleHelper::EnableTraces | ( | ) |
Enables trace sinks for MAC, RLC and PDCP.
Definition at line 218 of file lte-simple-helper.cc.
References EnablePdcpTraces(), and EnableRlcTraces().
void ns3::LteSimpleHelper::EnableUlPdcpTraces | ( | ) |
Enable trace sinks for UL PDCP layer.
Definition at line 365 of file lte-simple-helper.cc.
References NS_LOG_FUNCTION_NOARGS.
Referenced by EnablePdcpTraces().
void ns3::LteSimpleHelper::EnableUlRlcTraces | ( | ) |
Enable trace sinks for UL RLC layer.
Definition at line 336 of file lte-simple-helper.cc.
References NS_LOG_FUNCTION_NOARGS.
Referenced by EnableRlcTraces().
|
static |
Get the type ID.
Definition at line 51 of file lte-simple-helper.cc.
References m_lteRlcEntityType, ns3::MakeEnumAccessor(), ns3::MakeEnumChecker(), RLC_AM, RLC_UM, and ns3::TypeId::SetParent().
NetDeviceContainer ns3::LteSimpleHelper::InstallEnbDevice | ( | NodeContainer | c | ) |
create a set of eNB devices
c | the node container where the devices are to be installed |
Definition at line 80 of file lte-simple-helper.cc.
References ns3::NodeContainer::Begin(), ns3::NodeContainer::End(), ns3::Object::Initialize(), InstallSingleEnbDevice(), and NS_LOG_FUNCTION.
Install single ENB device.
n | the node |
Definition at line 109 of file lte-simple-helper.cc.
References ns3::Mac48Address::Allocate(), ns3::ObjectFactory::Create(), ns3::CreateObject(), m_enbDeviceFactory, m_enbMac, m_enbPdcp, m_enbRlc, m_enbRrc, m_lteRlcEntityType, m_phyChannel, ns3::MakeCallback(), NS_LOG_FUNCTION, ns3::LteTestMac::Receive(), and RLC_UM.
Referenced by InstallEnbDevice().
Install single UE device.
n | the node |
Definition at line 156 of file lte-simple-helper.cc.
References ns3::Mac48Address::Allocate(), ns3::ObjectFactory::Create(), ns3::CreateObject(), m_lteRlcEntityType, m_phyChannel, m_ueDeviceFactory, m_ueMac, m_uePdcp, m_ueRlc, m_ueRrc, ns3::MakeCallback(), NS_LOG_FUNCTION, ns3::LteTestMac::Receive(), and RLC_UM.
Referenced by InstallUeDevice().
NetDeviceContainer ns3::LteSimpleHelper::InstallUeDevice | ( | NodeContainer | c | ) |
create a set of UE devices
c | the node container where the devices are to be installed |
Definition at line 95 of file lte-simple-helper.cc.
References ns3::NodeContainer::Begin(), ns3::NodeContainer::End(), InstallSingleUeDevice(), and NS_LOG_FUNCTION.
|
private |
ENB device factory.
Definition at line 144 of file lte-simple-helper.h.
Referenced by LteSimpleHelper(), and InstallSingleEnbDevice().
Ptr<LteTestMac> ns3::LteSimpleHelper::m_enbMac |
ENB MAC.
Definition at line 134 of file lte-simple-helper.h.
Referenced by DoDispose(), and InstallSingleEnbDevice().
ENB PDCP.
Definition at line 138 of file lte-simple-helper.h.
Referenced by InstallSingleEnbDevice().
ENB RLC.
Definition at line 139 of file lte-simple-helper.h.
Referenced by InstallSingleEnbDevice().
Ptr<LteTestRrc> ns3::LteSimpleHelper::m_enbRrc |
ENB RRC.
Definition at line 131 of file lte-simple-helper.h.
Referenced by InstallSingleEnbDevice().
|
private |
RLC entity type.
Referenced by GetTypeId(), InstallSingleEnbDevice(), and InstallSingleUeDevice().
|
private |
the physical channel
Definition at line 128 of file lte-simple-helper.h.
Referenced by DoDispose(), DoInitialize(), InstallSingleEnbDevice(), and InstallSingleUeDevice().
|
private |
UE device factory.
Definition at line 145 of file lte-simple-helper.h.
Referenced by LteSimpleHelper(), and InstallSingleUeDevice().
Ptr<LteTestMac> ns3::LteSimpleHelper::m_ueMac |
UE MAC.
Definition at line 135 of file lte-simple-helper.h.
Referenced by DoDispose(), and InstallSingleUeDevice().
Ptr<LteTestRrc> ns3::LteSimpleHelper::m_ueRrc |