On Thursday 10 February 2005 11:05, Xavier Poinsard wrote:
> > I don't know, it doesn't seem all that useful. Anyone doing real
> > development will surely know what function they are calling and
> > will have the stacktrace handy. If we find out that Crystal
> > Reports or other applications only return the error message with
> > no context then we should probably do something about it. For now
> > I believe time would be better spent actually implementing these
> > methods.
>
> Sure, but they are a lot of methods to implement and if we want to
> fix quickly the functions used by Crystal reports (for example),
> without stack trace, it is the only simple way.
I haven't been following this thread very closely. Excuse me if I'm
totally off base here.
I assume you're talking about this method in org.postgresql.Driver:
public static SQLException notImplemented()
{
return new PSQLException(GT.tr("This method is not yet implemented."), PSQLState.NOT_IMPLEMENTED);
}
I agree with Kris that there is no need to include the method name in
the exception. It is already shown in the stack trace.
However, you can easily patch this method so that it includes the
caller's method name in its error message. All you have to do is peek
one level up the stack trace.