server: support flushing the output

So we can get some progress output
This commit is contained in:
Dirk-Jan C. Binnema
2022-02-03 22:58:53 +02:00
parent 05393ba797
commit b6d7d142f6
3 changed files with 14 additions and 8 deletions

View File

@ -33,8 +33,8 @@ namespace Mu {
*
*/
class Server {
public:
using Output = std::function<void(Sexp&& sexp)>;
public:
using Output = std::function<void(Sexp&& sexp, bool flush)>;
/**
* Construct a new server
@ -59,7 +59,7 @@ class Server {
*/
bool invoke(const std::string& expr) noexcept;
private:
private:
struct Private;
std::unique_ptr<Private> priv_;
};