⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 timeserviceservicelocator.java

📁 < J2EE应用开发详解>>一书全部的源代码. 本书基于J2EE 1.4平台
💻 JAVA
字号:
/**
 * TimeServiceServiceLocator.java
 *
 * This file was auto-generated from WSDL
 * by the Apache Axis WSDL2Java emitter.
 */

package localhost.test_axis.services.TimeService;

public class TimeServiceServiceLocator extends org.apache.axis.client.Service implements localhost.test_axis.services.TimeService.TimeServiceService {

    // Use to get a proxy class for TimeService
    private final java.lang.String TimeService_address = "http://localhost/test_axis/services/TimeService";

    public java.lang.String getTimeServiceAddress() {
        return TimeService_address;
    }

    // The WSDD service name defaults to the port name.
    private java.lang.String TimeServiceWSDDServiceName = "TimeService";

    public java.lang.String getTimeServiceWSDDServiceName() {
        return TimeServiceWSDDServiceName;
    }

    public void setTimeServiceWSDDServiceName(java.lang.String name) {
        TimeServiceWSDDServiceName = name;
    }

    public localhost.test_axis.services.TimeService.TimeService getTimeService() throws javax.xml.rpc.ServiceException {
       java.net.URL endpoint;
        try {
            endpoint = new java.net.URL(TimeService_address);
        }
        catch (java.net.MalformedURLException e) {
            throw new javax.xml.rpc.ServiceException(e);
        }
        return getTimeService(endpoint);
    }

    public localhost.test_axis.services.TimeService.TimeService getTimeService(java.net.URL portAddress) throws javax.xml.rpc.ServiceException {
        try {
            localhost.test_axis.services.TimeService.TimeServiceSoapBindingStub _stub = new localhost.test_axis.services.TimeService.TimeServiceSoapBindingStub(portAddress, this);
            _stub.setPortName(getTimeServiceWSDDServiceName());
            return _stub;
        }
        catch (org.apache.axis.AxisFault e) {
            return null;
        }
    }

    /**
     * For the given interface, get the stub implementation.
     * If this service has no port for the given interface,
     * then ServiceException is thrown.
     */
    public java.rmi.Remote getPort(Class serviceEndpointInterface) throws javax.xml.rpc.ServiceException {
        try {
            if (localhost.test_axis.services.TimeService.TimeService.class.isAssignableFrom(serviceEndpointInterface)) {
                localhost.test_axis.services.TimeService.TimeServiceSoapBindingStub _stub = new localhost.test_axis.services.TimeService.TimeServiceSoapBindingStub(new java.net.URL(TimeService_address), this);
                _stub.setPortName(getTimeServiceWSDDServiceName());
                return _stub;
            }
        }
        catch (java.lang.Throwable t) {
            throw new javax.xml.rpc.ServiceException(t);
        }
        throw new javax.xml.rpc.ServiceException("There is no stub implementation for the interface:  " + (serviceEndpointInterface == null ? "null" : serviceEndpointInterface.getName()));
    }

    /**
     * For the given interface, get the stub implementation.
     * If this service has no port for the given interface,
     * then ServiceException is thrown.
     */
    public java.rmi.Remote getPort(javax.xml.namespace.QName portName, Class serviceEndpointInterface) throws javax.xml.rpc.ServiceException {
        if (portName == null) {
            return getPort(serviceEndpointInterface);
        }
        String inputPortName = portName.getLocalPart();
        if ("TimeService".equals(inputPortName)) {
            return getTimeService();
        }
        else  {
            java.rmi.Remote _stub = getPort(serviceEndpointInterface);
            ((org.apache.axis.client.Stub) _stub).setPortName(portName);
            return _stub;
        }
    }

    public javax.xml.namespace.QName getServiceName() {
        return new javax.xml.namespace.QName("http://localhost/test_axis/services/TimeService", "TimeServiceService");
    }

    private java.util.HashSet ports = null;

    public java.util.Iterator getPorts() {
        if (ports == null) {
            ports = new java.util.HashSet();
            ports.add(new javax.xml.namespace.QName("TimeService"));
        }
        return ports.iterator();
    }

}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -