FileDocCategorySizeDatePackage
InOutApp.javaAPI DocExample1022Tue Feb 26 12:16:30 GMT 2002javasoap.book.ch4

InOutApp

public class InOutApp extends Object

Fields Summary
Constructors Summary
Methods Summary
public static voidmain(java.lang.String[] args)

      try {
         IStockPriceService ctr = 
           (IStockPriceService)Registry.bind(
             "http://georgetown:8004/glue/urn:StockPriceService.wsdl",
             IStockPriceService.class);
         StringInOut stock = new StringInOut("MiNdStRm");
         boolean ok = ctr.correctSymbol(stock);
         if (ok) {
           System.out.println("Symbol converted to: " 
                        + stock.value);
         }
         String currency = "USD";
         floatOut price = new floatOut();
         ok = ctr.getOutPrice(stock.value, currency, price);
         System.out.println("Result is " + price.value);
      }
      catch (RegistryException e)
      {
        System.out.println(e);
      }