[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Sat, 01 Mar 2003 16:02:25 -0800
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3b) Gecko/20030210
I just looked at a couple of classes (java.net.URI
and java.awt.GridBagLayout) and noticed lots of
unimplemented methods just do nothing or return null.
This has to stop. If an method does not do what it
is supposed to do, then it must throw an exception.
I'll make an exception for a method where you might
get semi-useful results if it isn't implemented
correctly, but if a class isn't anywhere close to
useful, it shouldn't pretend to be.
That raises the question: What exception to throw?
We could add a special gnu exception, but I suggest
public URI (String scheme, String ssp, String fragment)
throw new UnsupportedOperationException();
- unimplemented methods,
Per Bothner <=