【问题标题】:How to Connect a Webservice to an Android Application如何将 Web 服务连接到 Android 应用程序
【发布时间】:2012-04-19 06:51:14
【问题描述】:

我是 Web 服务的新手,我想制作一个 RESTful Web 服务,并将其连接到 Android 应用程序。我想要有关如何执行此操作的步骤或教程。

我开始使用这个链接This link gives steps to create web service but I can't get why it is using entity classes (customer , DicountCode) from an existing database. What are these classes for?创建我的服务

【问题讨论】:

    标签: java android rest


    【解决方案1】:

    您可以尝试使用它来自动连接和解析您的网络服务 http://www.wsdl2code.com

    SampleService srv1 = new SampleService();
         req = new Request();                     
         req.companyId = "1";
         req.userName = "userName";                                     
         req.password = "pas";
         Response response =    srv1.ServiceSample(req);
    

    【讨论】:

    • 这个网站很棒!感谢您的参考。
    【解决方案2】:

    由于您是此区域的新手,请务必查看以前对类似问题的回答。但是,您可以找到从 android here 访问 web 服务的教程,并且在 stackoverflow here 上回答了与您类似的问题。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2020-12-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多