ClickHouse/dbms/src/IO/ReadBufferFromString.h
2017-04-16 08:40:17 +03:00

20 lines
347 B
C++

#pragma once
#include <IO/ReadBufferFromMemory.h>
namespace DB
{
/** Allows to read from std::string-like object.
*/
class ReadBufferFromString : public ReadBufferFromMemory
{
public:
/// std::string or something similar
template <typename S>
ReadBufferFromString(const S & s) : ReadBufferFromMemory(s.data(), s.size()) {}
};
}