2 * JPredWSServiceLocator.java
4 * This file was auto-generated from WSDL
5 * by the Apache Axis 1.2RC2 Nov 16, 2004 (12:19:44 EST) WSDL2Java emitter.
9 * Jalview - A Sequence Alignment Editor and Viewer
10 * Copyright (C) 2005 AM Waterhouse, J Procter, G Barton, M Clamp, S Searle
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation; either version 2
15 * of the License, or (at your option) any later version.
17 * This program is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
22 * You should have received a copy of the GNU General Public License
23 * along with this program; if not, write to the Free Software
24 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
29 public class JPredWSServiceLocator extends org.apache.axis.client.Service implements ext.vamsas.JPredWSService {
31 public JPredWSServiceLocator() {
35 public JPredWSServiceLocator(org.apache.axis.EngineConfiguration config) {
39 // Use to get a proxy class for jpred
40 private java.lang.String jpred_address = "http://anaplog.compbio.dundee.ac.uk:8080/axis/services/jpred";
42 public java.lang.String getjpredAddress() {
46 // The WSDD service name defaults to the port name.
47 private java.lang.String jpredWSDDServiceName = "jpred";
49 public java.lang.String getjpredWSDDServiceName() {
50 return jpredWSDDServiceName;
53 public void setjpredWSDDServiceName(java.lang.String name) {
54 jpredWSDDServiceName = name;
57 public ext.vamsas.JPredWS getjpred() throws javax.xml.rpc.ServiceException {
58 java.net.URL endpoint;
60 endpoint = new java.net.URL(jpred_address);
62 catch (java.net.MalformedURLException e) {
63 throw new javax.xml.rpc.ServiceException(e);
65 return getjpred(endpoint);
68 public ext.vamsas.JPredWS getjpred(java.net.URL portAddress) throws javax.xml.rpc.ServiceException {
70 ext.vamsas.JpredSoapBindingStub _stub = new ext.vamsas.JpredSoapBindingStub(portAddress, this);
71 _stub.setPortName(getjpredWSDDServiceName());
74 catch (org.apache.axis.AxisFault e) {
79 public void setjpredEndpointAddress(java.lang.String address) {
80 jpred_address = address;
84 * For the given interface, get the stub implementation.
85 * If this service has no port for the given interface,
86 * then ServiceException is thrown.
88 public java.rmi.Remote getPort(Class serviceEndpointInterface) throws javax.xml.rpc.ServiceException {
90 if (ext.vamsas.JPredWS.class.isAssignableFrom(serviceEndpointInterface)) {
91 ext.vamsas.JpredSoapBindingStub _stub = new ext.vamsas.JpredSoapBindingStub(new java.net.URL(jpred_address), this);
92 _stub.setPortName(getjpredWSDDServiceName());
96 catch (java.lang.Throwable t) {
97 throw new javax.xml.rpc.ServiceException(t);
99 throw new javax.xml.rpc.ServiceException("There is no stub implementation for the interface: " + (serviceEndpointInterface == null ? "null" : serviceEndpointInterface.getName()));
103 * For the given interface, get the stub implementation.
104 * If this service has no port for the given interface,
105 * then ServiceException is thrown.
107 public java.rmi.Remote getPort(javax.xml.namespace.QName portName, Class serviceEndpointInterface) throws javax.xml.rpc.ServiceException {
108 if (portName == null) {
109 return getPort(serviceEndpointInterface);
111 java.lang.String inputPortName = portName.getLocalPart();
112 if ("jpred".equals(inputPortName)) {
116 java.rmi.Remote _stub = getPort(serviceEndpointInterface);
117 ((org.apache.axis.client.Stub) _stub).setPortName(portName);
122 public javax.xml.namespace.QName getServiceName() {
123 return new javax.xml.namespace.QName("vamsas", "JPredWSService");
126 private java.util.HashSet ports = null;
128 public java.util.Iterator getPorts() {
130 ports = new java.util.HashSet();
131 ports.add(new javax.xml.namespace.QName("vamsas", "jpred"));
133 return ports.iterator();
137 * Set the endpoint address for the specified port name.
139 public void setEndpointAddress(java.lang.String portName, java.lang.String address) throws javax.xml.rpc.ServiceException {
140 if ("jpred".equals(portName)) {
141 setjpredEndpointAddress(address);
143 else { // Unknown Port Name
144 throw new javax.xml.rpc.ServiceException(" Cannot set Endpoint Address for Unknown Port" + portName);
149 * Set the endpoint address for the specified port name.
151 public void setEndpointAddress(javax.xml.namespace.QName portName, java.lang.String address) throws javax.xml.rpc.ServiceException {
152 setEndpointAddress(portName.getLocalPart(), address);