File indexing completed on 2026-04-17 08:35:01
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020 #ifndef _THRIFT_TNAME_ME_H_
0021 #define _THRIFT_TNAME_ME_H_ 1
0022
0023 #include <thrift/async/TAsyncProcessor.h>
0024 #include <thrift/async/TAsyncBufferProcessor.h>
0025 #include <thrift/protocol/TProtocol.h>
0026
0027 namespace apache {
0028 namespace thrift {
0029 namespace async {
0030
0031 class TAsyncProtocolProcessor : public TAsyncBufferProcessor {
0032 public:
0033 TAsyncProtocolProcessor(std::shared_ptr<TAsyncProcessor> underlying,
0034 std::shared_ptr<apache::thrift::protocol::TProtocolFactory> pfact)
0035 : underlying_(underlying), pfact_(pfact) {}
0036
0037 void process(std::function<void(bool healthy)> _return,
0038 std::shared_ptr<apache::thrift::transport::TBufferBase> ibuf,
0039 std::shared_ptr<apache::thrift::transport::TBufferBase> obuf) override;
0040
0041 ~TAsyncProtocolProcessor() override = default;
0042
0043 private:
0044 static void finish(std::function<void(bool healthy)> _return,
0045 std::shared_ptr<apache::thrift::protocol::TProtocol> oprot,
0046 bool healthy);
0047
0048 std::shared_ptr<TAsyncProcessor> underlying_;
0049 std::shared_ptr<apache::thrift::protocol::TProtocolFactory> pfact_;
0050 };
0051 }
0052 }
0053 }
0054
0055 #endif