Adding a SOAP binding to the deployment descriptor

A service-client binding contains information about how the EGL runtime code connects to a service that is being invoked by your EGL code.

Prerequisites

Adding the service client binding information

  1. In the deployment descriptor editor, open the EGL deployment descriptor.
  2. On the Service Client Bindings tab, under Service Client Bindings, click Add.
  3. In the Add a Service Binding window, click Web Binding and then click Next.
  4. If the WSDL file is not in your EGL project but is elsewhere in your workspace, next to the WSDL File field, you can select Choose WSDL file from workspace and copy it to the current project. If that check box is selected, you can use the Browse mechanism to search your Workspace. If that check box is clear, you can use the Browse mechanism to search in the EGL source folders of your project and in the EGL source folders of any project in the EGL build path of your project. To access the build-path details, right click your project and click Properties. In the window that opens, click EGL Build Path.
  5. Under Interface Options, click Generate EGL Interface from WSDL file. This choice represents the preferred method for creating an Interface part to represent the service at development time.

    The process by which the workbench creates an Interface part is helpful when names that are copied from the WSDL file are not valid in EGL or when you want to use an EGL package name that is not derived from the WSDL file. For details, see “@xml.”

    If you select Use existing EGL interface and specify an existing one, when you work on a specific service-client binding in the EGL deployment descriptor editor, you can quickly access the Interface part that you created.

    If you specify your own Interface part, make sure that its function prototypes accurately reflect the service operations defined in the WSDL file.

  6. For the Web Binding Name, either accept the default value or type in a different name. When you access the service, the name will be the value of the bindingKey property field.
  7. In the WSDL URI field, you can specify a string that overrides the URL that is specified in the WSDL file. If the service is available at a location besides the one that is specified in the WSDL file, such as a different version of the service that is used for production or testing, you can enter that location here and use that version of the service.
  8. Click Next.
  9. On the New EGL Interface page, select the Interface parts to create from the WSDL file.
  10. Click Next.
  11. On the next page, each Interface part has a tab that lists each function in the selected Interface part. You can select or clear the check box for any of the functions to choose which functions are represented in the new Interface part.
  12. Set the location and name for the new interface part in the Source folder, Package, and EGL source file name fields.
  13. Click Finish.

Now you can create variables based on the Interface part and use these variables to access the service. For more information, see “Declaring an access variable to access a SOAP service.”

Shortcut to add client binding information

You can add client binding information directly from a WSDL file in your project by using the following shortcut:

  1. In the Project Explorer view, right-click the WSDL file and click Create EGL Interfaces and Web Client Binding.
  2. On the New EGL Interface page, select the interfaces to use from the WSDL file.
  3. Click Next.
  4. On the next page, each interface has a tab on which each function in the selected interfaces is listed. You can select or clear the check box for any of the functions to choose which functions will be in the new interface part.
  5. Set the location and name for the new interface part in the Source folder, Package, and EGL source file name fields.
  6. Click Next.
  7. In the EGL deployment descriptor file name field, select the name of the deployment descriptor file to add information to.
  8. To update information that is in a deployment descriptor file, select Update all existing bindings.
  9. In the table of ports, select the ports to generate into interfaces. You can change the binding name, which is the label for the Web service deployment listing in the deployment descriptor file.
  10. Click Finish.

Feedback