package biz;
import java.util.Date;
import java.text.DateFormat;
import org.apache.axis.client.Call;
import org.apache.axis.client.Service;
import javax.xml.namespace.QName;
import java.lang.Integer;
import javax.xml.rpc.ParameterMode;
public class TempService {
public static void main(String[] args) {
try {
String endpoint = " // 创建一个服务(service)调用(call) Service service = new Service(); Call call = (Call)service.createCall();// 通过service创建call对象 // 设置service所在URL call.setTargetEndpointAddress(new java.net.URL(endpoint)); call.setOperationName(new QName("http://WebXml.com.cn/","getMobileCodeInfo")); //Add 是net 那边的方法 " call.addParameter(new QName("http://WebXml.com.cn/","mobileCode"),org.apache.axis.encoding.XMLType.XSD_STRING, javax.xml.rpc.ParameterMode.IN); call.addParameter(new QName("http://WebXml.com.cn/","userID"),org.apache.axis.encoding.XMLType.XSD_STRING, javax.xml.rpc.ParameterMode.IN); // 这就是我搞了一天的原因所在,"test" 这个就是传参数的变量,也就是NET方面的参数,一定不要带错了 // 我当初不知道 ,以为这个参数是自己随便写的,结果总是报NULL,真是气死人了 call.setUseSOAPAction(true); call.setReturnType(org.apache.axis.encoding.XMLType.SOAP_STRING); //返回参数的类型