2 Replies Latest reply on Mar 29, 2007 10:19 AM by Tom Baeyens

    many exception types or just 1 ?

    Tom Baeyens Master

      about exceptions:

      I know for sure that runtime exceptions are better for frameworks. They need to be properly documented, though.

      But I'm still in doubt wether we need many individual exception types or not. It boiles down to the question: 'Would our users ever want to make a distinction in the exception handling (catch clauses) ?'

      Afaict that is not the case so i'm inclined to go for just 1 single exception type. Of course, there might be situations where people want to distinguish exception types that i'm not aware of.

      What is your opinion?