예제 #1
0
 public void AddRewardList(RewardList rewardList) {
   Context weblogicContext = ejbproxy.getInitialConnection();
   RewardListService serviceClient;
   try {
     serviceClient = (RewardListService) weblogicContext.lookup("RewardListBean/remote");
     serviceClient.AddRewardList(rewardList);
   } catch (NamingException e) {
     e.printStackTrace();
   }
 }
예제 #2
0
 public void DeleteRewardList(String id) {
   Context weblogicContext = ejbproxy.getInitialConnection();
   RewardListService serviceClient;
   try {
     serviceClient = (RewardListService) weblogicContext.lookup("RewardListBean/remote");
     serviceClient.DeleteRewardList(id);
   } catch (NamingException e) {
     // TODO Auto-generated catch block
     e.printStackTrace();
   }
 }
예제 #3
0
 public int GetRewardListCount(HashMap<String, String> map) {
   int total = 0;
   Context weblogicContext = ejbproxy.getInitialConnection();
   RewardListService serviceClient;
   try {
     serviceClient = (RewardListService) weblogicContext.lookup("RewardListBean/remote");
     total = serviceClient.GetRewardListCount(map);
   } catch (NamingException e) {
     // TODO Auto-generated catch block
     e.printStackTrace();
   }
   return total;
 }
예제 #4
0
  public RewardList findRewardList(String fid) {
    RewardList rewardList = new RewardList();
    try {
      Context weblogicContext = ejbproxy.getInitialConnection();
      RewardListService serviceClient =
          (RewardListService) weblogicContext.lookup("RewardListBean/remote");
      rewardList = serviceClient.findRewardList(fid);

    } catch (NamingException ne) {
      // TODO: handle exception
      System.err.println("不能连接NamingException在:" + ne.toString());
      ne.printStackTrace();
    }

    return rewardList;
  }
예제 #5
0
  public List<RewardList> ListRewardList(int offset, int length, HashMap<String, String> map) {
    List<RewardList> listRewardList = new ArrayList<RewardList>();
    try {
      Context weblogicContext = ejbproxy.getInitialConnection();
      RewardListService serviceClient =
          (RewardListService) weblogicContext.lookup("RewardListBean/remote");
      listRewardList = serviceClient.ListRewardList(offset, length, map);

    } catch (NamingException ne) {
      // TODO: handle exception
      System.err.println("不能连接NamingException在:" + ne.toString());
      ne.printStackTrace();
    }

    return listRewardList;
  }