Package complexsoap.client.stub.com.cdyne.ws

Examples of complexsoap.client.stub.com.cdyne.ws.LatLongReturn


            // create the stub
            Zip2GeoSoap stub = (Zip2GeoSoap) service.getStub(Zip2GeoSoap.class);

            // do the invocation
            // args[1] is the zip code
            LatLongReturn zipInfo = stub.GetLatLong(args[1], "");

            System.out.println(
                "This zip code is in "
                    + zipInfo.getCity()
                    + ","
                    + zipInfo.getStateAbbrev()
                    + " in "
                    + zipInfo.getCounty()
                    + " county\n"
                    + "It extends from longitude "
                    + zipInfo.getFromLongitude()
                    + " to longitude "
                    + zipInfo.getToLongitude()
                    + "\n and from latitude "
                    + zipInfo.getFromLatitude()
                    + " to latitude "
                    + zipInfo.getToLatitude());

        } catch (WSIFException we) {
            System.out.println(
                "Error while executing sample, received an exception from WSIF; details:");
            we.printStackTrace();
View Full Code Here


    private static void verifyAddress(Address address) throws Exception {
  // extract the zip code from the address
  String zipCode = ""+address.getZip();
  // look up information for that zip
  LatLongReturn zipInfo = zip2geo.GetLatLong(zipCode,"");
  if (!zipInfo.getCity().equals(address.getCity())) {
      printError("Zip "+zipCode+" is in city "+zipInfo.getCity()+
           ", not city "+address.getCity()+" as you specified");
  }
  if (!zipInfo.getStateAbbrev().equals(address.getState())) {
      printError("Zip "+zipCode+" is in state "+zipInfo.getStateAbbrev()+
           ", not state "+address.getState()+" as you specified");
  }
    }  
View Full Code Here

        // do the invocation
        if (operation.executeRequestResponseOperation(input, output, fault)) {
            // invocation succeeded, extract information from output
            // message
            LatLongReturn zipInfo =
                (LatLongReturn) output.getObjectPart("GetLatLongResult");
            System.out.println(
                "This zip code is in "
                    + zipInfo.getCity()
                    + ","
                    + zipInfo.getStateAbbrev()
                    + " in "
                    + zipInfo.getCounty()
                    + " county\n"
                    + "It extends from longitude "
                    + zipInfo.getFromLongitude()
                    + " to longitude "
                    + zipInfo.getToLongitude()
                    + "\n and from latitude "
                    + zipInfo.getFromLatitude()
                    + " to latitude "
                    + zipInfo.getToLatitude());
        } else {
            System.out.println("Invocation failed");
            // extract fault message info
        }
    }
View Full Code Here

TOP

Related Classes of complexsoap.client.stub.com.cdyne.ws.LatLongReturn

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.