00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023 package com.scalagent.kjndi.ksoap;
00024
00025 import java.util.Vector;
00026 import java.util.Hashtable;
00027
00028 public class SoapNamingContext {
00030 private String serviceUrl = null;
00031
00032 HttpConnection httpConnection = null;
00033
00034 public SoapNamingContext(String soapHost, int soapPort)
00035 throws Exception {
00036
00037
00038 serviceUrl = "http://" + soapHost + ":" + soapPort
00039 + "/soap/servlet/rpcrouter";
00040
00041 httpConnection = new HttpConnection(serviceUrl);
00042 }
00043
00044 public void bind(String name, Object obj) throws Exception {
00045 httpConnection.call("bind",name,obj);
00046 }
00047
00048 public void rebind(String name, Object obj) throws Exception {
00049 httpConnection.call("rebind",name,obj);
00050 }
00051
00052 public Object lookup(String name) throws Exception {
00053 return httpConnection.call("lookup",name,null);
00054 }
00055
00056 public void unbind(String name) throws Exception {
00057 httpConnection.call("unbind",name,null);
00058 }
00059 }