public class NullArgumentException extends NullPointerException
NullPointerException in order to stress out that
the error is an illegal argument rather than an unexpected usage of a null pointer
inside a method body.
IllegalArgumentException.
However NullPointerException has become a more widely adopted practice and
is now the recommended one in the Effective Java book.ArgumentChecks.ensureNonNull(String, Object),
Serialized FormDefined in the sis-utility module
| Constructor and Description |
|---|
NullArgumentException()
Constructs an exception with no detail message.
|
NullArgumentException(String message)
Constructs an exception with the specified detail message.
|
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toStringpublic NullArgumentException()
public NullArgumentException(String message)
message - the detail message.Copyright © 2010–2017 The Apache Software Foundation. All rights reserved.