Package java.rmi.server

Examples of java.rmi.server.ExportException


  throws ExportException
    {
  if (impl == null) {
      throw new NullPointerException("impl cannot be null");
  } else if (!(impl instanceof ActivationSystem)) {
      throw new ExportException("cannot create dispatcher",
              new IllegalArgumentException(
            "impl must be an ActivationSystem"));
  }
  return new SystemAccessILFactory.SystemDispatcher(
            methods, impl, caps,
View Full Code Here


  public synchronized Remote export(Remote impl) throws ExportException {
      this.impl = impl;
      try {
    return RemoteObject.toStub(impl);
      } catch (NoSuchObjectException e) {
    throw new ExportException("no stub found", e);
      }
  }
View Full Code Here

     * be more than one object table.
     *
     * Unsynchronized method.
     */
    void procRequestDispatchers() throws ExportException{
        if (exported) throw new ExportException("Target already exported");
        int i = 0;
        try {
            for (i = 0; i < requestDispatchers.length; i++) {
                requestDispatchers[i].put(this);
            }
View Full Code Here

     * after construction, prior to setExport.
     *
     * @param implRef
     */
    void setImplRef(ImplRef implRef) throws ExportException{
        if (exported) throw new ExportException("Target already exported");
        this.implRef = implRef;
    }
View Full Code Here

     * It should not be called if the object has been unexported.
     *
     * Unsynchronized method.
     */
    void setExported() throws ExportException{
        if (exported) throw new ExportException("Target already exported");
        if (unexported == true) throw new ExportException("Target cannot be re-exported");
        if (implRef == null) throw new ExportException("ImplRef cannot be null");
        if (success == false) throw new ExportException("RequestDispatchers unsuccessful");
        exported = true;
        if (keepAlive){
            keepAliveCount.incrementKeepAliveCount();
        }
    }
View Full Code Here

  } catch (InvocationTargetException e) {
      Throwable t = e.getTargetException();
      if (t instanceof ExportException) {
    throw (ExportException) t;
      } else if (t instanceof RemoteException) {
    throw new ExportException("export failed", (Exception) t);
      } else if (t instanceof RuntimeException) {
    throw (RuntimeException) t;
      } else if (t instanceof Error) {
    throw (Error) t;
      } else {
View Full Code Here

  throws ExportException
    {
  if (impl == null) {
      throw new NullPointerException("impl cannot be null");
  } else if (!(impl instanceof ActivationSystem)) {
      throw new ExportException("cannot create dispatcher",
              new IllegalArgumentException(
            "impl must be an ActivationSystem"));
  }
  return new SystemDispatcher(methods, impl, caps,
            getServerConstraints(),
View Full Code Here

               handler);
      success = true;
      return proxy;
     
  } catch (IllegalArgumentException e) {
      throw new ExportException("proxy creation failed", e);
     
  } finally {
      if (!success) {
    unexport(true);
      }
View Full Code Here

      /*
       * Complain if the underlying proxy has a non-public class and
       * implements non-public interfaces.
       */
      if (checkPublic && !Modifier.isPublic(intf.getModifiers())) {
    throw new ExportException(
        "proxy implements non-public interface");
      }
     
      /*
       * Don't add ProxyTrust remote interface to list of proxy
View Full Code Here

      throw new NullPointerException("impl is null");
  }
  try {
      return Util.getRemoteInterfaces(impl.getClass());
  } catch (IllegalArgumentException e) {
      throw new ExportException("cannot get proxy interfaces", e);
  }
    }
View Full Code Here

TOP

Related Classes of java.rmi.server.ExportException

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.