示例#1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ClientMsg&lt;BodyType&gt;"/> class.
 /// This a reply constructor.
 /// </summary>
 /// <param name="msg">The message that this instance is a reply for.</param>
 /// <param name="payloadReserve">The number of bytes to initialize the payload capacity to.</param>
 public ClientMsg(MsgBase <ExtendedClientMsgHdr> msg, int payloadReserve = 64)
     : this( payloadReserve )
 {
     // our target is where the message came from
     Header.TargetJobID = msg.Header.SourceJobID;
 }
示例#2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Msg&lt;BodyType&gt;"/> class.
 /// This a reply constructor.
 /// </summary>
 /// <param name="msg">The message that this instance is a reply for.</param>
 /// <param name="payloadReserve">The number of bytes to initialize the payload capacity to.</param>
 public Msg(MsgBase <MsgHdr> msg, int payloadReserve = 0)
     : this( payloadReserve )
 {
     // our target is where the message came from
     Header.TargetJobID = msg.Header.SourceJobID;
 }
示例#3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ClientMsgProtobuf&lt;BodyType&gt;"/> class.
 /// This a reply constructor.
 /// </summary>
 /// <param name="eMsg">The network message type this client message represents.</param>
 /// <param name="msg">The message that this instance is a reply for.</param>
 /// <param name="payloadReserve">The number of bytes to initialize the payload capacity to.</param>
 public ClientMsgProtobuf(EMsg eMsg, MsgBase <MsgHdrProtoBuf> msg, int payloadReserve = 64)
     : this(eMsg, payloadReserve)
 {
     // our target is where the message came from
     Header.Proto.jobid_target = msg.Header.Proto.jobid_source;
 }