public int GetMessageSize() // подсчет длины строки сообщения { string tmpString = String.Format("{0}={1}\u0001{2}={3}\u0001{4}={5}\u0001", // {6}={7}\u0001{8}={9}\u0001 (int)Tags.PosReqID, PosReqID.ToString(), (int)Tags.PosReqType, PosReqType.ToString(), (int)Tags.SubscriptionRequestType, SubscriptionRequestType //(int)Tags.PartyID, //PartyID.ToString(), //(int)Tags.PartyRole, //PartyRole.ToString() ); return(tmpString.Length); }
public override string ToString() // формирование строки сообщения { MessageString = String.Format("{0}={1}\u0001{2}={3}\u0001{4}={5}\u0001", // {6}={7}\u0001{8}={9}\u0001 (int)Tags.PosReqID, PosReqID.ToString(), (int)Tags.PosReqType, PosReqType.ToString(), (int)Tags.SubscriptionRequestType, SubscriptionRequestType //(int)Tags.PartyID, //PartyID.ToString(), //(int)Tags.PartyRole, //PartyRole.ToString() ); MessageSize = MessageString.Length; return(MessageString); }