diff --git a/src/core/model/attribute-helper.h b/src/core/model/attribute-helper.h --- a/src/core/model/attribute-helper.h +++ b/src/core/model/attribute-helper.h @@ -55,7 +55,7 @@ * Because these macros generate class and function definitions, it's * difficult to document the results directly. Instead, we use a * set of functions in print-introspected-doxygen.cc to generate - * most of the APi documentation. When using these macros, + * most of the API documentation. When using these macros, * please add the required function calls to print-introspected-doxygen.cc * so your new API is documented. */ diff --git a/src/core/model/type-id.cc b/src/core/model/type-id.cc --- a/src/core/model/type-id.cc +++ b/src/core/model/type-id.cc @@ -610,6 +610,12 @@ { NS_LOG_FUNCTION (this << uid << name << help << flags << initialValue << accessor << checker); struct IidInformation *information = LookupInformation (uid); + if (name.find (' ') != std::string::npos) + { + NS_FATAL_ERROR ("Attribute name \"" << name << "\" may not contain spaces ' ', " + << "encountered when registering TypeId \"" + << information->name << "\""); + } if (HasAttribute (uid, name)) { NS_FATAL_ERROR ("Attribute \"" << name << "\" already registered on tid=\"" << diff --git a/src/internet/model/ipv6-extension.cc b/src/internet/model/ipv6-extension.cc --- a/src/internet/model/ipv6-extension.cc +++ b/src/internet/model/ipv6-extension.cc @@ -832,7 +832,7 @@ static TypeId tid = TypeId ("ns3::Ipv6ExtensionRoutingDemux") .SetParent () .SetGroupName ("Internet") - .AddAttribute ("Routing Extensions", "The set of IPv6 Routing extensions registered with this demux.", + .AddAttribute ("RoutingExtensions", "The set of IPv6 Routing extensions registered with this demux.", ObjectVectorValue (), MakeObjectVectorAccessor (&Ipv6ExtensionRoutingDemux::m_extensionsRouting), MakeObjectVectorChecker ()) diff --git a/src/traffic-control/model/fq-codel-queue-disc.cc b/src/traffic-control/model/fq-codel-queue-disc.cc --- a/src/traffic-control/model/fq-codel-queue-disc.cc +++ b/src/traffic-control/model/fq-codel-queue-disc.cc @@ -105,7 +105,7 @@ StringValue ("5ms"), MakeStringAccessor (&FqCoDelQueueDisc::m_target), MakeStringChecker ()) - .AddAttribute ("Packet limit", + .AddAttribute ("PacketLimit", "The hard limit on the real queue size, measured in packets", UintegerValue (10 * 1024), MakeUintegerAccessor (&FqCoDelQueueDisc::m_limit), diff --git a/src/wifi/model/ampdu-tag.cc b/src/wifi/model/ampdu-tag.cc --- a/src/wifi/model/ampdu-tag.cc +++ b/src/wifi/model/ampdu-tag.cc @@ -34,7 +34,7 @@ .SetParent () .SetGroupName ("Wifi") .AddConstructor () - .AddAttribute ("Ampdu Exists", "The value that indicates that the packet contains an AMPDU", + .AddAttribute ("AmpduExists", "The value that indicates that the packet contains an AMPDU", UintegerValue (false), MakeUintegerAccessor (&AmpduTag::GetAmpdu), MakeUintegerChecker ()) diff --git a/src/wifi/model/aparf-wifi-manager.cc b/src/wifi/model/aparf-wifi-manager.cc --- a/src/wifi/model/aparf-wifi-manager.cc +++ b/src/wifi/model/aparf-wifi-manager.cc @@ -62,12 +62,12 @@ .SetParent () .SetGroupName ("Wifi") .AddConstructor () - .AddAttribute ("SuccessThreshold 1", + .AddAttribute ("SuccessThreshold1", "The minimum number of successful transmissions in \"High\" state to try a new power or rate.", UintegerValue (3), MakeUintegerAccessor (&AparfWifiManager::m_succesMax1), MakeUintegerChecker ()) - .AddAttribute ("SuccessThreshold 2", + .AddAttribute ("SuccessThreshold2", "The minimum number of successful transmissions in \"Low\" state to try a new power or rate.", UintegerValue (10), MakeUintegerAccessor (&AparfWifiManager::m_succesMax2), @@ -82,22 +82,22 @@ UintegerValue (10), MakeUintegerAccessor (&AparfWifiManager::m_powerMax), MakeUintegerChecker ()) - .AddAttribute ("Power decrement step", + .AddAttribute ("PowerDecrementStep", "Step size for decrement the power.", UintegerValue (1), MakeUintegerAccessor (&AparfWifiManager::m_powerDec), MakeUintegerChecker ()) - .AddAttribute ("Power increment step", + .AddAttribute ("PowerIncrementStep", "Step size for increment the power.", UintegerValue (1), MakeUintegerAccessor (&AparfWifiManager::m_powerInc), MakeUintegerChecker ()) - .AddAttribute ("Rate decrement step", + .AddAttribute ("RateDecrementStep", "Step size for decrement the rate.", UintegerValue (1), MakeUintegerAccessor (&AparfWifiManager::m_rateDec), MakeUintegerChecker ()) - .AddAttribute ("Rate increment step", + .AddAttribute ("RateIncrementStep", "Step size for increment the rate.", UintegerValue (1), MakeUintegerAccessor (&AparfWifiManager::m_rateInc), diff --git a/src/wifi/test/power-rate-adaptation-test.cc b/src/wifi/test/power-rate-adaptation-test.cc --- a/src/wifi/test/power-rate-adaptation-test.cc +++ b/src/wifi/test/power-rate-adaptation-test.cc @@ -348,8 +348,8 @@ /* * Configure thresholds for rate and power control. */ - manager->SetAttribute ("SuccessThreshold 1",UintegerValue (3)); - manager->SetAttribute ("SuccessThreshold 2",UintegerValue (10)); + manager->SetAttribute ("SuccessThreshold1",UintegerValue (3)); + manager->SetAttribute ("SuccessThreshold2",UintegerValue (10)); manager->SetAttribute ("FailThreshold",UintegerValue (1)); manager->SetAttribute ("PowerThreshold",UintegerValue (10));