2 * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8)
3 * Copyright (C) 2012 J Procter, AM Waterhouse, LM Lui, J Engelhardt, G Barton, M Clamp, S Searle
5 * This file is part of Jalview.
7 * Jalview is free software: you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
11 * Jalview is distributed in the hope that it will be useful, but
12 * WITHOUT ANY WARRANTY; without even the implied warranty
13 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14 * PURPOSE. See the GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License along with Jalview. If not, see <http://www.gnu.org/licenses/>.
18 package uk.ac.ebi.www.picr.AccessionMappingService;
20 public class AccessionMapperServiceLocator extends
21 org.apache.axis.client.Service implements
22 uk.ac.ebi.www.picr.AccessionMappingService.AccessionMapperService
25 public AccessionMapperServiceLocator()
29 public AccessionMapperServiceLocator(
30 org.apache.axis.EngineConfiguration config)
35 // Use to get a proxy class for AccessionMapperPort
36 private java.lang.String AccessionMapperPort_address = "http://www.ebi.ac.uk:80/Tools/picr/service";
38 public java.lang.String getAccessionMapperPortAddress()
40 return AccessionMapperPort_address;
43 // The WSDD service name defaults to the port name.
44 private java.lang.String AccessionMapperPortWSDDServiceName = "AccessionMapperPort";
46 public java.lang.String getAccessionMapperPortWSDDServiceName()
48 return AccessionMapperPortWSDDServiceName;
51 public void setAccessionMapperPortWSDDServiceName(java.lang.String name)
53 AccessionMapperPortWSDDServiceName = name;
56 public uk.ac.ebi.www.picr.AccessionMappingService.AccessionMapperInterface getAccessionMapperPort()
57 throws javax.xml.rpc.ServiceException
59 java.net.URL endpoint;
62 endpoint = new java.net.URL(AccessionMapperPort_address);
63 } catch (java.net.MalformedURLException e)
65 throw new javax.xml.rpc.ServiceException(e);
67 return getAccessionMapperPort(endpoint);
70 public uk.ac.ebi.www.picr.AccessionMappingService.AccessionMapperInterface getAccessionMapperPort(
71 java.net.URL portAddress) throws javax.xml.rpc.ServiceException
75 uk.ac.ebi.www.picr.AccessionMappingService.AccessionMapperBindingStub _stub = new uk.ac.ebi.www.picr.AccessionMappingService.AccessionMapperBindingStub(
77 _stub.setPortName(getAccessionMapperPortWSDDServiceName());
79 } catch (org.apache.axis.AxisFault e)
85 public void setAccessionMapperPortEndpointAddress(java.lang.String address)
87 AccessionMapperPort_address = address;
91 * For the given interface, get the stub implementation. If this service has
92 * no port for the given interface, then ServiceException is thrown.
94 public java.rmi.Remote getPort(Class serviceEndpointInterface)
95 throws javax.xml.rpc.ServiceException
99 if (uk.ac.ebi.www.picr.AccessionMappingService.AccessionMapperInterface.class
100 .isAssignableFrom(serviceEndpointInterface))
102 uk.ac.ebi.www.picr.AccessionMappingService.AccessionMapperBindingStub _stub = new uk.ac.ebi.www.picr.AccessionMappingService.AccessionMapperBindingStub(
103 new java.net.URL(AccessionMapperPort_address), this);
104 _stub.setPortName(getAccessionMapperPortWSDDServiceName());
107 } catch (java.lang.Throwable t)
109 throw new javax.xml.rpc.ServiceException(t);
111 throw new javax.xml.rpc.ServiceException(
112 "There is no stub implementation for the interface: "
113 + (serviceEndpointInterface == null ? "null"
114 : serviceEndpointInterface.getName()));
118 * For the given interface, get the stub implementation. If this service has
119 * no port for the given interface, then ServiceException is thrown.
121 public java.rmi.Remote getPort(javax.xml.namespace.QName portName,
122 Class serviceEndpointInterface)
123 throws javax.xml.rpc.ServiceException
125 if (portName == null)
127 return getPort(serviceEndpointInterface);
129 java.lang.String inputPortName = portName.getLocalPart();
130 if ("AccessionMapperPort".equals(inputPortName))
132 return getAccessionMapperPort();
136 java.rmi.Remote _stub = getPort(serviceEndpointInterface);
137 ((org.apache.axis.client.Stub) _stub).setPortName(portName);
142 public javax.xml.namespace.QName getServiceName()
144 return new javax.xml.namespace.QName(
145 "http://www.ebi.ac.uk/picr/AccessionMappingService",
146 "AccessionMapperService");
149 private java.util.HashSet ports = null;
151 public java.util.Iterator getPorts()
155 ports = new java.util.HashSet();
156 ports.add(new javax.xml.namespace.QName(
157 "http://www.ebi.ac.uk/picr/AccessionMappingService",
158 "AccessionMapperPort"));
160 return ports.iterator();
164 * Set the endpoint address for the specified port name.
166 public void setEndpointAddress(java.lang.String portName,
167 java.lang.String address) throws javax.xml.rpc.ServiceException
169 if ("AccessionMapperPort".equals(portName))
171 setAccessionMapperPortEndpointAddress(address);
174 { // Unknown Port Name
175 throw new javax.xml.rpc.ServiceException(
176 " Cannot set Endpoint Address for Unknown Port" + portName);
181 * Set the endpoint address for the specified port name.
183 public void setEndpointAddress(javax.xml.namespace.QName portName,
184 java.lang.String address) throws javax.xml.rpc.ServiceException
186 setEndpointAddress(portName.getLocalPart(), address);