/** * Autogenerated by Thrift for thrift/compiler/test/fixtures/basic/src/module.thrift * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated @nocommit */ #pragma once #include #include "thrift/compiler/test/fixtures/basic/gen-cpp2/FooServiceAsyncClient.h" #include "thrift/compiler/test/fixtures/basic/gen-cpp2/module_types.h" namespace folly { class IOBuf; class IOBufQueue; } namespace apache { namespace thrift { class Cpp2RequestContext; class BinaryProtocolReader; class CompactProtocolReader; namespace transport { class THeader; } }} namespace test::fixtures::basic { class FooService; class FooServiceAsyncProcessor; class FooServiceServiceInfoHolder : public apache::thrift::ServiceInfoHolder { public: apache::thrift::ServiceRequestInfoMap const& requestInfoMap() const override; static apache::thrift::ServiceRequestInfoMap staticRequestInfoMap(); }; } // namespace test::fixtures::basic namespace apache::thrift { template <> class ServiceHandler<::test::fixtures::basic::FooService> : public apache::thrift::ServerInterface { public: std::string_view getGeneratedName() const override { return "FooService"; } static const char* __fbthrift_thrift_uri() { return "test.dev/fixtures/basic/FooService"; } typedef ::test::fixtures::basic::FooServiceAsyncProcessor ProcessorType; std::unique_ptr getProcessor() override; CreateMethodMetadataResult createMethodMetadata() override; private: std::optional> getServiceRequestInfoMap() const; public: virtual void sync_simple_rpc(); [[deprecated("Use sync_simple_rpc instead")]] virtual void simple_rpc(); virtual folly::Future future_simple_rpc(); virtual folly::SemiFuture semifuture_simple_rpc(); #if FOLLY_HAS_COROUTINES virtual folly::coro::Task co_simple_rpc(); virtual folly::coro::Task co_simple_rpc(apache::thrift::RequestParams params); #endif virtual void async_tm_simple_rpc(apache::thrift::HandlerCallbackPtr callback); private: static ::test::fixtures::basic::FooServiceServiceInfoHolder __fbthrift_serviceInfoHolder; std::atomic __fbthrift_invocation_simple_rpc{apache::thrift::detail::si::InvocationType::AsyncTm}; }; } // namespace apache::thrift namespace test::fixtures::basic { using FooServiceSvIf [[deprecated("Use apache::thrift::ServiceHandler instead")]] = ::apache::thrift::ServiceHandler; } // namespace test::fixtures::basic namespace test::fixtures::basic { class FooServiceSvNull : public ::apache::thrift::ServiceHandler { public: void simple_rpc() override; }; class FooServiceAsyncProcessor : public ::apache::thrift::GeneratedAsyncProcessorBase { public: const char* getServiceName() override; void getServiceMetadata(apache::thrift::metadata::ThriftServiceMetadataResponse& response) override; using BaseAsyncProcessor = void; protected: ::apache::thrift::ServiceHandler<::test::fixtures::basic::FooService>* iface_; public: void processSerializedCompressedRequestWithMetadata(apache::thrift::ResponseChannelRequest::UniquePtr req, apache::thrift::SerializedCompressedRequest&& serializedRequest, const apache::thrift::AsyncProcessorFactory::MethodMetadata& methodMetadata, apache::thrift::protocol::PROTOCOL_TYPES protType, apache::thrift::Cpp2RequestContext* context, folly::EventBase* eb, apache::thrift::concurrency::ThreadManager* tm) override; void executeRequest(apache::thrift::ServerRequest&& serverRequest, const apache::thrift::AsyncProcessorFactory::MethodMetadata& methodMetadata) override; public: using ProcessFuncs = GeneratedAsyncProcessorBase::ProcessFuncs; using ProcessMap = GeneratedAsyncProcessorBase::ProcessMap; static const FooServiceAsyncProcessor::ProcessMap& getOwnProcessMap(); private: static const FooServiceAsyncProcessor::ProcessMap kOwnProcessMap_; private: template void setUpAndProcess_simple_rpc(apache::thrift::ResponseChannelRequest::UniquePtr req, apache::thrift::SerializedCompressedRequest&& serializedRequest, apache::thrift::Cpp2RequestContext* ctx, folly::EventBase* eb, apache::thrift::concurrency::ThreadManager* tm); template void executeRequest_simple_rpc(apache::thrift::ServerRequest&& serverRequest); template static apache::thrift::SerializedResponse return_simple_rpc(apache::thrift::ContextStack* ctx); template static void throw_wrapped_simple_rpc(apache::thrift::ResponseChannelRequest::UniquePtr req,int32_t protoSeqId,apache::thrift::ContextStack* ctx,folly::exception_wrapper ew,apache::thrift::Cpp2RequestContext* reqCtx); public: FooServiceAsyncProcessor(::apache::thrift::ServiceHandler<::test::fixtures::basic::FooService>* iface) : iface_(iface) {} ~FooServiceAsyncProcessor() override {} }; } // namespace test::fixtures::basic