Adding more doxygen documentation
diff --git a/apps/ccnx-app.h b/apps/ccnx-app.h
index c83ee0f..56093f9 100644
--- a/apps/ccnx-app.h
+++ b/apps/ccnx-app.h
@@ -44,7 +44,7 @@
{
public:
/**
- * \typedef A callback to pass packets to underlying CCNx protocol
+ * @brief A callback to pass packets to underlying CCNx protocol
*/
typedef Callback<bool, const Ptr<const Packet>&> ProtocolHandler;
@@ -88,36 +88,39 @@
Ptr<Packet> payload);
protected:
+ /**
+ * @brief Do cleanup when application is destroyed
+ */
virtual void
DoDispose ();
// inherited from Application base class. Originally they were private
virtual void
- StartApplication (); // Called at time specified by Start
+ StartApplication (); ///< @brief Called at time specified by Start
virtual void
- StopApplication (); // Called at time specified by Stop
+ StopApplication (); ///< @brief Called at time specified by Stop
protected:
- ProtocolHandler m_protocolHandler; ///< \brief A callback to pass packets to underlying CCNx protocol
- bool m_active;
- Ptr<CcnxFace> m_face; // local face that is created
+ ProtocolHandler m_protocolHandler; ///< @brief A callback to pass packets to underlying CCNx protocol
+ bool m_active; ///< @brief Flag to indicate that application is active (set by StartApplication and StopApplication)
+ Ptr<CcnxFace> m_face; ///< @brief automatically created application face through which application communicates
TracedCallback<Ptr<const CcnxInterestHeader>,
- Ptr<CcnxApp>, Ptr<CcnxFace> > m_receivedInterests;
+ Ptr<CcnxApp>, Ptr<CcnxFace> > m_receivedInterests; ///< @brief App-level trace of received Interests
TracedCallback<Ptr<const CcnxInterestHeader>,
- Ptr<CcnxApp>, Ptr<CcnxFace> > m_receivedNacks;
+ Ptr<CcnxApp>, Ptr<CcnxFace> > m_receivedNacks; ///< @brief App-level trace of received NACKs
TracedCallback<Ptr<const CcnxContentObjectHeader>, Ptr<const Packet>,
- Ptr<CcnxApp>, Ptr<CcnxFace> > m_receivedContentObjects;
+ Ptr<CcnxApp>, Ptr<CcnxFace> > m_receivedContentObjects; ///< @brief App-level trace of received Data
TracedCallback<Ptr<const CcnxInterestHeader>,
- Ptr<CcnxApp>, Ptr<CcnxFace> > m_transmittedInterests;
+ Ptr<CcnxApp>, Ptr<CcnxFace> > m_transmittedInterests; ///< @brief App-level trace of transmitted Interests
TracedCallback<Ptr<const CcnxContentObjectHeader>, Ptr<const Packet>,
- Ptr<CcnxApp>, Ptr<CcnxFace> > m_transmittedContentObjects;
+ Ptr<CcnxApp>, Ptr<CcnxFace> > m_transmittedContentObjects; ///< @brief App-level trace of transmitted Data
};
} // namespace ns3
diff --git a/apps/ccnx-consumer-cbr.h b/apps/ccnx-consumer-cbr.h
index 8f84a5b..6490fc8 100644
--- a/apps/ccnx-consumer-cbr.h
+++ b/apps/ccnx-consumer-cbr.h
@@ -61,9 +61,17 @@
virtual void
ScheduleNextPacket ();
+ /**
+ * @brief Set type of frequency randomization
+ * @param value Either 'none', 'uniform', or 'exponential'
+ */
void
SetRandomize (const std::string &value);
+ /**
+ * @brief Get type of frequency randomization
+ * @returns either 'none', 'uniform', or 'exponential'
+ */
std::string
GetRandomize () const;
@@ -80,7 +88,7 @@
// DataRate
// GetDesiredRate () const;
-protected:
+private:
double m_frequency; // Frequency of interest packets (in hertz)
bool m_firstTime;
RandomVariable *m_random;
diff --git a/apps/ccnx-consumer-window.h b/apps/ccnx-consumer-window.h
index 21a9759..cde300a 100644
--- a/apps/ccnx-consumer-window.h
+++ b/apps/ccnx-consumer-window.h
@@ -31,6 +31,9 @@
/**
* @ingroup ccnx
* \brief CCNx application for sending out Interest packets (window-based)
+ *
+ * !!! ATTENTION !!! This is highly experimental and relies on experimental features of the simulator.
+ * Behavior may be unpredictable if used incorrectly.
*/
class CcnxConsumerWindow: public CcnxConsumer
{
@@ -82,7 +85,7 @@
void
SetMaxSize (double size);
-protected:
+private:
uint32_t m_payloadSize; // expected payload size
double m_maxSize; // max size to request
diff --git a/apps/ccnx-consumer.h b/apps/ccnx-consumer.h
index 3477a66..dacc586 100644
--- a/apps/ccnx-consumer.h
+++ b/apps/ccnx-consumer.h
@@ -67,10 +67,16 @@
OnContentObject (const Ptr<const CcnxContentObjectHeader> &contentObject,
Ptr<Packet> payload);
+ /**
+ * @brief Timeout event
+ * @param sequenceNumber time outed sequence number
+ */
virtual void
OnTimeout (uint32_t sequenceNumber);
- // Simulator::Schedule doesn't work with protected members???
+ /**
+ * @brief Actually send packet
+ */
void
SendPacket ();
@@ -109,15 +115,15 @@
GetRetxTimer () const;
protected:
- UniformVariable m_rand; // nonce generator
+ UniformVariable m_rand; ///< @brief nonce generator
- uint32_t m_seq;
- uint32_t m_seqMax; // maximum number of sequence number
- EventId m_sendEvent; // Eventid of pending "send packet" event
- Time m_retxTimer;
- EventId m_retxEvent; // Event to check whether or not retransmission should be performed
+ uint32_t m_seq; ///< @brief currently requested sequence number
+ uint32_t m_seqMax; ///< @brief maximum number of sequence number
+ EventId m_sendEvent; ///< @brief EventId of pending "send packet" event
+ Time m_retxTimer; ///< @brief Currently estimated retransmission timer
+ EventId m_retxEvent; ///< @brief Event to check whether or not retransmission should be performed
- Ptr<RttEstimator> m_rtt;
+ Ptr<RttEstimator> m_rtt; ///< @brief RTT estimator
Time m_offTime; ///< \brief Time interval between packets
CcnxNameComponents m_interestName; ///< \brief CcnxName of the Interest (use CcnxNameComponents)
@@ -171,12 +177,12 @@
>
>
> { } ;
-/// @endcond
SeqTimeoutsContainer m_seqTimeouts; ///< \brief multi-index for the set of SeqTimeout structs
SeqTimeoutsContainer m_seqLifetimes;
TracedCallback<Ptr<Node>, Ptr<Node>, uint32_t, uint32_t > m_pathWeightsTrace;
+/// @endcond
};
} // namespace ns3
diff --git a/apps/ccnx-producer.h b/apps/ccnx-producer.h
index 55e7162..4b54d79 100644
--- a/apps/ccnx-producer.h
+++ b/apps/ccnx-producer.h
@@ -31,6 +31,14 @@
namespace ns3
{
+/**
+ * @brief A simple Interest-sink applia simple Interest-sink application
+ *
+ * A simple Interest-sink applia simple Interest-sink application,
+ * which replying every incoming Interest with Data packet with a specified
+ * size and name same as in Interest.cation, which replying every incoming Interest
+ * with Data packet with a specified size and name same as in Interest.
+ */
class CcnxProducer : public CcnxApp
{
public: