X-Git-Url: http://g0dil.de/git?a=blobdiff_plain;f=senf%2FUtils%2FString.hh;h=05000243b8f9c0fcf28aed10567124b5b4f7c084;hb=4101c2b818ec67e7469ebb44f030eed2185c4ab0;hp=ee71b555e270f5ad3ae6bd1444520d22ec700c33;hpb=601d1f509f5bb24df167a4dd5a20da67a0af9af8;p=senf.git diff --git a/senf/Utils/String.hh b/senf/Utils/String.hh index ee71b55..0500024 100644 --- a/senf/Utils/String.hh +++ b/senf/Utils/String.hh @@ -1,6 +1,6 @@ // $Id$ // -// Copyright (C) 2008 +// Copyright (C) 2008 // Fraunhofer Institute for Open Communication Systems (FOKUS) // Competence Center NETwork research (NET), St. Augustin, GERMANY // Stefan Bund @@ -30,10 +30,10 @@ #include //#include "String.mpp" -///////////////////////////////hh.p//////////////////////////////////////// +//-///////////////////////////////////////////////////////////////////////////////////////////////// namespace senf { - + /** \brief Join string range with separator into single string This utility will build string by joining all elements of \a range into a single string @@ -42,6 +42,22 @@ namespace senf { template std::string stringJoin(ForwardReadableRange const & range, std::string sep); + /** \brief Get string representation + + Returns the result of streaming the argument into a standard library string-based + stream and then out as a std::string object. The conversion is done with + boost::lexical_cast. The call is equivalent to +
+            boost::lexical_cast(t);
+        
+ \pre + t must be OutputStreamable, + meaning that an operator\<\< is defined\n + t must be CopyConstructible + + \see + boost::lexical_cast + */ template std::string str(T const & t); @@ -54,7 +70,7 @@ namespace senf { detail::lexical_caster lexical_cast(); } -///////////////////////////////hh.e//////////////////////////////////////// +//-///////////////////////////////////////////////////////////////////////////////////////////////// //#include "String.cci" #include "String.ct" #include "String.cti"