示例#1
0
        private static void Main(string[] args)
        {
            AppDomain.CurrentDomain.UnhandledException += (sender, e) => Microsoft.Practices.EnterpriseLibrary.ExceptionHandling.ExceptionPolicy.HandleException((Exception)e.ExceptionObject, "Log");
            TaxiOnlineServer server = new TaxiOnlineServer();

            server.InitStorage(srv => new TaxiOnlineStorage(srv));
            server.InitMobileService(srv => new TaxiOnlineSerivceHost(srv));
            ITaxiOnlineStorage       storage       = server.Storage;
            ITaxiOnlineMobileService mobileService = server.MobileService;

            server.LoadPersistentState();
            mobileService.Open();
            Console.ReadLine();
        }
示例#2
0
 public LogicExtender(TaxiOnlineServer server)
 {
     _storage = new Lazy <ITaxiOnlineStorage>(() => _storageInitDelegate(server), true);
 }
示例#3
0
 public CityLogic(CityInfo info, TaxiOnlineServer server, LogicExtender extender)
 {
     _info     = info;
     _extender = extender;
 }