Revision: 8870
http://playerstage.svn.sourceforge.net/playerstage/?rev=8870&view=rev
Author: hsujohnhsu
Date: 2010-09-02 01:36:24 +0000 (Thu, 02 Sep 2010)
Log Message:
-----------
adding support for deprecation message.
Modified Paths:
--------------
code/gazebo/branches/wg/server/Param.hh
Modified: code/gazebo/branches/wg/server/Param.hh
===================================================================
--- code/gazebo/branches/wg/server/Param.hh 2010-09-02 01:12:51 UTC (rev
8869)
+++ code/gazebo/branches/wg/server/Param.hh 2010-09-02 01:36:24 UTC (rev
8870)
@@ -85,7 +85,7 @@
class ParamT : public Param
{
/// \brief Constructor
- public: ParamT(std::string key, T defValue, int required);
+ public: ParamT(std::string key, T defValue, int required, bool
deprecated=false, std::string deprecate_msg=NULL);
/// \brief Destructor
public: virtual ~ParamT();
@@ -133,7 +133,7 @@
//////////////////////////////////////////////////////////////////////////////
// Constructor
template< typename T>
- ParamT<T>::ParamT(std::string key, T defValue, int required)
+ ParamT<T>::ParamT(std::string key, T defValue, int required, bool
deprecated, std::string deprecate_msg)
: Param(this)
{
this->key = key;
@@ -142,6 +142,7 @@
this->value = this->defaultValue;
this->typeName = typeid(T).name();
+ if (deprecated) std::cerr << "Param [" << key << "] is deprecated: [" <<
deprecate_msg << "]\n";
}
//////////////////////////////////////////////////////////////////////////////
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
This SF.net Dev2Dev email is sponsored by:
Show off your parallel programming skills.
Enter the Intel(R) Threading Challenge 2010.
http://p.sf.net/sfu/intel-thread-sfd
_______________________________________________
Playerstage-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/playerstage-commit