Esempio n. 1
0
 static void StartServer()
 {
     if (ServerInfo.ServerPort != 0)
     {
         ServerInfo.ZServer = new ZServer(ServerInfo.ServerPort);
         ServerInfo.AddEvents(ServerInfo.ZServer, true);
         ServerInfo.ZServer.Listen();
     }
 }
Esempio n. 2
0
 static void StopServer()
 {
     if (ServerInfo.ZServer != null)
     {
         ServerInfo.ZServer.Close();
         ServerInfo.ZServer.Dispose();
         ServerInfo.AddEvents(ServerInfo.ZServer, false);
         ServerInfo.ZServer = null;
     }
 }
Esempio n. 3
0
        static void StopServer()
        {
#if NO
            if (ServerInfo.ZServer != null)
            {
                ServerInfo.ZServer.Close();
                ServerInfo.ZServer.Dispose();
                ServerInfo.AddEvents(ServerInfo.ZServer, false);
                ServerInfo.ZServer = null;
            }
#endif
            ServerInfo.StopGlobalService();

            ServerInfo.EndRemotingServer();
        }
Esempio n. 4
0
        static void StartServer()
        {
            try
            {
                ServerInfo.StartRemotingServer();
            }
            catch (Exception ex)
            {
                WriteWindowsLog("dp2Capo StartRemotingServer() exception: " + ExceptionUtil.GetDebugText(ex),
                                EventLogEntryType.Error);
            }

            if (ServerInfo.Z3950ServerPort != -1)
            {
                ServerInfo.ZServer = new ZServer(ServerInfo.Z3950ServerPort);
                ServerInfo.AddEvents(ServerInfo.ZServer, true);
                ServerInfo.ZServer.Listen(1000);
            }
        }