Red Hat Training

A Red Hat training course is available for Red Hat JBoss Data Virtualization

8.6. Create a New Web Service View Model

8.6.1. Create a New Web Service View Model

To create a new empty web service view model:
  1. Launch the New Model Wizard.
  2. Specify a unique model name.
  3. Select Web Service option from Model Class drop-down menu.
  4. Select View Model from Model Type drop-down menu.
  5. Click Finish.

Note

You can change the target location (i.e. project or folder) by selecting the Browse... button and selecting a project or folder within your workspace.
In addition to creating a new empty web service view model, the following builder options are available:
  1. Copy from existing model of the same model class.
  2. Build from existing WSDL file(s) or URL.

8.6.2. Copy an Existing Web Service View Model

This builder option performs a structural copy of the contents of an existing model to a newly defined model. You can choose a full copy or select individual model components for copy.
To create a new relational model by copying contents from another web service view model, complete Create a New Web Service View Model section and continue with these additional steps:
  1. Select the model builder labeled Copy from existing model of the same model class and click Next >. The Copy Existing Model dialog will be displayed.
  2. Select an existing relational model from the workspace using the browse button.
  3. Select the Copy all descriptions option if desired. Click Finish.

8.6.3. Create a Web Service View Model from a WSDL File or URL

This builder option creates a Web service model based on a user defined WSDL file and its referenced schemas. In addition, applicable XML schema files and XML View document models (optional) are created.
To create a new relational model by copying contents from another web service view model, complete Create a New Web Service View Model section and continue with these additional steps:
  1. Select the model builder labeled Build from existing WSDL file(s) or URL and click Next >.
  2. The remaining wizard steps are identical to those found using the wsdl-to-web-service-import section action option.

8.6.4. Create a Web Service View Model from XML Document View Models

Web Service models and their corresponding Interfaces and Operations can be generated in Teiid Designer from XML View model components. Namely, XML View Documents and XML View Document roots.
To create a new Web service model from XML components:
  1. Select either a single XML Document or single XML Document root in the Model Explorer View.
  2. Right-click select Modeling > Create Web Service action .
  3. Fill in missing properties in Web Service Generation Wizard.
  4. Click Finish to generate model. When model generation is complete, a confirmation dialog is displayed. Click OK.

Note

Users can change the Web Service Model and Interface Name values (via "..." buttons) to use existing Web service model components. This will create a new operation in an existing model.