Using the WSDL Plug-in
The WSDL standard provides a common method of defining web services for programmatic use. XML files define the operations that can be performed on those web services, define the format for data transfer, and enforce validation of the requests and responses.
The AppStudio WSDL plug-in reads WSDL files and generates a custom plug-in DLL based on that file. This on-the-fly creation of a plug-in lets you connect to WSDL-based data sources and test connections to your back-end all from within AppStudio.
To use data from a WSDL-based data source, you:
- Install the WSDL plug-in.
- Generate a custom WSDL DLL.
- Add the generated DLL as a new data source.
- Map the new data source to your entities.
Each of these steps is described in the sections that follow.
Installing the WSDL Plug-in
The WSDL plug-in is not part of the core AppStudio plug-ins. However, it is included in the AppStudio and AppServer installers. To upgrade this plug-in, you must download and install it separately. For more information on installing the plug-in, see Downloading and installing non-core plug-ins.
In addition, you must have the .NET SDK or Microsoft Visual Studio installed to use this plug-in.
Generating a WSDL plug-in DLL
AppStudio automatically generates a WSDL plug-in based on the contents of your data source's WSDL file. The generated WSDL plug-in DLL is based on a WSDL plug-in template. The default template is appropriate for most circumstances. If you want to extend your WSDL plug-in to perform more advanced functionality, you can compile a custom WSDL plug-in to use as a template. For more information, see Developing Custom Plug-ins.
Before generating a WSDL plug-in DLL, be sure that your WSDL:
To generate a WSDL plug-in DLL from the default template:
- Open the Data Source Manager in AppStudio.
- Click the Add button to add a new data source.
- In the Name field, enter a name for your new data source. For example, "My WSDL DS". This is the data source that you will use when mapping entities to the web service's output fields.
- Click the + symbol next to the Plug-In Type drop-down list box:
The Add New Plug-In dialog box appears:
Enter details about the new plug-in DLL that is to be created. All fields are required, unless otherwise noted. Use the following table to determine the value of the fields:
Field Description Name Enter a name for the plug-in; for example, MyWSDLPlugIn. WSDL Location Enter the location of the *.wsdl file; for example:
The WSDL file must be WSE 3.0 compliant.
XSD Location(s) (Optional) Enter the location of the *.xsd (XML Schema Definition) files. XSD files are used to validate XML files such as WSDL files. For example:
If there are more than one XSD files, separate them with commas; for example:
XSD files are optional, but you are encouraged to use them to ensure that the data types being transmitted are clearly defined and meet the requirements of the web service.
Select the appropriate DLL. Unless you have created a custom WSDL plug-in template, select Plugins.WSDL.dll. For information on creating a custom template, see Using a Custom Template.
- Click the Add Plug-In button to generate the new DLL.
AppStudio generates a new plug-in DLL based on the WSDL file you provided. The name of the plug-in is the name you entered in the Add New Plug-In dialog box (for example, MyWSDLPlugIn.dll). This DLL is located in AppStudio's /Plugins directory. In that same directory, AppStudio also generates a *.pdb file. This file is a Program Debug Database file and is used for debugging the plug-in in Visual Studio. For more information, see Program Database Files.
- Copy the new DLL from the AppStudio /Plugins directory to your server's /bin/plugins directory.
- (Optional) Copy the *.pdb file from the AppStudio /Plugins directory to your server's /bin/plugins directory. While not required for deployment, this file is necessary if you want to step through the plug-in when debugging in Visual Studio.
- Save your application.
After the DLL is generated, the WSDL is no longer required. It does not need to be accessible at run-time by the server or the client devices.
Supported data types
|XSD Data Type||WSDL Plug-in Data Type||Additional Information|
For additional information about types that require that the
minOccurs attribute be set to "0", see Limitations of the WSDL Plug-in.