Using the WSDL Editor

Working with WSDL Files

This section contains the following topics

Creating a WSDL File From Scratch

When you create a WSDL file from scratch, the wizard contains three pages that you can fill out.

You do not need to complete all three pages. You can fill out the Name and Location page and then click Finish. Or you can fill out the Name and Location page and the Abstract Configuration page and then click Finish.

ProcedureTo create a WSDL file from scratch

  1. In the Projects window, right-click the Process Files node and choose New -> WSDL Document.

  2. In the Name and Location wizard page, do the following:

    1. Enter a name for the file. The name must comply with the rules for the NCName data type. You cannot enter a name that already exists in the project.

    2. (Optional) Change the default folder by clicking Browse and selecting the new folder.

    3. Enter the target namespace for the WSDL file. The target namespace will appear in the root element.

    4. Select the WSDL Type.

      The WSDL types are:

      • Abstract WSDL Document — The abstract type only requires that you fill out the Abstract Configuration page of the wizard.

      • Concrete WSDL Document — The concrete type requires you to select a Binding and a Binding Type. Additional configuration pages are added to the wizard, associated with the binding and type you select.

    5. Click Next.

  3. f you select the Abstract WSDL Document as the WSDL Type, or if you select SOAP/HTTP as the binding for the concrete type, the next page of the wizard is the Abstract Configuration.

    In the Abstract Configuration wizard page, do the following:

    1. Enter a name for the port type.

    2. Enter a name for the operation.

    3. Select the type of operation.

    4. Define the message that the operation receives as input.

    5. If the operation is a request-response operation, then define the message that the operation sends as output.

    6. (Optional) If the operation is a request-response operation, then you can optionally define a message that the operation sends as a fault.

    7. By default, the New WSDL Document wizard generates a partner link type automatically. If you want to create the partner link type manually, clear the Generate partnerlinktype automatically checkbox.

    8. If you select the Abstract WSDL Document as the WSDL type, click Finish. If you select SOAP/HTTP as the binding for the concrete type, click Next.

  4. The HTTP/SOAP Concrete Configuration includes the following settings.

    1. Enter a name for the binding.

    2. Enter a name for the port.

    3. Click Finish.

      The WSDL file is created. The WSDL Editor appears in WSDL view.More InformationFor SOAP Bindings.

Creating a WSDL File Based On an Existing WSDL File

Instead of creating a WSDL file from scratch, you can create a WSDL file based on an existing WSDL file.

ProcedureTo create a WSDL file based on an existing WSDL file

  1. In the Projects window, right-click the Process Files node and choose New -> Other.

  2. In the Choose File Type wizard page, do the following:

    1. In the Categories list, select the XML node.

    2. In the File Types list, select the External WSDL Document(s) node.

    3. Click Next.

  3. In the Specify Resource Location wizard page, do one of the following:

    • To create a WSDL file based on a running service:

      1. Select the From URL button.

      2. Enter the URL of the service's WSDL file.

      3. Click Finish.

    • To create a WSDL file by using an existing WSDL file on the local file system:

      1. Select the From Local File System button.

      2. Specify the folder where the WSDL file is located.

      3. Click Finish.

    The WSDL file is created. The WSDL Editor appears in WSDL view.

NCNAME Data Type

XML Schema includes a data type called NCName.

Any name that has the NCName data type must comply with the following rules:

Using Refactoring to Rename or Delete WSDL Components

You can perform refactoring by using the following approaches:

You can also rename a component by changing the value of the Name property. The WSDL Editor renames all occurrences in the same file, but not in other files.

Validating WSDL Files

The WSDL Editor includes a validation tool. The validation tool reviews the WSDL file for problems with syntax and semantics.

ProcedureTo validate a WSDL file

  1. Display any of the views in the WSDL Editor.

  2. In the toolbar, click the Validate XML button.

    The Output window displays any errors or warnings.