{{!

  Copyright (c) Meta Platforms, Inc. and affiliates.

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

      http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.

}}{{#function:return_type}}{{^function:starts_interaction?}}
  template <typename ProtocolIn_, typename ProtocolOut_>
  void setUpAndProcess_{{function:prefixed_name}}(apache::thrift::ResponseChannelRequest::UniquePtr req, apache::thrift::SerializedCompressedRequest&& serializedRequest, apache::thrift::Cpp2RequestContext* ctx, folly::EventBase* eb, apache::thrift::concurrency::ThreadManager* tm);
  template <typename ProtocolIn_, typename ProtocolOut_>
  void executeRequest_{{function:prefixed_name}}(apache::thrift::ServerRequest&& serverRequest);
{{^function:oneway?}}
  template <class ProtocolIn_, class ProtocolOut_>
{{#function:cpp_void?}}
  static apache::thrift::SerializedResponse return_{{function:prefixed_name}}(apache::thrift::ContextStack* ctx);
{{/function:cpp_void?}}
{{^function:cpp_void?}}
  {{^function:stream?}}{{^function:sink?}}
  static apache::thrift::SerializedResponse return_{{function:prefixed_name}}(apache::thrift::ContextStack* ctx, {{function:cpp_return_type}} const& _return);
  {{/function:sink?}}{{/function:stream?}}
  {{#function:stream?}}
  static apache::thrift::ResponseAndServerStreamFactory return_{{function:prefixed_name}}(apache::thrift::ContextStack* ctx, folly::Executor::KeepAlive<> executor, {{function:cpp_return_type}}&& _return);
  {{/function:stream?}}
  {{#function:sink?}}
  static std::pair<apache::thrift::SerializedResponse, apache::thrift::detail::SinkConsumerImpl> return_{{function:prefixed_name}}(apache::thrift::ContextStack* ctx, {{function:cpp_return_type}}&& _return, folly::Executor::KeepAlive<> executor);
  {{/function:sink?}}
{{/function:cpp_void?}}
  template <class ProtocolIn_, class ProtocolOut_>
  static void throw_wrapped_{{function:prefixed_name}}(apache::thrift::ResponseChannelRequest::UniquePtr req,int32_t protoSeqId,apache::thrift::ContextStack* ctx,folly::exception_wrapper ew,apache::thrift::Cpp2RequestContext* reqCtx);
{{/function:oneway?}}
{{/function:starts_interaction?}}{{#function:starts_interaction?}}
  std::unique_ptr<apache::thrift::Tile> {{function:cpp_name}}() {
    return iface_->{{function:cpp_name}}();
  }
{{/function:starts_interaction?}}{{/function:return_type}}
