StockQuotesLocator.java
上传用户:shen332233
上传日期:2021-09-03
资源大小:7478k
文件大小:5k
源码类别:

Ajax

开发平台:

Java

  1. /**
  2.  * StockQuotesLocator.java
  3.  *
  4.  * This file was auto-generated from WSDL
  5.  * by the Apache Axis 1.2.1 Jun 14, 2005 (09:15:57 EDT) WSDL2Java emitter.
  6.  */
  7. package ajaxdashboard.ws.stockquote;
  8. public class StockQuotesLocator extends org.apache.axis.client.Service implements ajaxdashboard.ws.stockquote.StockQuotes {
  9.     public StockQuotesLocator() {
  10.     }
  11.     public StockQuotesLocator(org.apache.axis.EngineConfiguration config) {
  12.         super(config);
  13.     }
  14.     public StockQuotesLocator(java.lang.String wsdlLoc, javax.xml.namespace.QName sName) throws javax.xml.rpc.ServiceException {
  15.         super(wsdlLoc, sName);
  16.     }
  17.     // Use to get a proxy class for StockQuotesSoap
  18.     private java.lang.String StockQuotesSoap_address = "http://www.swanandmokashi.com/HomePage/WebServices/StockQuotes.asmx";
  19.     public java.lang.String getStockQuotesSoapAddress() {
  20.         return StockQuotesSoap_address;
  21.     }
  22.     // The WSDD service name defaults to the port name.
  23.     private java.lang.String StockQuotesSoapWSDDServiceName = "StockQuotesSoap";
  24.     public java.lang.String getStockQuotesSoapWSDDServiceName() {
  25.         return StockQuotesSoapWSDDServiceName;
  26.     }
  27.     public void setStockQuotesSoapWSDDServiceName(java.lang.String name) {
  28.         StockQuotesSoapWSDDServiceName = name;
  29.     }
  30.     public ajaxdashboard.ws.stockquote.StockQuotesSoap getStockQuotesSoap() throws javax.xml.rpc.ServiceException {
  31.        java.net.URL endpoint;
  32.         try {
  33.             endpoint = new java.net.URL(StockQuotesSoap_address);
  34.         }
  35.         catch (java.net.MalformedURLException e) {
  36.             throw new javax.xml.rpc.ServiceException(e);
  37.         }
  38.         return getStockQuotesSoap(endpoint);
  39.     }
  40.     public ajaxdashboard.ws.stockquote.StockQuotesSoap getStockQuotesSoap(java.net.URL portAddress) throws javax.xml.rpc.ServiceException {
  41.         try {
  42.             ajaxdashboard.ws.stockquote.StockQuotesSoapStub _stub = new ajaxdashboard.ws.stockquote.StockQuotesSoapStub(portAddress, this);
  43.             _stub.setPortName(getStockQuotesSoapWSDDServiceName());
  44.             return _stub;
  45.         }
  46.         catch (org.apache.axis.AxisFault e) {
  47.             return null;
  48.         }
  49.     }
  50.     public void setStockQuotesSoapEndpointAddress(java.lang.String address) {
  51.         StockQuotesSoap_address = address;
  52.     }
  53.     /**
  54.      * For the given interface, get the stub implementation.
  55.      * If this service has no port for the given interface,
  56.      * then ServiceException is thrown.
  57.      */
  58.     public java.rmi.Remote getPort(Class serviceEndpointInterface) throws javax.xml.rpc.ServiceException {
  59.         try {
  60.             if (ajaxdashboard.ws.stockquote.StockQuotesSoap.class.isAssignableFrom(serviceEndpointInterface)) {
  61.                 ajaxdashboard.ws.stockquote.StockQuotesSoapStub _stub = new ajaxdashboard.ws.stockquote.StockQuotesSoapStub(new java.net.URL(StockQuotesSoap_address), this);
  62.                 _stub.setPortName(getStockQuotesSoapWSDDServiceName());
  63.                 return _stub;
  64.             }
  65.         }
  66.         catch (java.lang.Throwable t) {
  67.             throw new javax.xml.rpc.ServiceException(t);
  68.         }
  69.         throw new javax.xml.rpc.ServiceException("There is no stub implementation for the interface:  " + (serviceEndpointInterface == null ? "null" : serviceEndpointInterface.getName()));
  70.     }
  71.     /**
  72.      * For the given interface, get the stub implementation.
  73.      * If this service has no port for the given interface,
  74.      * then ServiceException is thrown.
  75.      */
  76.     public java.rmi.Remote getPort(javax.xml.namespace.QName portName, Class serviceEndpointInterface) throws javax.xml.rpc.ServiceException {
  77.         if (portName == null) {
  78.             return getPort(serviceEndpointInterface);
  79.         }
  80.         java.lang.String inputPortName = portName.getLocalPart();
  81.         if ("StockQuotesSoap".equals(inputPortName)) {
  82.             return getStockQuotesSoap();
  83.         }
  84.         else  {
  85.             java.rmi.Remote _stub = getPort(serviceEndpointInterface);
  86.             ((org.apache.axis.client.Stub) _stub).setPortName(portName);
  87.             return _stub;
  88.         }
  89.     }
  90.     public javax.xml.namespace.QName getServiceName() {
  91.         return new javax.xml.namespace.QName("http://swanandmokashi.com", "StockQuotes");
  92.     }
  93.     private java.util.HashSet ports = null;
  94.     public java.util.Iterator getPorts() {
  95.         if (ports == null) {
  96.             ports = new java.util.HashSet();
  97.             ports.add(new javax.xml.namespace.QName("http://swanandmokashi.com", "StockQuotesSoap"));
  98.         }
  99.         return ports.iterator();
  100.     }
  101.     /**
  102.     * Set the endpoint address for the specified port name.
  103.     */
  104.     public void setEndpointAddress(java.lang.String portName, java.lang.String address) throws javax.xml.rpc.ServiceException {
  105.         
  106. if ("StockQuotesSoap".equals(portName)) {
  107.             setStockQuotesSoapEndpointAddress(address);
  108.         }
  109.         else 
  110. { // Unknown Port Name
  111.             throw new javax.xml.rpc.ServiceException(" Cannot set Endpoint Address for Unknown Port" + portName);
  112.         }
  113.     }
  114.     /**
  115.     * Set the endpoint address for the specified port name.
  116.     */
  117.     public void setEndpointAddress(javax.xml.namespace.QName portName, java.lang.String address) throws javax.xml.rpc.ServiceException {
  118.         setEndpointAddress(portName.getLocalPart(), address);
  119.     }
  120. }