how do i convert stringstream to string?
How do I convert from std::stringstream to std::string in C++?
Do I need to call a method on the string stream?
i tried .str() but didnt work.
it copies string into stream and pass it as argument for the method addDoc above.when i tried to convert it back to string it didnt work saying .str() is not a member of &inStream.
Document*Repository::addDoc(iostream& inStream,string docId)
string s1 = "Hello World;"
but why is that since it is already been convert to stream in the test core and should be passed as stream form for the method.
can anyone explain this to me?