From 2133aa49c51ef9a2edf79a98a1f1940e1eeb33cf Mon Sep 17 00:00:00 2001 From: Josh Pelkey Date: Tue, 29 Jun 2010 20:24:20 -0400 Subject: [PATCH] ensure objects are regsitered --- src/applications/udp-client-server/udp-client.cc | 2 +- src/applications/udp-client-server/udp-server.cc | 2 +- .../udp-client-server/udp-trace-client.cc | 2 +- src/common/jakes-propagation-loss-model.cc | 4 ++-- src/common/packet-burst.cc | 2 +- src/common/tag.cc | 2 ++ src/contrib/flow-id-tag.cc | 2 ++ src/core/object-base.cc | 2 ++ src/devices/mesh/flame/flame-header.cc | 5 ++++- src/devices/mesh/flame/flame-protocol.cc | 1 + src/devices/spectrum/aloha-noack-mac-header.cc | 2 ++ src/devices/wifi/aarf-wifi-manager.cc | 2 +- src/devices/wifi/error-rate-model.cc | 2 ++ src/devices/wifi/mgt-headers.h | 2 +- src/devices/wifi/qos-tag.cc | 2 ++ src/devices/wifi/wifi-channel.cc | 2 ++ src/devices/wifi/wifi-information-element-vector.cc | 2 ++ src/devices/wifi/yans-wifi-channel.cc | 2 ++ src/devices/wimax/bs-net-device.cc | 2 +- src/devices/wimax/bs-scheduler-rtps.cc | 2 +- src/devices/wimax/bs-scheduler-simple.cc | 2 +- src/devices/wimax/bs-scheduler.cc | 2 +- src/devices/wimax/bs-uplink-scheduler-mbqos.cc | 2 +- src/devices/wimax/bs-uplink-scheduler-simple.cc | 2 +- src/devices/wimax/bs-uplink-scheduler.cc | 2 ++ src/devices/wimax/dl-mac-messages.cc | 4 ++-- src/devices/wimax/mac-messages.cc | 12 +++++++++--- src/devices/wimax/simple-ofdm-wimax-phy.cc | 2 +- src/devices/wimax/ul-mac-messages.cc | 4 ++-- src/devices/wimax/wimax-connection.cc | 2 +- src/devices/wimax/wimax-mac-header.cc | 10 +++++----- src/devices/wimax/wimax-mac-queue.cc | 2 +- src/devices/wimax/wimax-mac-to-mac-header.cc | 3 +++ src/devices/wimax/wimax-mac-to-mac-header.h | 4 ++-- src/devices/wimax/wimax-net-device.cc | 2 +- src/devices/wimax/wimax-phy.cc | 2 +- src/helper/canvas-location.cc | 2 ++ src/internet-stack/ipv4-interface.cc | 2 ++ src/internet-stack/loopback-net-device.cc | 2 ++ src/internet-stack/ndisc-cache.cc | 2 ++ src/internet-stack/nsc-sysctl.cc | 2 ++ src/mobility/mobility-model.cc | 2 ++ src/node/packet-socket.cc | 2 ++ src/node/radiotap-header.cc | 4 +++- src/node/simple-channel.cc | 2 ++ src/node/simple-net-device.cc | 2 ++ src/node/socket.cc | 4 ++++ src/routing/aodv/aodv-packet.cc | 9 +++++++++ src/routing/static-routing/ipv6-static-routing.cc | 1 + src/simulator/scheduler.cc | 2 ++ src/simulator/synchronizer.cc | 4 +++- 51 files changed, 107 insertions(+), 36 deletions(-) diff --git a/src/applications/udp-client-server/udp-client.cc b/src/applications/udp-client-server/udp-client.cc index 011fdf551..465f564a0 100644 --- a/src/applications/udp-client-server/udp-client.cc +++ b/src/applications/udp-client-server/udp-client.cc @@ -35,7 +35,7 @@ namespace ns3 { NS_LOG_COMPONENT_DEFINE ("UdpClient"); -NS_OBJECT_ENSURE_REGISTERED ( UdpClient); +NS_OBJECT_ENSURE_REGISTERED (UdpClient); TypeId UdpClient::GetTypeId (void) diff --git a/src/applications/udp-client-server/udp-server.cc b/src/applications/udp-client-server/udp-server.cc index 730e9fc05..7c229d5d8 100644 --- a/src/applications/udp-client-server/udp-server.cc +++ b/src/applications/udp-client-server/udp-server.cc @@ -36,7 +36,7 @@ namespace ns3 { NS_LOG_COMPONENT_DEFINE ("UdpServer"); -NS_OBJECT_ENSURE_REGISTERED ( UdpServer); +NS_OBJECT_ENSURE_REGISTERED (UdpServer); TypeId diff --git a/src/applications/udp-client-server/udp-trace-client.cc b/src/applications/udp-client-server/udp-trace-client.cc index d814c5b9d..0157cc7ab 100644 --- a/src/applications/udp-client-server/udp-trace-client.cc +++ b/src/applications/udp-client-server/udp-trace-client.cc @@ -37,7 +37,7 @@ namespace ns3 { NS_LOG_COMPONENT_DEFINE ("UdpTraceClient"); -NS_OBJECT_ENSURE_REGISTERED ( UdpTraceClient); +NS_OBJECT_ENSURE_REGISTERED (UdpTraceClient); struct UdpTraceClient::TraceEntry UdpTraceClient::g_defaultEntries[] = { {0, 534, 'I'}, diff --git a/src/common/jakes-propagation-loss-model.cc b/src/common/jakes-propagation-loss-model.cc index 440e92198..42a35e7ae 100644 --- a/src/common/jakes-propagation-loss-model.cc +++ b/src/common/jakes-propagation-loss-model.cc @@ -31,6 +31,8 @@ NS_LOG_COMPONENT_DEFINE ("Jakes"); namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (JakesPropagationLossModel); + class JakesPropagationLossModel::PathCoefficients { public: @@ -125,8 +127,6 @@ JakesPropagationLossModel::PathCoefficients::GetLoss (void) return 10 * log10 (k); } -NS_OBJECT_ENSURE_REGISTERED (JakesPropagationLossModel); - const double JakesPropagationLossModel::PI = 3.14159265358979323846; TypeId diff --git a/src/common/packet-burst.cc b/src/common/packet-burst.cc index ea7cdb242..dfbe5a0d2 100644 --- a/src/common/packet-burst.cc +++ b/src/common/packet-burst.cc @@ -28,7 +28,7 @@ NS_LOG_COMPONENT_DEFINE ("PacketBurst"); namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( PacketBurst); +NS_OBJECT_ENSURE_REGISTERED (PacketBurst); TypeId PacketBurst::GetTypeId (void) diff --git a/src/common/tag.cc b/src/common/tag.cc index c561dcb9c..01b6a1907 100644 --- a/src/common/tag.cc +++ b/src/common/tag.cc @@ -21,6 +21,8 @@ namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (Tag); + TypeId Tag::GetTypeId (void) { diff --git a/src/contrib/flow-id-tag.cc b/src/contrib/flow-id-tag.cc index 5eaacbe42..70850afa0 100644 --- a/src/contrib/flow-id-tag.cc +++ b/src/contrib/flow-id-tag.cc @@ -21,6 +21,8 @@ namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (FlowIdTag); + TypeId FlowIdTag::GetTypeId (void) { diff --git a/src/core/object-base.cc b/src/core/object-base.cc index c9fd7fd44..c9f4ba8a8 100644 --- a/src/core/object-base.cc +++ b/src/core/object-base.cc @@ -31,6 +31,8 @@ NS_LOG_COMPONENT_DEFINE ("ObjectBase"); namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (ObjectBase); + static TypeId GetObjectIid (void) { diff --git a/src/devices/mesh/flame/flame-header.cc b/src/devices/mesh/flame/flame-header.cc index 23ff869da..2665fcf3b 100644 --- a/src/devices/mesh/flame/flame-header.cc +++ b/src/devices/mesh/flame/flame-header.cc @@ -25,6 +25,9 @@ namespace ns3 { namespace flame { + +NS_OBJECT_ENSURE_REGISTERED (FlameHeader); + FlameHeader::FlameHeader () : m_cost (0), m_seqno (0), m_origDst (Mac48Address ()), m_origSrc (Mac48Address ()) { @@ -35,7 +38,7 @@ FlameHeader::~FlameHeader () TypeId FlameHeader::GetTypeId (void) { - static TypeId tid = TypeId ("ns3::FlameHeader") + static TypeId tid = TypeId ("ns3::flame::FlameHeader") .SetParent
() .AddConstructor (); return tid; diff --git a/src/devices/mesh/flame/flame-protocol.cc b/src/devices/mesh/flame/flame-protocol.cc index 5d8cd505b..3a0e4bd86 100644 --- a/src/devices/mesh/flame/flame-protocol.cc +++ b/src/devices/mesh/flame/flame-protocol.cc @@ -40,6 +40,7 @@ namespace flame { // FlameTag //----------------------------------------------------------------------------- NS_OBJECT_ENSURE_REGISTERED (FlameTag); +NS_OBJECT_ENSURE_REGISTERED (FlameProtocol); TypeId FlameTag::GetTypeId () diff --git a/src/devices/spectrum/aloha-noack-mac-header.cc b/src/devices/spectrum/aloha-noack-mac-header.cc index 683ac17f0..171b46e34 100644 --- a/src/devices/spectrum/aloha-noack-mac-header.cc +++ b/src/devices/spectrum/aloha-noack-mac-header.cc @@ -26,6 +26,8 @@ NS_LOG_COMPONENT_DEFINE ("AlohaNoackMacHeader"); namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (AlohaNoackMacHeader); + TypeId AlohaNoackMacHeader::GetTypeId (void) { diff --git a/src/devices/wifi/aarf-wifi-manager.cc b/src/devices/wifi/aarf-wifi-manager.cc index eb6c1582a..eb4154934 100644 --- a/src/devices/wifi/aarf-wifi-manager.cc +++ b/src/devices/wifi/aarf-wifi-manager.cc @@ -27,7 +27,7 @@ #define Min(a,b) ((ab)?a:b) -NS_LOG_COMPONENT_DEFINE ("ns3::AarfWifiManager"); +NS_LOG_COMPONENT_DEFINE ("AarfWifiManager"); namespace ns3 { diff --git a/src/devices/wifi/error-rate-model.cc b/src/devices/wifi/error-rate-model.cc index fe2f9d6a0..a1d96aad3 100644 --- a/src/devices/wifi/error-rate-model.cc +++ b/src/devices/wifi/error-rate-model.cc @@ -21,6 +21,8 @@ namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (ErrorRateModel); + TypeId ErrorRateModel::GetTypeId (void) { static TypeId tid = TypeId ("ns3::ErrorRateModel") diff --git a/src/devices/wifi/mgt-headers.h b/src/devices/wifi/mgt-headers.h index 6d8a9cd4b..40c13f830 100644 --- a/src/devices/wifi/mgt-headers.h +++ b/src/devices/wifi/mgt-headers.h @@ -215,7 +215,7 @@ public: CategoryValue GetCategory (); ActionValue GetAction (); - static TypeId GetTypeId (); + static TypeId GetTypeId (void); virtual TypeId GetInstanceTypeId () const; virtual void Print (std::ostream &os) const; virtual uint32_t GetSerializedSize () const; diff --git a/src/devices/wifi/qos-tag.cc b/src/devices/wifi/qos-tag.cc index 09c453ab7..32d2ccd08 100644 --- a/src/devices/wifi/qos-tag.cc +++ b/src/devices/wifi/qos-tag.cc @@ -23,6 +23,8 @@ namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (QosTag); + TypeId QosTag::GetTypeId (void) { diff --git a/src/devices/wifi/wifi-channel.cc b/src/devices/wifi/wifi-channel.cc index cc78c3273..7a50a0fe9 100644 --- a/src/devices/wifi/wifi-channel.cc +++ b/src/devices/wifi/wifi-channel.cc @@ -35,6 +35,8 @@ NS_LOG_COMPONENT_DEFINE ("WifiChannel"); namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (WifiChannel); + TypeId WifiChannel::GetTypeId (void) { diff --git a/src/devices/wifi/wifi-information-element-vector.cc b/src/devices/wifi/wifi-information-element-vector.cc index 3f60ff97e..74af5168b 100644 --- a/src/devices/wifi/wifi-information-element-vector.cc +++ b/src/devices/wifi/wifi-information-element-vector.cc @@ -24,6 +24,8 @@ namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (WifiInformationElementVector); + WifiInformationElementVector::WifiInformationElementVector () : m_maxSize (1500) { diff --git a/src/devices/wifi/yans-wifi-channel.cc b/src/devices/wifi/yans-wifi-channel.cc index b4738037c..b7ee09a0d 100644 --- a/src/devices/wifi/yans-wifi-channel.cc +++ b/src/devices/wifi/yans-wifi-channel.cc @@ -34,6 +34,8 @@ NS_LOG_COMPONENT_DEFINE ("YansWifiChannel"); namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (YansWifiChannel); + TypeId YansWifiChannel::GetTypeId (void) { diff --git a/src/devices/wimax/bs-net-device.cc b/src/devices/wimax/bs-net-device.cc index ab0a9c8a6..3a09a19c3 100644 --- a/src/devices/wimax/bs-net-device.cc +++ b/src/devices/wimax/bs-net-device.cc @@ -48,7 +48,7 @@ NS_LOG_COMPONENT_DEFINE ("BaseStationNetDevice"); namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( BaseStationNetDevice); +NS_OBJECT_ENSURE_REGISTERED (BaseStationNetDevice); TypeId BaseStationNetDevice::GetTypeId (void) { diff --git a/src/devices/wimax/bs-scheduler-rtps.cc b/src/devices/wimax/bs-scheduler-rtps.cc index 9aa5afceb..ff9a54c27 100644 --- a/src/devices/wimax/bs-scheduler-rtps.cc +++ b/src/devices/wimax/bs-scheduler-rtps.cc @@ -41,7 +41,7 @@ NS_LOG_COMPONENT_DEFINE ("BSSchedulerRtps"); namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( BSSchedulerRtps); +NS_OBJECT_ENSURE_REGISTERED (BSSchedulerRtps); TypeId BSSchedulerRtps::GetTypeId (void) diff --git a/src/devices/wimax/bs-scheduler-simple.cc b/src/devices/wimax/bs-scheduler-simple.cc index 7b1618705..cf46dce2d 100644 --- a/src/devices/wimax/bs-scheduler-simple.cc +++ b/src/devices/wimax/bs-scheduler-simple.cc @@ -39,7 +39,7 @@ NS_LOG_COMPONENT_DEFINE ("BSSchedulerSimple"); namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( BSSchedulerSimple); +NS_OBJECT_ENSURE_REGISTERED (BSSchedulerSimple); TypeId BSSchedulerSimple::GetTypeId (void) { diff --git a/src/devices/wimax/bs-scheduler.cc b/src/devices/wimax/bs-scheduler.cc index 56603bd51..9d4dd4302 100644 --- a/src/devices/wimax/bs-scheduler.cc +++ b/src/devices/wimax/bs-scheduler.cc @@ -38,7 +38,7 @@ NS_LOG_COMPONENT_DEFINE ("BSScheduler"); namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( BSScheduler); +NS_OBJECT_ENSURE_REGISTERED (BSScheduler); TypeId BSScheduler::GetTypeId (void) diff --git a/src/devices/wimax/bs-uplink-scheduler-mbqos.cc b/src/devices/wimax/bs-uplink-scheduler-mbqos.cc index ead60b71e..0c04175e1 100644 --- a/src/devices/wimax/bs-uplink-scheduler-mbqos.cc +++ b/src/devices/wimax/bs-uplink-scheduler-mbqos.cc @@ -33,7 +33,7 @@ NS_LOG_COMPONENT_DEFINE ("UplinkSchedulerMBQoS"); namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( UplinkSchedulerMBQoS); +NS_OBJECT_ENSURE_REGISTERED (UplinkSchedulerMBQoS); UplinkSchedulerMBQoS::UplinkSchedulerMBQoS () { diff --git a/src/devices/wimax/bs-uplink-scheduler-simple.cc b/src/devices/wimax/bs-uplink-scheduler-simple.cc index 4dca3721c..22e44292c 100644 --- a/src/devices/wimax/bs-uplink-scheduler-simple.cc +++ b/src/devices/wimax/bs-uplink-scheduler-simple.cc @@ -35,7 +35,7 @@ NS_LOG_COMPONENT_DEFINE ("UplinkSchedulerSimple"); namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( UplinkSchedulerSimple); +NS_OBJECT_ENSURE_REGISTERED (UplinkSchedulerSimple); UplinkSchedulerSimple::UplinkSchedulerSimple (void) { diff --git a/src/devices/wimax/bs-uplink-scheduler.cc b/src/devices/wimax/bs-uplink-scheduler.cc index 5ebdf517a..855509b9c 100644 --- a/src/devices/wimax/bs-uplink-scheduler.cc +++ b/src/devices/wimax/bs-uplink-scheduler.cc @@ -36,6 +36,8 @@ NS_LOG_COMPONENT_DEFINE ("UplinkScheduler"); namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (UplinkScheduler); + UplinkScheduler::UplinkScheduler (void) : m_bs (0), m_timeStampIrInterval (Seconds (0)), diff --git a/src/devices/wimax/dl-mac-messages.cc b/src/devices/wimax/dl-mac-messages.cc index b87993ac6..b109d9143 100644 --- a/src/devices/wimax/dl-mac-messages.cc +++ b/src/devices/wimax/dl-mac-messages.cc @@ -312,7 +312,7 @@ OfdmDlBurstProfile::Read (Buffer::Iterator start) // ---------------------------------------------------------------------------------------------------------- -NS_OBJECT_ENSURE_REGISTERED ( Dcd); +NS_OBJECT_ENSURE_REGISTERED (Dcd); Dcd::Dcd (void) : m_reserved (0), @@ -544,7 +544,7 @@ OfdmDlMapIe::Read (Buffer::Iterator start) // ---------------------------------------------------------------------------------------------------------- -NS_OBJECT_ENSURE_REGISTERED ( DlMap); +NS_OBJECT_ENSURE_REGISTERED (DlMap); DlMap::DlMap (void) : m_dcdCount (0), diff --git a/src/devices/wimax/mac-messages.cc b/src/devices/wimax/mac-messages.cc index 6d2e98c6d..595081aac 100644 --- a/src/devices/wimax/mac-messages.cc +++ b/src/devices/wimax/mac-messages.cc @@ -29,7 +29,7 @@ NS_LOG_COMPONENT_DEFINE ("MACMESSAGES"); namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( ManagementMessageType); +NS_OBJECT_ENSURE_REGISTERED (ManagementMessageType); ManagementMessageType::ManagementMessageType (void) : m_type (~0) @@ -106,7 +106,7 @@ ManagementMessageType::Deserialize (Buffer::Iterator start) // ---------------------------------------------------------------------------------------------------------- -NS_OBJECT_ENSURE_REGISTERED ( RngReq); +NS_OBJECT_ENSURE_REGISTERED (RngReq); RngReq::RngReq (void) : m_reserved (0), @@ -220,7 +220,7 @@ RngReq::Deserialize (Buffer::Iterator start) // ---------------------------------------------------------------------------------------------------------- -NS_OBJECT_ENSURE_REGISTERED ( RngRsp); +NS_OBJECT_ENSURE_REGISTERED (RngRsp); RngRsp::RngRsp (void) : m_reserved (0), @@ -497,6 +497,8 @@ RngRsp::Deserialize (Buffer::Iterator start) // ---------------------------------------------------------------------------------------------------------------------- +NS_OBJECT_ENSURE_REGISTERED (DsaReq); + DsaReq::DsaReq (void) : m_transactionId (0), m_sfid (0), @@ -629,6 +631,8 @@ DsaReq::SetServiceFlow (ServiceFlow sf) // ---------------------------------------------------------------------------------------------------------------------- +NS_OBJECT_ENSURE_REGISTERED (DsaRsp); + DsaRsp::DsaRsp (void) : m_transactionId (0), m_confirmationCode (0), @@ -767,6 +771,8 @@ DsaRsp::Deserialize (Buffer::Iterator start) // ---------------------------------------------------------------------------------------------------------- +NS_OBJECT_ENSURE_REGISTERED (DsaAck); + DsaAck::DsaAck (void) : m_transactionId (0), m_confirmationCode (0) diff --git a/src/devices/wimax/simple-ofdm-wimax-phy.cc b/src/devices/wimax/simple-ofdm-wimax-phy.cc index b3447d486..c66e87da0 100644 --- a/src/devices/wimax/simple-ofdm-wimax-phy.cc +++ b/src/devices/wimax/simple-ofdm-wimax-phy.cc @@ -38,7 +38,7 @@ NS_LOG_COMPONENT_DEFINE ("SimpleOfdmWimaxPhy"); namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( SimpleOfdmWimaxPhy); +NS_OBJECT_ENSURE_REGISTERED (SimpleOfdmWimaxPhy); TypeId SimpleOfdmWimaxPhy::GetTypeId (void) { diff --git a/src/devices/wimax/ul-mac-messages.cc b/src/devices/wimax/ul-mac-messages.cc index 71eb517cc..a22d89b7a 100644 --- a/src/devices/wimax/ul-mac-messages.cc +++ b/src/devices/wimax/ul-mac-messages.cc @@ -25,7 +25,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( Ucd); +NS_OBJECT_ENSURE_REGISTERED (Ucd); UcdChannelEncodings::UcdChannelEncodings (void) : m_bwReqOppSize (0), @@ -577,7 +577,7 @@ OfdmUlMapIe::Read (Buffer::Iterator start) // ---------------------------------------------------------------------------------------------------------- -NS_OBJECT_ENSURE_REGISTERED ( UlMap); +NS_OBJECT_ENSURE_REGISTERED (UlMap); UlMap::UlMap (void) : m_reserved (0), diff --git a/src/devices/wimax/wimax-connection.cc b/src/devices/wimax/wimax-connection.cc index 58ca773d0..a396e95c6 100644 --- a/src/devices/wimax/wimax-connection.cc +++ b/src/devices/wimax/wimax-connection.cc @@ -27,7 +27,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( WimaxConnection); +NS_OBJECT_ENSURE_REGISTERED (WimaxConnection); TypeId WimaxConnection::GetTypeId (void) { diff --git a/src/devices/wimax/wimax-mac-header.cc b/src/devices/wimax/wimax-mac-header.cc index 99e68c068..77a8155b2 100644 --- a/src/devices/wimax/wimax-mac-header.cc +++ b/src/devices/wimax/wimax-mac-header.cc @@ -25,7 +25,7 @@ namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( MacHeaderType); +NS_OBJECT_ENSURE_REGISTERED (MacHeaderType); MacHeaderType::MacHeaderType (void) : m_type (0) @@ -92,7 +92,7 @@ uint32_t MacHeaderType::Deserialize (Buffer::Iterator start) // ---------------------------------------------------------------------------------------------------------- -NS_OBJECT_ENSURE_REGISTERED ( GenericMacHeader); +NS_OBJECT_ENSURE_REGISTERED (GenericMacHeader); GenericMacHeader::GenericMacHeader (void) : m_ht (0), @@ -296,7 +296,7 @@ bool GenericMacHeader::check_hcs (void) const // ---------------------------------------------------------------------------------------------------------- -NS_OBJECT_ENSURE_REGISTERED ( BandwidthRequestHeader); +NS_OBJECT_ENSURE_REGISTERED (BandwidthRequestHeader); BandwidthRequestHeader::BandwidthRequestHeader (void) : m_ht (1), @@ -478,7 +478,7 @@ bool BandwidthRequestHeader::check_hcs (void) const // ---------------------------------------------------------------------------------------------------------- -NS_OBJECT_ENSURE_REGISTERED ( GrantManagementSubheader); +NS_OBJECT_ENSURE_REGISTERED (GrantManagementSubheader); GrantManagementSubheader::GrantManagementSubheader (void) : m_si (0), @@ -569,7 +569,7 @@ uint32_t GrantManagementSubheader::Deserialize (Buffer::Iterator start) // ---------------------------------------------------------------------------------------------------------- -NS_OBJECT_ENSURE_REGISTERED ( FragmentationSubheader); +NS_OBJECT_ENSURE_REGISTERED (FragmentationSubheader); FragmentationSubheader::FragmentationSubheader (void) : m_fc (0), diff --git a/src/devices/wimax/wimax-mac-queue.cc b/src/devices/wimax/wimax-mac-queue.cc index 4dc991b84..5e2c86af1 100644 --- a/src/devices/wimax/wimax-mac-queue.cc +++ b/src/devices/wimax/wimax-mac-queue.cc @@ -31,7 +31,7 @@ NS_LOG_COMPONENT_DEFINE ("WimaxMacQueue"); namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( WimaxMacQueue); +NS_OBJECT_ENSURE_REGISTERED (WimaxMacQueue); WimaxMacQueue::QueueElement::QueueElement (void) : m_packet (Create ()), diff --git a/src/devices/wimax/wimax-mac-to-mac-header.cc b/src/devices/wimax/wimax-mac-to-mac-header.cc index 99d45d67d..a2f586b82 100644 --- a/src/devices/wimax/wimax-mac-to-mac-header.cc +++ b/src/devices/wimax/wimax-mac-to-mac-header.cc @@ -23,6 +23,9 @@ #include "ns3/uinteger.h" #include "ns3/log.h" namespace ns3 { + +NS_OBJECT_ENSURE_REGISTERED (WimaxMacToMacHeader); + WimaxMacToMacHeader::WimaxMacToMacHeader (void) : m_len (0) { diff --git a/src/devices/wimax/wimax-mac-to-mac-header.h b/src/devices/wimax/wimax-mac-to-mac-header.h index fbf12d16e..bdb9094b6 100644 --- a/src/devices/wimax/wimax-mac-to-mac-header.h +++ b/src/devices/wimax/wimax-mac-to-mac-header.h @@ -31,13 +31,13 @@ namespace ns3 { */ class WimaxMacToMacHeader : public Header { - static TypeId GetTypeId (void); - virtual TypeId GetInstanceTypeId (void) const; public: WimaxMacToMacHeader (); ~WimaxMacToMacHeader (); WimaxMacToMacHeader (uint32_t len); + static TypeId GetTypeId (void); + virtual TypeId GetInstanceTypeId (void) const; uint32_t GetSerializedSize (void) const; void Serialize (Buffer::Iterator start) const; uint32_t Deserialize (Buffer::Iterator start); diff --git a/src/devices/wimax/wimax-net-device.cc b/src/devices/wimax/wimax-net-device.cc index 20e79a187..75fc402e5 100644 --- a/src/devices/wimax/wimax-net-device.cc +++ b/src/devices/wimax/wimax-net-device.cc @@ -43,7 +43,7 @@ NS_LOG_COMPONENT_DEFINE ("WimaxNetDevice"); namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( WimaxNetDevice); +NS_OBJECT_ENSURE_REGISTERED (WimaxNetDevice); uint32_t WimaxNetDevice::m_nrFrames = 0; uint8_t WimaxNetDevice::m_direction = ~0; diff --git a/src/devices/wimax/wimax-phy.cc b/src/devices/wimax/wimax-phy.cc index 073c9104a..ccb3c1731 100644 --- a/src/devices/wimax/wimax-phy.cc +++ b/src/devices/wimax/wimax-phy.cc @@ -34,7 +34,7 @@ NS_LOG_COMPONENT_DEFINE ("WimaxPhy"); namespace ns3 { -NS_OBJECT_ENSURE_REGISTERED ( WimaxPhy); +NS_OBJECT_ENSURE_REGISTERED (WimaxPhy); TypeId WimaxPhy::GetTypeId (void) { diff --git a/src/helper/canvas-location.cc b/src/helper/canvas-location.cc index a0a5c1079..4fe4fb0de 100644 --- a/src/helper/canvas-location.cc +++ b/src/helper/canvas-location.cc @@ -22,6 +22,8 @@ namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (CanvasLocation); + TypeId CanvasLocation::GetTypeId (void) { diff --git a/src/internet-stack/ipv4-interface.cc b/src/internet-stack/ipv4-interface.cc index 9ca20cfa2..c64a47832 100644 --- a/src/internet-stack/ipv4-interface.cc +++ b/src/internet-stack/ipv4-interface.cc @@ -34,6 +34,8 @@ NS_LOG_COMPONENT_DEFINE ("Ipv4Interface"); namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (Ipv4Interface); + TypeId Ipv4Interface::GetTypeId (void) { diff --git a/src/internet-stack/loopback-net-device.cc b/src/internet-stack/loopback-net-device.cc index 9182e8144..644ab6810 100644 --- a/src/internet-stack/loopback-net-device.cc +++ b/src/internet-stack/loopback-net-device.cc @@ -28,6 +28,8 @@ NS_LOG_COMPONENT_DEFINE ("LoopbackNetDevice"); namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (LoopbackNetDevice); + TypeId LoopbackNetDevice::GetTypeId (void) { diff --git a/src/internet-stack/ndisc-cache.cc b/src/internet-stack/ndisc-cache.cc index 246874064..d31730f65 100644 --- a/src/internet-stack/ndisc-cache.cc +++ b/src/internet-stack/ndisc-cache.cc @@ -32,6 +32,8 @@ namespace ns3 NS_LOG_COMPONENT_DEFINE ("NdiscCache"); +NS_OBJECT_ENSURE_REGISTERED (NdiscCache); + TypeId NdiscCache::GetTypeId () { static TypeId tid = TypeId ("ns3::NdiscCache") diff --git a/src/internet-stack/nsc-sysctl.cc b/src/internet-stack/nsc-sysctl.cc index 1ce0ea548..1280c2a1a 100644 --- a/src/internet-stack/nsc-sysctl.cc +++ b/src/internet-stack/nsc-sysctl.cc @@ -142,6 +142,8 @@ Ns3NscStack::Set (std::string name, std::string value) } } +NS_OBJECT_ENSURE_REGISTERED (Ns3NscStack); + TypeId Ns3NscStack::Ns3NscStack::GetTypeId (void) { diff --git a/src/mobility/mobility-model.cc b/src/mobility/mobility-model.cc index b88d74710..12f2d47c8 100644 --- a/src/mobility/mobility-model.cc +++ b/src/mobility/mobility-model.cc @@ -25,6 +25,8 @@ namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (MobilityModel); + TypeId MobilityModel::GetTypeId (void) { diff --git a/src/node/packet-socket.cc b/src/node/packet-socket.cc index 9ca73dc42..06d1772ef 100644 --- a/src/node/packet-socket.cc +++ b/src/node/packet-socket.cc @@ -33,6 +33,8 @@ NS_LOG_COMPONENT_DEFINE ("PacketSocket"); namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (PacketSocket); + TypeId PacketSocket::GetTypeId (void) { diff --git a/src/node/radiotap-header.cc b/src/node/radiotap-header.cc index afaa83c57..49dc16795 100644 --- a/src/node/radiotap-header.cc +++ b/src/node/radiotap-header.cc @@ -26,6 +26,8 @@ NS_LOG_COMPONENT_DEFINE ("RadiotapHeader"); namespace ns3 { + +NS_OBJECT_ENSURE_REGISTERED (RadiotapHeader); RadiotapHeader::RadiotapHeader() : m_length(8), @@ -43,7 +45,7 @@ RadiotapHeader::RadiotapHeader() TypeId RadiotapHeader::GetTypeId (void) { - static TypeId tid = TypeId ("RadiotapHeader") + static TypeId tid = TypeId ("ns3::RadiotapHeader") .SetParent
() .AddConstructor () ; diff --git a/src/node/simple-channel.cc b/src/node/simple-channel.cc index dbd9b6f5b..c0d3760cf 100644 --- a/src/node/simple-channel.cc +++ b/src/node/simple-channel.cc @@ -28,6 +28,8 @@ NS_LOG_COMPONENT_DEFINE ("SimpleChannel"); namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (SimpleChannel); + TypeId SimpleChannel::GetTypeId (void) { diff --git a/src/node/simple-net-device.cc b/src/node/simple-net-device.cc index 49e527499..921b4d9fe 100644 --- a/src/node/simple-net-device.cc +++ b/src/node/simple-net-device.cc @@ -30,6 +30,8 @@ NS_LOG_COMPONENT_DEFINE ("SimpleNetDevice"); namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (SimpleNetDevice); + TypeId SimpleNetDevice::GetTypeId (void) { diff --git a/src/node/socket.cc b/src/node/socket.cc index d05a5f222..f5884ec7c 100644 --- a/src/node/socket.cc +++ b/src/node/socket.cc @@ -344,6 +344,7 @@ SocketAddressTag::GetAddress (void) const return m_address; } +NS_OBJECT_ENSURE_REGISTERED (SocketAddressTag); TypeId SocketAddressTag::GetTypeId (void) @@ -396,6 +397,7 @@ SocketIpTtlTag::GetTtl (void) const return m_ttl; } +NS_OBJECT_ENSURE_REGISTERED (SocketIpTtlTag); TypeId SocketIpTtlTag::GetTypeId (void) @@ -452,6 +454,8 @@ SocketSetDontFragmentTag::IsEnabled (void) const return m_dontFragment; } +NS_OBJECT_ENSURE_REGISTERED (SocketSetDontFragmentTag); + TypeId SocketSetDontFragmentTag::GetTypeId (void) { diff --git a/src/routing/aodv/aodv-packet.cc b/src/routing/aodv/aodv-packet.cc index 30b0298af..9c3684f66 100644 --- a/src/routing/aodv/aodv-packet.cc +++ b/src/routing/aodv/aodv-packet.cc @@ -34,6 +34,8 @@ namespace ns3 namespace aodv { +NS_OBJECT_ENSURE_REGISTERED (TypeHeader); + TypeHeader::TypeHeader (MessageType t) : m_type (t), m_valid (true) { @@ -143,6 +145,8 @@ RreqHeader::RreqHeader (uint8_t flags, uint8_t reserved, uint8_t hopCount, uint3 { } +NS_OBJECT_ENSURE_REGISTERED (RreqHeader); + TypeId RreqHeader::GetTypeId () { @@ -280,6 +284,8 @@ RrepHeader::RrepHeader (uint8_t prefixSize, uint8_t hopCount, Ipv4Address dst, m_lifeTime = uint32_t (lifeTime.GetMilliSeconds ()); } +NS_OBJECT_ENSURE_REGISTERED (RrepHeader); + TypeId RrepHeader::GetTypeId () { @@ -421,6 +427,7 @@ RrepAckHeader::RrepAckHeader () : { } +NS_OBJECT_ENSURE_REGISTERED (RrepAckHeader); TypeId RrepAckHeader::GetTypeId () { @@ -485,6 +492,8 @@ RerrHeader::RerrHeader () : { } +NS_OBJECT_ENSURE_REGISTERED (RerrHeader); + TypeId RerrHeader::GetTypeId () { diff --git a/src/routing/static-routing/ipv6-static-routing.cc b/src/routing/static-routing/ipv6-static-routing.cc index 1ec9ed419..6a9aeb7f9 100644 --- a/src/routing/static-routing/ipv6-static-routing.cc +++ b/src/routing/static-routing/ipv6-static-routing.cc @@ -30,6 +30,7 @@ namespace ns3 { NS_LOG_COMPONENT_DEFINE ("Ipv6StaticRouting"); +NS_OBJECT_ENSURE_REGISTERED (Ipv6StaticRouting); TypeId Ipv6StaticRouting::GetTypeId () { diff --git a/src/simulator/scheduler.cc b/src/simulator/scheduler.cc index aec66614b..b416fee0f 100644 --- a/src/simulator/scheduler.cc +++ b/src/simulator/scheduler.cc @@ -23,6 +23,8 @@ namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (Scheduler); + Scheduler::~Scheduler () { } diff --git a/src/simulator/synchronizer.cc b/src/simulator/synchronizer.cc index 41d68e652..765ed98ab 100644 --- a/src/simulator/synchronizer.cc +++ b/src/simulator/synchronizer.cc @@ -20,10 +20,12 @@ namespace ns3 { +NS_OBJECT_ENSURE_REGISTERED (Synchronizer); + TypeId Synchronizer::GetTypeId (void) { - static TypeId tid = TypeId ("Synchronizer") + static TypeId tid = TypeId ("ns3::Synchronizer") .SetParent () ; return tid;