Docs Menu
API Developer Guide / middleware / pub / string / NullOrWhiteSpc

Service: NullOrWhiteSpc

This service is responsible for checking whether a given string is null or consists only of whitespace characters.

Input Parameter:

Name Type Description
text: String Input String to be checked for null or whitespaces
ifPresent: Boolean An optional boolean parameter that, when set to true, indicates that the service should check for the presence of non-whitespace characters in the string

Output Parameter:

Name Type Description
result: Boolean A boolean value indicating the result of the check. If the input string is null or consists only of whitespace characters (if ifPresent is set to true), the result will be true. Otherwise, it will be false.
text: String The original input string provided for reference. This is the same input string provided in the input parameters.