public ServerInfo(PipeServiceBinder server, PipeCallInvoker callInvoker,
                   GrpcConnection connection, RemoteObjectStores stores,
                   LldbMockFactories mockFactories)
 {
     Server        = server;
     CallInvoker   = callInvoker;
     Connection    = connection;
     Stores        = stores;
     MockFactories = mockFactories;
 }
        private ServerInfo CreateServer(
            PipeCallInvokerFactory callInvokerFactory, GrpcConnectionFactory connectionFactory)
        {
            PipeCallInvoker callInvoker = callInvokerFactory.Create();
            GrpcConnection  connection  = connectionFactory.Create(callInvoker);

            string[] inPipeHandles, outPipeHandles;
            callInvoker.GetClientPipeHandles(out inPipeHandles, out outPipeHandles);

            // Note: The client's out handles are the server's in handles and vice versa.
            PipeServiceBinder server = new PipeServiceBinder(outPipeHandles, inPipeHandles);
            var stores        = new RemoteObjectStores();
            var mockFactories = new LldbMockFactories();

            BindServices(server, stores, mockFactories);
            server.Start();
            return(new ServerInfo(server, callInvoker, connection, stores, mockFactories));
        }