The spec for java.util.UnknownFormatConversionException declares: "Unless otherwise specified, passing a null argument to any method or constructor in this class will cause a NullPointerException to be thrown."
But the constructor
public UnknownFormatConversionException(String s)
does not throw an exception if it is called with null argument.
For example, the following code:
try {
new java.util.UnknownFormatConversionException(null);
System.out.println("FAILURE");
} catch (NullPointerException npe) {
System.out.println("OKAY");
}
Produces the following printout:
FAILURE
###@###.### 2005-05-05 15:42:49 GMT
But the constructor
public UnknownFormatConversionException(String s)
does not throw an exception if it is called with null argument.
For example, the following code:
try {
new java.util.UnknownFormatConversionException(null);
System.out.println("FAILURE");
} catch (NullPointerException npe) {
System.out.println("OKAY");
}
Produces the following printout:
FAILURE
###@###.### 2005-05-05 15:42:49 GMT