Creating an Interface part to access a SOAP service

An EGL Interface part includes one or more function prototypes, each of which identifies an operation that is available in a service. As shown in the following example, a function prototype has an ending semicolon (;) and includes a function name, parameter list, and (optionally) a return type:
Interface WeatherForecast
   Function GetWeatherByZipCode(zipcode string in) returns(myRecordPart);
end

In relation to a Web service, the function prototypes can include parameters that have the modifiers IN, INOUT, or OUT.

The workbench provides different ways to create an Interface part from a WSDL file. Here is one:
  1. Bring the WSDL file for the Web service into your EGL Source folder; for example, into a subfolder named wsdl
  2. In the Project Explorer, right click the WSDL file and click EGL Services and Create EGL Client Interface
  3. Follow the directions of the wizard that creates the Interface part. You might put that part into an EGLSource subdirectory named interfaces.
  4. Note the comments that were written into the file that holds the Interface part. They represent a complex property that might be useful when you specify details about accessing the service. You specify those details in one of two cases:
    • When you create a service-access variable that is based on the Interface part
    • When you create a service-client binding that is referenced by the service-access variable.

The process by which the workbench creates an Interface part might be helpful when names 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 more details, see “@xml.”


Feedback