l
三种方式
=================================
动态调用接口:
import java.net.URL;
import javax.xml.namespace.QName;
import org.apache.axis.client.Call;
import org.apache.axis.client.Service;
public class UsingDII {
public static void main(String[] args) {
try {
int a = 100, b=60;
String endPoint = "http://localhost:9000/testaxis/AddFunction.jws";
Service service = new Service();
Call call = (Call)service.createCall();
call.setOperationName(new QName(endPoint,"addInt"));
call.setTargetEndpointAddress(new URL(endPoint));
Integer result = (Integer)call.invoke(new Object[]{new Integer(a),new Integer(b)});