10.1: Define a WSDL file that corresponds to the same method and parameter signature as the calculator extensions defined in previous questions. The trick in this question is that not only should the extension be defined, but a mechanism of connecting to a specific Web Service extension implementation also has to be defined. Consider this extra trick as being some type of factory method for Web Services. The objective of the WSDL definition is to be able to use the Web Service as if it were a calculator, where a properly programmed client could assemble and execute the questions dynamically, like the calculator application currently can. The difference is that a network exists between the consumer and implementation.
10.2: Implement the WSDL file defined in question 10.1. For the time being, keep the different operations simple, like adding and subtracting.
10.3: Generate the client stubs of the WSDL file defined in question 10.1. Of all questions in the entire book, this is the trickiest. If the WSDL is properly defined, then the generated stubs should be identical to the extensions defined in the calculator application. The objective of this question is to structure the calculator application such that whenever a calculation is to be performed, the extension is dynamically retrieved.
The application will have a configuration, batch file processing, etc., that stays the same. What changes is how the implementation of the calculator operation is executed. In this question, the implementation could be local, it could be a library that needs to be defined remotely, or it could be based on a Web Service defined remotely. In the configuration file, the ability to define a factory for other Web Services is then dynamically assigned.
It is important that you spend some time designing this part of the application because after this step, your calculator will be complete and should be fully operational. Then, in the implementation, anybody could use your WSDL file to define and integrate their Web Service.
10.4 (Optional) If these exercises are part of a bigger group effort, then exchange WSDL files and attempt to use other Web Service implementations . The key here is not to update your WSDL file, but rather figure out a strategy of how to integrate, which may or may not include updating the WSDL file.