Invoking Web Service

In the new version (2.1) of CAI (or Application Designer) you can easily build a page on base of a web service, using the Web Service Layout Assistant. And there is no need to provide any Java coding. Application Designer provides for the adapter to call the service.

Here is an example page XML:

<?xml version="1.0" encoding="UTF-8"?>
<wsdlpage wsdlpagename="OrderType" wsdlurl="http://localhost:51000/cis/services/SrvSalesDef?wsdl" service="SrvSalesDef" port="SrvSalesDefHttpPort" operation="getOrderType">
    <titlebar name="WSDLTemplate">
    <header withdistance="false">
            <itr height="8">
                <label name="Type Id" width="100">
                <field valueprop="getOrderType.in0" width="200" wsdlparams="Input;;getOrderType;;in0">
            <itr height="8">
                <button name="get order types" method="getOrderType">
        <rowarea name="Order Type">
            <itr height="8">
                <label name="Code" width="100">
                <field valueprop="getOrderTypeResponse.out.code" width="200" wsdlparams="Output;;getOrderTypeResponse;;out;;code">
            <itr height="8">
                <label name="Name" width="100">
                <field valueprop="" width="200" wsdlparams="Output;;getOrderTypeResponse;;out;;name">
    <statusbar withdistance="false">

However I need to do some coding within the page, especially after the Web Service method is invoked.

I think it is not possible to bind an adapter to Web Service Layouts. Is it :?:

And therefore I need to use a standard layout and invoke the web service myself in the adapter. But I do not know how to accomplish this. How can I invoke a Web Service from the adapter code?



I did not fully understand: yes you can build pages that are calling one web service. From the web service definition you can drag & drop the page and then execute the web service. Teh adapter for the page is a generic one.

In case you want to include any web service into your adapter processing on yourself (i.e. your own adapter, i.e. you created a page without reference to web service) you have to use some web service framework (e.g. Axis, or JWSDP) in order to call the web service from Java.