Exemplo n.º 1
0
        public ReturnMethod DeleteAccount(ReqClientInfo clientInfo)
        {
            var req = new ReqClientInfo()
            {
                ServiceSettings = clientInfo.ServiceSettings, MemberId = memberId, ClientInfo = clientInfo.ClientInfo
            };

            return(this.Call <ReturnMethod, ReqClientInfo>(req, "DeleteAccount"));
        }
Exemplo n.º 2
0
        /// <summary>
        ///  Отвечаем на запрос клиенту
        /// </summary>
        private void WriteToClient(string request, TcpClient Client)
        {
            var p = GetReqParam(request);
            //  string c = "<HTML><HEAD> </HEAD><BODY>HELLO WORD !</BODY><HTML>";
            var rq = new ReqClientInfo()
            {
                Params = p
            };

            OnWriteToClient?.Invoke(this, rq);
            var bb = Encoding.ASCII.GetBytes(rq.Answer);

            WriteHeaderToClient("text/html", bb.Length, Client);
            Client.GetStream().Write(bb, 0, bb.Length);
        }