Added convenience function Client::Response::Content::string()
This commit is contained in:
parent
4efdc095bd
commit
6b7fd993cf
5 changed files with 29 additions and 4 deletions
|
|
@ -126,6 +126,7 @@ namespace SimpleWeb {
|
|||
size_t size() {
|
||||
return streambuf.size();
|
||||
}
|
||||
/// Convenience function to return std::string. Note that the stream buffer is emptied when this functions is used.
|
||||
std::string string() {
|
||||
std::stringstream ss;
|
||||
ss << rdbuf();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue