27 lines
589 B
C++
27 lines
589 B
C++
#ifndef __ASYNC_RANGE_HPP__
|
|
#define __ASYNC_RANGE_HPP__
|
|
|
|
#include <grpc++/grpc++.h>
|
|
#include "proto/rpc.grpc.pb.h"
|
|
#include "etcd/v3/Action.hpp"
|
|
#include "etcd/v3/AsyncRangeResponse.hpp"
|
|
|
|
|
|
using grpc::ClientAsyncResponseReader;
|
|
using etcdserverpb::RangeResponse;
|
|
|
|
namespace etcdv3
|
|
{
|
|
class AsyncRangeAction : public etcdv3::Action
|
|
{
|
|
public:
|
|
AsyncRangeAction(etcdv3::ActionParameters const ¶m);
|
|
AsyncRangeResponse ParseResponse();
|
|
private:
|
|
RangeResponse reply;
|
|
std::unique_ptr<ClientAsyncResponseReader<RangeResponse>> response_reader;
|
|
};
|
|
}
|
|
|
|
#endif
|