public static void doesNotContain(String textToSearch, String substring, String message) {
        if (StringUtils.hasLength(textToSearch) && StringUtils.hasLength(substring) &&
                textToSearch.indexOf(substring) != -1) {
            throw new IllegalArgumentException(message);
        }
    }
Assert that the given text does not contain the given substring.
<pre class="code">Assert.doesNotContain(name, "rod", "Name must not contain 'rod'");</pre>
@param textToSearch the text to search
@param substring the substring to find within the text
@param message the exception message to use if the assertion fails
src/main/java/org/apache/shiro/lang/util/Assert.java