Package org.ctan.site.services.util
Interface NullCheck
public interface NullCheck
The class
NullCheck contains the utility methods for treatment
of null values.-
Method Summary
Static MethodsModifier and TypeMethodDescriptionstatic BooleancopyNonNull(Boolean value) The methodcopyNonNullprovides means to create a copy without null values.static LongcopyNonNull(Long value) The methodcopyNonNullprovides means to create a copy without null values.static StringcopyNonNull(String value) The methodcopyNonNullprovides means to create a copy without null values.static LocalDateTimecopyNonNull(LocalDateTime value) The methodcopyNonNullprovides means to create a copy without null values.static UploadcopyNonNull(@NonNull Upload up) The methodcopyNonNullprovides means to create a shallow copy without null values.static Upload.TerminationStatusThe methodcopyNonNullprovides means to create a copy without null values.static StringThe methodisNotNullprovides means to check the value for null and throw aNullPointerExceptionif the value is null.static voidisNotNullObject(Object value, String msg) The methodisNotNullObjectprovides means to check the value for null and throw aNullPointerExceptionif the value is null.
-
Method Details
-
copyNonNull
The methodcopyNonNullprovides means to create a copy without null values.- Parameters:
value- the input- Returns:
- a shallow copy
-
copyNonNull
The methodcopyNonNullprovides means to create a copy without null values.- Parameters:
value- the input- Returns:
- a shallow copy
-
copyNonNull
The methodcopyNonNullprovides means to create a copy without null values.- Parameters:
value- the input- Returns:
- a shallow copy
-
copyNonNull
The methodcopyNonNullprovides means to create a copy without null values.- Parameters:
value- the input- Returns:
- a shallow copy
-
copyNonNull
The methodcopyNonNullprovides means to create a copy without null values.- Parameters:
value- the input- Returns:
- a shallow copy
-
copyNonNull
The methodcopyNonNullprovides means to create a shallow copy without null values.- Parameters:
up- the input- Returns:
- a shallow copy
-
isNotNull
The methodisNotNullprovides means to check the value for null and throw aNullPointerExceptionif the value is null.- Parameters:
value- the valuemsg- the name of the parameter- Returns:
- the value
-
isNotNullObject
The methodisNotNullObjectprovides means to check the value for null and throw aNullPointerExceptionif the value is null.- Parameters:
value- the valuemsg- the name of the parameter
-