问题
Is it possible to create a single file to generate a client from a WCF generated WSDL file (and any additional XSD files that are also generated from this service)
I can generate a valid client using svcutil.exe passing both the wsdl file and each xsd file, but I have a customer who is using a PHP tool to generate this and I wanted to see if I could make it easy for them by having only one file instead of many.
回答1:
Yes, you can - with some clever WCF extensions. Check out these ready-made solutions:
- Flatten your WSDL with this Custom ServiceHost for WCF
- Improving WCF Interoperability: Flattening your WSDL
- Flatten WCF WSDL on demand
- Inline XSD in WSDL for WCF
Hope that helps!
Marc
来源:https://stackoverflow.com/questions/1589598/can-you-combine-the-wsdl-and-xsd-data-from-a-wcf-service