Results 1 to 2 of 2

Thread: Is there any standard exception that can contain an Object rather than Throwable?

Hybrid View

  1. #1
    Join Date
    Sep 2004
    Posts
    346

    Default Is there any standard exception that can contain an Object rather than Throwable?

    Is there any standard exception that can contain an Object rather than Throwable? i.e some exception interface that has getObject() method?

  2. #2
    Join Date
    Jan 2005
    Location
    Bucharest, Romania
    Posts
    5,403

    Default

    Are you talking about Spring or java in general?
    What should the getObject() return? Throwables already provide much of the things you need - a message, a cause and the exception itself.
    You can wrap objects if you want inside a custom exception.
    Costin Leau
    SpringSource - http://www.SpringSource.com- Spring Training, Consulting, and Support - "From the Source"
    http://twitter.com/costinl
    Please use [ c o d e ] [ / c o d e ] tags

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •