/**
 * Autogenerated by Thrift for shared.thrift
 *
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
 *  @generated
 */

#include <thrift/compiler/test/fixtures/interactions/gen-py3/shared/services_wrapper.h>
#include <thrift/compiler/test/fixtures/interactions/gen-py3/shared/services_api.h>
#include <thrift/lib/cpp2/async/AsyncProcessor.h>

namespace thrift {
namespace shared_interactions {

InteractLocallyWrapper::InteractLocallyWrapper(PyObject *obj, folly::Executor* exc)
  : if_object(obj), executor(exc)
  {
    import_test__fixtures__another_interactions__shared__services();
  }


std::unique_ptr<InteractLocallySvIf::SharedInteractionIf> InteractLocallyWrapper::createSharedInteraction() {
  throw std::runtime_error("Py3 server doesn't support interactions.");
}
std::shared_ptr<apache::thrift::ServerInterface> InteractLocallyInterface(PyObject *if_object, folly::Executor *exc) {
  return std::make_shared<InteractLocallyWrapper>(if_object, exc);
}
folly::SemiFuture<folly::Unit> InteractLocallyWrapper::semifuture_onStartServing() {
  auto [promise, future] = folly::makePromiseContract<folly::Unit>();
  call_cy_InteractLocally_onStartServing(
      this->if_object,
      std::move(promise)
  );
  return std::move(future);
}
folly::SemiFuture<folly::Unit> InteractLocallyWrapper::semifuture_onStopRequested() {
  auto [promise, future] = folly::makePromiseContract<folly::Unit>();
  call_cy_InteractLocally_onStopRequested(
      this->if_object,
      std::move(promise)
  );
  return std::move(future);
}
} // namespace thrift
} // namespace shared_interactions
