diff --git a/doc/Doxyfile.extra.in b/doc/Doxyfile.extra.in index 6aa319ac48d5b94db0ea62c52fd53685b76657dc..156f8f2d373927e8a63610304ad9763870496fc9 100644 --- a/doc/Doxyfile.extra.in +++ b/doc/Doxyfile.extra.in @@ -6,4 +6,6 @@ IMAGE_PATH = @CMAKE_SOURCE_DIR@/doc/pictures \ FILE_PATTERNS = *.cc *.cpp *.h *.hh *.hxx TAGFILES = \ -"@CMAKE_INSTALL_PREFIX@/share/doc/dynamic-graph-python.doxytag = @CMAKE_INSTALL_PREFIX@/share/doc/dynamic-graph-python" \ No newline at end of file +"@CMAKE_INSTALL_PREFIX@/share/doc/dynamic-graph-python.doxytag = @CMAKE_INSTALL_PREFIX@/share/doc/dynamic-graph-python" + +EXAMPLE_PATH = @CMAKE_SOURCE_DIR@ diff --git a/doc/additionalDoc/debug-doc.h b/doc/additionalDoc/debug-doc.h index 7028e278e969bef31ff68e5adfeea5e16d227ddb..cb14c143ce90e10fd5180dc4459ff12ff63d5c05 100644 --- a/doc/additionalDoc/debug-doc.h +++ b/doc/additionalDoc/debug-doc.h @@ -13,6 +13,6 @@ WARNING, ERROR). It is described in details here: \subpage subp_logger int: \subpage subp_dbg_trace - If you just need to collect informations from signals (like rosbag). You can use an entity called Tracer inside the graph:\subpage tracerdoc . <br> A real -time version exists to write directly inside a memory buffer \subpage -tracerrealtimedoc +time version exists to write directly inside a memory buffer +\subpage tracerrealtimedoc **/ diff --git a/doc/additionalDoc/debug-trace-doc.h b/doc/additionalDoc/debug-trace-doc.h index 8900be96400c4044f0829d906ceeef4c7daa7dd2..1cf0ef6bfb47773f03bf9ca267eb532f07ef3114 100644 --- a/doc/additionalDoc/debug-trace-doc.h +++ b/doc/additionalDoc/debug-trace-doc.h @@ -65,5 +65,5 @@ test \endcode \section subp_dbg_trace_wrk_exp Working example A full working example is given here: -\include ../tests/debug-trace.cpp +\include tests/debug-trace.cpp */ diff --git a/doc/additionalDoc/package.h b/doc/additionalDoc/package.h index 1deb6be9e9f96ac2089baf099dcf5dd0d9a80037..1945511af3a0bbb3ff755a5742d8c93d05c53cce 100644 --- a/doc/additionalDoc/package.h +++ b/doc/additionalDoc/package.h @@ -22,8 +22,8 @@ The software graph structure is detailled in \subpage p_graph For debugging your entities detailed instructions are given in \subpage debug -For citing the software in your research work please refer to \subpage -subp_references +For citing the software in your research work please refer to +\subpage subp_references \namespace dynamicgraph This is the namespace where every object and class of this library is located. diff --git a/include/dynamic-graph/entity.h b/include/dynamic-graph/entity.h index 716dd347f170da067cada9ae7a1985e2bca79a04..1a4b33e905e0b60fe4e456bd635afa528237e46f 100644 --- a/include/dynamic-graph/entity.h +++ b/include/dynamic-graph/entity.h @@ -85,7 +85,7 @@ public: /** \name Logger related methods */ /** \{*/ - /// \brief Send messages \param msg with level t. + /// \brief Send messages \c msg with level \c t. /// Add string file and line to message. void sendMsg(const std::string &msg, MsgType t = MSG_TYPE_INFO, const char *file = "", int line = 0); diff --git a/include/dynamic-graph/null-ptr.hh b/include/dynamic-graph/null-ptr.hh index e1715eff29390f650001be5dd2901a7a4133a459..ee84493804be28aec14d01b2f3fbaa0989ff8149 100644 --- a/include/dynamic-graph/null-ptr.hh +++ b/include/dynamic-graph/null-ptr.hh @@ -5,6 +5,7 @@ #define DYNAMIC_GRAPH_NULL_PTR_HH namespace dynamicgraph { +/// \cond const class { public: template <class T> operator T *() const { return 0; } @@ -14,6 +15,7 @@ public: private: void operator&() const; } nullptr = {}; +/// \endcond } // end of namespace dynamicgraph. diff --git a/include/dynamic-graph/process-list.hh b/include/dynamic-graph/process-list.hh index 6725b984570b283b82f3e8b66044b20f6f985e6a..54c99d01fd52883d3314ae916cf3614ed0118d2c 100644 --- a/include/dynamic-graph/process-list.hh +++ b/include/dynamic-graph/process-list.hh @@ -22,7 +22,7 @@ public: ProcessList(); }; -/// \class This class gather information on a specific CPU. +/// This class gather information on a specific CPU. /// class DYNAMIC_GRAPH_DLLAPI CPUData { public: @@ -123,7 +123,7 @@ public: } }; -/// \class This class gathers information on a computer. +/// This class gathers information on a computer. /// This includes a list of CPU class DYNAMIC_GRAPH_DLLAPI System { private: diff --git a/include/dynamic-graph/signal-time-dependent.h b/include/dynamic-graph/signal-time-dependent.h index c834d613d763ce2097926238eb4ba27223d289f6..ca1115da2c18f1111b33ecc60693d853b36b8f7f 100644 --- a/include/dynamic-graph/signal-time-dependent.h +++ b/include/dynamic-graph/signal-time-dependent.h @@ -13,16 +13,49 @@ namespace dynamicgraph { signals, making sure its inputs are up to date on access, using a incrementing time tick as reference. - It works this way: for a given SignalTimeDependent S, the user manually - adds dependent signals through the - use of the addDependency function. On access (calling the signal S - operator () or access(Time) function), - if the dependent signals are not up-to-date, i.e. if their [last update] - time is less than the - current time, their value will be access ()'ed to bring them up-to-date. - Thus, the value of dependent - signals can be accessed \b quickly and \b repeatedly through the - accessCopy () function. + + It works this way. For a given SignalTimeDependent S, + - the user manually adds dependent signals through the use of the SignalTimeDependent::addDependency function. + - On access (calling the signal S SignalTimeDependent::operator()(const Time&) or + SignalTimeDependent::access(const Time&) function), if the dependent signals are not + up-to-date, i.e. if their [last update] time is less than the current time, + their value will be SignalTimeDependent::access ()'ed to bring them up-to-date. + + Thus, the value of dependent signals can be accessed \b quickly and + \b repeatedly through the Signal::accessCopy () function. + + An example: + \code + class MyEntity : public Entity { + public: + // Some signal dependencies + SignalPtr<T,int> dep1, dep2; + SignalTimeDependent<T,int> signal; + + MyEntity (const std::string& name) + : Entity (name) + , signal ( + // Set the function that computes the signal value + boost::bind (&Entity::computeSignal, this, _1, _2), + // Declare the dependencies + dep1 << dep2, + "signalname") + {} + + T& computeSignal (T& res, int time) + { + // The accesses below update the signal if necessary. + dep1(time); + dep1.access(time); + dep1.recompute(time); + // If dep1 and dep2 are already up-to-date, for a faster access, use + dep1.accessCopy(); + dep2.accessCopy(); + + // Compute res + return res; + } + \endcode */ template <class T, class Time> class SignalTimeDependent : public virtual Signal<T, Time>,