Package javax.xml.rpc

Examples of javax.xml.rpc.ServiceException


                if (seiFactory != null) {
                    return seiFactory.createServiceEndpoint();
                }
            }
        }
        throw new ServiceException("Unrecognized method name or argument list: " + method.getName());
    }
View Full Code Here


        Callback[] callbacks = new Callback[]{SerializableNoOp.INSTANCE, callback};
        Enhancer.registerCallbacks(serviceEndpointClass, callbacks);
        try {
            return (Remote) constructor.newInstance(new Object[]{serviceEndpoint});
        } catch (InvocationTargetException e) {
            throw (ServiceException)new ServiceException("Could not construct service instance", e.getTargetException()).initCause(e);
        }
    }
View Full Code Here

    }

    public Call[] getCalls(QName portName) throws ServiceException {

        if (portName == null)
            throw new ServiceException("Portname cannot be null");

        SEIFactory factory = (SEIFactory) portToImplementationMap.get(portName.getLocalPart());
        if( factory == null )
            throw new ServiceException("No port for portname: " + portName);

        OperationInfo[] operationInfos = factory.getOperationInfos();
        javax.xml.rpc.Call[] array = new javax.xml.rpc.Call[operationInfos.length];
        for (int i = 0; i < operationInfos.length; i++) {
            OperationInfo operation = operationInfos[i];
View Full Code Here

        if (portToImplementationMap.containsKey(portName)) {
            SEIFactory seiFactory = (SEIFactory) portToImplementationMap.get(portName);
            Remote port = seiFactory.createServiceEndpoint();
            return port;
        }
        throw new ServiceException("No port for portname: " + portName);
    }
View Full Code Here

        if (seiClassNameToFactoryMap.containsKey(className)) {
            SEIFactory seiFactory = (SEIFactory) seiClassNameToFactoryMap.get(className);
            Remote port = seiFactory.createServiceEndpoint();
            return port;
        }
        throw new ServiceException("no port for class " + className);
    }
View Full Code Here

      service1Control.setReturnValue(new RemoteBean());
    }

    public Service createService(QName qName) throws ServiceException {
      if (!"myNamespace".equals(qName.getNamespaceURI()) || !"myService1".equals(qName.getLocalPart())) {
        throw new ServiceException("not supported");
      }
      serviceCount++;
      return service1;
    }
View Full Code Here

    public Service createService(URL url, QName qName) throws ServiceException {
      try {
        if (!(new URL("http://myUrl1")).equals(url) || !"".equals(qName.getNamespaceURI()) ||
            !"myService2".equals(qName.getLocalPart())) {
          throw new ServiceException("not supported");
        }
      }
      catch (MalformedURLException ex) {
      }
      serviceCount++;
View Full Code Here

    public Service loadService(URL url, QName qName, Properties props) throws ServiceException {
      try {
        if (!(new URL("http://myUrl1")).equals(url) || !"".equals(qName.getNamespaceURI()) ||
            !"myService2".equals(qName.getLocalPart())) {
          throw new ServiceException("not supported");
        }
      }
      catch (MalformedURLException ex) {
      }
      if (props == null || !"myValue".equals(props.getProperty("myKey"))) {
        throw new ServiceException("invalid properties");
      }
      serviceCount++;
      return service1;
    }
View Full Code Here

      return service1;
    }

    public Service loadService(Class ifc) throws ServiceException {
      if (!IRemoteBean.class.equals(ifc)) {
        throw new ServiceException("not supported");
      }
      serviceCount++;
      return service2;
    }
View Full Code Here

    }

    public Service loadService(URL url, Class ifc, Properties props) throws ServiceException {
      try {
        if (!(new URL("http://myUrl1")).equals(url) || !IRemoteBean.class.equals(ifc)) {
          throw new ServiceException("not supported");
        }
      }
      catch (MalformedURLException ex) {
      }
      if (props == null || !"myValue".equals(props.getProperty("myKey"))) {
        throw new ServiceException("invalid properties");
      }
      serviceCount++;
      return service1;
    }
View Full Code Here

TOP

Related Classes of javax.xml.rpc.ServiceException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.