public WSAddressing10ProblemHeaderQNameFault(ActionMismatchAddressingException e) { _invalidHeaderName = AddressingStrings.Action; _code = FaultCode.CreateSenderFaultCode( new FaultCode(Addressing10Strings.ActionMismatch, AddressingVersion.WSAddressing10.Namespace)); _reason = new FaultReason(new FaultReasonText(e.Message, CultureInfo.CurrentCulture.Name)); _actor = ""; _node = ""; }
// protected ActionNotSupportedException(SerializationInfo info, StreamingContext context) : base(info, context) { } internal Message ProvideFault(MessageVersion messageVersion) { Fx.Assert(messageVersion.Addressing != AddressingVersion.None, ""); FaultCode code = FaultCode.CreateSenderFaultCode(AddressingStrings.ActionNotSupported, messageVersion.Addressing.Namespace); string reason = Message; return(Channels.Message.CreateMessage( messageVersion, code, reason, messageVersion.Addressing.FaultAction)); }
public WSAddressing10ProblemHeaderQNameFault(MessageHeaderException e) { _invalidHeaderName = e.HeaderName; if (e.IsDuplicate) { _code = FaultCode.CreateSenderFaultCode( new FaultCode(Addressing10Strings.InvalidAddressingHeader, AddressingVersion.WSAddressing10.Namespace, new FaultCode(Addressing10Strings.InvalidCardinality, AddressingVersion.WSAddressing10.Namespace))); } else { _code = FaultCode.CreateSenderFaultCode( new FaultCode(Addressing10Strings.MessageAddressingHeaderRequired, AddressingVersion.WSAddressing10.Namespace)); } _reason = new FaultReason(new FaultReasonText(e.Message, CultureInfo.CurrentCulture.Name)); _actor = ""; _node = ""; }