<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    Java,J2EE,Weblogic,Oracle

    java項(xiàng)目隨筆
    隨筆 - 90, 文章 - 6, 評(píng)論 - 61, 引用 - 0
    數(shù)據(jù)加載中……

    axis 調(diào)用 c++ 的 webservice

    package com.test.axis;

    import org.apache.axis.client.Call;
    import org.apache.axis.client.Service;

    import javax.xml.namespace.QName;
    import javax.xml.rpc.ServiceException;


    public class GroupCallChatClient {
     /**
      *
      * @param phoneno   手機(jī)號(hào)碼
      * @param ORGANISE_ID   渠道ID
      * @param serviceId   業(yè)務(wù)編碼
      * @return
      */
     
     public static int callWebservice(String phoneno, String ORGANISE_ID,String serviceId){
      /*1表示已訂購(gòu),0表示沒有訂購(gòu),3表示配置錯(cuò)誤,4接口傳入?yún)?shù)存在問(wèn)題,5.數(shù)據(jù)庫(kù)錯(cuò)誤  6錯(cuò)誤 */
      int flag = 6;
      
      String endpoint = "http://211.96.25.137:9091/";
         Service service = new Service();
         Call call = null;
        
         try { 
       call = (Call)service.createCall();
      
         call.setTargetEndpointAddress(endpoint);
        

         call.setOperationName(new QName("http://www.qnuse.com/query_inerface", "query"));
         call.addParameter( "account-id",new QName("http://www.w3.org/2001/XMLSchema", "string"),javax.xml.rpc.ParameterMode.IN);
         call.addParameter( "order-way-id",new QName("http://www.w3.org/2001/XMLSchema", "string"),javax.xml.rpc.ParameterMode.IN);
         call.addParameter( "service-id",new QName("http://www.w3.org/2001/XMLSchema", "string"),javax.xml.rpc.ParameterMode.IN);
         call.setReturnClass(int.class);
        
         Object _resp = call.invoke(new Object[]{phoneno, ORGANISE_ID, serviceId});
        
         if (_resp != null && !"".equals(_resp)){
          flag =  ((Integer) _resp).intValue();
         }   
         System.out.println(phoneno+"---->群呼群聊,返回值:" + flag );
       
      } catch (Exception e) {
       // TODO Auto-generated catch block
       e.printStackTrace();
       System.out.println("群呼群聊出錯(cuò): " + e);
      }
        
     
      
      return flag;
      
     }

    }




    c++  的 webservice   的 wsdl

    <?xml version="1.0" encoding="UTF-8"?>
    <definitions name="QUERY_inerface"
     targetNamespace="http://www.qnuse.com/query_inerface.wsdl"
     xmlns:tns="http://www.qnuse.com/query_inerface.wsdl"
     xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
     xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
     xmlns:xsd="http://www.w3.org/2001/XMLSchema"
     xmlns:orderI="http://www.qnuse.com/query_inerface"
     xmlns:SOAP="http://schemas.xmlsoap.org/wsdl/soap/"
     xmlns:MIME="http://schemas.xmlsoap.org/wsdl/mime/"
     xmlns:DIME="http://schemas.xmlsoap.org/ws/2002/04/dime/wsdl/"
     xmlns:WSDL="http://schemas.xmlsoap.org/wsdl/"
     xmlns="http://schemas.xmlsoap.org/wsdl/">

    <types>

     <schema targetNamespace="http://www.qnuse.com/query_inerface"
      xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
      xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xmlns:xsd="http://www.w3.org/2001/XMLSchema"
      xmlns:orderI="http://www.qnuse.com/query_inerface"
      xmlns="http://www.w3.org/2001/XMLSchema"
      elementFormDefault="unqualified"
      attributeFormDefault="unqualified">
      <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
     </schema>

    </types>

    <message name="queryRequest">
     <part name="account-id" type="xsd:string"/>
     <part name="order-way-id" type="xsd:string"/>
     <part name="service-id" type="xsd:string"/>
    </message>

    <message name="queryResponse">
     <part name="result" type="xsd:int"/>
    </message>

    <portType name="QUERY_inerfacePortType">
     <operation name="query">
      <documentation>Service definition of function orderI__query</documentation>
      <input message="tns:queryRequest"/>
      <output message="tns:queryResponse"/>
     </operation>
    </portType>

    <binding name="QUERY_inerface" type="tns:QUERY_inerfacePortType">
     <SOAP:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
     <operation name="query">
      <SOAP:operation style="rpc" soapAction=""/>
      <input>
         <SOAP:body use="encoded" namespace="http://www.qnuse.com/query_inerface" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
      </input>
      <output>
         <SOAP:body use="encoded" namespace="http://www.qnuse.com/query_inerface" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
      </output>
     </operation>
    </binding>

    <service name="QUERY_inerface">
     <documentation>gSOAP 2.7.7 generated service definition</documentation>
     <port name="QUERY_inerface" binding="tns:QUERY_inerface">
      <SOAP:address location="http://10.130.28.3:9093/"/>
     </port>
    </service>

    </definitions>

    posted on 2010-08-25 12:01 龔椿深 閱讀(860) 評(píng)論(0)  編輯  收藏


    只有注冊(cè)用戶登錄后才能發(fā)表評(píng)論。


    網(wǎng)站導(dǎo)航:
     
    主站蜘蛛池模板: 久久青草91免费观看| 久久青青草原亚洲av无码app| 亚洲喷奶水中文字幕电影| 日本媚薬痉挛在线观看免费| 女人与禽交视频免费看 | 国产亚洲精品看片在线观看| 亚洲欧洲精品成人久久曰| 18禁美女裸体免费网站| 中文字幕亚洲综合精品一区| 1000部拍拍拍18勿入免费视频下载| 亚洲日本va午夜中文字幕一区| 日韩免费在线视频| 亚洲视频网站在线观看| 免费A级毛片无码专区| 亚洲日本在线观看网址| 国产精品入口麻豆免费观看| 精品亚洲成在人线AV无码| 国产乱子精品免费视观看片| 亚洲综合欧美色五月俺也去| 国产免费观看黄AV片 | 亚洲AV成人片色在线观看| 91大神免费观看| 最新亚洲春色Av无码专区| 国产国产人免费视频成69大陆| 污网站在线免费观看| 精品亚洲成α人无码成α在线观看 | 亚洲欧美日韩中文高清www777| 国产精品久久免费视频| fc2免费人成在线| 久久综合亚洲鲁鲁五月天| 超pen个人视频国产免费观看| 美女视频黄频a免费大全视频| 亚洲人成人77777网站| 24小时日本韩国高清免费| 国产亚洲欧美日韩亚洲中文色| 久久亚洲色一区二区三区| 99久久国产免费中文无字幕| 亚洲人成人网站18禁| 国产午夜亚洲精品午夜鲁丝片| 最近中文字幕免费2019| 免费精品视频在线|