ClickHouse/dbms/src/DataStreams/copyData.h

21 lines
470 B
C++
Raw Normal View History

2011-11-06 06:22:52 +00:00
#pragma once
2010-03-04 19:20:28 +00:00
#include <atomic>
#include <functional>
2010-03-04 19:20:28 +00:00
2010-03-04 19:20:28 +00:00
namespace DB
{
class IBlockInputStream;
class IBlockOutputStream;
2017-05-13 22:19:04 +00:00
/** Copies data from the InputStream into the OutputStream
* (for example, from the database to the console, etc.)
2010-03-04 19:20:28 +00:00
*/
void copyData(IBlockInputStream & from, IBlockOutputStream & to, std::atomic<bool> * is_cancelled = nullptr);
2010-03-04 19:20:28 +00:00
void copyData(IBlockInputStream & from, IBlockOutputStream & to, const std::function<bool()> & is_cancelled);
2010-03-04 19:20:28 +00:00
}