From 90cf5b60a2d6885690dcd1b0d4ec33376896c63a Mon Sep 17 00:00:00 2001 From: "Peter D. Barnes, Jr." Date: Wed, 7 Jan 2015 15:43:53 -0800 Subject: [PATCH] [Doxygen] Files implementing attributes. --- src/core/model/attribute-accessor-helper.h | 6 ++++++ src/core/model/attribute-construction-list.cc | 6 ++++++ src/core/model/attribute-construction-list.h | 6 ++++++ src/core/model/attribute-helper.h | 6 ++++++ src/core/model/attribute.cc | 7 +++++++ src/core/model/attribute.h | 13 ++++++++++++- src/core/model/boolean.cc | 6 ++++++ src/core/model/boolean.h | 6 ++++++ src/core/model/double.cc | 16 ++++++++++++++++ src/core/model/double.h | 11 +++++++++++ src/core/model/enum.cc | 6 ++++++ src/core/model/enum.h | 8 +++++++- src/core/model/integer.cc | 15 +++++++++++++++ src/core/model/integer.h | 13 ++++++++++++- src/core/model/object-map.h | 6 ++++++ src/core/model/object-ptr-container.cc | 6 ++++++ src/core/model/object-ptr-container.h | 7 +++++++ src/core/model/object-vector.h | 6 ++++++ src/core/model/pointer.cc | 6 ++++++ src/core/model/pointer.h | 13 ++++++++++++- src/core/model/string.cc | 6 ++++++ src/core/model/string.h | 8 +++++++- src/core/model/type-name.cc | 6 ++++++ src/core/model/type-name.h | 6 ++++++ src/core/model/uinteger.cc | 15 +++++++++++++++ src/core/model/uinteger.h | 13 ++++++++++++- src/core/model/vector.cc | 6 ++++++ src/core/model/vector.h | 6 ++++++ 28 files changed, 229 insertions(+), 6 deletions(-) diff --git a/src/core/model/attribute-accessor-helper.h b/src/core/model/attribute-accessor-helper.h index 18056501f..54d0a92a1 100644 --- a/src/core/model/attribute-accessor-helper.h +++ b/src/core/model/attribute-accessor-helper.h @@ -22,6 +22,12 @@ #include "attribute.h" +/** + * \file + * \ingroup attributeimpl + * ns3::MakeAccessorHelper declarations and template implementations. + */ + namespace ns3 { diff --git a/src/core/model/attribute-construction-list.cc b/src/core/model/attribute-construction-list.cc index e54246483..038842ea0 100644 --- a/src/core/model/attribute-construction-list.cc +++ b/src/core/model/attribute-construction-list.cc @@ -20,6 +20,12 @@ #include "attribute-construction-list.h" #include "log.h" +/** + * \file + * \ingroup object + * ns3::AttributeConstructionList implementation. + */ + namespace ns3 { NS_LOG_COMPONENT_DEFINE("AttributeConstructionList"); diff --git a/src/core/model/attribute-construction-list.h b/src/core/model/attribute-construction-list.h index 0866e8eb3..14881ed3b 100644 --- a/src/core/model/attribute-construction-list.h +++ b/src/core/model/attribute-construction-list.h @@ -23,6 +23,12 @@ #include "attribute.h" #include +/** + * \file + * \ingroup object + * ns3::AttributeConstructionList declaration. + */ + namespace ns3 { /** diff --git a/src/core/model/attribute-helper.h b/src/core/model/attribute-helper.h index ff0c65529..7b9f2c473 100644 --- a/src/core/model/attribute-helper.h +++ b/src/core/model/attribute-helper.h @@ -25,6 +25,12 @@ #include #include "fatal-error.h" +/** + * \file + * \ingroup attributehelper + * Declaration of Attribute helper macros. + */ + namespace ns3 { /** diff --git a/src/core/model/attribute.cc b/src/core/model/attribute.cc index 1a2e5ad30..7f427529b 100644 --- a/src/core/model/attribute.cc +++ b/src/core/model/attribute.cc @@ -23,6 +23,13 @@ #include "string.h" #include +/** + * \file + * \ingroup attribute + * ns3::AttributeValue, ns3::AttributeAccessor and + * ns3::AttributeChecker implementations. + */ + namespace ns3 { NS_LOG_COMPONENT_DEFINE ("AttributeValue"); diff --git a/src/core/model/attribute.h b/src/core/model/attribute.h index 643d25cc7..44b2f082c 100644 --- a/src/core/model/attribute.h +++ b/src/core/model/attribute.h @@ -25,6 +25,13 @@ #include "ptr.h" #include "simple-ref-count.h" +/** + * \file + * \ingroup attribute + * ns3::AttributeValue, ns3::AttributeAccessor and + * ns3::AttributeChecker declarations. + */ + namespace ns3 { class AttributeAccessor; @@ -219,7 +226,11 @@ public: }; -/** A class for an empty attribute value. */ +/** + * \brief A class for an empty attribute value. + * + * \ingroup attribute + */ class EmptyAttributeValue : public AttributeValue { public: diff --git a/src/core/model/boolean.cc b/src/core/model/boolean.cc index 42957b9eb..09bf82a94 100644 --- a/src/core/model/boolean.cc +++ b/src/core/model/boolean.cc @@ -21,6 +21,12 @@ #include "fatal-error.h" #include "log.h" +/** + * \file + * \ingroup attribute_Boolean + * Boolean attribute value implementaations. + */ + namespace ns3 { NS_LOG_COMPONENT_DEFINE ("Boolean"); diff --git a/src/core/model/boolean.h b/src/core/model/boolean.h index ada957d56..ab65c99ec 100644 --- a/src/core/model/boolean.h +++ b/src/core/model/boolean.h @@ -23,6 +23,12 @@ #include "attribute.h" #include "attribute-helper.h" +/** + * \file + * \ingroup attribute_Boolean + * Boolean attribute value declarations. + */ + namespace ns3 { class BooleanValue : public AttributeValue diff --git a/src/core/model/double.cc b/src/core/model/double.cc index 585f031ea..8907e975f 100644 --- a/src/core/model/double.cc +++ b/src/core/model/double.cc @@ -22,14 +22,30 @@ #include "log.h" #include +/** + * \file + * \ingroup attribute_Double + * Double attribute value implementations. + */ + namespace ns3 { NS_LOG_COMPONENT_DEFINE ("Double"); ATTRIBUTE_VALUE_IMPLEMENT_WITH_NAME (double, Double); +/** Namespace for implementation details. */ namespace internal { +/** + * \ingroup attribute_Double + * Make a Double attribute checker with embedded numeric type name. + * + * \param min The minimum allowed value. + * \param max The maximum allowed value. + * \param name The original type name ("float", "double"). + * \returns The AttributeChecker. + */ Ptr MakeDoubleChecker (double min, double max, std::string name) { NS_LOG_FUNCTION (min << max << name); diff --git a/src/core/model/double.h b/src/core/model/double.h index 3ef34f818..c708823ab 100644 --- a/src/core/model/double.h +++ b/src/core/model/double.h @@ -25,6 +25,12 @@ #include #include +/** + * \file + * \ingroup attribute_Double + * Double attribute value declarations and template implementations. + */ + namespace ns3 { // Additional docs for class DoubleValue: @@ -66,6 +72,11 @@ Ptr MakeDoubleChecker (double min, double max); } // namespace ns3 + +/*************************************************************** + * Implementation of the templates declared above. + ***************************************************************/ + #include "type-name.h" namespace ns3 { diff --git a/src/core/model/enum.cc b/src/core/model/enum.cc index eb4c91199..38eba98b6 100644 --- a/src/core/model/enum.cc +++ b/src/core/model/enum.cc @@ -22,6 +22,12 @@ #include "log.h" #include +/** + * \file + * \ingroup attribute_Enum + * Enum attribute value implementations. + */ + namespace ns3 { NS_LOG_COMPONENT_DEFINE ("Enum"); diff --git a/src/core/model/enum.h b/src/core/model/enum.h index ae690e17e..6909b3d20 100644 --- a/src/core/model/enum.h +++ b/src/core/model/enum.h @@ -24,9 +24,15 @@ #include "attribute-accessor-helper.h" #include +/** + * \file + * \ingroup attribute_Enum + * Enum attribute value declarations. + */ + namespace ns3 { -// Additional docs for class DoubleValue: +// Additional docs for class EnumValue: /** * Hold variables of type \c enum * diff --git a/src/core/model/integer.cc b/src/core/model/integer.cc index 324123585..a0a2d12f3 100644 --- a/src/core/model/integer.cc +++ b/src/core/model/integer.cc @@ -22,6 +22,12 @@ #include "log.h" #include +/** + * \file + * \ingroup attribute_Integer + * Integer attribute value implementations. + */ + namespace ns3 { NS_LOG_COMPONENT_DEFINE ("Integer"); @@ -30,6 +36,15 @@ ATTRIBUTE_VALUE_IMPLEMENT_WITH_NAME (int64_t, Integer); namespace internal { +/** + * \ingroup attribute_Integer + * Make an Integer attribute checker with embedded numeric type name. + * + * \param min The minimum allowed value. + * \param max The maximum allowed value. + * \param name The original type name ("int8_t", "int16_t", _etc_.). + * \returns The AttributeChecker. + */ Ptr MakeIntegerChecker (int64_t min, int64_t max, std::string name) { diff --git a/src/core/model/integer.h b/src/core/model/integer.h index 6f2ee3309..68eacc9e4 100644 --- a/src/core/model/integer.h +++ b/src/core/model/integer.h @@ -25,9 +25,15 @@ #include #include +/** + * \file + * \ingroup attribute_Integer + * Integer attribute value declarations and template implementations. + */ + namespace ns3 { -// Additional docs for class DoubleValue: +// Additional docs for class IntegerValue: /** * Hold a signed integer type * @@ -68,6 +74,11 @@ Ptr MakeIntegerChecker (int64_t min, int64_t max); } // namespace ns3 + +/*************************************************************** + * Implementation of the templates declared above. + ***************************************************************/ + #include "type-name.h" namespace ns3 { diff --git a/src/core/model/object-map.h b/src/core/model/object-map.h index deb8013a5..42f98e3ee 100644 --- a/src/core/model/object-map.h +++ b/src/core/model/object-map.h @@ -25,6 +25,12 @@ #include "attribute.h" #include "object-ptr-container.h" +/** + * \file + * \ingroup attribute_ObjectMap + * ObjectMap attribute value declarations and template implementations. + */ + namespace ns3 { /** diff --git a/src/core/model/object-ptr-container.cc b/src/core/model/object-ptr-container.cc index 65f3bef66..5187cbc1c 100644 --- a/src/core/model/object-ptr-container.cc +++ b/src/core/model/object-ptr-container.cc @@ -20,6 +20,12 @@ #include "object-ptr-container.h" #include "log.h" +/** + * \file + * \ingroup attribute_ObjectPtrContainer + * ObjectPtrContainer attribute value implementation. + */ + namespace ns3 { NS_LOG_COMPONENT_DEFINE ("ObjectPtrContainer"); diff --git a/src/core/model/object-ptr-container.h b/src/core/model/object-ptr-container.h index 96eea74ca..b2f219eff 100644 --- a/src/core/model/object-ptr-container.h +++ b/src/core/model/object-ptr-container.h @@ -25,6 +25,13 @@ #include "ptr.h" #include "attribute.h" +/** + * \file + * \ingroup attribute_ObjectPtrContainer + * ObjectPtrContainer attribute value declarations and template implementations. + */ + + namespace ns3 { /** diff --git a/src/core/model/object-vector.h b/src/core/model/object-vector.h index 77e857884..608437fba 100644 --- a/src/core/model/object-vector.h +++ b/src/core/model/object-vector.h @@ -25,6 +25,12 @@ #include "attribute.h" #include "object-ptr-container.h" +/** + * \file + * \ingroup attribute_ObjectVector + * ObjectVector attribute value declarations and template implementations. + */ + namespace ns3 { /** diff --git a/src/core/model/pointer.cc b/src/core/model/pointer.cc index d7652bbd5..97fb59e09 100644 --- a/src/core/model/pointer.cc +++ b/src/core/model/pointer.cc @@ -22,6 +22,12 @@ #include "log.h" #include +/** + * \file + * \ingroup attribute_Pointer + * Pointer attribute value implementations. + */ + namespace ns3 { NS_LOG_COMPONENT_DEFINE ("Pointer"); diff --git a/src/core/model/pointer.h b/src/core/model/pointer.h index 1badad152..785fef5c2 100644 --- a/src/core/model/pointer.h +++ b/src/core/model/pointer.h @@ -23,6 +23,12 @@ #include "attribute.h" #include "object.h" +/** + * \file + * \ingroup attribute_Pointer + * Pointer attribute value declarations and template implementations. + */ + namespace ns3 { // Additional docs for class PointerValue: @@ -99,9 +105,14 @@ Ptr MakePointerChecker (void); } // namespace ns3 -namespace ns3 { +/*************************************************************** + * Implementation of the templates declared above. + ***************************************************************/ + +namespace ns3 { + namespace internal { /** PointerChecker implementation. */ diff --git a/src/core/model/string.cc b/src/core/model/string.cc index 5544a5405..e3e13748a 100644 --- a/src/core/model/string.cc +++ b/src/core/model/string.cc @@ -19,6 +19,12 @@ #include "string.h" +/** + * \file + * \ingroup attribute_String + * String attribute value implementations. + */ + namespace ns3 { ATTRIBUTE_CHECKER_IMPLEMENT_WITH_NAME (String, "std::string"); diff --git a/src/core/model/string.h b/src/core/model/string.h index ffc1d8c10..eff162aac 100644 --- a/src/core/model/string.h +++ b/src/core/model/string.h @@ -23,9 +23,15 @@ #include #include "attribute-helper.h" +/** + * \file + * \ingroup attribute_String + * String attribute value declarations. + */ + namespace ns3 { -// Additional docs for class DoubleValue: +// Additional docs for class StringValue: /** * Hold variables of type string * diff --git a/src/core/model/type-name.cc b/src/core/model/type-name.cc index 6ed303d31..4640420f6 100644 --- a/src/core/model/type-name.cc +++ b/src/core/model/type-name.cc @@ -19,6 +19,12 @@ #include "type-name.h" +/** + * \file + * \ingroup attributeimpl + * ns3::TypeNameGet() function implementations. + */ + namespace ns3 { template <> std::string TypeNameGet< int8_t > (void) { return "int8_t" ; } diff --git a/src/core/model/type-name.h b/src/core/model/type-name.h index 2ade473c9..c59d11066 100644 --- a/src/core/model/type-name.h +++ b/src/core/model/type-name.h @@ -23,6 +23,12 @@ #include #include +/** + * \file + * \ingroup attributeimpl + * ns3::TypeNameGet() function declarations. + */ + namespace ns3 { /** diff --git a/src/core/model/uinteger.cc b/src/core/model/uinteger.cc index fc9589642..37c1718fe 100644 --- a/src/core/model/uinteger.cc +++ b/src/core/model/uinteger.cc @@ -22,6 +22,12 @@ #include "log.h" #include +/** + * \file + * \ingroup attribute_Uinteger + * Uinteger attribute value implementations. + */ + namespace ns3 { NS_LOG_COMPONENT_DEFINE ("Uinteger"); @@ -30,6 +36,15 @@ ATTRIBUTE_VALUE_IMPLEMENT_WITH_NAME (uint64_t,Uinteger); namespace internal { +/** + * \ingroup attribute_Uinteger + * Make an Uinteger attribute checker with embedded numeric type name. + * + * \param min The minimum allowed value. + * \param max The maximum allowed value. + * \param name The original type name ("uint8_t", "uint16_t", _etc_.). + * \returns The AttributeChecker. + */ Ptr MakeUintegerChecker (uint64_t min, uint64_t max, std::string name) { NS_LOG_FUNCTION (min << max << name); diff --git a/src/core/model/uinteger.h b/src/core/model/uinteger.h index 7e0c29e7b..abf4c24d3 100644 --- a/src/core/model/uinteger.h +++ b/src/core/model/uinteger.h @@ -25,9 +25,15 @@ #include #include +/** + * \file + * \ingroup attribute_Uinteger + * Unsigned integer attribute value declarations and template implementations. + */ + namespace ns3 { -// Additional docs for class DoubleValue: +// Additional docs for class UintegerValue: /** * Hold an unsigned integer type. * @@ -69,6 +75,11 @@ Ptr MakeUintegerChecker (uint64_t min, uint64_t max); } // namespace ns3 + +/*************************************************************** + * Implementation of the templates declared above. + ***************************************************************/ + #include "type-name.h" namespace ns3 { diff --git a/src/core/model/vector.cc b/src/core/model/vector.cc index 12d37adb4..a3a824015 100644 --- a/src/core/model/vector.cc +++ b/src/core/model/vector.cc @@ -23,6 +23,12 @@ #include #include +/** + * \file + * \ingroup attribute_Vector + * ns3::Vector, ns3::Vector2D and ns3::Vector3D attribute value implementations. + */ + namespace ns3 { NS_LOG_COMPONENT_DEFINE ("Vector"); diff --git a/src/core/model/vector.h b/src/core/model/vector.h index eaa0b92e7..6f013b293 100644 --- a/src/core/model/vector.h +++ b/src/core/model/vector.h @@ -23,6 +23,12 @@ #include "attribute.h" #include "attribute-helper.h" +/** + * \file + * \ingroup attribute_Vector + * ns3::Vector, ns3::Vector2D and ns3::Vector3D attribute value declarations. + */ + namespace ns3 { /**