Program.cs 886 B

12345678910111213141516171819202122232425262728293031323334353637
  1. #region File Description
  2. //-----------------------------------------------------------------------------
  3. // Program.cs
  4. //
  5. // Microsoft XNA Community Game Platform
  6. // Copyright (C) Microsoft Corporation. All rights reserved.
  7. //-----------------------------------------------------------------------------
  8. #endregion
  9. #region Using Statements
  10. using System;
  11. using System.ServiceModel;
  12. using TicTacToeServices;
  13. #endregion
  14. namespace Server
  15. {
  16. class Program
  17. {
  18. static void Main(string[] args)
  19. {
  20. using (ServiceHost host = new ServiceHost(typeof(TicTacToeService)))
  21. {
  22. host.Open();
  23. Console.WriteLine("TicTacToe server is up...");
  24. Console.WriteLine("Press 'Enter' key to exit");
  25. Console.ReadLine();
  26. }
  27. Console.WriteLine("Exiting....");
  28. }
  29. }
  30. }