WEB开发网
开发学院软件开发Java 用 Apache Geronimo 和 Axis2 实现在线银行,第 2... 阅读

用 Apache Geronimo 和 Axis2 实现在线银行,第 2 部分: 服务:填充内容(下)

 2010-03-19 00:00:00 来源:WEB开发网   
核心提示: /*LOOKUPACCOUNTS*/publicstaticbooleanlookupAccounts(OnlineBankingPortTypeStubstub,byte[]token){try{LookupAccountsDocumentreqDoc00=LookupAccountsDocu

  /* LOOKUPACCOUNTS */ 
  public static boolean lookupAccounts 
      (OnlineBankingPortTypeStub stub, byte[] token){ 
    try{ 
      LookupAccountsDocument reqDoc00 = 
        LookupAccountsDocument.Factory.newInstance(); 
      LookupAccountsDocument. 
        LookupAccounts reqDoc01 = 
        reqDoc00.addNewLookupAccounts(); 
 
      reqDoc01.setToken(token); 
 
      LookupAccountsResponseDocument resDoc00 = 
        stub.LookupAccounts(reqDoc00); 
      LookupAccountsResponseDocument. 
        LookupAccountsResponse resDoc01 = 
        resDoc00.getLookupAccountsResponse(); 
 
      int[] numbers = resDoc01.getNumbersArray(); 
      float[] balances = resDoc01.getBalancesArray(); 
      String[] types = resDoc01.getTypesArray(); 
      System.out.println("Accounts:"); 
      for(int i = 0; i < numbers.length; i++){ 
        System.out.println(numbers[i]+" : "+balances[i]+ 
                  " : "+types[i]); 
      } 
 
      return true; 
    } catch(Exception e){ 
      e.printStackTrace(); 
    } 
    return false; 
  } 

上一页  1 2 3 4 5 6 7 8 9  下一页

Tags:Apache Geronimo Axis

编辑录入:爽爽 [复制链接] [打 印]
赞助商链接