1. /*
  2. * @(#)AddressingDispositionException.java 1.4 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. package com.sun.corba.se.internal.iiop;
  8. import com.sun.corba.se.internal.iiop.messages.KeyAddr;
  9. /**
  10. * This exception is thrown while reading GIOP 1.2 Request, LocateRequest
  11. * to indicate that a TargetAddress disposition is unacceptable.
  12. * If this exception is caught explicitly, this need to be rethrown. This
  13. * is eventually handled within RequestPRocessor and an appropriate reply
  14. * is sent back to the client.
  15. *
  16. * GIOP 1.2 allows three dispositions : KeyAddr (ObjectKey), ProfileAddr (ior
  17. * profile), IORAddressingInfo (IOR). If the ORB does not support the
  18. * disposition contained in the GIOP Request / LocateRequest 1.2 message,
  19. * then it sends a Reply / LocateReply indicating the correct disposition,
  20. * which the client ORB shall use to transparently retry the request
  21. * with the correct disposition.
  22. *
  23. */
  24. public class AddressingDispositionException extends RuntimeException {
  25. private short expectedAddrDisp = KeyAddr.value;
  26. public AddressingDispositionException(short expectedAddrDisp) {
  27. this.expectedAddrDisp = expectedAddrDisp;
  28. }
  29. public short expectedAddrDisp() {
  30. return this.expectedAddrDisp;
  31. }
  32. }