public static void hasText(String text, String message) {
        if (!StringUtils.hasText(text)) {
            throw new IllegalArgumentException(message);
        }
    }
Assert that the given String has valid text content; that is, it must not
be <code>null</code> and must contain at least one non-whitespace character.
<pre class="code">Assert.hasText(name, "'name' must not be empty");</pre>

@param text    the String to check
@param message the exception message to use if the assertion fails
@see StringUtils#hasText
lang/src/main/java/org/apache/shiro/lang/util/Assert.java