示例#1
0
 public SocketRequestHandlerContext(ITcpConnection connection, Action <byte[]> sendReplyAction)
 {
     Connection           = connection;
     SendRemotingResponse = remotingResponse =>
     {
         sendReplyAction(RemotingUtil.BuildResponseMessage(remotingResponse));
     };
 }
示例#2
0
        private static byte[] BuildRemotingServerMessage(RemotingResponse remotingResponse)
        {
            byte[] remotingResponseData  = RemotingUtil.BuildResponseMessage(remotingResponse);
            var    remotingServerMessage = new RemotingServerMessage(
                RemotingServerMessageType.RemotingResponse,
                100,
                remotingResponseData,
                null);

            return(RemotingUtil.BuildRemotingServerMessage(remotingServerMessage));
        }