Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有这个对象:
istringstream ob_stream;
我需要将此对象转换为字符串和字符数组才能工作。怎么做?
对于一个std::string:
std::string
ob_stream.str();
对于char数组:
char
ob_stream.str().c_str();