R
Ryan Melville
Hi,
I understand that I can add custom fault information to the Detail element
of a SOAP fault. For example, I can serialize my own custom type into the
Detail element.
However, how do I communicate that custom type and its presence in faults
from the server to the client? The WSDL generated by ASP.NET does not seem
to have:
- My custom type added to the <wsdl:types>.
- A <wsdl:message> for my custom fault message.
- A <wsdl:fault> for the operations that can "return" the custom fault
message.
Are there attributes or other things I can use to force these items into the
generated WSDL?
Alternatively, is there some way I can force at least the type into the
generated WSDL? I may be able to live without the <wsdl:message> and
<wsdl:fault> tags if I can at least communicate the custom fault type
through WSDL. Then, I would just have to document that the Detail element
of faults contains this type serialized.
For example, [WebMethod] causes a method to be in the WSDL as an operation.
The paremeter/return types of the method are automatically added to the
WSDL. But my custom fault type is not a paramter/return from a [WebMethod]
so it doesn't make it into the WSDL. Is there a [WebType] attribute or
similary?
Thanks for any help anyone may be able to provide!
Ryan
I understand that I can add custom fault information to the Detail element
of a SOAP fault. For example, I can serialize my own custom type into the
Detail element.
However, how do I communicate that custom type and its presence in faults
from the server to the client? The WSDL generated by ASP.NET does not seem
to have:
- My custom type added to the <wsdl:types>.
- A <wsdl:message> for my custom fault message.
- A <wsdl:fault> for the operations that can "return" the custom fault
message.
Are there attributes or other things I can use to force these items into the
generated WSDL?
Alternatively, is there some way I can force at least the type into the
generated WSDL? I may be able to live without the <wsdl:message> and
<wsdl:fault> tags if I can at least communicate the custom fault type
through WSDL. Then, I would just have to document that the Detail element
of faults contains this type serialized.
For example, [WebMethod] causes a method to be in the WSDL as an operation.
The paremeter/return types of the method are automatically added to the
WSDL. But my custom fault type is not a paramter/return from a [WebMethod]
so it doesn't make it into the WSDL. Is there a [WebType] attribute or
similary?
Thanks for any help anyone may be able to provide!
Ryan