public static bool TryExtractErrorMessage(SoapException ex, out ServiceFaultDetail fault)
        {
            fault = null;
            if (ex == null)
            {
                return(false);
            }

            try
            {
                fault = Serialized.Deserialize <ServiceFaultDetail>(ex.Detail.InnerXml);
            }
            catch
            {
                return(false);
            }

            return(true);
        }
 public static Exception Create(ServiceFaultDetail fault, Exception ex)
 {
     return(new ServiceRequestException(fault, ex));
 }
 internal ServiceRequestException(ServiceFaultDetail fault, Exception ex)
     : base(fault.DetailedMessage, ex)
 {
     Fault = fault;
 }