FaultBinding Class
.NET Framework 3.0
Specifies the format for any error messages that might be output as a result of the operation. This class cannot be inherited.
Namespace: System.Web.Services.Description
Assembly: System.Web.Services (in system.web.services.dll)
Assembly: System.Web.Services (in system.web.services.dll)
The FaultBinding class corresponds to the Web Services Description Language (WSDL) <fault> element enclosed by the <operation> element, which in turn corresponds to the OperationBinding class. For more information about WSDL, see the specification at http://www.w3.org/TR/wsdl/.
The following example demonstrates a typical use of the FaultBinding class.
FaultBindingCollection^ myFaultBindingCollection = myOperationBinding->Faults; FaultBinding^ myFaultBinding = gcnew FaultBinding; myFaultBinding->Name = "ErrorString"; // Associate SOAP fault binding to the fault binding of the operation. myExtensions = myFaultBinding->Extensions; SoapFaultBinding^ mySoapFaultBinding = gcnew SoapFaultBinding; mySoapFaultBinding->Use = SoapBindingUse::Literal; mySoapFaultBinding->Namespace = "http://www.contoso.com/stockquote"; myExtensions->Add( mySoapFaultBinding ); myFaultBindingCollection->Add( myFaultBinding );
FaultBindingCollection myFaultBindingCollection =
myOperationBinding.get_Faults();
FaultBinding myFaultBinding = new FaultBinding();
myFaultBinding.set_Name("ErrorString");
// Associate SOAP fault binding to the fault binding of the operation.
myExtensions = myFaultBinding.get_Extensions();
SoapFaultBinding mySoapFaultBinding = new SoapFaultBinding();
mySoapFaultBinding.set_Use(SoapBindingUse.Literal);
mySoapFaultBinding.set_Namespace("http://www.contoso.com/stockquote");
myExtensions.Add(mySoapFaultBinding);
myFaultBindingCollection.Add(myFaultBinding);
System.Object
System.Web.Services.Description.DocumentableItem
System.Web.Services.Description.NamedItem
System.Web.Services.Description.MessageBinding
System.Web.Services.Description.FaultBinding
System.Web.Services.Description.DocumentableItem
System.Web.Services.Description.NamedItem
System.Web.Services.Description.MessageBinding
System.Web.Services.Description.FaultBinding
Windows 98, Windows Server 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.Community Additions
ADD
Show: