Package com.priint.pubserver.exception
Class NullArgumentException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- java.lang.IllegalArgumentException
-
- com.priint.pubserver.exception.NullArgumentException
-
- All Implemented Interfaces:
java.io.Serializable
public class NullArgumentException extends java.lang.IllegalArgumentExceptionThrown if input validation fails. This is a runtime exception. It is a special case of anIllegalArgumentExceptionthat signalsnullarguments.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description NullArgumentException()Default constructor.NullArgumentException(java.lang.Object caller, int errorCode, java.lang.String message, java.lang.Throwable cause, java.lang.String... parameters)Instantiates a new Null argument exception.NullArgumentException(java.lang.String variableName)NullArgumentException(java.lang.String variableName, java.lang.String message)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetCode()ErrorCodeInfogetErrorCodeInfo()This methods returns ErrorCodeInfo object.java.util.List<ErrorStackInfo>getErrorsStack()This method returns list of ErrorStackInfo, the list is not filled automatically.java.lang.StringgetModule()java.lang.String[]getParameters()voidretrieveErrorCodeInfo()Sets errorCodeInfo objectvoidretrieveErrorsStack()Sets errorsStack list
-
-
-
Constructor Detail
-
NullArgumentException
public NullArgumentException(java.lang.Object caller, int errorCode, java.lang.String message, java.lang.Throwable cause, java.lang.String... parameters)Instantiates a new Null argument exception.- Parameters:
caller- the callererrorCode- the error codemessage- the messagecause- the causeparameters- the parameters
-
NullArgumentException
public NullArgumentException()
Default constructor. It is recommended to useNullArgumentException(String)instead.
-
NullArgumentException
public NullArgumentException(java.lang.String variableName)
- Parameters:
variableName- name of the argument that should not be null.
-
NullArgumentException
public NullArgumentException(java.lang.String variableName, java.lang.String message)- Parameters:
variableName- name of the argument that should not be empty or null.message- the error message.
-
-
Method Detail
-
getCode
public int getCode()
-
getModule
public java.lang.String getModule()
-
getErrorsStack
public java.util.List<ErrorStackInfo> getErrorsStack()
This method returns list of ErrorStackInfo, the list is not filled automatically. To fill this list you need to call setErrorsStack() method manually.- Returns:
-
retrieveErrorsStack
public void retrieveErrorsStack()
Sets errorsStack list
-
getErrorCodeInfo
public ErrorCodeInfo getErrorCodeInfo()
This methods returns ErrorCodeInfo object. This object is not filled automatically. To set this object you must call setErrorCodeInfo();- Returns:
-
retrieveErrorCodeInfo
public void retrieveErrorCodeInfo()
Sets errorCodeInfo object
-
getParameters
public java.lang.String[] getParameters()
-
-