I. Introduction
Web Service is a new Web application.ProgramBranch. They are self-contained, self-described, and modular applications that can be released, located, and called through the Web. Web services can execute any function from simple requests to complex business processing. After deployment, other Web service applications can discover and call the services deployed by the application. Web Service is an application that uses standard Internet protocols, such as Hypertext Transfer Protocol (HTTP) and XML, to visually display functions on the Internet and on the enterprise intranet. Web services can be considered as Web component programming.
II. Two important technologies
To achieve this goal, Web Services uses two technologies:
◆ XML is a great way to transmit structured data on the Web. Web services must operate data in a reliable and automatic manner. HTML does not meet the requirements, XML allows web services to process data conveniently, and its content and representation separation is ideal.
◆ Soap uses XML messages to call remote methods, so that web services can interact with remote machines through the post and get methods of the HTTP protocol. In addition, soap is more robust, flexible, and easy to use.
Other technologies such as UDDI and WSDL are closely integrated with XML and soap for service discovery.
Their features are openness, cross-platform, and openness, which is the foundation of Web Services.
3. Introduction to WSDL
Web Services Description Language is an XML language used to describe Web Services and describe how to communicate with Web Services.
Functions of WSDL:
How can I introduce to others what functions your web service has and the parameters for each function call? You may write a set of documents on your own. You may even verbally tell people who need your web service. These informal methods have at least one serious problem: when programmers sit in front of a computer and want to use your web service, their tools (such as Visual Studio) they cannot provide any help, because these tools do not know your web service at all. The solution is to provide a formal description document that can be read by machines. The Web Service Description Language (WSDL) is an XML-based language used to describe Web services and their functions, parameters, and returned values. Because it is based on XML, WSDL is both readable and readable, which is a great benefit. Some of the latest development tools can generate a WSDL document based on your web service, and import the WSDL document to generateCode.
3. Use of web services between different platforms.
Take Java and. NET as an example:
1. Java provides a standard WSDL document describing Web Services.
2..netuses vs's wsdl.exe tool to generate corresponding interfaces or classes
Generation interface: wsdl.exe/Si D:/project/xxx. WSDL
Generation Method: wsdl.exe/out: D:/project/xxx. Cs D:/project/xxx. WSDL
3. Then. net uses the generated CS file to perform the next operation, establish a web service, and so on.
_________________________________________________
Method for generating WSDL in. net
With ASP. NET, you do not have to write the WSDL and soap documents in person.
You will find that ASP. NET will automatically create WSDL and SOAP requests.
WSDL is an XML format used to describe how to call a specific web service, and what kind of service the Web Service provides.
There are three methods to generate WSDL in. Net:
1. Add the wdsl requirement after the URL of the Web Service, as follows:
Http: // localhost/webexamples/simpleservice. asmx? WSDL
2.use disco.exe. Write the following command in the command line:
Disco http: // localhost/webexamples/simpleservice. asmx