Пример #1
0
 /// <summary>
 /// Tests if incoming message header has proper RelatedTo element
 /// </summary>
 /// <param name="header">Incoming SOAP message header</param>
 /// <returns>true, if incoming message header has proper RelatedTo element</returns>
 protected bool IsExpectedMessageHeader(ICollection <XmlElement> header)
 {
     if (!string.IsNullOrEmpty(_listenMessage))
     {
         string relatedTo = DiscoveryUtils.ExtractRelatesTo(header);
         if (!DiscoveryUtils.CompareUUID(_listenMessage, relatedTo))
         {
             return(false);
         }
     }
     return(true);
 }
Пример #2
0
 /// <summary>
 /// Tests if incoming message header has proper RelatedTo element
 /// </summary>
 /// <param name="header">Incoming SOAP message header</param>
 /// <returns>true, if incoming message header has proper RelatedTo element</returns>
 protected bool IsExpectedMessageHeader(ICollection <XmlElement> header)
 {
     if (_listenMessages.Count() > 0)
     {
         string relatedTo = DiscoveryUtils.ExtractRelatesTo(header);
         foreach (string listenMessage in _listenMessages)
         {
             if (DiscoveryUtils.CompareUUID(listenMessage, relatedTo))
             {
                 return(true);
             }
         }
         return(false);
     }
     return(true);
 }