示例#1
0
        public void SendAck(InjectionResult code)
        {
            var type   = code == InjectionResult.Success ? Constants.Ok : Constants.Error;
            var ackMsg = new PipeMessage(type, ((Int32)code).ToString());

            _writer.WriteLine(ackMsg.Serialize());
            _writer.Flush();
        }
示例#2
0
        private PipeMessage SendData(PipeMessage msg)
        {
            _writer.WriteLine(msg.Serialize());
            _writer.Flush();
            var ack = _reader.ReadLine();

            return(PipeMessage.Create(ack));
        }
        public void SendAck(InjectionResult code, String message)
        {
            var value  = String.Format("{0}|{1}", code, message);
            var type   = code == InjectionResult.Success ? Constants.Ok : Constants.Error;
            var ackMsg = new PipeMessage(type, value);

            _writer.WriteLine(ackMsg.Serialize());
            _writer.Flush();
        }