Esempio n. 1
0
        public static string SentRequest(string server, int port, Request request)
        {
            Log.logger.Debug("request: " + request.ToString());

            SocketUserClient client = new SocketUserClient(server, port);

            return client.SentMsgToServer(request.ToString());
        }
Esempio n. 2
0
        public static bool IsAgentAvaliable(string server, int port, int timeout)
        {
            try
            {
                var userClient = new SocketUserClient(server, port);

                return userClient.CanConnectServer(timeout);
            }
            catch
            {
                return false;
            }
        }
Esempio n. 3
0
 public SocketRequest(string server, int port)
     : base(server, port)
 {
     client = new SocketUserClient(server, port);
 }