Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4398872

Throwable needs getWrappedException() method

    XMLWordPrintable

    Details

    • Type: Enhancement
    • Status: Closed
    • Priority: P3
    • Resolution: Duplicate
    • Affects Version/s: 1.3.0
    • Fix Version/s: None
    • Component/s: core-libs
    • Labels:
    • Subcomponent:
    • CPU:
      generic
    • OS:
      generic

      Description



      Name: krC82822 Date: 12/16/2000


      It is common practice among Java developers to wrap exceptions. See the SAX
      API's SaxException for an example. If Throwable had a method
      getNextException() or getWrappedException() or maybe getWrappedThrowable(),
      it would make dealing with wrapped exceptions in a generic way very easy.

      The default implementation in Throwable would return null.
      So all we are asking for is three lines in java.lang.Throwable:

      public Throwable getWrappedThrowable(){
        return null;
      }


      (or getWrappedException() equivalent)


      (Review ID: 113916)
      ======================================================================

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              jjb Josh Bloch
              Reporter:
              kryansunw Kevin Ryan (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: