1. /*
  2. * @(#)UnknownException.java 1.9 03/01/23
  3. *
  4. * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
  5. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  6. */
  7. /*
  8. * Licensed Materials - Property of IBM
  9. * RMI-IIOP v1.0
  10. * Copyright IBM Corp. 1998 1999 All Rights Reserved
  11. *
  12. * US Government Users Restricted Rights - Use, duplication or
  13. * disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  14. */
  15. package org.omg.CORBA.portable;
  16. /**
  17. * The org.omg.CORBA.portable.UnknownException is used for reporting
  18. * unknown exceptions between ties and ORBs and between ORBs and stubs.
  19. * It provides a Java representation of an UNKNOWN system exception
  20. * that has an UnknownExceptionInfo service context.
  21. * If the CORBA system exception org.omg.CORBA.portable.UnknownException
  22. * is thrown, then the stub does one of the following:
  23. * (1) Translates it to org.omg.CORBA.UNKNOWN.
  24. * (2) Translates it to the nested exception that the UnknownException contains.
  25. * (3) Passes it on directly to the user.
  26. */
  27. public class UnknownException extends org.omg.CORBA.SystemException {
  28. /**
  29. * A throwable--the original exception that was wrapped in a CORBA
  30. * UnknownException.
  31. */
  32. public Throwable originalEx;
  33. /**
  34. * Constructs an UnknownException object.
  35. * @param ex a Throwable object--to be wrapped in this exception.
  36. */
  37. public UnknownException(Throwable ex) {
  38. super("", 0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE);
  39. originalEx = ex;
  40. }
  41. }