// This autogenerated skeleton file illustrates how to build a server.
// You should copy it to another filename to avoid overwriting it.

#include "EnumTestService.h"
#include <thrift/protocol/TBinaryProtocol.h>
#include <thrift/server/TSimpleServer.h>
#include <thrift/transport/TServerSocket.h>
#include <thrift/transport/TBufferTransports.h>

using namespace ::apache::thrift;
using namespace ::apache::thrift::protocol;
using namespace ::apache::thrift::transport;
using namespace ::apache::thrift::server;

class EnumTestServiceHandler : virtual public EnumTestServiceIf {
 public:
  EnumTestServiceHandler() {
    // Your initialization goes here
  }

  MyEnum3::type testEnum(const MyEnum3::type enum1) {
    // Your implementation goes here
    printf("testEnum\n");
  }

  void testEnumList(std::vector<MyEnum3::type> & _return, const std::vector<MyEnum3::type> & enum1) {
    // Your implementation goes here
    printf("testEnumList\n");
  }

  void testEnumSet(std::set<MyEnum3::type> & _return, const std::set<MyEnum3::type> & enum1) {
    // Your implementation goes here
    printf("testEnumSet\n");
  }

  void testEnumMap(std::map<MyEnum3::type, MyEnum3::type> & _return, const std::map<MyEnum3::type, MyEnum3::type> & enum1) {
    // Your implementation goes here
    printf("testEnumMap\n");
  }

  void testEnumStruct(EnumTestStruct& _return, const EnumTestStruct& enum1) {
    // Your implementation goes here
    printf("testEnumStruct\n");
  }

};

int main(int argc, char **argv) {
  int port = 9090;
  ::std::shared_ptr<EnumTestServiceHandler> handler(new EnumTestServiceHandler());
  ::std::shared_ptr<TProcessor> processor(new EnumTestServiceProcessor(handler));
  ::std::shared_ptr<TServerTransport> serverTransport(new TServerSocket(port));
  ::std::shared_ptr<TTransportFactory> transportFactory(new TBufferedTransportFactory());
  ::std::shared_ptr<TProtocolFactory> protocolFactory(new TBinaryProtocolFactory());

  TSimpleServer server(processor, serverTransport, transportFactory, protocolFactory);
  server.serve();
  return 0;
}

